Search found 105 matches
- Tue Feb 19, 2019 3:09 am
- Forum: Cortex-M0, M3, M4 and M7
- Topic: ISR Use of Registers; Privileged Mode?
- Replies: 5
- Views: 28731
ISR Use of Registers; Privileged Mode?
Two questions: With an interrupt, only R0 to R3 [1] are pushed onto the stack upon entry of the ISR. Does the compiler automatically account for this limitation when compiling ISRs, or is there anything I need to take care of manually? Does all thread mode (ie. not handler) code run privileged? Is t...
- Mon Feb 18, 2019 10:12 am
- Forum: Astrobe for ARM Cortex-M0, M3, M4 and M7
- Topic: user traps
- Replies: 7
- Views: 28436
Re: user traps
Here's a version that works without changing Traps.mod, using the vector swapping technique (relevant excerpt from my Kernel.mod module, leaving out the SysTick business). CONST ... SVC_Instruction = 0DF00H; SVC_Vector = 02CH; VAR ... sysHandler: PROCEDURE; svcTrapAddr: INTEGER; PROCEDURE svcHandler...
- Mon Feb 18, 2019 9:26 am
- Forum: Astrobe for ARM Cortex-M0, M3, M4 and M7
- Topic: user traps
- Replies: 7
- Views: 28436
Re: user traps
I want to use the SVC call/mechanism not only for error handling, but also executing code that is safe from interference by interrupt service routines (ISR), eg. to avoid race conditions. Thusly executed code must be small and fast for the least possible interference with the incoming interrupts. As...
- Wed Feb 13, 2019 4:22 am
- Forum: Cortex-M0, M3, M4 and M7
- Topic: Call Stack
- Replies: 3
- Views: 23069
Re: Call Stack
IMO, that would be a great addition to the debugging toolbox. The location of an error is a good start and mostly helpful for modules of your main controller-logic, but for library modules that are used from different locations, to know what calls lead to an error is crucial. I am also confident tha...
- Tue Feb 12, 2019 7:30 am
- Forum: Cortex-M0, M3, M4 and M7
- Topic: Call Stack
- Replies: 3
- Views: 23069
Call Stack
If a run-time error occurs, or a user-trap is triggered, is it possible to get (print, or create/retrieve a data structure such as a linked list) the call stack, ie. the chain of procedure calls that resulted in the trap? Thanks.