ADD g030, g050, g070

This commit is contained in:
Nima Askari (نیما عسکری) 2023-04-03 12:26:32 +03:30 committed by GitHub
parent 11729d4869
commit d1ecc316e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 17 additions and 5 deletions

15
ee.c
View File

@ -18,8 +18,8 @@
#endif
#if defined(STM32F103x8)
#define _EE_MAX_SIZE 1024
#define _EE_ADDR_INUSE (((uint32_t)0x08000000) | (_EE_MAX_SIZE * _EE_USE_FLASH_PAGE_OR_SECTOR))
#define _EE_SIZE 1024
#define _EE_ADDR_INUSE (((uint32_t)0x08000000) | (_EE_SIZE * _EE_USE_FLASH_PAGE_OR_SECTOR))
#define _EE_FLASH_BANK FLASH_BANK_1
#define _EE_PAGE_OR_SECTOR PAGE
#if (_EE_USE_FLASH_PAGE_OR_SECTOR > 63)
@ -144,7 +144,7 @@
#endif
#endif
#if defined(STM32G030xx_H)
#if defined(STM32G030xx) || defined(STM32G050xx)
#define _EE_SIZE 2048
#define _EE_ADDR_INUSE (((uint32_t)0x08000000) | (_EE_SIZE * _EE_USE_FLASH_PAGE_OR_SECTOR))
#define _EE_PAGE_OR_SECTOR PAGE_NUM
@ -153,6 +153,15 @@
#endif
#endif
#if defined(STM32G070xx)
#define _EE_SIZE 2048
#define _EE_ADDR_INUSE (((uint32_t)0x08000000) | (_EE_SIZE * _EE_USE_FLASH_PAGE_OR_SECTOR))
#define _EE_PAGE_OR_SECTOR PAGE_NUM
#if (_EE_USE_FLASH_PAGE_OR_SECTOR > 63)
#error "Please Enter correct address, maximum is (63)"
#endif
#endif
#if defined(STM32L433xx)
#define _EE_SIZE 2048
#define _EE_ADDR_INUSE (((uint32_t)0x08000000) | (_EE_SIZE * _EE_USE_FLASH_PAGE_OR_SECTOR))

5
ee.h
View File

@ -7,8 +7,11 @@
Instagram: http://instagram.com/github.NimaLTD
Youtube: https://www.youtube.com/channel/UCUhY7qY1klJm1d2kulr9ckw
Version: 2.0.3
Version: 2.0.4
(2.0.4)
Add G030, G050, G070.
(2.0.3)
Add F411.

View File

@ -1,7 +1,7 @@
#ifndef __EECONFIG_H
#define __EECONFIG_H
#define _EE_USE_FLASH_PAGE_OR_SECTOR (127)
#define _EE_USE_FLASH_PAGE_OR_SECTOR (31)
#define _EE_USE_RAM_BYTE (1024)
#define _EE_VOLTAGE FLASH_VOLTAGE_RANGE_3 // use in some devices
#endif