Porting S32K146 example from S32 Design Studio for ARM 2.2 to Keil IDE5.29


I have try to port over lptmr_periodic_interrupt example using the S32K146EVB  from S32 Design Studio to Keil IDE by individually adding C library source and header files under NXP\S32DS_ARMv2.2\S32DS\software\S32SDK_S32K1xx_RTM_3.0.0  (including those in Generated_Code folder such as clockMan1.c, clockMan1.h, Cpu.c, Cpu.h etc).

My reason for doing so is because I think the Keil IDE environment has better debug support while S32 Design Studio tends to have error message and hang or exit during debug when user paused the debug process. Also the S32 Design Studio does not seem to halt when I insert the breakpoints in the code.

Anyway, I have managed to port the example over to Keil and the build process is successful with no error UNTIL the final stage where it says the .sct file in the project does not have enough information on where to allocate the program and data code in the program flash memory bank. I have copied and pasted the build console output:


Rebuild started: Project: lptmr_periodic_interrupt
*** Using Compiler 'V5.06 update 6 (build 750)', folder: 'C:\Keil_v5\ARM\ARMCC\Bin'
Rebuild target 'lptmr_periodic_interrupt'
compiling Cpu.c...
compiling pin_mux.c...
compiling clockMan1.c...
compiling main.c...
compiling lpTmr1.c...
.\Objects\lptmr_periodic_interrupt.sct(7): error: L6236E: No section matches selector - no section to be FIRST/LAST.
Not enough information to list image symbols.
Not enough information to list load addresses in the image map.
Finished: 2 information, 0 warning and 1 error messages.
".\Objects\lptmr_periodic_interrupt.axf" - 1 Error(s), 0 Warning(s).
Target not created.
Build Time Elapsed: 00:00:01


Can anyone advise me how to modify the pasted contents of lptmr_periodic_interrupt.sct file pasted below to overcome the problem so I may proceed to test out the example project and see if it works with Keil IDE.

; *************************************************************
; *** Scatter-Loading Description File generated by uVision ***
; *************************************************************

LR_IROM1 0x00000000 0x00100000 { ; load region size_region
ER_IROM1 0x00000000 0x00100000 { ; load address = execution address
*.o (RESET, +First)
.ANY (+RO)
.ANY (+XO)
RW_IRAM1 0x20000000 0x0000F000 { ; RW data
.ANY (+RW +ZI)

To add, I have added correct board support package (Keil.S32_SDK_DFP.1.3.0.pack) to Keil IDE and I can see all the S32K14x series devices in Keil device database and have selected the S32K146UAxxxLHx MCU part for the example project.

I can see the output heartbeat LED (D11) of S32K146EVB alternate between 3 colors periodically to test modified example code. But in debug perspective, I cannot see the program halt at designated breakpoints both inside the interrupt routine and in main program. Which is why I try to port over to Keil because I have used Keil before and know it has good breakpoint support for debug. Unless someone can help me overcome this problem in S32 Design Studio for ARM v2.2, I feel I do not get the development support I need and will try switch over to Keil.


You may reach me at chwai.tang1@outlook.com

Best regards

More questions in this forum