-
Use pic as slave in I2C
Hello,
is it possible to store data in a Pic eeprom to be read from another Pic?
I'd like to have a pic as a slave in a I2C network and another one as a master reading and possibly writing onto pic slave memory.
I have few data to be shared between the pics.
Thanks.
-
You asked a variation of this question before - back in May 2005. The answer is still the same as then... PICBasic does not support I2CSlave mode. You have to create your own routines to do that.
-
There is an example of doing I2C Slave in PBP in the examples on MELABS website here http://www.picbasic.com/resources/samples.htm, just download the I2CSLAVE.BAS and I2CMAST.BAS and try them out. These samples are for the 16F877A but with some modification they do work on the 18F452 and serveral other PIC MCUs.