77 error_t
read_reg(uint32_t index, uint8_t *data);
92 error_t
read_regs(uint32_t index, uint8_t *data, uint16_t size);
107 error_t
write_reg(uint32_t index, uint8_t data, uint8_t access);
123 error_t
write_regs(uint32_t index, uint8_t *data, uint16_t size, uint8_t access);
error_t execute_reg_change()
Executes or commits all register changes on the periphs.
Definition: app_reg.c:61
error_t write_regs(uint32_t index, uint8_t *data, uint16_t size, uint8_t access)
Writes multiple register from the register map.
Definition: app_reg.c:104
error_t read_regs(uint32_t index, uint8_t *data, uint16_t size)
Reads multiple registers from the register map.
Definition: app_reg.c:89
uint32_t get_reg_size()
Gets the total size of the register map in bytes.
Definition: app_reg.c:77
void add_index(uint16_t *i)
Adds a number and wraps around if register size exceeded.
Definition: app_reg.c:122
void unprotected_read_uint8(uint32_t index, uint8_t *data)
An unprotected read from the register map.
Definition: app_reg.c:81
The memory map.
Definition: PHiLIP_typedef.h:340
error_t write_reg(uint32_t index, uint8_t data, uint8_t access)
Writes a register from the register map.
Definition: app_reg.c:99
error_t read_reg(uint32_t index, uint8_t *data)
Reads a register from the register map.
Definition: app_reg.c:85
void init_app_reg(map_t *reg)
Initializes application registers.
Definition: app_reg.c:50
void sub_index(uint16_t *i)
Subtracts a number and wraps around if 0.
Definition: app_reg.c:128