This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software:
Hi Team
I have requirement to Firmware upgrade the the application binary using ethernet bootloader directly in RAM
The Ethernet bootloader will be residing in flash , but the application should be directly need to be flashed in RAM using the Bootloader ,
Is there any example code for running the binary directly in RAM instead of FLASH
My requirement is to load the application from RAM when ever in system Bootup, Like each time on power up through Ethernet bootloader I need to directly firmware(application) download to RAM and boot from RAM not from Flash
My second question is there any code or example projects for Ethernet packet encryption and decryption
Please respond ASAP
Applicationtobedownloaded .cmd file
/****************************************************************************** * * blinky_ccs.cmd - CCS linker configuration file for blinky. * * Copyright (c) 2013-2020 Texas Instruments Incorporated. All rights reserved. * Software License Agreement * * Texas Instruments (TI) is supplying this software for use solely and * exclusively on TI's microcontroller products. The software is owned by * TI and/or its suppliers, and is protected under applicable copyright * laws. You may not combine this software with "viral" open-source * software in order to form a larger program. * * THIS SOFTWARE IS PROVIDED "AS IS" AND WITH ALL FAULTS. * NO WARRANTIES, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT * NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR * A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. TI SHALL NOT, UNDER ANY * CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR CONSEQUENTIAL * DAMAGES, FOR ANY REASON WHATSOEVER. * * This is part of revision 2.2.0.295 of the EK-TM4C1294XL Firmware Package. * *****************************************************************************/ --retain=g_pfnVectors /* The following command line options are set as part of the CCS project. */ /* If you are building using the command line, or for some reason want to */ /* define them here, you can uncomment and modify these lines as needed. */ /* If you are using CCS for building, it is probably better to make any such */ /* modifications in your CCS project and leave this file alone. */ /* */ /* --heap_size=0 */ /* --stack_size=256 */ /* --library=rtsv7M3_T_le_eabi.lib */ /* The starting address of the application. Normally the interrupt vectors */ /* must be located at the beginning of the application. */ #define RAM_BASE 0x20800000 #define APP_LENGTH 0x00004000 #define SRAM_VTABLE 0x20160000 #define SRAM_VTABLE_LEN 0x00004000 //#define APP_BASE 0x00000000 //#define RAM_BASE 0x20000000 MEMORY { /* Application stored in and executes from internal flash*/ //FLASH (RX) : origin = APP_BASE, length = APP_LENGTH /* Application uses internal RAM for data*/ SRAMAPP (RWX) : origin = RAM_BASE, length = APP_LENGTH SRAM (RWX) : origin = SRAM_VTABLE, length = SRAM_VTABLE_LEN } /* System memory map */ /*MEMORY { /* Application stored in and executes from internal flash FLASH (RX) : origin = APP_BASE, length = 0x00100000 /* Application uses internal RAM for data SRAM (RWX) : origin = 0x20000000, length = 0x00040000 }*/ SECTIONS { .intvecs: > RAM_BASE .text : > SRAMAPP .const : > SRAMAPP .cinit : > SRAMAPP .pinit : > SRAMAPP .init_array : > SRAMAPP .vtable : > SRAM_VTABLE .data : > SRAM .bss : > SRAM .sysmem : > SRAM .stack : > SRAM #ifdef __TI_COMPILER_VERSION__ #if __TI_COMPILER_VERSION__ >= 15009000 .TI.ramfunc : {} load=SRAMAPP, run=SRAM, table(BINIT) #endif #endif } /* Section allocation in memory */ /*SECTIONS { .intvecs: > APP_BASE .text : > FLASH .const : > FLASH .cinit : > FLASH .pinit : > FLASH .init_array : > FLASH .vtable : > RAM_BASE .data : > SRAM .bss : > SRAM .sysmem : > SRAM .stack : > SRAM #ifdef __TI_COMPILER_VERSION__ #if __TI_COMPILER_VERSION__ >= 15009000 .TI.ramfunc : {} load=FLASH, run=SRAM, table(BINIT) #endif #endif }*/ __STACK_TOP = __stack + 512;
Bootloaded.cmd file
/****************************************************************************** * * Medtronic-HHC-primary.cmd - CCS linker configuration file for medtronic primary. * * Copyright (c) 2013-2017 Texas Instruments Incorporated. All rights reserved. * Software License Agreement * * Texas Instruments (TI) is supplying this software for use solely and * exclusively on TI's microcontroller products. The software is owned by * TI and/or its suppliers, and is protected under applicable copyright * laws. You may not combine this software with "viral" open-source * software in order to form a larger program. * * THIS SOFTWARE IS PROVIDED "AS IS" AND WITH ALL FAULTS. * NO WARRANTIES, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT * NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR * A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. TI SHALL NOT, UNDER ANY * CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR CONSEQUENTIAL * DAMAGES, FOR ANY REASON WHATSOEVER. * * *****************************************************************************/ --retain=g_pfnVectors /* The following command line options are set as part of the CCS project. */ /* If you are building using the command line, or for some reason want to */ /* define them here, you can uncomment and modify these lines as needed. */ /* If you are using CCS for building, it is probably better to make any such */ /* modifications in your CCS project and leave this file alone. */ /* */ /* --heap_size=0 */ /* --stack_size=256 */ /* --library=rtsv7M3_T_le_eabi.lib */ /* The starting address of the application. Normally the interrupt vectors */ /* must be located at the beginning of the application. */ #define APP_BASE 0x00000000 #define RAM_BASE 0x20000000 #define APP_LENGTH 0x00016000 /* System memory map */ MEMORY { /* Application stored in and executes from internal flash */ FLASH (RX) : origin = APP_BASE, length = APP_LENGTH /* Application uses internal RAM for data */ SRAM (RWX) : origin = RAM_BASE, length = 0x00040000 } /* Section allocation in memory */ SECTIONS { .intvecs: > APP_BASE .text : > FLASH .const : > FLASH .cinit : > FLASH .pinit : > FLASH .init_array : > FLASH .vtable : > RAM_BASE .data : > SRAM .bss : > SRAM .sysmem : > SRAM .stack : > SRAM #ifdef __TI_COMPILER_VERSION__ #if __TI_COMPILER_VERSION__ >= 15009000 .TI.ramfunc : {} load=FLASH, run=SRAM, table(BINIT) #endif #endif }
Hi,
I'm currently on travel. I will reply your post when I come back on Wednesday. Sorry for the inconvenience.
The Ethernet bootloader will be residing in flash , but the application should be directly need to be flashed in RAM using the Bootloader ,
The RAM is only 256kB. Is your firmware small enough to fit in this size? Please be aware that you can't fully use the 256k for the firmware as RAM is also used for runtime stack and heap memories.
Is there any example code for running the binary directly in RAM instead of FLASH
No, we don't have any example as such. You will need to modify the bootloader so that you will download the firmware to the RAM instead of to the flash. RAM is a single cycle access memory. It is actually easier to program your firmware to RAM. It is a matter of writing to RAM. After the firmware is written to the RAM, you just move the program counter to the RAM address for execution.
My second question is there any code or example projects for Ethernet packet encryption and decryption
There are some AES examples for encryption and decryption.