I have a question to trigger a destructive reset from within the software on an S32G2xx device.
I work with an S32G274A on the RDB2 board, my application is a multicore (M7_0 and M7_1) classic AUTOSAR stack, the A53s I don't use (and it is ok that the complete SoC is reset)
I use the SW32G_RTD_4.4_3.0.2_HF01 under my AUTOSAR BSW stack, with Tresos 27.1.0.
When performing the shutdown/reset sequence, at the end there is a callout were we usually (on other targets) call the AUTOSR API Mcu_PerformReset(). In Tresos, I have configured the Mcu Reset Module to do a destructive reset.
Problem: after the call my software is still stuck in the end of the Os Shutdown, but a proper reset and reboot I don't see.
What I see in the Mcu code and during debugging is:
- at some point the MC_ME_MODE_CONF register is filled,
- then the UPD register is set,
- then the control keys are written
after this the reset should happen in my humble opinion, but the software gets stuck in an OS shutdowen loop after this.
I am not writing anything else to any other MC_ME register (was hoping the reset could be performed only with AUTOSAR / MCAL APIs.) But in the callout I have the freedom to do so if required.
Questions:
1) In General: does a destructive reset lead me though the BootROM again ? or Can I trigger to go through the BootROM again from SW ?
2) is Mcu_PerformReset() the correct way ? or do I need to swith a mode with the Mcu_SetMode() API ? or something else ?
3) In case I need to use Mcu_SetMode(): Is there an example for the configuration (in Tresos) ? I played a little bit with it, but without success so far. For instance, I am not really clear whether the "Boot Address" should be the address of the Reset_Handler, or the start of the int vec table ? I also naturally thought to activate the "Core reset Enable Checkbox", but that triggers an error in the Tresos tool.
any hints welcome
best regards,
Stefan
Solved! Go to Solution.
oook, it works now. Both with Mcu_PerformReset() and Mcu_SetMode(). Maybe it eas the debugger disturbing the process, it works fine when bookting from Flash.
Topic closed
oook, it works now. Both with Mcu_PerformReset() and Mcu_SetMode(). Maybe it eas the debugger disturbing the process, it works fine when bookting from Flash.
Topic closed