42#ifdef PREINIT_SUPPORTED
46#ifdef MikroCCoreVersion
47 #if MikroCCoreVersion >= 1
52#include "drv_digital_out.h"
53#include "drv_i2c_master.h"
66#define I2CISOLATOR_MAP_MIKROBUS( cfg, mikrobus ) \
67 cfg.scl = MIKROBUS( mikrobus, MIKROBUS_SCL ); \
68 cfg.sda = MIKROBUS( mikrobus, MIKROBUS_SDA )
75#define I2CISOLATOR_RETVAL uint8_t
77#define I2CISOLATOR_OK 0x00
78#define I2CISOLATOR_INIT_ERROR 0xFF
#define I2CISOLATOR_RETVAL
Definition i2cisolator.h:75
void i2cisolator_cfg_setup(i2cisolator_cfg_t *cfg)
Config Object Initialization function.
void i2cisolator_generic_write(i2cisolator_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
Generic write function.
void i2cisolator_generic_read(i2cisolator_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
Generic read function.
I2CISOLATOR_RETVAL i2cisolator_init(i2cisolator_t *ctx, i2cisolator_cfg_t *cfg)
Initialization function.
void i2cisolator_default_cfg(i2cisolator_t *ctx)
Click Default Configuration function.
Click configuration structure definition.
Definition i2cisolator.h:108
uint32_t i2c_speed
Definition i2cisolator.h:117
pin_name_t scl
Definition i2cisolator.h:111
pin_name_t sda
Definition i2cisolator.h:112
uint8_t i2c_address
Definition i2cisolator.h:118
Click ctx object definition.
Definition i2cisolator.h:92
i2c_master_t i2c
Definition i2cisolator.h:96
uint8_t slave_address
Definition i2cisolator.h:100