Merge pull request #10449 from fredlee12001/UNO_91H_PDMC

Configure UNO_91H to support PDMC compile
pull/10529/head
Martin Kojtal 2019-05-02 19:04:27 +01:00 committed by GitHub
commit bb3fdac760
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 49 additions and 3 deletions

View File

@ -21,9 +21,19 @@
#if defined(RDA_ICACHE_DISABLE)
#define RDA_CODE_BASE (RDA_FLASH_BASE + RDA_PADDR_OFST)
#else /* RDA_ICACHE_DISABLE */
#if !defined(MBED_APP_START) /* MBED_APP_START */
#define RDA_CODE_BASE (RDA_ICACHE_BASE + RDA_PADDR_OFST)
#else /* MBED_APP_START */
#define RDA_CODE_BASE (MBED_APP_START)
#endif /* MBED_APP_START */
#endif /* RDA_ICACHE_DISABLE */
#define RDA_CODE_SIZE (0x001F4000)
#if !defined(MBED_APP_SIZE)
#define MBED_APP_SIZE (0x1F4000)
#endif
#define RDA_CODE_SIZE (MBED_APP_SIZE)
#define RDA_AHB1_BASE (0x40100000)
#define RDA_MEMC_BASE (RDA_AHB1_BASE + 0x00000)

View File

@ -6,12 +6,20 @@
STACK_SIZE = MBED_BOOT_STACK_SIZE;
#if !defined(MBED_APP_START)
#define MBED_APP_START 0x18001000
#endif
#if !defined(MBED_APP_SIZE)
#define MBED_APP_SIZE 2000K
#endif
/* Linker script to configure memory regions. */
MEMORY
{
/* If ICache is enable, use virtual flash base address */
/* Use partition index: 0 */
FLASH (rx) : ORIGIN = 0x18001000, LENGTH = 2000K
FLASH (rx) : ORIGIN = MBED_APP_START, LENGTH = MBED_APP_SIZE
/* Use partition index: 1 */
/* FLASH (rx) : ORIGIN = 0x181F5000, LENGTH = 2000K */

View File

@ -17,7 +17,12 @@ if (0 == RDA_PARTITION_INDEX) {
if (1 == RDA_ICACHE_DISABLE) {
define symbol RDA_CODE_BASE = RDA_FLASH_BASE + RDA_PADDR_OFST;
} else {
/* MBED_APP_START */
if (!isdefinedsymbol(MBED_APP_START)) {
define symbol RDA_CODE_BASE = RDA_ICACHE_BASE + RDA_PADDR_OFST;
} else {
define symbol RDA_CODE_BASE = MBED_APP_START;
}
}
define symbol RDA_CODE_END = RDA_CODE_BASE + 0x1F3FFF;
define symbol RDA_AHB1_BASE = 0x40100000;

View File

@ -18,6 +18,14 @@
#include "flash_data.h"
#include "mbed_critical.h"
#ifndef MBED_ROM_SIZE
#define MBED_FLASH_SIZE 0x100000
#else
//there is 4K BOOTROM at beginning of the flash
#define MBED_FLASH_SIZE (MBED_ROM_SIZE+0x1000)
#endif
// This file is automagically generated
// This is a flash algo binary blob. It is PIC (position independent code) that should be stored in RAM
@ -68,7 +76,7 @@ static const sector_info_t sectors_info[] = {
static const flash_target_config_t flash_target_config = {
.page_size = 0x100,
.flash_start = 0x18000000,
.flash_size = 0x100000,
.flash_size = MBED_FLASH_SIZE,
.sectors = sectors_info,
.sector_info_count = sizeof(sectors_info) / sizeof(sector_info_t)
};

View File

@ -42,4 +42,12 @@ extern uint32_t Image$$ARM_LIB_HEAP$$ZI$$Length[];
#error "no toolchain defined"
#endif
#if defined(TARGET_UNO_91H)
/* Stack Pointer */
#ifndef INITIAL_SP
#define INITIAL_SP (0x120000UL)
//#define INITIAL_SP (0x1A8000UL)
#endif
#endif
#endif // MBED_MBED_RTX_H

View File

@ -8519,6 +8519,13 @@
"UNO_91H": {
"inherits": ["RDA5981X"],
"detect_code": ["8001"],
"components_add": ["FLASHIAP"],
"bootloader_supported": true,
"mbed_ram_start": "0x00100080",
"mbed_ram_size": "0x1ff80",
"mbed_rom_start": "0x18001000",
"mbed_rom_size": "0x1F4000",
"sectors": [[0,4096]],
"overrides": {
"network-default-interface-type" : "WIFI"
}