eeprom 2.0.0.0
|
This file contains API for EEPROM Click driver. More...
#include "drv_digital_out.h"
#include "drv_i2c_master.h"
Go to the source code of this file.
Data Structures | |
struct | eeprom_t |
Click context object definition. More... | |
struct | eeprom_cfg_t |
Click configuration structure definition. More... | |
Macros | |
#define | EEPROM_BLOCK_ADDR_START 0x00 |
#define | EEPROM_BLOCK_ADDR_MIDDLE 0x80 |
#define | EEPROM_BLOCK_ADDR_END 0xFF |
#define | EEPROM_NBYTES_MIN 1 |
#define | EEPROM_NBYTES_PAGE 16 |
#define | EEPROM_NBYTES_MAX 256 |
#define | EEPROM_MAP_MIKROBUS(cfg, mikrobus) |
Enumerations | |
enum | eeprom_i2c_address_selector_t { EEPROM_I2C_ADDR_SEL_0 = 0 , EEPROM_I2C_ADDR_SEL_1 , EEPROM_I2C_ADDR_SEL_2 , EEPROM_I2C_ADDR_SEL_3 , EEPROM_I2C_ADDR_SEL_4 , EEPROM_I2C_ADDR_SEL_5 , EEPROM_I2C_ADDR_SEL_6 , EEPROM_I2C_ADDR_SEL_7 } |
Click address (memory block) selection. More... | |
enum | eeprom_retval_t { EEPROM_RETVAL_OK = 0x00 , EEPROM_RETVAL_ERR_DRV_INIT = 0xFE , EEPROM_RETVAL_ERR_NBYTES } |
Click error code. More... | |
Functions | |
void | eeprom_cfg_setup (eeprom_cfg_t *cfg) |
Config Structure Setup function. | |
eeprom_retval_t | eeprom_init (eeprom_t *context, eeprom_cfg_t *cfg) |
Click Initialization function. | |
void | eeprom_write_byte (eeprom_t *context, uint8_t reg_addr, uint8_t data_in) |
Byte Write function. | |
void | eeprom_write_page (eeprom_t *context, uint8_t reg_addr, uint8_t *data_in) |
Page Write function. | |
uint8_t | eeprom_read_byte (eeprom_t *context, uint8_t reg_addr) |
Byte Read function. | |
eeprom_retval_t | eeprom_read_sequential (eeprom_t *context, uint8_t reg_addr, uint16_t n_bytes, uint8_t *data_out) |
Sequential Read function. | |
void | eeprom_write_enable (eeprom_t *context) |
Write Enable function. | |
void | eeprom_write_protect (eeprom_t *context) |
Write Protect function. | |
This file contains API for EEPROM Click driver.