Author Topic: I2C Slave address acknowledge problem  (Read 656 times)

0 Members and 1 Guest are viewing this topic.

Offline rill17

  • Contributor
  • Posts: 15
  • Country: mt
I2C Slave address acknowledge problem
« on: December 27, 2015, 01:07:11 AM »
hi, i'm using an lpc1115 board to interface with a gyroscope/accelerometer board and I am sending the correct device id however am failing to recieve an acknowledge from the board. i am using the lpc1115 as the master and the following is my code. i am also generating an  interrupt each 100ms so as to update the registers each 100ms. i verified that the slave address is 0x68 by using a scope, connections were verified to be correct several times and i am using 10k pull up ressistors with the SDA and SCL lines. the following is a link to the accelerometer/gryro board

Please Help, thanks
« Last Edit: December 27, 2015, 06:12:14 AM by rill17 »

Offline Gixy

  • Regular Contributor
  • *
  • Posts: 173
  • Country: fr
Re: I2C Slave address acknowledge problem
« Reply #1 on: December 27, 2015, 10:53:46 AM »
I don't see your code but a common mistake is to think that the slave address is expressed as a byte: it is a 7 bit word, which should be followed by the direction bit (0=write, 1=read). In your case, 0x68 gives the 7 first bits of the byte. You should then send 0xD0 to write something to the device, and 0xD1 to read something (this assuming your device is configured with pin 9 low, if not the 7 bit adress will be 0x69). Hope this helps.

Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo