Hi there!
I'm new on bare-metal programming and trying to code a basic template (a main that increments the counter var value) for Renesas RA2A1 evaluation board. The reason of doing bare-metal without the smart configurator of Renesas is due to avoid the FSP and BSP that e2studio always uses, in order to have the control of all code parts. The need to have all the control of the code is due to a safety related environment, needed to certify in the future. So when starting a simple project, I use ARM Cortex M23 (ARMCM23) template with the CMSIS Core and Device Startup software components selected. I'm following a Udemy course of Complete ARM Cortex-M Bare-Metal Programming (Israel Gbati), he starts the project as I explained and the add to the source group a main.c file with just the following:
Int main ()
{
Int counter = 0;
++counter;
}
Seems a simple code that should compile correctly, but when building always gives the same error:
.\Objects\CoreBox.axf: Error: L6218E: Undefined symbol Image$$ARM_LIB_STACK$$ZI$$Limit (referred from startup_armcm23. o).
Not enough information to list load addresses in the image map.
Searching on the internet and forums as well seems a common error about configuration, but the given solutions don't solve out the problem. Does anyone know what I'm doing wrong?
I attach the project. Thanks in advance!
ARM CORTEX M23.rar
Hello Andreas Barth,
Thanks! The errors have disappeared, but I can't simulate them with the debugger, the CPU DLL and Dialog DLL are blank as the pic shows:
So I've been looking to some example and ended up with this:
Any clue how to configure in order to use the simulator?
Thanks in advance!
Hello aitor_azkolain, right, the uVision simulator does not support Arm V8-M targets anymore. You can use Fast Models instead.
For that, go to Options for Target ... -> Debug. There on the right side click "Use" and select "Models ARMv8-M Debugger". In settings select for example the "C:\Keil_v5\ARM\VHT\VHT_MPS2_Cortex-M23.exe".
That the program runs with the default model options requires adjustments of the ARMCM23_ac6.sct. Set:
#define __ROM_BASE 0x10000000
and:
#define __RAM_BASE 0x30000000
Then rebuild the project and start debug. The model should launch and in the debug session the program should stop at main().
Hello Andreas,
It worked, thank you very much!
Best regards,
Aitor Azkolain