Let me get this straight ...
A read op from DS3231 must be in this form I think ...
i2cREAD SDA,SCL,%11010001,$00,var
Am I mistaken ?
Let me get this straight ...
A read op from DS3231 must be in this form I think ...
i2cREAD SDA,SCL,%11010001,$00,var
Am I mistaken ?
- Ipsa scientia potestas est -
from the book
I2CREAD DataPin, ClockPin, Control,{Address,}[Var{,Var...}]{,Label}
again
from the book (i2cread)
The upper 7 bits of the
Control byte contain the control code along with chip select
or additional address information, depending on the particular device. The low
order bit is an internal flag indicating whether it is a read or write command and
should be kept clear.
So there is no use of the lsb of the control bit , then it's determined by the command's itself ... I mean if it is I2CREAD op then it automatically determines this bit itself ... Am I correct ? I'll give it a try once more by using
At least I may read the control or the status register ...Code:i2cREAD SDA,SCL,%11010000,$00,var
Thanks ..![]()
- Ipsa scientia potestas est -
I don't want to be rude but RTFM, p.156:
Pull-up resistors are mandatory for I2C. Keep trying, the DS3231 has nice features like alarms and is more accurate than the DS1307.The Address size sent (byte or word) is determined by the size of the variable that is used. If a byte-sized variable is used for the Address, an 8-bit address is sent. If a word-sized variable is used, a 16-bit address is sent. Be sure to use the proper sized variable for the device you wish to communicate with. Constants should not be used for the Address as the size can vary dependent on the size of the constant. Also, expressions should not be used as they can cause an improper Address size to be sent.
Bookmarks