test
This commit is contained in:
@@ -8,11 +8,19 @@
|
||||
#ifndef PCF8574_IO_EXPANDER_CM_PCF8574_DRIVER_H_
|
||||
#define PCF8574_IO_EXPANDER_CM_PCF8574_DRIVER_H_
|
||||
|
||||
#include "stdint.h"
|
||||
|
||||
enum{
|
||||
CM_PCF8574_OK = 0,
|
||||
CM_PCF8574_NOK
|
||||
};
|
||||
|
||||
enum{
|
||||
CM_PCF8574_I2C_GET = 0,
|
||||
CM_PCF8574_I2C_SET = 1,
|
||||
|
||||
};
|
||||
|
||||
typedef int (*setGet_I2C_Event_fpt)(void *inst, uint8_t *data, uint32_t len, uint8_t set_get);
|
||||
|
||||
|
||||
@@ -38,7 +46,8 @@ typedef struct{
|
||||
|
||||
}cm_pcf8574_t;
|
||||
|
||||
int cm_pcf8574_RegTransEvt(cm_pcf8574_t inst, void i2c_inst, setGet_I2C_Event_fpt i2c_transfer_evt);
|
||||
int cm_pcf8574_init(cm_pcf8574_t *inst);
|
||||
int cm_pcf8574_SetPort(cm_pcf8574_t *inst, uint8_t port_val);
|
||||
int cm_pcf8574_RegTransEvt(cm_pcf8574_t *inst, void *i2c_inst, setGet_I2C_Event_fpt i2c_transfer_evt);
|
||||
int cm_pcf8574_Init(cm_pcf8574_t *inst);
|
||||
|
||||
#endif /* PCF8574_IO_EXPANDER_CM_PCF8574_DRIVER_H_ */
|
||||
|
||||
Reference in New Issue
Block a user