This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to connect 8051 as a slave device through I2C

Hi friends,

I have interfaced EEPROM and RTC with AT89C51 through I2C .Now i am trying to interface another AT89C51 as a slave device.In that i am having two issues

NO1:If I2C Bus needs any External Pull up Resistors ?
I am not having clear idea whether i can connect SDA(Serial Data pin) & SCL(Serial Clock pin ) directly to Master controller from Slave controller.Because while i am connecting EEROM i put 2.2k pull up resistor to SDA&SCL , also i know that in AT89C51 only P0 (port 0) is alone open collector. but here i am using P3 .

NO2:How to deal with I2C driver in Slave 8051?
Do u have any documents that how to write slave side program or web links.. for the same. because when i am searching i found plenty of documents only describing Master side programming. But i need details about slave side programming which is in Bit banking method.

Please share your experience and give good Web Links & Documents

Thanks & Regards,
Kirba

Parents
  • Do u have any documents that how to write slave side program or web links..
    I do not know if 'micro' (u) does, I do not

    But i need details about slave side programming which is in Bit banking method.
    Bit-banging a master is fairly simple, bit-banging a slave is a true ***, are you surte you are up to it. There are derivatives (such as the NXP LPCs) that are very cheap and have hardware IIC, use one such and save yourself the cost of a bottle of aspirin.

    Erik

Reply
  • Do u have any documents that how to write slave side program or web links..
    I do not know if 'micro' (u) does, I do not

    But i need details about slave side programming which is in Bit banking method.
    Bit-banging a master is fairly simple, bit-banging a slave is a true ***, are you surte you are up to it. There are derivatives (such as the NXP LPCs) that are very cheap and have hardware IIC, use one such and save yourself the cost of a bottle of aspirin.

    Erik

Children