Hey all,
I'm interfacing a Max5477 digital pot to a PIC16F627 with PicBasic Pro V2.47. It took me a bit to get it to work and the problem I see is that the I2CWRITE command's subsequent statements (DataPin, ClockPin, Control, Address, Value) don't work in the order that they're published. In order to get it to work I have to enter it like this:
I2cwrite PortA.6, PortA.2, Control_NVreg, value, Address
ie. I have to swap the Value and Address statement to get it to work.
With:
Control_NVreg = %00100001
Value = %10000000
Address = %01010010
In all the other I2C posts I looked at everyone is using it in the published order.
Does anyone have a clue why mine is messed up?
Mark
Bookmarks