home *** CD-ROM | disk | FTP | other *** search
/ Team Palmtops 7 / Palmtops_numero07.iso / Ti / Magazine / Tests / DOORSOSD.ZIP / Doc / ProgFormat.txt < prev    next >
Encoding:
Text File  |  1999-04-05  |  2.5 KB  |  77 lines

  1.         Format of 89 and 92+ ASM files
  2.         ------------------------------
  3.  
  4. Sorry this file is not very well explained yet.
  5.  
  6.  
  7. Offset    Size    Desc
  8. --------------------
  9. $0    4    Bsr to the loader code
  10. $4    4    68k ASM Signature "68kP" or "68kL"
  11. $8    2    Reloc count
  12. $A    2    offset to _comment
  13. $C    2    offset to _main
  14. $E    2    offset to _exit
  15. $10    2    compatibility and special flags
  16.          bit 0 - runs on 92+
  17.          bit 1 - runs on 89
  18.          bit 14 - used internally by DoorsOS. If set, the file is temporarily unarchived
  19.          bit 15 - TI-89 emulation (force 89 screen size on 92+)
  20. $12    2    handle of BSS block ; when program is in use
  21. $14    2    offset to BSS table
  22. $16    2    offset to export table
  23. $18    2    offset to Extra RAM table
  24. $1A    2+NA    Import Table
  25. NA    2+NA    ROM Table
  26. NA    2+NA    RAM Table
  27. NA    2+NA    Relocation table
  28. NA    4+NA    BSS Table
  29. NA    2+NA    Export Table
  30.  
  31.  
  32. Format of Import Table
  33. 1st word: nb of libs used
  34. Then is the libs name list: each lib name is 10 bytes:
  35. 8 chars + a word at the end
  36.  
  37.     Then, for each lib is a lib reloc table:
  38.  
  39.     1st word: nb of functions used in this lib - 1 (for the dbra)
  40.         Then, for each function is a table:
  41.         1st word: index of the library function used
  42.             Then is a null terminated list of offsets (words).
  43.  
  44.  
  45. Format of ROM Table
  46. 1st word: if null, there is no ROM call.
  47. Then is a reloc table which is like a lib reloc table.
  48.  
  49. Format of extra RAM address table
  50. 1st word: if null, there are no extra RAM addresses
  51. Then there are pairs of words.  The first word is the address on the
  52. 89 and the second word is the address on the 92+.  The list is
  53. terminated by a null word.
  54.  
  55. Format of RAM table
  56. 1st word: if null, there are no RAM address/value references
  57. Next word: nb of RAM addresses/values used  - 1 (for the dbra)
  58.     Then, for each address/value is a table:
  59.         1st word: index of the RAM address/value used
  60.             Then is a null terminated list of offsets (words).
  61. RAM address/value index is this:
  62. Bit 0-13:  RAM address number.  If bit 14 is not set, they are as follows:
  63.        
  64. Bit 14:   Set if an "extra" RAM address (not defined by the kernel).
  65.       The address is stored in the extra RAM address table.
  66. Bit 15:   Set if reference is word, clear if reference is dword
  67.  
  68. Format of BSS Table
  69. 1st Long Word: size of the BSS block to allocate.
  70. Then is a null terminated list of offsets (words)
  71.  
  72. Format of Export Table
  73. 1st word : nb of functions exported
  74. Then is a null terminated list of offsets (words)
  75.  
  76. Format of relocation Table
  77. This is a null terminated list of offsets (words).