Guru Meditation
From Wikipedia, the free encyclopedia
Guru Meditation is the name of the error that occurred on early versions of the Amiga home computers when they crashed. It is analogous to the "screens of death" in other operating systems.
Contents |
[edit] Description
When a Guru Meditation is displayed, the options are to reboot by pressing the left mouse button, or to invoke ROMWack by pressing the right mouse button. (ROMWack is a minimalist debugger built into the operating system which is accessible by connecting a 9600 bit/s terminal to the serial port).
The alert itself appears as a black rectangular box located in the upper portion of the screen. Its border and text is red for a normal Guru Meditation, or green/yellow for a Recoverable Alert, another kind of Guru Meditation. The screen goes black, and the power and disk-activity LEDs may blink immediately before the alert appears. In AmigaOS 1.x, programmed in ROMs known as Kickstart 1.1, 1.2 and 1.3, the errors are always red. In AmigaOS 2.x and 3.x, recoverable alerts are yellow, except for some very early versions of 2.x where they were green. Dead-end alerts are red in all OS versions.
This error is sometimes referred to colloquially as a "trip to India," or the "Unwelcome Visitor from the East," or just "alert".
The alert occurred when there was a fatal problem with the system. If the system had no means of recovery, it could display the alert, even in systems with numerous critical flaws. In extreme cases, the alert could even be displayed if the system's memory was completely exhausted.
The error is displayed as two fields, separated by a period. The format is #0000000x.yyyyyyyy in case of a CPU error, or #aabbcccc.dddddddd in case of a system software error. If the first number is "0" the alert is recoverable, otherwise if the first number is "8", then it's a unrecoverable alert (Dead End Alert). The first field is either the Motorola 68000 exception number that occurred (if a CPU error occours) or an internal error identifier (such as an 'Out of Memory' code), in case of a system software error. The second can be the address of a Task structure, or the address of a memory block whose allocation or deallocation failed. It is never the address of the code that caused the error. If the cause of the crash is uncertain, this number is rendered as 48454C50, which stands for "HELP" in hexadecimal ASCII characters (48=H, 45=E, 4C=L, 50=P).
The text of the alert messages was completely baffling to most users. Only highly technically adept Amiga users would know, for example, that exception 3 was an address error, and meant the program was accessing a word on an unaligned boundary. Users without this specialized knowledge would have no recourse but to look for a "Guru" or to simply reboot the machine and hope for the best.
[edit] System software error codes
The first byte specifies the particular area of the system affected. The top bit will be set if the error is a dead end alert.
Area of system | Value | Specific part of system |
---|---|---|
Libraries | 01 | Exec library |
02 | Graphics library | |
03 | Layers library | |
04 | Intuition library | |
05 | Math library | |
06 | CList library | |
07 | AmigaDOS library | |
08 | RAM Handler library | |
09 | Icons library | |
Devices | 10 | Audio device |
11 | Console device | |
12 | Gameport device | |
13 | Keyboard device | |
14 | Trackdisk device | |
15 | Timer device | |
Resources | 20 | CIA resource |
21 | Disk resource | |
22 | Misc resource | |
Other areas | 30 | Bootstrap |
31 | Workbench | |
32 | Diskcopy |
[edit] Origins
The term "Guru Meditation Error" was an in-house joke from Amiga's early days. One of the company's products was the joyboard, a game controller much like a joystick but operated by one's feet. In a game developed for the early Amiga computer, a person would sit cross-legged on the joyboard, resembling an Indian guru. The player was supposed to remain perfectly still with the goal of the game being to stay still the longest. If the player moved, a "guru meditation error" resulted. This error was removed from subsequent versions of the Amiga ROM (Kickstart), but some users chose to patch it back in.
[edit] Trivia
The blinking border of the original guru meditation number was created by writing the border in black 6,809 times and then writing it in red 6,809 times. This was in honor of the Motorola 6809, a popular CPU that was a favourite of the system designers.
Guru Meditation errors are also adopted in Nullsoft Winamp's script engine "MAKI" (Winamp3 and Winamp5 freeform skin engine) when something goes wrong.
[edit] Later versions of AmigaOS
Since version 4.0 (Beta) of the OS, many alerts are replaced by an error handler known as "The Grim Reaper". The Grim Reaper displays the task which caused an error and the nature of the error (illegal memory access etc.), whereupon it presents the user with several options such as suspending/killing the task, displaying more information such as a register dump or attaching a debugger (gdb).
It should also be noted that although the Grim Reaper replaces many of the alerts, the error is still called a "Guru Meditation" as seen in the first screenshot.
The program which caused the particular error used as an example here was the following:
int main(void) { int *bad=0; *bad=0; return(0); }
[edit] See also
[edit] External links
- Guru Meditation code explained
- Joyboard Controller
- Guru Meditation (the introduction page contains an image of the effect)
- CGI::GuruMeditation Perl die handler to catch abnormal CGI termination and visually mimicking Amiga behavior
- Guru Meditation (a simulation of the effect when a corrupted disk is inserted - there are minor changes to the images)