home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / Misc / M2V11-1.LHA / modula / amiga / Alerts.def next >
Encoding:
Text File  |  1993-11-01  |  10.7 KB  |  278 lines

  1. DEFINITION FOR C MODULE Alerts ;
  2.  
  3. (*---------------------------------------------------------------------
  4. |
  5. |  Format of the alert error number:
  6. |
  7. |    +-+-------------+----------------+--------------------------------+
  8. |    |D|  SubSysId   |    General Error |    SubSystem Specific Error    |
  9. |    +-+-------------+----------------+--------------------------------+
  10. |     1    7 bits       8 bits           16 bits
  11. |
  12. |             D:  DeadEnd alert
  13. |          SubSysId:  indicates ROM subsystem number.
  14. |     General Error:  roughly indicates what the error was
  15. |    Specific Error:  indicates more detail
  16. |
  17. ----------------------------------------------------------------------*)
  18.  
  19. (*---------------------------------------------------------------------
  20. |
  21. |  Hardware/CPU specific alerts:  They may show without the 8 at the
  22. |  front of the number.  These are CPU/68000 specific.    See 680x0
  23. |  programmer's manuals for more details.
  24. |
  25. ----------------------------------------------------------------------*)
  26.  
  27. CONST
  28.   ACPU_BusErr     = 080000002H ;    (* Hardware bus fault/access error    *)
  29.   ACPU_AddressErr= 080000003H ;    (* Illegal address access (ie: odd)   *)
  30.   ACPU_InstErr     = 080000004H ;    (* Illegal instruction              *)
  31.   ACPU_DivZero     = 080000005H ;    (* Divide by zero              *)
  32.   ACPU_CHK     = 080000006H ;    (* Check instruction error          *)
  33.   ACPU_TRAPV     = 080000007H ;    (* TrapV instruction error          *)
  34.   ACPU_PrivErr     = 080000008H ;    (* Privilege violation error          *)
  35.   ACPU_Trace     = 080000009H ;    (* Trace error                  *)
  36.   ACPU_LineA     = 08000000AH ;    (* Line 1010 Emulator error          *)
  37.   ACPU_LineF     = 08000000BH ;    (* Line 1111 Emulator error          *)
  38.   ACPU_Format     = 08000000EH ;    (* Stack frame format error          *)
  39.   ACPU_Spurious     = 080000018H ;    (* Spurious interrupt error          *)
  40.   ACPU_AutoVec1     = 080000019H ;    (* AutoVector Level 1 interrupt error *)
  41.   ACPU_AutoVec2     = 08000001AH ;    (* AutoVector Level 2 interrupt error *)
  42.   ACPU_AutoVec3     = 08000001BH ;    (* AutoVector Level 3 interrupt error *)
  43.   ACPU_AutoVec4     = 08000001CH ;    (* AutoVector Level 4 interrupt error *)
  44.   ACPU_AutoVec5     = 08000001DH ;    (* AutoVector Level 5 interrupt error *)
  45.   ACPU_AutoVec6     = 08000001EH ;    (* AutoVector Level 6 interrupt error *)
  46.   ACPU_AutoVec7     = 08000001FH ;    (* AutoVector Level 7 interrupt error *)
  47.  
  48. (*--------------------------------------------------------------------
  49. |
  50. |  General Alerts
  51. |
  52. |  For example: timer.device cannot open math.library would be  = 005038015
  53. |
  54. |    Alert(AN_TimerDev|AG_OpenLib|AO_MathLib) ;
  55. |
  56. ----------------------------------------------------------------------*)
  57.  
  58. (*------ alert types --------*)
  59.   AT_DeadEnd     = 080000000H ;
  60.   AT_Recovery     = 000000000H ;
  61.  
  62. (*------ general purpose alert codes -------*)
  63.  
  64.   AG_NoMemory     = 000010000H ;
  65.   AG_MakeLib     = 000020000H ;
  66.   AG_OpenLib     = 000030000H ;
  67.   AG_OpenDev     = 000040000H ;
  68.   AG_OpenRes     = 000050000H ;
  69.   AG_IOError     = 000060000H ;
  70.   AG_NoSignal     = 000070000H ;
  71.   AG_BadParm     = 000080000H ;
  72.   AG_CloseLib     = 000090000H ;    (* usually too many closes *)
  73.   AG_CloseDev     = 0000A0000H ;    (* or a mismatched close   *)
  74.   AG_ProcCreate     = 0000B0000H ;    (* Process creation failed *)
  75.  
  76. (*------ alert objects: --------*)
  77.   AO_ExecLib     = 000008001H ;
  78.   AO_GraphicsLib = 000008002H ;
  79.   AO_LayersLib     = 000008003H ;
  80.   AO_Intuition     = 000008004H ;
  81.   AO_MathLib     = 000008005H ;
  82.   AO_DOSLib     = 000008007H ;
  83.   AO_RAMLib     = 000008008H ;
  84.   AO_IconLib     = 000008009H ;
  85.   AO_ExpansionLib= 00000800AH ;
  86.   AO_DiskfontLib = 00000800BH ;
  87.   AO_UtilityLib     = 00000800CH ;
  88.   AO_KeyMapLib     = 00000800DH ;
  89.  
  90.   AO_AudioDev     = 000008010H ;
  91.   AO_ConsoleDev     = 000008011H ;
  92.   AO_GamePortDev = 000008012H ;
  93.   AO_KeyboardDev = 000008013H ;
  94.   AO_TrackDiskDev= 000008014H ;
  95.   AO_TimerDev     = 000008015H ;
  96.  
  97.   AO_CIARsrc     = 000008020H ;
  98.   AO_DiskRsrc     = 000008021H ;
  99.   AO_MiscRsrc     = 000008022H ;
  100.  
  101.   AO_BootStrap     = 000008030H ;
  102.   AO_Workbench     = 000008031H ;
  103.   AO_DiskCopy     = 000008032H ;
  104.   AO_GadTools     = 000008033H ;
  105.   AO_Unknown     = 000008035H ;
  106.  
  107. (*--------------------------------------------------------------------
  108. |
  109. |   Specific Alerts:
  110. |
  111. |   For example:   exec.library -- corrupted memory list
  112. |
  113. |        ALERT  AN_MemCorrupt ;8100 0005
  114. |
  115. ----------------------------------------------------------------------*)
  116.  
  117. (*------ exec.library --------*)
  118.   AN_ExecLib      = 001000000H ;
  119.   AN_ExcptVect      = 001000001H ; (* 68000 exception vector checksum (obs.)  *)
  120.   AN_BaseChkSum      = 001000002H ; (* Execbase checksum (obs.)            *)
  121.   AN_LibChkSum      = 001000003H ; (* Library checksum failure             *)
  122.  
  123.   AN_MemCorrupt      = 081000005H ; (* Corrupt memory list detected in FreeMem *)
  124.   AN_IntrMem      = 081000006H ; (* No memory for interrupt servers         *)
  125.   AN_InitAPtr      = 001000007H ; (* InitStruct() of an APTR source (obs.)   *)
  126.   AN_SemCorrupt      = 001000008H ; (* A semaphore is in an illegal state      *)
  127.                  (* at ReleaseSemaphore()                   *)
  128.  
  129.   AN_FreeTwice      = 001000009H ; (* Freeing memory already freed            *)
  130.   AN_BogusExcpt      = 08100000AH ; (* illegal 68k exception taken (obs.)      *)
  131.   AN_IOUsedTwice  = 00100000BH ; (* Attempt to reuse active IORequest       *)
  132.   AN_MemoryInsane = 00100000CH ; (* Sanity check on memory list failed      *)
  133.                  (* during AvailMem(MEMF_LARGEST)           *)
  134.  
  135.   AN_IOAfterClose = 00100000DH ; (* IO attempted on closed IORequest        *)
  136.   AN_StackProbe      = 00100000EH ; (* Stack appears to extend out of range    *)
  137.   AN_BadFreeAddr  = 00100000FH ; (* Memory header not located. [ Usually an *)
  138.                  (* invalid address passed to FreeMem() ]   *)
  139.  
  140.   AN_BadSemaphore = 001000010H ; (* An attempt was made to use the old      *)
  141.                  (* message semaphores.                *)
  142.  
  143. (*------ graphics.library --------*)
  144.   AN_GraphicsLib  = 002000000H ;
  145.   AN_GfxNoMem      = 082010000H ; (* graphics out of memory        *)
  146.   AN_GfxNoMemMspc = 082010001H ; (* MonitorSpec alloc, no memory    *)
  147.   AN_LongFrame      = 082010006H ; (* long frame, no memory        *)
  148.   AN_ShortFrame      = 082010007H ; (* short frame, no memory        *)
  149.   AN_TextTmpRas      = 002010009H ; (* text, no memory for TmpRas        *)
  150.   AN_BltBitMap      = 08201000AH ; (* BltBitMap, no memory        *)
  151.   AN_RegionMemory = 08201000BH ; (* regions, memory not available    *)
  152.   AN_MakeVPort      = 082010030H ; (* MakeVPort, no memory        *)
  153.   AN_GfxNewError  = 00200000CH ;
  154.   AN_GfxFreeError = 00200000DH ;
  155.  
  156.   AN_GfxNoLCM      = 082011234H ; (* emergency memory not available    *)
  157.  
  158.   AN_ObsoleteFont = 002000401H ; (* unsupported font description used    *)
  159.  
  160. (*------ layers.library --------*)
  161.   AN_LayersLib     = 003000000H  ;
  162.   AN_LayersNoMem = 083010000H  ; (* layers out of memory        *)
  163.  
  164. (*------ intuition.library ------*)
  165.   AN_Intuition     = 004000000H ;
  166.   AN_GadgetType     = 084000001H ;    (* unknown gadget type             *)
  167.   AN_BadGadget     = 004000001H ;    (* Recovery form of AN_GadgetType    *)
  168.   AN_CreatePort     = 084010002H ;    (* create port, no memory        *)
  169.   AN_ItemAlloc     = 004010003H ;    (* item plane alloc, no memory        *)
  170.   AN_SubAlloc     = 004010004H ;    (* sub alloc, no memory            *)
  171.   AN_PlaneAlloc     = 084010005H ;    (* plane alloc, no memory        *)
  172.   AN_ItemBoxTop     = 084000006H ;    (* item box top < RelZero        *)
  173.   AN_OpenScreen     = 084010007H ;    (* open screen, no memory        *)
  174.   AN_OpenScrnRast= 084010008H ;    (* open screen, raster alloc, no memory *)
  175.   AN_SysScrnType = 084000009H ;    (* open sys screen, unknown type    *)
  176.   AN_AddSWGadget = 08401000AH ;    (* add SW gadgets, no memory        *)
  177.   AN_OpenWindow     = 08401000BH ;    (* open window, no memory        *)
  178.   AN_BadState     = 08400000CH ;    (* Bad State Return entering Intuition    *)
  179.   AN_BadMessage     = 08400000DH ;    (* Bad Message received by IDCMP    *)
  180.   AN_WeirdEcho     = 08400000EH ;    (* Weird echo causing incomprehension    *)
  181.   AN_NoConsole     = 08400000FH ;    (* couldn't open the Console Device    *)
  182.   AN_NoISem     = 004000010H ;    (* Intuition skipped obtaining a sem    *)
  183.   AN_ISemOrder     = 004000011H ;    (* Intuition obtained a sem in bad order*)
  184.  
  185. (*------ math.library ------*)
  186.   AN_MathLib     = 005000000H ;
  187.  
  188. (*------ dos.library -------*)
  189.   AN_DOSLib     = 007000000H ;
  190.   AN_StartMem     = 007010001H ; (* no memory at startup              *)
  191.   AN_EndTask     = 007000002H ; (* EndTask didn't              *)
  192.   AN_QPktFail     = 007000003H ; (* Qpkt failure                  *)
  193.   AN_AsyncPkt     = 007000004H ; (* Unexpected packet received          *)
  194.   AN_FreeVec     = 007000005H ; (* Freevec failed              *)
  195.   AN_DiskBlkSeq     = 007000006H ; (* Disk block sequence error          *)
  196.   AN_BitMap     = 007000007H ; (* Bitmap corrupt              *)
  197.   AN_KeyFree     = 007000008H ; (* Key already free              *)
  198.   AN_BadChkSum     = 007000009H ; (* Invalid checksum              *)
  199.   AN_DiskError     = 00700000AH ; (* Disk Error                  *)
  200.   AN_KeyRange     = 00700000BH ; (* Key out of range              *)
  201.   AN_BadOverlay     = 00700000CH ; (* Bad overlay                  *)
  202.   AN_BadInitFunc = 00700000DH ; (* Invalid init packet for cli/shell      *)
  203.   AN_FileReclosed= 00700000EH ; (* A filehandle was closed more than once *)
  204.  
  205. (*------ ramlib.library -----*)
  206.   AN_RAMLib     = 008000000H ;
  207.   AN_BadSegList     = 008000001H ;    (* no overlays in library seglists *)
  208.  
  209. (*------ icon.library -------*)
  210.   AN_IconLib     = 009000000H ;
  211.  
  212. (*------ expansion.library -----*)
  213.   AN_ExpansionLib     = 00A000000H ;
  214.   AN_BadExpansionFree = 00A000001H ; (* freeed free region *)
  215.  
  216. (*------ diskfont.library ------*)
  217.   AN_DiskfontLib = 00B000000H ;
  218.  
  219. (*------ audio.device ----------*)
  220.   AN_AudioDev     = 010000000H ;
  221.  
  222. (*------ console.device --------*)
  223.   AN_ConsoleDev     = 011000000H ;
  224.   AN_NoWindow     = 011000001H ;    (* Console can't open initial window *)
  225.  
  226. (*------ gameport.device -------*)
  227.   AN_GamePortDev = 012000000H ;
  228.  
  229. (*------ keyboard.device -------*)
  230.   AN_KeyboardDev = 013000000H ;
  231.  
  232. (*------ trackdisk.device ------*)
  233.   AN_TrackDiskDev = 014000000H ;
  234.   AN_TDCalibSeek  = 014000001H ; (* calibrate: seek error      *)
  235.   AN_TDDelay      = 014000002H ; (* delay: error on timer wait *)
  236.  
  237. (*------ timer.device ---------*)
  238.   AN_TimerDev     = 015000000H ;
  239.   AN_TMBadReq     = 015000001H ; (* bad request                *)
  240.   AN_TMBadSupply = 015000002H ; (* power supply -- no 50/60Hz ticks *)
  241.  
  242. (*------ cia.resource ---------*)
  243.   AN_CIARsrc     = 020000000H ;
  244.  
  245. (*------ disk.resource --------*)
  246.   AN_DiskRsrc     = 021000000H ;
  247.   AN_DRHasDisk     = 021000001H ;    (* get unit: already has disk *)
  248.   AN_DRIntNoAct     = 021000002H ;    (* interrupt: no active unit  *)
  249.  
  250. (*------ misc.resource --------*)
  251.   AN_MiscRsrc     = 022000000H ;
  252.  
  253. (*------ bootstrap --------*)
  254.   AN_BootStrap     = 030000000H ;
  255.   AN_BootError     = 030000001H ;    (* boot code returned an error *)
  256.  
  257. (*------ Workbench --------*)
  258.   AN_Workbench        = 031000000H ;
  259.   AN_NoFonts        = 0B1000001H ;
  260.   AN_WBBadStartupMsg1    = 031000001H ;
  261.   AN_WBBadStartupMsg2   = 031000002H ;
  262.   AN_WBBadIOMsg        = 031000003H ; (* Hacker code?    *)
  263.   AN_WBReLayoutToolMenu    = 0B1010009H ; (* GadTools broke? *)
  264.  
  265. (*------ DiskCopy ---------*)
  266.   AN_DiskCopy     = 032000000H ;
  267.  
  268. (*------ toolkit for Intuition --------*)
  269.   AN_GadTools     = 033000000H ;
  270.  
  271. (*------ System utility library --------*)
  272.   AN_UtilityLib     = 034000000H ;
  273.  
  274. (*------ For use by any application that needs it -------*)
  275.   AN_Unknown     = 035000000H ;
  276.  
  277. END Alerts.
  278.