Description Register a function to be called when a master requests data from this slave device. Parameters handler: the function to be called, takes no parameters and returns nothing, e.g.: void myHandler() Returns None See also - Wire.onReceive() Libraries Reference Home The text of the 86Duino reference is a modification of the Arduino reference, and […]
Description Registers a function to be called when a slave device receives a transmission from a master. Parameters handler: the function to be called when the slave receives data; this should take a single int parameter (the number of bytes read from the master) and return nothing, e.g.: void myHandler(int numBytes) Returns None See also […]
Description Reads a byte that was transmitted from a slave device to a master after a call to requestFrom() or was transmitted from a master to a slave. read() inherits from the Stream utility class. Syntax Wire.read() Parameters none Returns The next byte received Example Libraries Reference Home The text of the 86Duino reference is […]
Description Returns the number of bytes available for retrieval with read(). This should be called on a master device after a call to requestFrom() or on a slave inside the onReceive() handler. available() inherits from the Stream utility class. Parameters None Returns The number of bytes available for reading. See also - Wire.read() - Stream.available() […]
Description Writes data from a slave device in response to a request from a master, or queues bytes for transmission from a master to slave device (in-between calls to beginTransmission() and endTransmission()). Syntax Wire.write(value) Wire.write(string) Wire.write(data, length) Parameters value: a value to send as a single byte string: a string to send as a series […]
Description Ends a transmission to a slave device that was begun by beginTransmission() and transmits the bytes that were queued by write(). endTransmission() accepts a boolean argument (stop) changing its behavior for compatibility with certain I2C devices. If true, endTransmission() sends a stop message after transmission, releasing the I2C bus. If false, endTransmission() sends a […]
Description Begin a transmission to the I2C slave device with the given address. Subsequently, queue bytes for transmission with the write() function and transmit them by calling endTransmission(). Parameters address: the 7-bit address of the device to transmit to Returns None See also - Wire.write() - Wire.endTransmission() Libraries Reference Home The text of the 86Duino […]
Description Used by the master to request bytes from a slave device. The bytes may then be retrieved with the available() and read() functions. requestFrom() accepts a boolean argument (stop) changing its behavior for compatibility with certain I2C devices. If true, requestFrom() sends a stop message after the request, releasing the I2C bus. If false, […]
Description Initiate the Wire library and join the I2C bus as a master or slave. This should normally be called only once. Parameters address: the 7-bit slave address (optional); if not specified, join the bus as a master. Returns None Libraries Reference Home The text of the 86Duino reference is a modification of the Arduino […]
Description Gets the port of the remote UDP connection. This function must be called after UDP.parsePacket(). Syntax UDP.remotePort(); Parameters None Returns The port of the host who sent the current incoming packet Libraries Reference Home The text of the 86Duino reference is a modification of the 86Duino reference, and is licensed under a Creative Commons […]