Hi,
Maybe just first try a simple i2c bus scan to see if the chip answers. Something like:
[code:1:38a2b4dcbc]For Temp_byte = 0 To 254 Step 2 'Scan every even address
I2cstart 'Ping chip
I2cwbyte Temp_byte 'get result
If Err = 0 Then 'err=hw problem
Print #1 , Temp_byte ; "," ; 'no error so device
End If 'ie. no i2c device
I2cstop 'stop bus
Next Temp_byte 'loop through each sensor[/code:1:38a2b4dcbc]
When that works, check the specs again. Without reading the chip specs it's hard to say if something is wrong, the only thing I see is the i2cstart in the middle of the transaction, shouldn't that be a stop/start or repstart?
Regards
Ian Dobson
↧