Hello! Please, suggest an appropriate way to generate reset from the user's firmware. Now I am using the next function:
tgt_reset(void){
_disable_interrupts();
asm(" .ref _vector0");
asm(" NOP 5");
asm(" MVKL _vector0, B0"); // jump on 0 addr
asm(" MVKH _vector0, B0");
asm(" B B0");
asm(" NOP 5");
}
but it works strange - sometimes it goes to unknown state and I have to apply hardware reset.
Thanks!