reram 2.0.0.0
|
Functions | |
void | reram_cfg_setup (reram_cfg_t *cfg) |
Configuration Object Setup function. | |
reram_err_t | reram_init (reram_t *ctx, reram_cfg_t *cfg) |
Click Initialization function. | |
void | reram_default_cfg (reram_t *ctx) |
Click Default Configuration function. | |
reram_err_t | reram_send_cmd (reram_t *ctx, uint8_t cmd_code) |
Command Send function. | |
uint8_t | reram_read_status (reram_t *ctx) |
Status Read function. | |
void | reram_write_status (reram_t *ctx, uint8_t data_in) |
Status Write function. | |
reram_err_t | reram_read_memory (reram_t *ctx, uint32_t mem_addr, uint8_t *data_out, uint16_t n_bytes) |
Memory Read function. | |
reram_err_t | reram_write_memory (reram_t *ctx, uint32_t mem_addr, uint8_t *data_in, uint16_t n_bytes) |
Memory Write function. | |
uint32_t | reram_read_id (reram_t *ctx) |
ID Read function. | |
void | reram_set_hold_pin (reram_t *ctx, reram_pin_state_t state) |
Hold Pin Set function. | |
void | reram_set_write_protect_pin (reram_t *ctx, reram_pin_state_t state) |
Write Protect Pin Set function. | |
void | reram_wake_up (reram_t *ctx) |
Wake Up function. | |
void reram_cfg_setup | ( | reram_cfg_t * | cfg | ) |
Configuration Object Setup function.
cfg | Click configuration structure. |
@description This function initializes all used pins to unconnected state.
void reram_default_cfg | ( | reram_t * | ctx | ) |
Click Default Configuration function.
ctx | Click object. |
@description This function executes a default configuration for ReRAM Click.
reram_err_t reram_init | ( | reram_t * | ctx, |
reram_cfg_t * | cfg ) |
Click Initialization function.
ctx | Click object. |
cfg | Click configuration structure. |
@description This function initializes all peripherals and pins used by ReRAM Click.
uint32_t reram_read_id | ( | reram_t * | ctx | ) |
ID Read function.
ctx | Click object. |
@description This function returns the 32-bit device ID.
reram_err_t reram_read_memory | ( | reram_t * | ctx, |
uint32_t | mem_addr, | ||
uint8_t * | data_out, | ||
uint16_t | n_bytes ) |
Memory Read function.
ctx | Click object. |
mem_addr | Memory address. |
data_out | Memory where data be stored. |
n_bytes | Number of bytes to be read. |
@description This function reads a selected block of memory, starting from the selected address.
uint8_t reram_read_status | ( | reram_t * | ctx | ) |
Status Read function.
ctx | Click object. |
@description This function reads status byte.
reram_err_t reram_send_cmd | ( | reram_t * | ctx, |
uint8_t | cmd_code ) |
Command Send function.
ctx | Click object. |
cmd_code | Command to be sent. |
@description This function allows user to send a desired command to the device.
void reram_set_hold_pin | ( | reram_t * | ctx, |
reram_pin_state_t | state ) |
Hold Pin Set function.
ctx | Click object. |
state | Pin state to be set. |
@description This function sets Hold pin to the desired state.
void reram_set_write_protect_pin | ( | reram_t * | ctx, |
reram_pin_state_t | state ) |
Write Protect Pin Set function.
ctx | Click object. |
state | Pin state to be set. |
@description This function sets Write Protect pin to the desired state.
void reram_wake_up | ( | reram_t * | ctx | ) |
Wake Up function.
ctx | Click object. |
@description This function executes a device wake up sequence.
reram_err_t reram_write_memory | ( | reram_t * | ctx, |
uint32_t | mem_addr, | ||
uint8_t * | data_in, | ||
uint16_t | n_bytes ) |
Memory Write function.
ctx | Click object. |
mem_addr | Memory address. |
data_in | Data to be written. |
n_bytes | Number of bytes to be written. |
@description This function writes data to the selected memory block, starting from the selected address.
void reram_write_status | ( | reram_t * | ctx, |
uint8_t | data_in ) |
Status Write function.
ctx | Click object. |
data_in | Data to be written. |
@description This function writes data byte to Status register.