jamespollard
Posts: 5
Joined: Sat Jan 11, 2014 9:49 pm

wiringPi I2C Read

Fri Jan 17, 2014 4:17 pm

I am having some trouble using the wiringPiI2C library to read data off an MCP3424 chip.

There are two chips, 0x68 and 0x69, I am connecting to via an I2C link.

Each chip has channels 1-4, 0x98, 0x9B, 0x9D and 0x9E, respectively.

Does anybody know how can I perform a wiringPiI2CRead or wiringPiI2CReadReg8/16 function using this information.

gbarnes59
Posts: 4
Joined: Sun Mar 30, 2014 11:15 am

Re: wiringPi I2C Read

Tue Jun 02, 2015 10:38 am

Did you get anywhere with this?
I'm using the WiringPi library with the MCP3422 extension (the documentation says it will work with MCP3424)
It seems to set up OK, but the analogRead function hangs.
Similarly, when I test it with the GPIO aread facility it hangs.

My setup command is mcp3422Setup (1920, 104, MCP3422_SR_15, MCP3422_GAIN_1) ;

The read command is analogRead(1920 + channel); (channel is 0- 3)

I'm really stumped on this one.

Return to “Interfacing (DSI, CSI, I2C, etc.)”