I'm new to netburner and am trying to get the I2C bus to talk to an AtoD chip. Seems fairly straight forward but I get a "Failed to read error: 9" when I try the sample "Mod5270 I2C2Serial" program that came with the board. I am running only one netburner module so I have the "#include "i2cmaster.h" " code uncommented and I just took out the other code relating to multi master mode.
I don't know where these errors are to be found in the documentation. I believe I have the hardware hooked up correctly with the pullup resistors, etc. I had to change the while statement so that my address of 91 Hex was valid.
I2C
Re: I2C
I2C functions with "#include "i2cmaster.h" operate correctly with my mod5270 together with at24c64b EEPROM together with Rel22_rc2.
Of course, I call the I2C functions from the custom at24c64b specific module (which cares I2C address, page write, etc).
I didn't try to use the "Mod5270 I2C2Serial" program that came with the board.
Of course, I call the I2C functions from the custom at24c64b specific module (which cares I2C address, page write, etc).
I didn't try to use the "Mod5270 I2C2Serial" program that came with the board.
Yevgeni Tunik
Embedded/RealTime software engineer
https://www.linkedin.com/in/yevgenitunik/
________________________
Embedded/RealTime software engineer
https://www.linkedin.com/in/yevgenitunik/
________________________
Re: I2C
Hello,
I just answered this ticket in the NetBurner support queue but this might be a helpful solution to post for the group. I2C only has seven bit addressing. Some data sheets will show the R/W bit as the least significant bit in an address but this is not truly part of the address. Shift this whole address word over 1 bit to the right to get the real I2C address. The NetBurner I2C functions will automatically control the R/W bit.
-Larry
I just answered this ticket in the NetBurner support queue but this might be a helpful solution to post for the group. I2C only has seven bit addressing. Some data sheets will show the R/W bit as the least significant bit in an address but this is not truly part of the address. Shift this whole address word over 1 bit to the right to get the real I2C address. The NetBurner I2C functions will automatically control the R/W bit.
-Larry