home *** CD-ROM | disk | FTP | other *** search
/ ARM Club 3 / TheARMClub_PDCD3.iso / hensa / programming / oslib / oslib_1 / OSLib / Computer / Hdr / RAMFS < prev    next >
Encoding:
Text File  |  1995-06-22  |  4.0 KB  |  157 lines

  1. ;Assembler header file for RamFS
  2. ;written by DefMod (Jun 12 1995) on Thu Jun 22 12:13:54 1995
  3. ;Jonathan Coxhead, Acorn Computers Ltd
  4.  
  5.         [       :LNOT: :DEF: Get_Types
  6.         GBLS    Get_Types
  7.         ]
  8.         [       :LNOT: :DEF: Types_Hdr
  9. Get_Types                       SETS    "GET OS:Hdr.Types"
  10.         |
  11. Get_Types                       SETS    ""
  12.         ]
  13.         $Get_Types
  14.  
  15.         [       :LNOT: :DEF: Get_OS
  16.         GBLS    Get_OS
  17.         ]
  18.         [       :LNOT: :DEF: OS_Hdr
  19. Get_OS                          SETS    "GET OS:Hdr.OS"
  20.         |
  21. Get_OS                          SETS    ""
  22.         ]
  23.         $Get_OS
  24.  
  25.         [       :LNOT: :DEF: Get_FileCore
  26.         GBLS    Get_FileCore
  27.         ]
  28.         [       :LNOT: :DEF: FileCore_Hdr
  29. Get_FileCore                    SETS    "GET OS:Hdr.FileCore"
  30.         |
  31. Get_FileCore                    SETS    ""
  32.         ]
  33.         $Get_FileCore
  34.  
  35.         [       :LNOT: :DEF: RamFS_Hdr
  36.         GBLS    RamFS_Hdr
  37.  
  38. ;Symbols for SWI's and SWI reason codes
  39. XRamFS_DiscOp                   *       &60780
  40. RamFS_DiscOp                    *       &40780
  41.  
  42. RamFSDiscOp_Verify              *       &0
  43.    ;Entry
  44.    ;  R1 = &0 :OR: flags (Bits)
  45.    ;  R2 = disc_addr (FileCore_DiscAddress)
  46.    ;  R4 = size (Int)
  47.    ;Exit
  48.    ;  R2 = next_disc_addr (FileCore_DiscAddress)
  49.    ;  R4 = unverified (Int)
  50.  
  51. RamFSDiscOp_ReadSectors         *       &1
  52.    ;Entry
  53.    ;  R1 = &1 :OR: flags (Bits)
  54.    ;  R2 = disc_addr (FileCore_DiscAddress)
  55.    ;  R3 = data (pointer to data)
  56.    ;  R4 = size (Int)
  57.    ;Exit
  58.    ;  R2 = next_disc_addr (FileCore_DiscAddress)
  59.    ;  R3 = next_data (pointer to data)
  60.    ;  R4 = unread (Int)
  61.  
  62. RamFSDiscOp_WriteSectors        *       &2
  63.    ;Entry
  64.    ;  R1 = &2 :OR: flags (Bits)
  65.    ;  R2 = disc_addr (FileCore_DiscAddress)
  66.    ;  R3 -> data (data)
  67.    ;  R4 = size (Int)
  68.    ;Exit
  69.    ;  R2 = next_disc_addr (FileCore_DiscAddress)
  70.    ;  R3 -> next_data (data)
  71.    ;  R4 = unwritten (Int)
  72.  
  73. RamFSDiscOp_ReadTrack           *       &3
  74.    ;Entry
  75.    ;  R1 = &3 :OR: flags (Bits)
  76.    ;  R2 = disc_addr (FileCore_DiscAddress)
  77.    ;  R3 = data (pointer to data)
  78.  
  79. RamFSDiscOp_ReadId              *       &3
  80.    ;Entry
  81.    ;  R1 = &3 :OR: flags (Bits)
  82.    ;  R2 = disc_addr (FileCore_DiscAddress)
  83.    ;  R3 = data (pointer to data)
  84.  
  85. RamFSDiscOp_WriteTrack          *       &4
  86.    ;Entry
  87.    ;  R1 = &4 :OR: flags (Bits)
  88.    ;  R2 = disc_addr (FileCore_DiscAddress)
  89.    ;  R3 -> data (data)
  90.  
  91. RamFSDiscOp_FormatTrack         *       &4
  92.    ;Entry
  93.    ;  R1 = &4 :OR: flags (Bits)
  94.    ;  R2 = disc_addr (FileCore_DiscAddress)
  95.    ;  R3 = &0
  96.    ;  R4 -> track_format (FileCore_TrackFormat)
  97.  
  98. RamFSDiscOp_Seek                *       &5
  99.    ;Entry
  100.    ;  R1 = &5 :OR: flags (Bits)
  101.    ;  R2 = disc_addr (FileCore_DiscAddress)
  102.  
  103. RamFSDiscOp_Restore             *       &6
  104.    ;Entry
  105.    ;  R1 = &6 :OR: flags (Bits)
  106.    ;  R2 = disc_addr (FileCore_DiscAddress)
  107.  
  108. RamFSDiscOp_StepIn              *       &7
  109.    ;Entry
  110.    ;  R1 = &7 :OR: flags (Bits)
  111.  
  112. RamFSDiscOp_StepOut             *       &8
  113.    ;Entry
  114.    ;  R1 = &8 :OR: flags (Bits)
  115.  
  116. RamFSDiscOp_ReadSectorsViaCache *       &9
  117.    ;Entry
  118.    ;  R1 = &9 :OR: flags (Bits)
  119.    ;  R2 = disc_addr (FileCore_DiscAddress)
  120.    ;  R3 = data (pointer to data)
  121.    ;  R4 = size (Int)
  122.    ;  R6 = cache_handle (Int)
  123.    ;Exit
  124.    ;  R2 = next_disc_addr (FileCore_DiscAddress)
  125.    ;  R3 = next_data (pointer to data)
  126.    ;  R4 = unread (Int)
  127.    ;  R6 = cache_handle_out (Int)
  128.  
  129. RamFSDiscOp_Specify             *       &F
  130.    ;Entry
  131.    ;  R1 = &F :OR: flags (Bits)
  132.    ;  R2 = disc_addr (FileCore_DiscAddress)
  133.  
  134. XRamFS_Drives                   *       &60782
  135. RamFS_Drives                    *       &40782
  136.    ;Exit
  137.    ;  R0 = default_drive (Int)
  138.    ;  R1 = floppy_count (Int)
  139.    ;  R2 = hard_disc_count (Int)
  140.  
  141. XRamFS_FreeSpace                *       &60783
  142. RamFS_FreeSpace                 *       &40783
  143.    ;Entry
  144.    ;  R0 -> disc_name (String)
  145.    ;Exit
  146.    ;  R0 = free (Int)
  147.    ;  R1 = max (Int)
  148.  
  149. XRamFS_DescribeDisc             *       &60785
  150. RamFS_DescribeDisc              *       &40785
  151.    ;Entry
  152.    ;  R0 -> disc_name (String)
  153.    ;  R1 = disc (pointer to FileCore_Disc)
  154.  
  155.         ]
  156.         END
  157.