![]() |
LibDriver PCF8574
|
pcf8574 base driver modules More...
Data Structures | |
| struct | pcf8574_handle_s |
| pcf8574 handle structure definition More... | |
| struct | pcf8574_info_s |
| pcf8574 information structure definition More... | |
Typedefs | |
| typedef struct pcf8574_handle_s | pcf8574_handle_t |
| pcf8574 handle structure definition | |
| typedef struct pcf8574_info_s | pcf8574_info_t |
| pcf8574 information structure definition | |
Enumerations | |
| enum | pcf8574_address_t { PCF8574_ADDRESS_A000 = 0 , PCF8574_ADDRESS_A001 = 1 , PCF8574_ADDRESS_A010 = 2 , PCF8574_ADDRESS_A011 = 3 , PCF8574_ADDRESS_A100 = 4 , PCF8574_ADDRESS_A101 = 5 , PCF8574_ADDRESS_A110 = 6 , PCF8574_ADDRESS_A111 = 7 } |
| pcf8574 address enumeration definition More... | |
| enum | pcf8574_pin_t { PCF8574_PIN_0 = 0x00 , PCF8574_PIN_1 = 0x01 , PCF8574_PIN_2 = 0x02 , PCF8574_PIN_3 = 0x03 , PCF8574_PIN_4 = 0x04 , PCF8574_PIN_5 = 0x05 , PCF8574_PIN_6 = 0x06 , PCF8574_PIN_7 = 0x07 } |
| pcf8574 pin enumeration definition More... | |
| enum | pcf8574_pin_level_t { PCF8574_PIN_LEVEL_LOW = 0x00 , PCF8574_PIN_LEVEL_HIGH = 0x01 } |
| pcf8574 pin enumeration definition More... | |
Functions | |
| uint8_t | pcf8574_info (pcf8574_info_t *info) |
| get chip's information | |
| uint8_t | pcf8574_set_addr_pin (pcf8574_handle_t *handle, pcf8574_address_t addr_pin) |
| set the address pin | |
| uint8_t | pcf8574_get_addr_pin (pcf8574_handle_t *handle, pcf8574_address_t *addr_pin) |
| get the address pin | |
| uint8_t | pcf8574_init (pcf8574_handle_t *handle) |
| initialize the chip | |
| uint8_t | pcf8574_deinit (pcf8574_handle_t *handle) |
| close the chip | |
| uint8_t | pcf8574_read (pcf8574_handle_t *handle, pcf8574_pin_t pin, pcf8574_pin_level_t *level) |
| read the pin | |
| uint8_t | pcf8574_write (pcf8574_handle_t *handle, pcf8574_pin_t pin, pcf8574_pin_level_t level) |
| write the pin | |
pcf8574 base driver modules
| typedef struct pcf8574_handle_s pcf8574_handle_t |
pcf8574 handle structure definition
| typedef struct pcf8574_info_s pcf8574_info_t |
pcf8574 information structure definition
| enum pcf8574_address_t |
pcf8574 address enumeration definition
Definition at line 62 of file driver_pcf8574.h.
| enum pcf8574_pin_level_t |
pcf8574 pin enumeration definition
| Enumerator | |
|---|---|
| PCF8574_PIN_LEVEL_LOW | low level |
| PCF8574_PIN_LEVEL_HIGH | high level |
Definition at line 92 of file driver_pcf8574.h.
| enum pcf8574_pin_t |
pcf8574 pin enumeration definition
| Enumerator | |
|---|---|
| PCF8574_PIN_0 | pin 0 |
| PCF8574_PIN_1 | pin 1 |
| PCF8574_PIN_2 | pin 2 |
| PCF8574_PIN_3 | pin 3 |
| PCF8574_PIN_4 | pin 4 |
| PCF8574_PIN_5 | pin 5 |
| PCF8574_PIN_6 | pin 6 |
| PCF8574_PIN_7 | pin 7 |
Definition at line 77 of file driver_pcf8574.h.
| uint8_t pcf8574_deinit | ( | pcf8574_handle_t * | handle | ) |
close the chip
| [in] | *handle | pointer to a pcf8574 handle structure |
Definition at line 178 of file driver_pcf8574.c.
| uint8_t pcf8574_get_addr_pin | ( | pcf8574_handle_t * | handle, |
| pcf8574_address_t * | addr_pin ) |
get the address pin
| [in] | *handle | pointer to a pcf8574 handle structure |
| [out] | *addr_pin | pointer to a chip address pins buffer |
Definition at line 82 of file driver_pcf8574.c.
| uint8_t pcf8574_info | ( | pcf8574_info_t * | info | ) |
get chip's information
| [out] | *info | pointer to a pcf8574 info structure |
Definition at line 361 of file driver_pcf8574.c.
| uint8_t pcf8574_init | ( | pcf8574_handle_t * | handle | ) |
initialize the chip
| [in] | *handle | pointer to a pcf8574 handle structure |
Definition at line 105 of file driver_pcf8574.c.
| uint8_t pcf8574_read | ( | pcf8574_handle_t * | handle, |
| pcf8574_pin_t | pin, | ||
| pcf8574_pin_level_t * | level ) |
read the pin
| [in] | *handle | pointer to a pcf8574 handle structure |
| [in] | pin | read pin |
| [out] | *level | pointer to a level buffer |
Definition at line 215 of file driver_pcf8574.c.
| uint8_t pcf8574_set_addr_pin | ( | pcf8574_handle_t * | handle, |
| pcf8574_address_t | addr_pin ) |
set the address pin
| [in] | *handle | pointer to a pcf8574 handle structure |
| [in] | addr_pin | chip address pins |
Definition at line 60 of file driver_pcf8574.c.
| uint8_t pcf8574_write | ( | pcf8574_handle_t * | handle, |
| pcf8574_pin_t | pin, | ||
| pcf8574_pin_level_t | level ) |
write the pin
| [in] | *handle | pointer to a pcf8574 handle structure |
| [in] | pin | written pin |
| [in] | level | pin level |
Definition at line 253 of file driver_pcf8574.c.