class TwoWire : public Stream;
class TwoWire : public Stream;
TwoWire class interface enables LinkIt ONE to connect to other devices through I2C/TWI bus. It occupies pin D18 (SDA) as the serial data wire and pin D19 (SCL) as the serial clock wire.
Wire.h
|
Method |
Description |
|
Sets up the host address for I2C communication. LinkIt ONE supports void TwoWire:begin(void), which means the I2C bus is joined as a host. To use the Wire library, under normal conditions, this function must be called and called only once. | |
|
Enables the communication with the slave at an assigned address. After that, the data are written by using write()and transmitted by using endTransmission(). | |
|
Enables the communication with the slave at an assigned address. After that, the data are written by using write() and transmitted by using endTransmission(). | |
|
Ends the communication with the slave assigned by beginTransmission() and transmits the data buffered by write() to the slave. | |
|
Reads a byte of data which are sent from master to slave or from slave to master. The master makes requests by using requestFrom(). | |
|
This function writes data into the queue and is called between functions beginTransmission()and endTransmission(). | |
|
|