1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- /*
- * flash.h
- *
- * Created on: 2019. 7. 4.
- * Author: parkyj
- */
- #ifndef FLASH_H_
- #define FLASH_H_
- #include "main.h"
- #include "CRC.h"
- #define FLASH_USER_BANK_NUM ((uint32_t)0x08008000) - 150
- #define FLASH_MBICUSER_START_ADDR (uint32_t)((0x08008000) - 128)
- #define FLASH_MBICUSER_END_ADDR FLASH_MBICUSER_START_ADDR + ((uint32_t)0xFFFF)
- #define FLASH_USER_START_ADDR ((uint32_t)0x08008000)
- #define FLASH_USER_END_ADDR FLASH_USER_START_ADDR + ((uint32_t)0x000FFFF) /* End @ of user Flash area */
- #define APPLICATION_ADDRESS (uint32_t)0x08008000 /* Start user code address: ADDR_FLASH_PAGE_8 */
- #define BOOTLOADER_ADDRESS (uint32_t)0x08000000 /* Start user code address: ADDR_FLASH_PAGE_8 */
- #define FLASH_USER_BANK1_START_ADDR ((uint32_t)0x08028000)
- #define FLASH_USER_BANK1_END_ADDR FLASH_USER_BANK1_START_ADDR + ((uint32_t)0x1FF80) /* End @ of user Flash area */
- #define FLASH_USER_BANK2_START_ADDR ((uint32_t)0x08048000)
- #define FLASH_USER_BANK2_END_ADDR FLASH_USER_BANK2_START_ADDR + ((uint32_t)0x1FF80)
- #define FLASH_USER_TEMPDATA_START_ADDR ((uint32_t)0x08040000)
- #define FirmwareUpdataAck 0x11
- #define FirmwareUpdataNak 0x22
- #define FirmwareUpdateDelay 50
- #endif /* FLASH_H_ */
|