|
#define LowspeedRead |
( |
_port, |
|
|
_buflen, |
|
|
_buffer, |
|
|
_result |
|
) |
__lowspeedRead(_port, _buflen, _buffer, _result) |
Read lowspeed data.
Read the specified number of bytes from the I2C device on the specified port and store the bytes read in the byte array buffer provided. The maximum number of bytes that can be written or read is 16.
- Parameters:
-
| _port | The port to which the I2C device is attached. See the NBC Input port constants group. You may use a constant or a variable. Constants should be used where possible to avoid blocking access to I2C devices on other ports by code running on other threads. |
| _buflen | The initial size of the output buffer. |
| _buffer | A byte array that contains the data read from the internal I2C buffer. If the return value is negative then the output buffer will be empty. |
| _result | A status code indicating whether the write completed successfully or not. See TCommLSRead for possible Result values. If the return value is NO_ERR then the last operation did not cause any errors. |
- See also:
- LowspeedWrite, LowspeedCheckStatus, LowspeedBytesReady, and LowspeedStatus
|