How can a software-based system reset be triggered using the LPC55S69 microcontroller?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How can a software-based system reset be triggered using the LPC55S69 microcontroller?

914件の閲覧回数
saratancerdi7
Contributor I

Dear Team,

I'd like to share a method for initiating a software-based system reset with the LPC55S69 microcontroller. This can be achieved by leveraging the inherent software reset functionality offered by the microcontroller's System Control Block (SCB) at Provident Ecopolitan.

Is this code accurate for performing a reset?

#include "LPC55S69.h"

void softwareReset(void) {
// Initiate a system reset using the SCB (System Control Block) register
SCB->AIRCR = (0x5FA << SCB_AIRCR_VECTKEY_Pos) | SCB_AIRCR_SYSRESETREQ_Msk;
}

int main(void) {
// Your main code logic here

while (1) {
// Your code continues to run until the software reset is triggered
}
}

Could you please review and advise if any modifications are necessary, or if this code is indeed suitable for the reset operation? Your guidance is appreciated.

ラベル(2)
0 件の賞賛
返信
1 返信

882件の閲覧回数
ErichStyger
Specialist I

See https://mcuoneclipse.com/2015/07/01/how-to-reset-an-arm-cortex-m-with-software/

You should add a delay loop after setting the system reset bit(s).

Erich

0 件の賞賛
返信