Arrow / Mbed OS DAPLink Reset
Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers daplink_addr.h Source File

daplink_addr.h

00001 /**
00002  * @file    daplink_addr.h
00003  * @brief
00004  *
00005  * DAPLink Interface Firmware
00006  * Copyright (c) 2009-2016, ARM Limited, All Rights Reserved
00007  * SPDX-License-Identifier: Apache-2.0
00008  *
00009  * Licensed under the Apache License, Version 2.0 (the "License"); you may
00010  * not use this file except in compliance with the License.
00011  * You may obtain a copy of the License at
00012  *
00013  * http://www.apache.org/licenses/LICENSE-2.0
00014  *
00015  * Unless required by applicable law or agreed to in writing, software
00016  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
00017  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00018  * See the License for the specific language governing permissions and
00019  * limitations under the License.
00020  */
00021 
00022 #ifndef DAPLINK_ADDR_H
00023 #define DAPLINK_ADDR_H
00024 
00025 #define KB(size)                        ((size) * 1024)
00026 
00027 /* Device sizes */
00028 
00029 #define DAPLINK_ROM_START               0x00000000
00030 #define DAPLINK_ROM_SIZE                KB(256)
00031 
00032 #define DAPLINK_RAM_START               0x20000000
00033 #define DAPLINK_RAM_SIZE                KB(160)
00034 
00035 /* ROM sizes */
00036 
00037 #define DAPLINK_ROM_BL_START            0x00000000
00038 #define DAPLINK_ROM_BL_SIZE             KB(48)
00039 
00040 #define DAPLINK_ROM_CONFIG_ADMIN_START  0x0000C000
00041 #define DAPLINK_ROM_CONFIG_ADMIN_SIZE   KB(0)
00042 
00043 #define DAPLINK_ROM_IF_START            0x0000C000
00044 #define DAPLINK_ROM_IF_SIZE             KB(204)
00045 
00046 #define DAPLINK_ROM_CONFIG_USER_START   0x0003F000
00047 #define DAPLINK_ROM_CONFIG_USER_SIZE    KB(4)
00048 
00049 /* RAM sizes */
00050 
00051 #define DAPLINK_RAM_APP_START           0x20000000
00052 #define DAPLINK_RAM_APP_SIZE            KB(156)
00053 
00054 #define DAPLINK_RAM_SHARED_START        0x20027000
00055 #define DAPLINK_RAM_SHARED_SIZE         KB(4)
00056 
00057 /* Flash Programming Info */
00058 
00059 #define DAPLINK_SECTOR_SIZE             KB(4)
00060 #define DAPLINK_MIN_WRITE_SIZE          (256)
00061 
00062 /* Current build */
00063 
00064 #if defined(DAPLINK_BL)
00065 
00066 #define DAPLINK_ROM_APP_START           DAPLINK_ROM_BL_START
00067 #define DAPLINK_ROM_APP_SIZE            DAPLINK_ROM_BL_SIZE
00068 #define DAPLINK_ROM_UPDATE_START        DAPLINK_ROM_IF_START
00069 #define DAPLINK_ROM_UPDATE_SIZE         DAPLINK_ROM_IF_SIZE
00070 
00071 #elif defined(DAPLINK_IF)
00072 
00073 #define DAPLINK_ROM_APP_START           DAPLINK_ROM_IF_START
00074 #define DAPLINK_ROM_APP_SIZE            DAPLINK_ROM_IF_SIZE
00075 #define DAPLINK_ROM_UPDATE_START        DAPLINK_ROM_BL_START
00076 #define DAPLINK_ROM_UPDATE_SIZE         DAPLINK_ROM_BL_SIZE
00077 
00078 #else
00079 
00080 #error "Build must be either bootloader or interface"
00081 
00082 #endif
00083 
00084 #endif