LibTiePie
0.9.13
Library for interfacing TiePie engineering instruments
|
Functions to setup and control I2C hosts.
All I2C host related functions require an I2C host handle to identify the I2C host, see opening a device.
Some I2C addresses may be reserved for internal use in the instrument, these addresses can not be controlled via the I2C host routines. Use I2CIsInternalAddress() to check whether an address is used internally.
Modules | |
Reading data | |
Functions to read data from an I2C device. | |
Writing data | |
Functions to write data to an I2C device. | |
Writing/reading data | |
Functions to write and read data to/from an I2C device. | |
Speed | |
Functions to control the I2C clock speed. | |
Functions | |
bool8_t | I2CIsInternalAddress (LibTiePieHandle_t hDevice, uint16_t wAddress) |
Check whether an address is used internally. More... | |
uint32_t | I2CGetInternalAddresses (LibTiePieHandle_t hDevice, uint16_t *pAddresses, uint32_t dwLength) |
Get all addresses which are used internally. More... | |
bool8_t I2CIsInternalAddress | ( | LibTiePieHandle_t | hDevice, |
uint16_t | wAddress | ||
) |
Check whether an address is used internally.
[in] | hDevice | A device handle identifying the I2C host. |
[in] | wAddress | An I2C device address. |
INVALID_HANDLE | The handle is not a valid I2C host handle. |
OBJECT_GONE | The object indicated by the handle is no longer available. |
LIBRARY_NOT_INITIALIZED | The library is not initialized, see LibInit(). |
SUCCESS | The function executed successfully. |
uint32_t I2CGetInternalAddresses | ( | LibTiePieHandle_t | hDevice, |
uint16_t * | pAddresses, | ||
uint32_t | dwLength | ||
) |
Get all addresses which are used internally.
[in] | hDevice | A device handle identifying the I2C host. |
[out] | pAddresses | A pointer to an array for the addresses. |
[in] | dwLength | The number of elements in the array. |
INVALID_HANDLE | The handle is not a valid I2C host handle. |
OBJECT_GONE | The object indicated by the handle is no longer available. |
LIBRARY_NOT_INITIALIZED | The library is not initialized, see LibInit(). |
SUCCESS | The function executed successfully. |