BC
Description
This command can be used to query the last crash information. Like any complex computer system, the Avisaro Module can probably crash due to bugs in the firmware or faulty BASIC scripts. If such breakdown occurs, the module stores crash information into battery powered RAM and re-starts itself.
If crash information is available, BC? outputs a line containing seven parts separated by spaces. These are, from left to right:
- Exception Reason
PRE -- Instruction fetch memory abort. The processor tried to execute code at an undefined address.
DAT -- Data access memory abort. The processor tries to read from or write to an undefined address.
UND -- Undefined instruction. The processor tried to decode an instruction that is not part of the ARM7 instruction set.
BRW -- Brown out. Low peak of supply voltage below 2.95V.
- Processor state when exception happened
ARM -- The processor was in ARM state.
TMB -- The processor was in THUMB state.
- Processor mode when exception happened
USR -- The processor was in normal "user" mode.
FIQ -- The processor was executing a fast interrupt routine.
IRQ -- The processor was executing a general interrupt routine.
SUP -- The processor was in "supervisor" mode.
ABT -- The processor emulates virtual memory. (not used)
UND -- The processor emulates code for a co-processor. (not used)
SYS -- The processor was in "system" (highest privilege) mode.
- Date when exception happened
- Time when exception happened
- The value of the instruction pointer when exception happend
This is a hexadecimal value without leading zeros.
- The value of the status register when exception happend
Also a hex value without leading zeros
Parameters
BC? does not need any arguments.
Return Value
The return value is always ERR_OK (0)
Example
BC?
Example Output
BRW ARM SUP 2008/01/01 22:46:20 13a14 60000013
Remarks
Exception information is only stored among power on/offs if the module has a battery (usually used to keep the RTC running). When a crash occurs, the module reboots.