GlobLib
HAL and API libraries for MCUs and hardware.
stm32f103cb_flash.h
Go to the documentation of this file.
1 #ifndef STM32F103CB_FLASH_H_
2 #define STM32F103CB_FLASH_H_
3 
63 #include "stm32f103cb_debug.h"
64 #include <libopencm3/stm32/flash.h>
65 #include <stdint.h>
66 
67 
80 mcu_error FLASH_clearPage(uint32_t pageNumber);
96 mcu_error FLASH_write(uint32_t pageNumber, uint32_t address, uint32_t data);
114 mcu_error FLASH_writes(uint32_t pageNumber, uint32_t address, uint32_t *data, uint16_t size);
123 uint32_t FLASH_read(uint32_t pageNumber, uint32_t address);
136 mcu_error FLASH_reads(uint32_t pageNumber, uint32_t address, uint32_t *data, uint16_t size);
147 mcu_error FLASH_readPage(uint32_t pageNumber, uint32_t *data);
158 uint8_t FLASH_pageEmpty(uint32_t pageNumber);
168 uint8_t FLASH_firstEmptyPage(void);
169 
170 //Read page
171 //Write page
172 
175 #endif
mcu_error FLASH_readPage(uint32_t pageNumber, uint32_t *data)
Read an entire page from flash.
Header file for stm32f103cb DEBUG.
uint8_t FLASH_firstEmptyPage(void)
Get the first empty page is flash.
mcu_error FLASH_writes(uint32_t pageNumber, uint32_t address, uint32_t *data, uint16_t size)
Write multiple words to flash, address incremented automatically.
uint8_t FLASH_pageEmpty(uint32_t pageNumber)
Determine if a given page is empty.
uint32_t FLASH_read(uint32_t pageNumber, uint32_t address)
Read a single word from flash memory.
mcu_error FLASH_clearPage(uint32_t pageNumber)
Clear a page (1kb) of flash.
mcu_error FLASH_reads(uint32_t pageNumber, uint32_t address, uint32_t *data, uint16_t size)
Read multiple words from flash.
mcu_error FLASH_write(uint32_t pageNumber, uint32_t address, uint32_t data)
Write a single word to flash.
mcu_error
Error enumerators for the Debug peripheral.