42#define CHIP_NAME "RAMXEED MB85RCXX"
43#define MANUFACTURER_NAME "RAMXEED"
44#define SUPPLY_VOLTAGE_MIN 1.7f
45#define SUPPLY_VOLTAGE_MAX 5.5f
46#define MAX_CURRENT 1.20f
47#define TEMPERATURE_MIN -40.0f
48#define TEMPERATURE_MAX 85.0f
49#define DRIVER_VERSION 1000
73 handle->
debug_print(
"mb85rcxx: iic_init is null.\n");
79 handle->
debug_print(
"mb85rcxx: iic_deinit is null.\n");
85 handle->
debug_print(
"mb85rcxx: iic_read is null.\n");
91 handle->
debug_print(
"mb85rcxx: iic_write is null.\n");
97 handle->
debug_print(
"mb85rcxx: iic_read_address16 is null.\n");
103 handle->
debug_print(
"mb85rcxx: iic_write_address16 is null.\n");
109 handle->
debug_print(
"mb85rcxx: delay_ms is null.\n");
116 handle->
debug_print(
"mb85rcxx: iic init failed.\n");
148 handle->
debug_print(
"mb85rcxx: iic deinit failed.\n");
173 handle->
id = (uint32_t)type;
266 if ((address + len) > handle->
id)
268 handle->
debug_print(
"mb85rcxx: read out of range.\n");
276 address % 65536, buf,
286 if (handle->
iic_read((uint8_t)(handle->
iic_addr + ((address / 256) << 1)), address % 256,
322 if ((address + len) > handle->
id)
324 handle->
debug_print(
"mb85rcxx: write out of range.\n");
332 address % 65536, buf,
342 if (handle->
iic_write((uint8_t)(handle->
iic_addr + ((address / 256) << 1)), address % 256,
#define SUPPLY_VOLTAGE_MAX
#define MANUFACTURER_NAME
#define SUPPLY_VOLTAGE_MIN
#define CHIP_NAME
chip information definition
driver mb85rcxx header file
uint8_t mb85rcxx_deinit(mb85rcxx_handle_t *handle)
close the chip
uint8_t mb85rcxx_get_type(mb85rcxx_handle_t *handle, mb85rcxx_t *type)
get the chip type
uint8_t mb85rcxx_set_addr_pin(mb85rcxx_handle_t *handle, mb85rcxx_address_t addr_pin)
set the chip address pin
mb85rcxx_address_t
mb85rcxx address enumeration definition
mb85rcxx_t
mb85rcxx type enumeration definition
struct mb85rcxx_info_s mb85rcxx_info_t
mb85rcxx information structure definition
uint8_t mb85rcxx_write(mb85rcxx_handle_t *handle, uint32_t address, uint8_t *buf, uint16_t len)
write bytes to the chip
uint8_t mb85rcxx_info(mb85rcxx_info_t *info)
get chip's information
uint8_t mb85rcxx_get_addr_pin(mb85rcxx_handle_t *handle, mb85rcxx_address_t *addr_pin)
get the chip address pin
uint8_t mb85rcxx_set_type(mb85rcxx_handle_t *handle, mb85rcxx_t type)
set the chip type
uint8_t mb85rcxx_init(mb85rcxx_handle_t *handle)
initialize the chip
uint8_t mb85rcxx_read(mb85rcxx_handle_t *handle, uint32_t address, uint8_t *buf, uint16_t len)
read bytes from the chip
struct mb85rcxx_handle_s mb85rcxx_handle_t
mb85rcxx handle structure definition
void(* delay_ms)(uint32_t ms)
uint8_t(* iic_read_address16)(uint8_t addr, uint16_t reg, uint8_t *buf, uint16_t len)
void(* debug_print)(const char *const fmt,...)
uint8_t(* iic_init)(void)
uint8_t(* iic_write_address16)(uint8_t addr, uint16_t reg, uint8_t *buf, uint16_t len)
uint8_t(* iic_write)(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len)
uint8_t(* iic_read)(uint8_t addr, uint8_t reg, uint8_t *buf, uint16_t len)
uint8_t(* iic_deinit)(void)
float supply_voltage_max_v
char manufacturer_name[32]
float supply_voltage_min_v