Skip to main content
croket_2512
Associate
April 22, 2015
Question

[HELP] Question about Illegal Opcode Reset

  • April 22, 2015
  • 1 reply
  • 1463 views
Posted on April 22, 2015 at 05:15

Hello everyone!

I am using STM8S105 and I don't understand the Illegal Opcode Reset function yet. How does it work? What is its function exactly? And which case do we use it?

Thanks and best regards!
    This topic has been closed for replies.

    1 reply

    Ian Legg
    Visitor II
    April 23, 2015
    Posted on April 23, 2015 at 14:57

    Hello,

    There is a small paragraph in the STM8 Reference Manual under the Resets section that talks about the illegal opcode reset.

    In short any opcode that is executed from the flash or ram that is unknown, i.e. not part of the supported opcodes will cause the microcontroller to reset itself, probably setting a flag in a status register somewhere to indicate the cause of the reset.

    Obviously one doesn't want the microcontroller executing non valid opcodes as this is likely to cause the software to fault.

    Hope that helps.

    Thanks,

    Ian