<< Previous | Next >> | |
|
Description
- Initiates I2C transmission by sending the start sequence, which is defined as a high to low transition on SDA while SCL is high. The point being that SDA is supposed to remain stable while SCL is high. If it does not, then that indicates a start (S) or stop (P) condition. This function first waits for possible clock stretching, which is when a bus peripheral holds SCK low.
- This function is essentially the same as
i2c_start_tx()
with the addition of a clock stretch delay, which is 2000 "counts," inserted after the start sequence. (A count is an iteration through a loop.)Return value
0
: Success.
-1
: Clock stretching timeout.Library
- I2C.LIB
See also
- Technical Note 215, Using the I2C Bus with a Rabbit Microprocessor.
Dynamic C Functions | << Previous | Next >> | rabbit.com |