PCA9536
Driver for PCA9536 4-bit I2C IO pin expander.
Protected Attributes
Type
Name
I2C
Public Functions
Type
Name
int
int
int
int
int
int
int
int
Protected Functions
Type
Name
int
int
Protected Attributes Documentation
variable _i2c
Public Functions Documentation
function PCA9536
function set_all_inputs
Set port as input.
Returns:
0 on success; non-0 on fail
function set_all_outputs
Set port as output.
Returns:
0 on success; non-0 on fail
function set_output
Set pin as output.
Parameters:
pin pin number to set as output (0 - 3)
Returns:
0 on success; -2 on invalid pin; non-0 on fail
function set_input
Set pin as input.
Parameters:
pin pin number to set (0 - 3)
Returns:
0 on success; -2 on invalid pin; non-0 on fail
function set_value
Set port value.
Parameters:
value value to set on port (0 - F)
Returns:
0 on success; non-0 on fail
function set_value
Set pin value.
Parameters:
pin pin number to set (0 - 3)
pin value to set (0 or 1)
Returns:
0 on success; -2 on invalid pin; non-0 on fail
function get_value
Get port value.
Parameters:
value pointer to byte to read the value in to
Returns:
0 on success; non-0 on fail
function get_value
Get pin value.
Parameters:
pin pin to read
value pointer to byte to read the value in to
Returns:
0 on success; -2 on invalid pin; non-0 on fail
Protected Functions Documentation
function _write_reg
function _read_reg
The documentation for this class was generated from the following file: D:/w/hw-libs/\_libs\_/libraries/PCA9536.h
Last updated