Mercurial > hg > Members > kono > nitros9-code
annotate defs/os9.d @ 3041:7a78f43d97c1
makefile: Prepare for improved nightly upload burst script
If uploader and server are in different time zones, the dates might
not match, so let the uploader specify the date to be used.
Let the uploader specify the name as well, allowing burst to become
a more generic tool.
author | Tormod Volden <debian.tormod@gmail.com> |
---|---|
date | Fri, 23 Jan 2015 23:35:28 +0100 |
parents | 482a547d5155 |
children | 145bbd061aa0 |
rev | line source |
---|---|
2624 | 1 IFNE OS9.D-1 |
2 | |
3 OS9.D SET 1 | |
4 | |
5 ******************************************************************** | |
6 * os9.d - NitrOS-9 System Definitions | |
7 * | |
8 * $Id$ | |
9 * | |
10 * Edt/Rev YYYY/MM/DD Modified by | |
11 * Comment | |
12 * ------------------------------------------------------------------ | |
13 * 1985/08/29 KMZ | |
14 * Fixed DT.SBF/NFM values to 3/4 | |
15 * | |
16 * 1985/09/01 KMZ | |
17 * Added SS.FDInf, SS.Attr to accept 68K request thru NET. | |
18 * | |
19 * 1985/09/03 KMZ/Robert F. Doggett | |
20 * Eliminated E$BPrcID, made Error #238 become E$DNE for | |
21 * 68000 compatability. | |
22 * | |
23 * 1986/04/15 Mark G. Hawkins | |
24 * F$AlHRAM System call added for COCO. | |
25 * | |
26 * 1986/09/08 Mark G. Hawkins | |
27 * F$Alarm for COCO Clock Module. | |
28 * | |
29 * 1986/09/17 Mark G. Hawkins | |
30 * SS.Tone For COCO. | |
31 * | |
32 * 1986/09/23 Mark G. Hawkins | |
33 * Added F$NMLink and F$NMLoad for COCO. | |
34 * | |
35 * 1986/09/30 Mark G. Hawkins | |
36 * Added Reserved User $70 to $7f in sytem calls. | |
37 * | |
38 * 1986/09/30 Mark G. Hawkins | |
39 * Created Color Computer 3 Version of OS9Defs. | |
40 * | |
41 * 1998/10/03 Boisy G. Pitre | |
42 * Consoldated Level 1/Level 2 os9defs. | |
43 * | |
44 * 2002/04/04 Boisy G. Pitre | |
45 * Consoldated Level 2/Level 2 V3 os9defs. | |
46 * | |
47 * 2002/04/30 Boisy G. Pitre | |
48 * Added NitrOS-9 definitions. | |
49 * | |
50 * 2003/05/30 Boisy G. Pitre | |
51 * Added WD1002 sys vars to Level One section. | |
52 * | |
53 * 2003/06/02 Boisy G. Pitre | |
54 * Fixed incorrectly ordered D.X*** system globals for OS-9 Level One and | |
55 * changed the sizes from 2 to 3 bytes. | |
56 * DT.NFM is now the same for both Level One and Level Two. | |
57 * Added DT.CDFM type for future CD-ROM file manager | |
58 * | |
59 * 2003/11/05 Robert Gault | |
60 * Fixed MouseInf. Made it rmb 2 as it should be. Also changes to init and cc3io. | |
61 * | |
62 * 2005/11/02 P.Harvey-Smith | |
63 * Added definitions for boot areas on Dragon computers. | |
64 * | |
65 * 2006/03/03 Boisy G. Pitre | |
66 * Added F$Debug and D.DbgMem areas, common to all levels of NitrOS-9 | |
67 | |
68 NAM os9.d | |
69 IFEQ Level-1 | |
70 TTL NitrOS-9 Level 1 System Symbol Definitions | |
71 ELSE | |
72 IFEQ Level-2 | |
73 TTL NitrOS-9 Level 2 System Symbol Definitions | |
74 ELSE | |
75 TTL NitrOS-9 Level 3 System Symbol Definitions | |
76 ENDC | |
77 ENDC | |
78 | |
79 * Common definitions | |
80 true EQU 1 useful name | |
81 false EQU 0 useful name | |
82 | |
83 PAG | |
84 ***************************************** | |
85 * System Service Request Code Definitions | |
86 * | |
87 ORG 0 | |
88 F$Link RMB 1 Link to Module | |
89 F$Load RMB 1 Load Module from File | |
90 F$UnLink RMB 1 Unlink Module | |
91 F$Fork RMB 1 Start New Process | |
92 F$Wait RMB 1 Wait for Child Process to Die | |
93 F$Chain RMB 1 Chain Process to New Module | |
94 F$Exit RMB 1 Terminate Process | |
95 F$Mem RMB 1 Set Memory Size | |
96 F$Send RMB 1 Send Signal to Process | |
97 F$Icpt RMB 1 Set Signal Intercept | |
98 F$Sleep RMB 1 Suspend Process | |
99 F$SSpd RMB 1 Suspend Process | |
100 F$ID RMB 1 Return Process ID | |
101 F$SPrior RMB 1 Set Process Priority | |
102 F$SSWI RMB 1 Set Software Interrupt | |
103 F$PErr RMB 1 Print Error | |
104 F$PrsNam RMB 1 Parse Pathlist Name | |
105 F$CmpNam RMB 1 Compare Two Names | |
106 F$SchBit RMB 1 Search Bit Map | |
107 F$AllBit RMB 1 Allocate in Bit Map | |
108 F$DelBit RMB 1 Deallocate in Bit Map | |
109 F$Time RMB 1 Get Current Time | |
110 F$STime RMB 1 Set Current Time | |
111 F$CRC RMB 1 Generate CRC ($17) | |
112 | |
113 IFGT Level-1 | |
114 | |
115 * NitrOS-9 Level 2 system calls | |
116 F$GPrDsc RMB 1 Get Process Descriptor copy ($18) | |
117 F$GBlkMp RMB 1 Get System Block Map copy ($19) | |
118 F$GModDr RMB 1 Get Module Directory copy ($1A) | |
119 F$CpyMem RMB 1 Copy External Memory ($1B) | |
120 F$SUser RMB 1 Set User ID number ($1C) | |
121 F$UnLoad RMB 1 Unlink Module by name ($1D) | |
122 F$Alarm RMB 1 Color Computer 3 Alarm Call ($1E) | |
123 RMB 2 Reserved - For overlap of other systems ($1F) | |
124 F$NMLink RMB 1 Color Computer 3 Non-Mapping Link ($21) | |
125 F$NMLoad RMB 1 Color Computer 3 Non-Mapping Load ($22) | |
126 | |
127 ELSE | |
128 | |
129 * NitrOS-9 Level 1 system call padding | |
130 RMB 11 | |
131 | |
132 ENDC | |
133 | |
134 F$Debug RMB 1 Drop the system into the debugger ($23) | |
135 | |
136 IFGT Level-1 | |
137 | |
138 ORG $25 | |
139 F$TPS RMB 1 Return System's Ticks Per Second | |
140 F$TimAlm RMB 1 CoCo individual process alarm call | |
141 | |
142 ENDC | |
143 | |
144 ORG $27 Beginning of System Reserved Calls | |
145 * NitrOS-9 common system calls | |
146 F$VIRQ RMB 1 Install/Delete Virtual IRQ | |
147 F$SRqMem RMB 1 System Memory Request | |
148 F$SRtMem RMB 1 System Memory Return | |
149 F$IRQ RMB 1 Enter IRQ Polling Table | |
150 F$IOQu RMB 1 Enter I/O Queue | |
151 F$AProc RMB 1 Enter Active Process Queue | |
152 F$NProc RMB 1 Start Next Process | |
153 F$VModul RMB 1 Validate Module | |
154 F$Find64 RMB 1 Find Process/Path Descriptor | |
155 F$All64 RMB 1 Allocate Process/Path Descriptor | |
156 F$Ret64 RMB 1 Return Process/Path Descriptor | |
157 F$SSvc RMB 1 Service Request Table Initialization | |
158 F$IODel RMB 1 Delete I/O Module | |
159 | |
160 IFGT Level-1 | |
161 | |
162 F$SLink RMB 1 System Link | |
163 F$Boot RMB 1 Bootstrap System | |
164 F$BtMem RMB 1 Bootstrap Memory Request | |
165 F$GProcP RMB 1 Get Process ptr | |
166 F$Move RMB 1 Move Data (low bound first) | |
167 F$AllRAM RMB 1 Allocate RAM blocks | |
168 F$AllImg RMB 1 Allocate Image RAM blocks | |
169 F$DelImg RMB 1 Deallocate Image RAM blocks | |
170 F$SetImg RMB 1 Set Process DAT Image | |
171 F$FreeLB RMB 1 Get Free Low Block | |
172 F$FreeHB RMB 1 Get Free High Block | |
173 F$AllTsk RMB 1 Allocate Process Task number | |
174 F$DelTsk RMB 1 Deallocate Process Task number | |
175 F$SetTsk RMB 1 Set Process Task DAT registers | |
176 F$ResTsk RMB 1 Reserve Task number | |
177 F$RelTsk RMB 1 Release Task number | |
178 F$DATLog RMB 1 Convert DAT Block/Offset to Logical | |
179 F$DATTmp RMB 1 Make temporary DAT image (Obsolete) | |
180 F$LDAXY RMB 1 Load A [X,[Y]] | |
181 F$LDAXYP RMB 1 Load A [X+,[Y]] | |
182 F$LDDDXY RMB 1 Load D [D+X,[Y]] | |
183 F$LDABX RMB 1 Load A from 0,X in task B | |
184 F$STABX RMB 1 Store A at 0,X in task B | |
185 F$AllPrc RMB 1 Allocate Process Descriptor | |
186 F$DelPrc RMB 1 Deallocate Process Descriptor | |
187 F$ELink RMB 1 Link using Module Directory Entry | |
188 F$FModul RMB 1 Find Module Directory Entry | |
189 F$MapBlk RMB 1 Map Specific Block | |
190 F$ClrBlk RMB 1 Clear Specific Block | |
191 F$DelRAM RMB 1 Deallocate RAM blocks | |
192 F$GCMDir RMB 1 Pack module directory | |
193 F$AlHRAM RMB 1 Allocate HIGH RAM Blocks | |
194 | |
195 * Alan DeKok additions | |
196 F$ReBoot RMB 1 Reboot machine (reload OS9Boot) or drop to RSDOS | |
197 F$CRCMod RMB 1 CRC mode, toggle or report current status | |
198 F$XTime RMB 1 Get Extended time packet from RTC (fractions of second) | |
199 F$VBlock RMB 1 Verify modules in a block of memory, add to module directory | |
200 | |
201 ENDC | |
202 | |
203 * | |
204 * Numbers $70 through $7F are reserved for user definitions | |
205 * | |
206 ORG $70 | |
207 | |
208 IFEQ Level-1 | |
209 | |
210 RMB 16 Reserved for user definition | |
211 | |
212 ELSE | |
213 | |
214 F$RegDmp RMB 1 Ron Lammardo's debugging register dump | |
215 F$NVRAM RMB 1 Non Volatile RAM (RTC battery backed static) read/write | |
216 | |
217 RMB $80-. Reserved for user definitions | |
218 ENDC | |
219 | |
220 PAG | |
221 ************************************** | |
222 * I/O Service Request Code Definitions | |
223 * | |
224 ORG $80 | |
225 I$Attach RMB 1 Attach I/O Device | |
226 I$Detach RMB 1 Detach I/O Device | |
227 I$Dup RMB 1 Duplicate Path | |
228 I$Create RMB 1 Create New File | |
229 I$Open RMB 1 Open Existing File | |
230 I$MakDir RMB 1 Make Directory File | |
231 I$ChgDir RMB 1 Change Default Directory | |
232 I$Delete RMB 1 Delete File | |
233 I$Seek RMB 1 Change Current Position | |
234 I$Read RMB 1 Read Data | |
235 I$Write RMB 1 Write Data | |
236 I$ReadLn RMB 1 Read Line of ASCII Data | |
237 I$WritLn RMB 1 Write Line of ASCII Data | |
238 I$GetStt RMB 1 Get Path Status | |
239 I$SetStt RMB 1 Set Path Status | |
240 I$Close RMB 1 Close Path | |
241 I$DeletX RMB 1 Delete from current exec dir | |
242 | |
243 ******************* | |
244 * File Access Modes | |
245 * | |
246 READ. EQU %00000001 | |
247 WRITE. EQU %00000010 | |
248 UPDAT. EQU READ.+WRITE. | |
249 EXEC. EQU %00000100 | |
250 PREAD. EQU %00001000 | |
251 PWRIT. EQU %00010000 | |
252 PEXEC. EQU %00100000 | |
253 SHARE. EQU %01000000 | |
254 DIR. EQU %10000000 | |
255 ISIZ. EQU %00100000 | |
256 | |
257 ************** | |
258 * Signal Codes | |
259 * | |
260 ORG 0 | |
261 S$Kill RMB 1 Non-Interceptable Abort | |
262 S$Wake RMB 1 Wake-up Sleeping Process | |
263 S$Abort RMB 1 Keyboard Abort | |
264 S$Intrpt RMB 1 Keyboard Interrupt | |
265 S$Window RMB 1 Window Change | |
266 S$HUP EQU S$Window Hang Up | |
267 S$Alarm RMB 1 CoCo individual process' alarm signal | |
268 | |
269 PAG | |
270 ********************************** | |
271 * Status Codes for GetStat/GetStat | |
272 * | |
273 ORG 0 | |
274 SS.Opt RMB 1 Read/Write PD Options | |
275 SS.Ready RMB 1 Check for Device Ready | |
276 SS.Size RMB 1 Read/Write File Size | |
277 SS.Reset RMB 1 Device Restore | |
278 SS.WTrk RMB 1 Device Write Track | |
279 SS.Pos RMB 1 Get File Current Position | |
280 SS.EOF RMB 1 Test for End of File | |
281 SS.Link RMB 1 Link to Status routines | |
282 SS.ULink RMB 1 Unlink Status routines | |
283 SS.Feed RMB 1 Issue form feed | |
284 SS.Frz RMB 1 Freeze DD. information | |
285 SS.SPT RMB 1 Set DD.TKS to given value | |
286 SS.SQD RMB 1 Sequence down hard disk | |
287 SS.DCmd RMB 1 Send direct command to disk | |
288 SS.DevNm RMB 1 Return Device name (32-bytes at [X]) | |
289 SS.FD RMB 1 Return File Descriptor (Y-bytes at [X]) | |
290 SS.Ticks RMB 1 Set Lockout honor duration | |
291 SS.Lock RMB 1 Lock/Release record | |
292 SS.DStat RMB 1 Return Display Status (CoCo) | |
293 SS.Joy RMB 1 Return Joystick Value (CoCo) | |
294 SS.BlkRd RMB 1 Block Read | |
295 SS.BlkWr RMB 1 Block Write | |
296 SS.Reten RMB 1 Retension cycle | |
297 SS.WFM RMB 1 Write File Mark | |
298 SS.RFM RMB 1 Read past File Mark | |
299 SS.ELog RMB 1 Read Error Log | |
300 SS.SSig RMB 1 Send signal on data ready | |
301 SS.Relea RMB 1 Release device | |
302 SS.AlfaS RMB 1 Return Alfa Display Status (CoCo, SCF/GetStat) | |
303 SS.Attr EQU SS.AlfaS To serve 68K/RBF/SetStat only, thru NET | |
304 SS.Break RMB 1 Send break signal out acia | |
305 SS.RsBit RMB 1 Reserve bitmap sector (do not allocate in) LSB(X)=sct# | |
306 RMB 1 Reserved | |
307 SS.FDInf EQU $20 To serve 68K/RBF/GetStat only, thru NET | |
2658
fbf145e9d668
Renamed rfmdefs to rfm.d
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2630
diff
changeset
|
308 SS.DirEnt RMB 1 Reserve bitmap sector (do not allocate in) LSB(X)=sct# |
fbf145e9d668
Renamed rfmdefs to rfm.d
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2630
diff
changeset
|
309 RMB 3 Reserve $20-$23 for Japanese version (Hoshi) |
2624 | 310 SS.SetMF RMB 1 Reserve $24 for Gimix G68 (Flex compatability?) |
311 SS.Cursr RMB 1 Cursor information for COCO | |
312 SS.ScSiz RMB 1 Return screen size for COCO | |
313 SS.KySns RMB 1 Getstat/SetStat for COCO keyboard | |
314 SS.ComSt RMB 1 Getstat/SetStat for Baud/Parity | |
315 SS.Open RMB 1 SetStat to tell driver a path was opened | |
316 SS.Close RMB 1 SetStat to tell driver a path was closed | |
317 SS.HngUp RMB 1 SetStat to tell driver to hangup phone | |
318 SS.FSig RMB 1 New signal for temp locked files | |
319 SS.DSize EQU SS.ScSiz Return disk size (RBF GetStat) | |
320 SS.VarSect EQU SS.DStat Variable Sector Size (RBF GetStat) | |
321 | |
322 * System Specific and User defined codes above $80 | |
323 ORG $80 | |
324 SS.AAGBf RMB 1 SetStat to Allocate Additional Graphic Buffer | |
325 SS.SLGBf RMB 1 SetStat to Select a different Graphic Buffer | |
326 SS.Mount RMB 1 Network 4 Mount Setstat | |
327 SS.RdNet RMB 1 Read Raw Sector from Network 4 Omnidrive | |
328 SS.MpGPB RMB 1 SetStat to request a Get/Put Buffer be mapped in workspace | |
329 SS.Slots RMB 1 Network 4 slots? getstat | |
330 | |
2661
9e9ed6d6b4c2
Updated so that scdwn handles SS.Montr
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2658
diff
changeset
|
331 * IFGT Level-1 |
9e9ed6d6b4c2
Updated so that scdwn handles SS.Montr
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2658
diff
changeset
|
332 IFNE 1 |
2624 | 333 * Level 2 Windowing |
334 SS.WnSet RMB 1 Set up High Level Windowing Information | |
335 SS.MnSel RMB 1 Request High level Menu Handler take determine next event | |
336 SS.SBar RMB 1 SetStat to set position block on Window scroll bars | |
337 SS.Mouse RMB 1 Return Mouse information packet (COCO) | |
338 SS.MsSig RMB 1 SetStat to tell driver to send signal on mouse event | |
339 SS.AScrn RMB 1 Allocate a screen for application poking | |
340 SS.DScrn RMB 1 Display a screen allocated by SS.AScrn | |
341 SS.FScrn RMB 1 Free a screen allocated by SS.AScrn | |
342 SS.PScrn RMB 1 Polymorph Screen into different screen type | |
343 SS.ScInf RMB 1 Get Current screen info for direct writes | |
344 RMB 1 Reserved | |
345 SS.Palet RMB 1 Return palette information | |
346 SS.Montr RMB 1 Get and Set Monitor Type | |
347 SS.ScTyp RMB 1 Get screen type information | |
348 SS.GIP RMB 1 Global Input Parameters (SetStat) | |
349 SS.UMBar RMB 1 update menu bar (SetStat) | |
350 SS.FBRgs RMB 1 return color registers (GetStat) | |
351 SS.DfPal RMB 1 set/return default palette registers (Getstat/Setstat) | |
352 SS.Tone RMB 1 Generate a tone using 6 bit sound | |
353 SS.GIP2 RMB 1 Global Input Params #2 (L2V3) | |
354 SS.AnPal RMB 1 Animate palettes (L2V3) | |
355 SS.FndBf RMB 1 Find named buffer (L2V3) | |
356 | |
357 * sc6551 defined | |
358 SS.CDSta EQU SS.GIP2 | |
359 SS.CDSig EQU SS.AnPal | |
360 SS.CDRel EQU SS.FndBf | |
361 ELSE | |
362 * These are wide open in Level 1 | |
363 RMB 19 | |
364 | |
365 * sc6551 defined | |
366 SS.CDSta RMB 1 | |
367 SS.CDSig RMB 1 | |
368 SS.CDRel RMB 1 | |
369 ENDC | |
370 | |
371 ORG $A0 | |
372 * | |
373 * New Default SCF input buffer Set status call | |
374 SS.Fill RMB 1 Pre-load SCF device input buffer | |
375 SS.Hist RMB 1 Enable command-line history easily | |
376 | |
377 | |
378 ORG $B0 | |
379 * | |
380 * New WDDisk get/set status calls | |
381 SS.ECC RMB 1 ECC corrected data error enable/disable (GetStat/SetStat) | |
382 | |
383 * | |
384 IFGT Level-1 | |
385 | |
386 * VRN get/set status calls. Named by Alan DeKok. | |
387 SS.VCtr EQU $80 Return FS2 total VIRQ counter | |
388 SS.VSig EQU $81 Return FS2 number of signals sent | |
389 | |
390 SS.FClr EQU $81 Set/clear FS2 VIRQ | |
391 SS.FSet EQU $C7 Set FS2+ VIRQ | |
392 SS.KSet EQU $C8 Set KQ3 VIRQ | |
393 SS.KClr EQU $C9 Clr KQ3 VIRQ | |
394 SS.ARAM EQU $CA Allocate RAM blocks | |
395 SS.DRAM EQU $CB De-allocate RAM blocks | |
396 | |
397 * SDisk 3 Definition Equates | |
398 SS.DRead EQU SS.AAGBf SDisk3 Direct Sector Read ($80) | |
399 SS.DWrit EQU SS.DRead SDisk3 Direct sector Write ($80) | |
400 SS.UnFrz EQU SS.SLGBf SDisk3 UNFreeze DD info ($81) | |
401 SS.MOFF EQU SS.Mount SDisk3 fast motor off call ($82) | |
402 SS.MoTim EQU SS.RdNet SDisk3 Set motor shut off time ($83) | |
403 SS.SDRD EQU SS.MpGPB SDisk3 System direct read ($84) | |
404 SS.SDWRT EQU SS.SDRD SDisk3 System direct writes ($84) | |
405 SS.Sleep EQU SS.Slots SDisk3 (DMC ONLY) Enable/disable F$Sleep calls in read/write 1773 I/O ($85) | |
406 SS.DrvCh EQU SS.WnSet SDisk3 (DMC ONLY) Set drive number to cache, or return drive number being cached ($86) | |
407 | |
408 ENDC | |
409 | |
410 TTL Direct Page Definitions | |
411 PAG | |
412 | |
413 ********************************** | |
414 * Direct Page Variable Definitions | |
415 * | |
416 ORG $00 | |
417 D.WDAddr RMB 2 FHL/Isted WD1002-05 interface base address | |
418 D.WDBtDr RMB 1 FHL/Isted WD1002-05 boot physical device drive num. | |
419 D.SWPage RMB 1 SmartWatch page # (see clock2_smart) | |
420 RMB 5 | |
421 D.COCOXT RMB 1 Busy flag for CoCo-XT driver (one drive at a time) | |
422 D.DbgMem RMB 2 Debug memory pointer | |
423 D.DWSubAddr RMB 2 DriveWire subroutine module pointer | |
424 D.DWStat RMB 2 DriveWire statics page | |
2720
482a547d5155
Fixed so OP_DWINIT puts response in globals
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2661
diff
changeset
|
425 D.DWSrvID RMB 1 DriveWire server ID |
2624 | 426 |
427 ORG $20 | |
428 | |
429 IFEQ Level-1 | |
430 | |
431 * Level 1 DP vars | |
432 D.FMBM RMB 4 Free memory bit map pointers | |
433 D.MLIM RMB 2 Memory limit $24 | |
434 D.ModDir RMB 4 Module directory $26 | |
435 D.Init RMB 2 Rom base address $2A | |
436 D.SWI3 RMB 2 Swi3 vector $2C | |
437 D.SWI2 RMB 2 Swi2 vector $2E | |
438 D.FIRQ RMB 2 Firq vector $30 | |
439 D.IRQ RMB 2 Irq vector $32 | |
440 D.SWI RMB 2 Swi vector $34 | |
441 D.NMI RMB 2 Nmi vector $36 | |
442 D.SvcIRQ RMB 2 Interrupt service entry $38 | |
443 D.Poll RMB 2 Interrupt polling routine $3A | |
444 D.UsrIRQ RMB 2 User irq routine $3C | |
445 D.SysIRQ RMB 2 System irq routine $3E | |
446 D.UsrSvc RMB 2 User service request routine $40 | |
447 D.SysSvc RMB 2 System service request routine $42 | |
448 D.UsrDis RMB 2 User service request dispatch table | |
449 D.SysDis RMB 2 System service reuest dispatch table | |
450 D.Slice RMB 1 Process time slice count $48 | |
451 D.PrcDBT RMB 2 Process descriptor block address $49 | |
452 D.Proc RMB 2 Process descriptor address $4B | |
453 D.AProcQ RMB 2 Active process queue $4D | |
454 D.WProcQ RMB 2 Waiting process queue $4F | |
455 D.SProcQ RMB 2 Sleeping process queue $51 | |
456 D.Time EQU . Time | |
457 D.Year RMB 1 $53 | |
458 D.Month RMB 1 $54 | |
459 D.Day RMB 1 $55 | |
460 D.Hour RMB 1 $56 | |
461 D.Min RMB 1 $57 | |
462 D.Sec RMB 1 $58 | |
463 D.Tick RMB 1 $59 | |
464 D.TSec RMB 1 Ticks / second $5A | |
465 D.TSlice RMB 1 Ticks / time-slice $5B | |
466 D.IOML RMB 2 I/O mgr free memory low bound $5C | |
467 D.IOMH RMB 2 I/O mgr free memory hi bound $5E | |
468 D.DevTbl RMB 2 Device driver table addr $60 | |
469 D.PolTbl RMB 2 Irq polling table addr $62 | |
470 D.PthDBT RMB 2 Path descriptor block table addr $64 | |
471 D.BTLO RMB 2 Bootstrap low address $66 | |
472 D.BTHI RMB 2 Bootstrap hi address $68 | |
473 D.DMAReq RMB 1 DMA in use flag $6A | |
474 D.AltIRQ RMB 2 Alternate IRQ vector (CC) $6B | |
475 D.KbdSta RMB 2 Keyboard scanner static storage (CC) $6D | |
476 D.DskTmr RMB 2 Disk Motor Timer (CC) $6F | |
477 D.CBStrt RMB 16 reserved for CC warmstart ($71) | |
478 D.Clock RMB 2 Address of Clock Tick Routine (CC) $81 | |
479 D.Boot RMB 1 Bootstrap attempted flag | |
480 D.URtoSs RMB 2 address of user to system routine (VIRQ) $84 | |
481 D.CLTb RMB 2 Pointer to clock interrupt table (VIRQ) $86 | |
482 D.MDREG RMB 1 6309 MD (mode) shadow register $88 (added in V2.01.00) | |
483 D.CRC RMB 1 CRC checking mode flag $89 (added in V2.01.00) | |
484 D.Clock2 RMB 2 CC Clock2 entry address | |
485 | |
486 ORG $100 | |
2630
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
487 *D.XSWI3 RMB 3 |
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
488 *D.XSWI2 RMB 3 |
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
489 *D.XFIRQ RMB 3 |
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
490 *D.XIRQ RMB 3 |
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
491 *D.XSWI RMB 3 |
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
492 *D.XNMI RMB 3 |
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
493 |
2624 | 494 D.XSWI3 RMB 3 |
495 D.XSWI2 RMB 3 | |
496 D.XSWI RMB 3 | |
497 D.XNMI RMB 3 | |
2630
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
498 D.XIRQ RMB 3 |
e310e8613606
Fixed earlier change from yesterday due to misunderstanding of ordering of 6809 vectors on CoCo 1/2...
Boisy Pitre <boisy.pitre@nuance.com>
parents:
2624
diff
changeset
|
499 D.XFIRQ RMB 3 |
2624 | 500 |
501 * Table Sizes | |
502 BMAPSZ EQU 32 Bitmap table size | |
503 SVCTNM EQU 2 Number of service request tables | |
504 SVCTSZ EQU (256-BMAPSZ)/SVCTNM-2 Service request table size | |
505 | |
506 ELSE | |
507 | |
508 * Level 2 DP vars | |
509 D.Tasks RMB 2 Task User Table | |
510 D.TmpDAT RMB 2 Temporary DAT Image stack | |
511 D.Init RMB 2 Initialization Module ptr | |
512 D.Poll RMB 2 Interrupt Polling Routine ptr | |
513 D.Time EQU . System Time | |
514 D.Year RMB 1 | |
515 D.Month RMB 1 | |
516 D.Day RMB 1 | |
517 D.Hour RMB 1 | |
518 D.Min RMB 1 | |
519 D.Sec RMB 1 | |
520 D.Tick RMB 1 | |
521 D.Slice RMB 1 current slice remaining | |
522 D.TSlice RMB 1 Ticks per Slice | |
523 D.Boot RMB 1 Bootstrap attempted flag | |
524 D.MotOn RMB 1 Floppy Disk Motor-On time out | |
525 D.ErrCod RMB 1 Reset Error Code | |
526 D.Daywk RMB 1 day of week, com-trol clock | |
527 D.TkCnt RMB 1 Tick Counter | |
528 D.BtPtr RMB 2 Address of Boot in System Address space | |
529 D.BtSz RMB 2 Size of Boot | |
530 | |
531 IFNE H6309 | |
532 D.MDREG RMB 1 6309 MD (mode) shadow register | |
533 ELSE | |
534 RMB 1 Currently unused in NitrOS-9/6809 | |
535 ENDC | |
536 | |
537 D.CRC RMB 1 CRC checking mode flag | |
538 | |
539 D.Tenths RMB 1 Tenths and hundredths of second for F$Xtime | |
540 D.Task1N RMB 1 Map type 1 task number*2 - offset into [D.TskIPt] | |
541 D.Quick RMB 1 Quick system call return flag - 0 =stack is at $FEE1 | |
542 D.QIRQ RMB 1 Quick IRQ flag - 0 =IRQ wasn't clock, so quick return | |
543 | |
544 ORG $40 | |
545 D.BlkMap RMB 4 Memory Block Map ptr | |
546 D.ModDir RMB 4 Module Directory ptrs | |
547 D.PrcDBT RMB 2 Process Descriptor Block Table ptr | |
548 D.SysPrc RMB 2 System Process Descriptor ptr | |
549 D.SysDAT RMB 2 System DAT Image ptr | |
550 D.SysMem RMB 2 System Memory Map ptr | |
551 D.Proc RMB 2 Current Process ptr | |
552 D.AProcQ RMB 2 Active Process Queue | |
553 D.WProcQ RMB 2 Waiting Process Queue | |
554 D.SProcQ RMB 2 Sleeping Process Queue | |
555 D.ModEnd RMB 2 Module Directory end ptr | |
556 D.ModDAT RMB 2 Module Dir DAT image end ptr | |
557 D.CldRes RMB 2 Cold Restart vector | |
558 D.BtBug RMB 3 Boot debug information | |
559 D.Pipe RMB 2 | |
560 | |
561 ORG $6B | |
562 D.Crash RMB 6 Pointer to CC Crash Routine | |
563 D.CBStrt RMB $B Reserved for CC warmstart ($71) | |
564 D.QCnt RMB 1 Count of number of quick system calls performed | |
565 | |
566 ORG $80 | |
567 D.DevTbl RMB 2 I/O Device Table | |
568 D.PolTbl RMB 2 I/O Polling Table | |
569 RMB 4 reserved | |
570 D.PthDBT RMB 2 Path Descriptor Block Table ptr | |
571 D.DMAReq RMB 1 DMA Request flag | |
572 | |
573 ******** | |
574 * CoCo 3 STUFF COMES NEXT | |
575 * This area is used for the CoCo Hardware Registers | |
576 * | |
577 ORG $90 | |
578 D.HINIT RMB 1 GIME INIT0 register (hardware setup $FF90) | |
579 D.TINIT RMB 1 GIME INIT1 register (timer/task register $FF91) | |
580 D.IRQER RMB 1 Interrupt enable regsiter ($FF92) | |
581 D.FRQER RMB 1 Fast Interrupt enable register ($FF93) | |
582 D.TIMMS RMB 1 Timer most significant nibble ($FF94) | |
583 D.TIMLS RMB 1 Timer least significant byte ($FF95) | |
584 D.RESV1 RMB 1 reserved register ($FF96) | |
585 D.RESV2 RMB 1 reserved register ($FF97) | |
586 D.VIDMD RMB 1 video mode register ($FF98) | |
587 D.VIDRS RMB 1 video resolution register ($FF99) | |
588 D.BORDR RMB 1 border register ($FF9A) | |
589 D.RESV3 RMB 1 reserved register ($FF9B) | |
590 D.VOFF2 RMB 1 vertical scroll/offset 2 register ($FF9C) | |
591 D.VOFF1 RMB 1 vertical offset 1 register ($FF9D) | |
592 D.VOFF0 RMB 1 vertical offset 0 register ($FF9E) | |
593 D.HOFF0 RMB 1 horizontal offset 0 register ($FF9F) | |
594 D.Speed RMB 1 Speed of COCO CPU 0=slow,1=fast ($A0) | |
595 D.TskIPt RMB 2 Task image Pointer table (CC) ($A1) | |
596 D.MemSz RMB 1 128/512K memory flag (CC) ($A3) | |
597 D.SSTskN RMB 1 System State Task Number (COCO) ($A4) | |
598 D.CCMem RMB 2 Pointer to beginning of CC Memory ($A5) | |
599 D.CCStk RMB 2 Pointer to top of CC Memory ($A7) | |
600 D.Flip0 RMB 2 Change to Task 0 ($A9) | |
601 D.Flip1 RMB 2 Change to reserved Task 1 ($AB) | |
602 D.VIRQ RMB 2 VIRQ Polling routine ($AD) | |
603 D.IRQS RMB 1 IRQ shadow register (CC Temporary) ($AF) | |
604 D.CLTb RMB 2 VIRQ Table address ($B0) | |
605 D.AltIRQ RMB 2 Alternate IRQ Vector (CC) ($B2) | |
606 D.GPoll RMB 2 CC GIME IRQ enable/disable toggle | |
607 D.Clock2 RMB 2 CC Clock2 entry address | |
608 ORG $C0 | |
609 D.SysSvc RMB 2 System Service Routine entry | |
610 D.SysDis RMB 2 System Service Dispatch Table ptr | |
611 D.SysIRQ RMB 2 System IRQ Routine entry | |
612 D.UsrSvc RMB 2 User Service Routine entry | |
613 D.UsrDis RMB 2 User Service Dispatch Table ptr | |
614 D.UsrIRQ RMB 2 User IRQ Routine entry | |
615 D.SysStk RMB 2 System stack | |
616 D.SvcIRQ RMB 2 In-System IRQ service | |
617 D.SysTsk RMB 1 System Task number | |
618 ORG $E0 | |
619 D.Clock RMB 2 | |
620 D.XSWI3 RMB 2 | |
621 D.XSWI2 RMB 2 | |
622 D.XFIRQ RMB 2 | |
623 D.XIRQ RMB 2 | |
624 D.XSWI RMB 2 | |
625 D.XNMI RMB 2 | |
626 D.ErrRst RMB 2 | |
627 D.SysVec RMB 2 F$xxx system call vector for NitrOS-9 Level 3 | |
628 D.SWI3 RMB 2 | |
629 D.SWI2 RMB 2 | |
630 D.FIRQ RMB 2 | |
631 D.IRQ RMB 2 | |
632 D.SWI RMB 2 | |
633 D.NMI RMB 2 | |
634 | |
635 ************************* | |
636 * Level 2 Block Map flags | |
637 * | |
638 NotRAM EQU %10000000 Block Not RAM flag | |
639 VidRAM EQU %00000100 Block is being used as Video RAM | |
640 ModBlock EQU %00000010 Module in Block | |
641 RAMinUse EQU %00000001 RAM Block in use flag | |
642 * | |
643 * Service Dispatch Table special entries | |
644 * | |
645 IOEntry EQU 254 | |
646 | |
647 ENDC | |
648 | |
649 TTL Structure Formats | |
650 PAG | |
651 ************************************ | |
652 * Module Directory Entry Definitions | |
653 * | |
654 ORG 0 | |
655 IFGT Level-1 | |
656 MD$MPDAT RMB 2 Module DAT Image ptr | |
657 MD$MBSiz RMB 2 Memory Block size | |
658 ENDC | |
659 MD$MPtr RMB 2 Module ptr | |
660 MD$Link RMB 2 Module Link count | |
661 MD$ESize EQU . Module Directory Entry size | |
662 | |
663 ************************************ | |
664 * Module Definitions | |
665 * | |
666 * Universal Module Offsets | |
667 * | |
668 ORG 0 | |
669 M$ID RMB 2 ID Code | |
670 M$Size RMB 2 Module Size | |
671 M$Name RMB 2 Module Name | |
672 M$Type RMB 1 Type / Language | |
673 M$Revs RMB 1 Attributes / Revision Level | |
674 M$Parity RMB 1 Header Parity | |
675 M$IDSize EQU . Module ID Size | |
676 * | |
677 * Type-Dependent Module Offsets | |
678 * | |
679 * System, File Manager, Device Driver, Program Module | |
680 * | |
681 M$Exec RMB 2 Execution Entry Offset | |
682 * | |
683 * Device Driver, Program Module | |
684 * | |
685 M$Mem RMB 2 Stack Requirement | |
686 * | |
687 * Device Driver, Device Descriptor Module | |
688 * | |
689 M$Mode RMB 1 Device Driver Mode Capabilities | |
690 * | |
691 * Device Descriptor Module | |
692 * | |
693 ORG M$IDSize | |
694 M$FMgr RMB 2 File Manager Name Offset | |
695 M$PDev RMB 2 Device Driver Name Offset | |
696 RMB 1 M$Mode (defined above) | |
697 M$Port RMB 3 Port Address | |
698 M$Opt RMB 1 Device Default Options | |
699 M$DTyp RMB 1 Device Type | |
700 IT.DTP EQU M$DTyp Descriptor type offset | |
701 * | |
702 * Configuration Module Entry Offsets | |
703 * | |
704 ORG M$IDSize | |
705 MaxMem RMB 3 Maximum Free Memory | |
706 PollCnt RMB 1 Entries in Interrupt Polling Table | |
707 DevCnt RMB 1 Entries in Device Table | |
708 InitStr RMB 2 Initial Module Name | |
709 SysStr RMB 2 System Device Name | |
710 StdStr RMB 2 Standard I/O Pathlist | |
711 BootStr RMB 2 Bootstrap Module name | |
712 ProtFlag RMB 1 Write protect enable flag | |
713 | |
714 OSLevel RMB 1 OS level | |
715 OSVer RMB 1 OS version | |
716 OSMajor RMB 1 OS major | |
717 OSMinor RMB 1 OS minor | |
718 Feature1 RMB 1 feature byte 1 | |
719 Feature2 RMB 1 feature byte 2 | |
720 OSName RMB 2 OS revision name string (nul terminated) | |
721 InstallName RMB 2 installation name string (nul terminated) | |
722 RMB 4 reserved for future use | |
723 | |
724 IFGT Level-1 | |
725 * -- VTIO area -- (NitrOS-9 Level 2 and above) * | |
726 MonType RMB 1 Monitor type (0=CMP,1=RGB,2=MONO) | |
727 MouseInf RMB 2 Mouse resolution/Mouse port; was 1, major error RG. | |
728 KeyRptS RMB 1 Key repeat start constant | |
729 KeyRptD RMB 1 Key repeat delay constant | |
730 ENDC | |
731 | |
732 * Feature1 byte definitions | |
733 CRCOn EQU %00000001 CRC checking on | |
734 CRCOff EQU %00000000 CRC checking off | |
735 Proc6809 EQU %00000000 6809 procesor | |
736 Proc6309 EQU %00000010 6309 procesor | |
737 | |
738 PAG | |
739 ************************** | |
740 * Module Field Definitions | |
741 * | |
742 * ID Field - First two bytes of a NitrOS-9 module | |
743 * | |
744 M$ID1 EQU $87 Module ID code byte one | |
745 M$ID2 EQU $CD Module ID code byte two | |
746 M$ID12 EQU M$ID1*256+M$ID2 | |
747 | |
748 * | |
749 * Module Type/Language Field Masks | |
750 * | |
751 TypeMask EQU %11110000 Type Field | |
752 LangMask EQU %00001111 Language Field | |
753 | |
754 * | |
755 * Module Type Values | |
756 * | |
757 Devic EQU $F0 Device Descriptor Module | |
758 Drivr EQU $E0 Physical Device Driver | |
759 FlMgr EQU $D0 File Manager | |
760 Systm EQU $C0 System Module | |
761 ShellSub EQU $50 Shell+ shell sub module | |
762 Data EQU $40 Data Module | |
763 Multi EQU $30 Multi-Module | |
764 Sbrtn EQU $20 Subroutine Module | |
765 Prgrm EQU $10 Program Module | |
766 | |
767 * | |
768 * Module Language Values | |
769 * | |
770 Objct EQU 1 6809 Object Code Module | |
771 ICode EQU 2 Basic09 I-code | |
772 PCode EQU 3 Pascal P-code | |
773 CCode EQU 4 C I-code | |
774 CblCode EQU 5 Cobol I-code | |
775 FrtnCode EQU 6 Fortran I-code | |
776 Obj6309 EQU 7 6309 object code | |
777 * | |
778 * Module Attributes / Revision byte | |
779 * | |
780 * Field Masks | |
781 * | |
782 AttrMask EQU %11110000 Attributes Field | |
783 RevsMask EQU %00001111 Revision Level Field | |
784 * | |
785 * Attribute Flags | |
786 * | |
787 ReEnt EQU %10000000 Re-Entrant Module | |
788 ModProt EQU %01000000 Gimix Module protect bit (0=protected, 1=write enable) | |
789 ModNat EQU %00100000 6309 native mode attribute | |
790 | |
791 ******************** | |
792 * Device Type Values | |
793 * | |
794 * These values define various classes of devices, which are | |
795 * managed by a file manager module. The Device Type is embedded | |
796 * in a device's device descriptor. | |
797 * | |
798 DT.SCF EQU 0 Sequential Character File Manager | |
799 DT.RBF EQU 1 Random Block File Manager | |
800 DT.Pipe EQU 2 Pipe File Manager | |
801 DT.SBF EQU 3 Sequential Block File Manager | |
802 DT.NFM EQU 4 Network File Manager | |
803 DT.CDFM EQU 5 CD-ROM File Manager | |
804 DT.RFM EQU 6 Remote File Manager | |
805 | |
806 ********************* | |
807 * CRC Result Constant | |
808 * | |
809 CRCCon1 EQU $80 | |
810 CRCCon23 EQU $0FE3 | |
811 | |
812 TTL Process Information | |
813 PAG | |
814 ******************************** | |
815 * Process Descriptor Definitions | |
816 * | |
817 IFEQ Level-1 | |
818 | |
819 * Level 1 process descriptor defs | |
820 DefIOSiz EQU 12 | |
821 NumPaths EQU 16 Number of Local Paths | |
822 | |
823 ORG 0 | |
824 P$ID RMB 1 Process ID | |
825 P$PID RMB 1 Parent's ID | |
826 P$SID RMB 1 Sibling's ID | |
827 P$CID RMB 1 Child's ID | |
828 P$SP RMB 2 Stack ptr | |
829 P$CHAP RMB 1 process chapter number | |
830 P$ADDR RMB 1 user address beginning page number | |
831 P$PagCnt RMB 1 Memory Page Count | |
832 P$User RMB 2 User Index $09 | |
833 P$Prior RMB 1 Priority $0B | |
834 P$Age RMB 1 Age $0C | |
835 P$State RMB 1 Status $0D | |
836 P$Queue RMB 2 Queue Link (Process ptr) $0E | |
837 P$IOQP RMB 1 Previous I/O Queue Link (Process ID) $10 | |
838 P$IOQN RMB 1 Next I/O Queue Link (Process ID) | |
839 P$PModul RMB 2 Primary Module | |
840 P$SWI RMB 2 SWI Entry Point | |
841 P$SWI2 RMB 2 SWI2 Entry Point | |
842 P$SWI3 RMB 2 SWI3 Entry Point $18 | |
843 P$DIO RMB DefIOSiz default I/O ptrs $1A | |
844 P$PATH RMB NumPaths I/O path table $26 | |
845 P$Signal RMB 1 Signal Code $36 | |
846 P$SigVec RMB 2 Signal Intercept Vector | |
847 P$SigDat RMB 2 Signal Intercept Data Address | |
848 P$NIO RMB 4 additional dio pointers for net | |
849 RMB $40-. unused | |
850 P$Size EQU . Size of Process Descriptor | |
851 | |
852 * | |
853 * Process State Flags | |
854 * | |
855 SysState EQU %10000000 | |
856 TimSleep EQU %01000000 | |
857 TimOut EQU %00100000 | |
858 ImgChg EQU %00010000 | |
859 Condem EQU %00000010 | |
860 Dead EQU %00000001 | |
861 | |
862 ELSE | |
863 | |
864 * Level 2 process descriptor defs | |
865 DefIOSiz EQU 16 Default I/O Data Length | |
866 NefIOSiz EQU 12 On-Net Default I/O Data Length | |
867 NumPaths EQU 16 Number of Local Paths | |
868 | |
869 ORG 0 | |
870 P$ID RMB 1 Process ID | |
871 P$PID RMB 1 Parent's ID | |
872 P$SID RMB 1 Sibling's ID | |
873 P$CID RMB 1 Child's ID | |
874 P$SP RMB 2 Stack ptr | |
875 P$Task RMB 1 Task Number | |
876 P$PagCnt RMB 1 Memory Page Count | |
877 P$User RMB 2 User Index | |
878 P$Prior RMB 1 Priority | |
879 P$Age RMB 1 Age | |
880 P$State RMB 1 Status | |
881 P$Queue RMB 2 Queue Link (Process ptr) | |
882 P$IOQP RMB 1 Previous I/O Queue Link (Process ID) | |
883 P$IOQN RMB 1 Next I/O Queue Link (Process ID) | |
884 P$PModul RMB 2 Primary Module | |
885 P$SWI RMB 2 SWI Entry Point | |
886 P$SWI2 RMB 2 SWI2 Entry Point | |
887 P$SWI3 RMB 2 SWI3 Entry Point | |
888 P$Signal RMB 1 Signal Code | |
889 P$SigVec RMB 2 Signal Intercept Vector | |
890 P$SigDat RMB 2 Signal Intercept Data Address | |
891 P$DeadLk RMB 1 Dominant proc ID if I/O locked | |
892 RMB $20-. unused | |
893 P$DIO RMB DefIOSiz Default I/O ptrs | |
894 P$Path RMB NumPaths I/O Path Table | |
895 P$DATImg RMB 64 DAT Image | |
896 P$Links RMB 32 Block Link counts | |
897 P$NIO RMB 6*2 additional DIO ptrs for net, compatible with 68k | |
898 P$SelP RMB 1 Selected Path for COCO Windows (Default 0) | |
899 P$UTicks RMB 4 proc User Tick counter (L2V3) | |
900 P$STicks RMB 4 proc System Tick counter (L2V3) | |
901 P$FCalls RMB 4 proc F$ call counter (L2V3) | |
902 P$ICalls RMB 4 proc I$ call counter (L2V3) | |
903 P$DatBeg RMB 3 proc Date of creation (Y/M/D) (L2V3) | |
904 P$TimBeg RMB 3 proc Time of creation (H/M/S) (L2V3) | |
905 P$Alarm RMB 6 | |
906 RMB $200-. Local stack | |
907 P$Stack EQU . Top of Stack | |
908 P$Size EQU . Size of Process Descriptor | |
909 | |
910 * | |
911 * Process State Flags | |
912 * | |
913 SysState EQU %10000000 | |
914 TimSleep EQU %01000000 | |
915 TimOut EQU %00100000 | |
916 ImgChg EQU %00010000 | |
917 Suspend EQU %00001000 | |
918 Condem EQU %00000010 | |
919 Dead EQU %00000001 | |
920 | |
921 ENDC | |
922 | |
923 TTL NitrOS-9 I/O Symbolic Definitions | |
924 PAG | |
925 ************************* | |
926 * Path Descriptor Offsets | |
927 * | |
928 ORG 0 | |
929 PD.PD RMB 1 Path Number | |
930 PD.MOD RMB 1 Mode (Read/Write/Update) | |
931 PD.CNT RMB 1 Number of Open Images | |
932 PD.DEV RMB 2 Device Table Entry Address | |
933 PD.CPR RMB 1 Current Process | |
934 PD.RGS RMB 2 Caller's Register Stack | |
935 PD.BUF RMB 2 Buffer Address | |
936 PD.FST RMB 32-. File Manager's Storage | |
937 PD.OPT EQU . PD GetSts(0) Options | |
938 PD.DTP RMB 1 Device Type | |
939 RMB 64-. Path options | |
940 PDSIZE EQU . | |
941 | |
942 * | |
943 * Pathlist Special Symbols | |
944 * | |
945 PDELIM EQU '/ Pathlist Name Separator | |
946 PDIR EQU '. Directory | |
947 PENTIR EQU '@ Entire Device | |
948 | |
949 PAG | |
950 **************************** | |
951 * File Manager Entry Offsets | |
952 * | |
953 ORG 0 | |
954 FMCREA RMB 3 Create (Open New) File | |
955 FMOPEN RMB 3 Open File | |
956 FMMDIR RMB 3 Make Directory | |
957 FMCDIR RMB 3 Change Directory | |
958 FMDLET RMB 3 Delete File | |
959 FMSEEK RMB 3 Position File | |
960 FMREAD RMB 3 Read from File | |
961 FMWRIT RMB 3 Write to File | |
962 FMRDLN RMB 3 ReadLn | |
963 FMWRLN RMB 3 WritLn | |
964 FMGSTA RMB 3 Get File Status | |
965 FMSSTA RMB 3 Set File Status | |
966 FMCLOS RMB 3 Close File | |
967 | |
968 ***************************** | |
969 * Device Driver Entry Offsets | |
970 * | |
971 ORG 0 | |
972 D$INIT RMB 3 Device Initialization | |
973 D$READ RMB 3 Read from Device | |
974 D$WRIT RMB 3 Write to Device | |
975 D$GSTA RMB 3 Get Device Status | |
976 D$PSTA RMB 3 Put Device Status | |
977 D$TERM RMB 3 Device Termination | |
978 | |
979 ********************* | |
980 * Device Table Format | |
981 * | |
982 ORG 0 | |
983 V$DRIV RMB 2 Device Driver module | |
984 V$STAT RMB 2 Device Driver Static storage | |
985 V$DESC RMB 2 Device Descriptor module | |
986 V$FMGR RMB 2 File Manager module | |
987 V$USRS RMB 1 use count | |
988 IFGT Level-1 | |
989 V$DRIVEX RMB 2 Device Driver execution address | |
990 V$FMGREX RMB 2 File Manager execution address | |
991 ENDC | |
992 DEVSIZ EQU . | |
993 | |
994 ******************************* | |
995 * Device Static Storage Offsets | |
996 * | |
997 ORG 0 | |
998 V.PAGE RMB 1 Port Extended Address | |
999 V.PORT RMB 2 Device 'Base' Port Address | |
1000 V.LPRC RMB 1 Last Active Process ID | |
1001 V.BUSY RMB 1 Active Process ID (0=UnBusy) | |
1002 V.WAKE RMB 1 Active PD if Driver MUST Wake-up | |
1003 V.USER EQU . Driver Allocation Origin | |
1004 | |
1005 ******************************** | |
1006 * Interrupt Polling Table Format | |
1007 * | |
1008 ORG 0 | |
1009 Q$POLL RMB 2 Absolute Polling Address | |
1010 Q$FLIP RMB 1 Flip (EOR) Byte ..normally Zero | |
1011 Q$MASK RMB 1 Polling Mask (after Flip) | |
1012 Q$SERV RMB 2 Absolute Service routine Address | |
1013 Q$STAT RMB 2 Static Storage Address | |
1014 Q$PRTY RMB 1 Priority (Low Numbers=Top Priority) | |
1015 IFGT Level-1 | |
1016 Q$MAP RMB 2 NitrOS-9 Level 2 and above | |
1017 ENDC | |
1018 POLSIZ EQU . | |
1019 | |
1020 ******************** | |
1021 * VIRQ packet format | |
1022 * | |
1023 ORG 0 | |
1024 Vi.Cnt RMB 2 count down counter | |
1025 Vi.Rst RMB 2 reset value for counter | |
1026 Vi.Stat RMB 1 status byte | |
1027 Vi.PkSz EQU . | |
1028 | |
1029 Vi.IFlag EQU %00000001 status byte virq flag | |
1030 | |
1031 PAG | |
1032 ************************************* | |
1033 * Machine Characteristics Definitions | |
1034 * | |
1035 R$CC EQU 0 Condition Codes register | |
1036 R$A EQU 1 A Accumulator | |
1037 R$B EQU 2 B Accumulator | |
1038 R$D EQU R$A Combined A:B Accumulator | |
1039 IFNE H6309 | |
1040 R$E EQU 3 E Accumulator | |
1041 R$F EQU 4 F Accumulator | |
1042 R$W EQU R$E Combined E:F Accumulator | |
1043 R$Q EQU R$A Combined A:B:E:F Accumulator | |
1044 R$DP EQU 5 Direct Page register | |
1045 R$X EQU 6 X Index register | |
1046 R$Y EQU 8 Y Index register | |
1047 R$U EQU 10 User Stack register | |
1048 R$PC EQU 12 Program Counter register | |
1049 R$Size EQU 14 Total register package size | |
1050 ELSE | |
1051 R$DP EQU 3 Direct Page register | |
1052 R$X EQU 4 X Index register | |
1053 R$Y EQU 6 Y Index register | |
1054 R$U EQU 8 User Stack register | |
1055 R$PC EQU 10 Program Counter register | |
1056 R$Size EQU 12 Total register package size | |
1057 ENDC | |
1058 | |
1059 * MD register masks | |
1060 * 6309 definitions | |
1061 DIV0 EQU %10000000 division by 0 trap flag : 1 = trap occured | |
1062 badinstr EQU %01000000 illegal instruction trap flag : 1 = trap occured | |
1063 | |
1064 Entire EQU %10000000 Full Register Stack flag | |
1065 FIRQMask EQU %01000000 Fast-Interrupt Mask bit | |
1066 HalfCrry EQU %00100000 Half Carry flag | |
1067 IRQMask EQU %00010000 Interrupt Mask bit | |
1068 Negative EQU %00001000 Negative flag | |
1069 Zero EQU %00000100 Zero flag | |
1070 TwosOvfl EQU %00000010 Two's Comp Overflow flag | |
1071 Carry EQU %00000001 Carry bit | |
1072 IntMasks EQU IRQMask+FIRQMask | |
1073 Sign EQU %10000000 sign bit | |
1074 | |
1075 TTL Error Code Definitions | |
1076 PAG | |
1077 ************************ | |
1078 * Error Code Definitions | |
1079 * | |
1080 * Basic09 Error Codes | |
1081 * | |
1082 ORG 10 | |
1083 E$UnkSym RMB 1 Unknown symbol | |
1084 E$ExcVrb RMB 1 Excessive verbage | |
1085 E$IllStC RMB 1 Illegal statement construction | |
1086 E$ICOvf RMB 1 I-code overflow | |
1087 E$IChRef RMB 1 Illegal channel reference | |
1088 E$IllMod RMB 1 Illegal mode | |
1089 E$IllNum RMB 1 Illegal number | |
1090 E$IllPrf RMB 1 Illegal prefix | |
1091 E$IllOpd RMB 1 Illegal operand | |
1092 E$IllOpr RMB 1 Illegal operator | |
1093 E$IllRFN RMB 1 Illegal record field name | |
1094 E$IllDim RMB 1 Illegal dimension | |
1095 E$IllLit RMB 1 Illegal literal | |
1096 E$IllRet RMB 1 Illegal relational | |
1097 E$IllSfx RMB 1 Illegal type suffix | |
1098 E$DimLrg RMB 1 Dimension too large | |
1099 E$LinLrg RMB 1 Line number too large | |
1100 E$NoAssg RMB 1 Missing assignment statement | |
1101 E$NoPath RMB 1 Missing path number | |
1102 E$NoComa RMB 1 Missing coma | |
1103 E$NoDim RMB 1 Missing dimension | |
1104 E$NoDO RMB 1 Missing DO statement | |
1105 E$MFull RMB 1 Memory full | |
1106 E$NoGoto RMB 1 Missing GOTO | |
1107 E$NoLPar RMB 1 Missing left parenthesis | |
1108 E$NoLRef RMB 1 Missing line reference | |
1109 E$NoOprd RMB 1 Missing operand | |
1110 E$NoRPar RMB 1 Missing right parenthesis | |
1111 E$NoTHEN RMB 1 Missing THEN statement | |
1112 E$NoTO RMB 1 Missing TO statement | |
1113 E$NoVRef RMB 1 Missing variable reference | |
1114 E$EndQou RMB 1 Missing end quote | |
1115 E$SubLrg RMB 1 Too many subscripts | |
1116 E$UnkPrc RMB 1 Unknown procedure | |
1117 E$MulPrc RMB 1 Multiply defined procedure | |
1118 E$DivZer RMB 1 Divice by zero | |
1119 E$TypMis RMB 1 Operand type mismatch | |
1120 E$StrOvf RMB 1 String stack overflow | |
1121 E$NoRout RMB 1 Unimplemented routine | |
1122 E$UndVar RMB 1 Undefined variable | |
1123 E$FltOvf RMB 1 Floating Overflow | |
1124 E$LnComp RMB 1 Line with compiler error | |
1125 E$ValRng RMB 1 Value out of range for destination | |
1126 E$SubOvf RMB 1 Subroutine stack overflow | |
1127 E$SubUnd RMB 1 Subroutine stack underflow | |
1128 E$SubRng RMB 1 Subscript out of range | |
1129 E$ParmEr RMB 1 Paraemter error | |
1130 E$SysOvf RMB 1 System stack overflow | |
1131 E$IOMism RMB 1 I/O type mismatch | |
1132 E$IONum RMB 1 I/O numeric input format bad | |
1133 E$IOConv RMB 1 I/O conversion: number out of range | |
1134 E$IllInp RMB 1 Illegal input format | |
1135 E$IOFRpt RMB 1 I/O format repeat error | |
1136 E$IOFSyn RMB 1 I/O format syntax error | |
1137 E$IllPNm RMB 1 Illegal path number | |
1138 E$WrSub RMB 1 Wrong number of subscripts | |
1139 E$NonRcO RMB 1 Non-record type operand | |
1140 E$IllA RMB 1 Illegal argument | |
1141 E$IllCnt RMB 1 Illegal control structure | |
1142 E$UnmCnt RMB 1 Unmatched control structure | |
1143 E$IllFOR RMB 1 Illegal FOR variable | |
1144 E$IllExp RMB 1 Illegal expression type | |
1145 E$IllDec RMB 1 Illegal declarative statement | |
1146 E$ArrOvf RMB 1 Array size overflow | |
1147 E$UndLin RMB 1 Undefined line number | |
1148 E$MltLin RMB 1 Multiply defined line number | |
1149 E$MltVar RMB 1 Multiply defined variable | |
1150 E$IllIVr RMB 1 Illegal input variable | |
1151 E$SeekRg RMB 1 Seek out of range | |
1152 E$NoData RMB 1 Missing data statement | |
1153 | |
1154 * | |
1155 * System Dependent Error Codes | |
1156 * | |
1157 | |
1158 * Level 2 windowing error codes | |
1159 ORG 183 | |
1160 E$IWTyp RMB 1 Illegal window type | |
1161 E$WADef RMB 1 Window already defined | |
1162 E$NFont RMB 1 Font not found | |
1163 E$StkOvf RMB 1 Stack overflow | |
1164 E$IllArg RMB 1 Illegal argument | |
1165 RMB 1 reserved | |
1166 E$ICoord RMB 1 Illegal coordinates | |
1167 E$Bug RMB 1 Bug (should never be returned) | |
1168 E$BufSiz RMB 1 Buffer size is too small | |
1169 E$IllCmd RMB 1 Illegal command | |
1170 E$TblFul RMB 1 Screen or window table is full | |
1171 E$BadBuf RMB 1 Bad/Undefined buffer number | |
1172 E$IWDef RMB 1 Illegal window definition | |
1173 E$WUndef RMB 1 Window undefined | |
1174 | |
1175 E$Up RMB 1 Up arrow pressed on SCF I$ReadLn with PD.UP enabled | |
1176 E$Dn RMB 1 Down arrow pressed on SCF I$ReadLn with PD.DOWN enabled | |
1177 E$Alias RMB 1 | |
1178 | |
1179 | |
1180 * | |
1181 * Standard NitrOS-9 Error Codes | |
1182 * | |
1183 ORG 200 | |
1184 E$PthFul RMB 1 Path Table full | |
1185 E$BPNum RMB 1 Bad Path Number | |
1186 E$Poll RMB 1 Polling Table Full | |
1187 E$BMode RMB 1 Bad Mode | |
1188 E$DevOvf RMB 1 Device Table Overflow | |
1189 E$BMID RMB 1 Bad Module ID | |
1190 E$DirFul RMB 1 Module Directory Full | |
1191 E$MemFul RMB 1 Process Memory Full | |
1192 E$UnkSvc RMB 1 Unknown Service Code | |
1193 E$ModBsy RMB 1 Module Busy | |
1194 E$BPAddr RMB 1 Bad Page Address | |
1195 E$EOF RMB 1 End of File | |
1196 RMB 1 | |
1197 E$NES RMB 1 Non-Existing Segment | |
1198 E$FNA RMB 1 File Not Accesible | |
1199 E$BPNam RMB 1 Bad Path Name | |
1200 E$PNNF RMB 1 Path Name Not Found | |
1201 E$SLF RMB 1 Segment List Full | |
1202 E$CEF RMB 1 Creating Existing File | |
1203 E$IBA RMB 1 Illegal Block Address | |
1204 E$HangUp RMB 1 Carrier Detect Lost | |
1205 E$MNF RMB 1 Module Not Found | |
1206 RMB 1 | |
1207 E$DelSP RMB 1 Deleting Stack Pointer memory | |
1208 E$IPrcID RMB 1 Illegal Process ID | |
1209 E$BPrcID EQU E$IPrcID Bad Process ID (formerly #238) | |
1210 RMB 1 | |
1211 E$NoChld RMB 1 No Children | |
1212 E$ISWI RMB 1 Illegal SWI code | |
1213 E$PrcAbt RMB 1 Process Aborted | |
1214 E$PrcFul RMB 1 Process Table Full | |
1215 E$IForkP RMB 1 Illegal Fork Parameter | |
1216 E$KwnMod RMB 1 Known Module | |
1217 E$BMCRC RMB 1 Bad Module CRC | |
1218 E$USigP RMB 1 Unprocessed Signal Pending | |
1219 E$NEMod RMB 1 Non Existing Module | |
1220 E$BNam RMB 1 Bad Name | |
1221 E$BMHP RMB 1 (bad module header parity) | |
1222 E$NoRAM RMB 1 No (System) RAM Available | |
1223 E$DNE RMB 1 Directory not empty | |
1224 E$NoTask RMB 1 No available Task number | |
1225 RMB $F0-. reserved | |
1226 E$Unit RMB 1 Illegal Unit (drive) | |
1227 E$Sect RMB 1 Bad Sector number | |
1228 E$WP RMB 1 Write Protect | |
1229 E$CRC RMB 1 Bad Check Sum | |
1230 E$Read RMB 1 Read Error | |
1231 E$Write RMB 1 Write Error | |
1232 E$NotRdy RMB 1 Device Not Ready | |
1233 E$Seek RMB 1 Seek Error | |
1234 E$Full RMB 1 Media Full | |
1235 E$BTyp RMB 1 Bad Type (incompatable) media | |
1236 E$DevBsy RMB 1 Device Busy | |
1237 E$DIDC RMB 1 Disk ID Change | |
1238 E$Lock RMB 1 Record is busy (locked out) | |
1239 E$Share RMB 1 Non-sharable file busy | |
1240 E$DeadLk RMB 1 I/O Deadlock error | |
1241 | |
1242 | |
1243 IFEQ Level-1 | |
1244 | |
1245 ******************************** | |
1246 * Boot defs for NitrOS-9 Level 1 | |
1247 * | |
1248 * These defs are not strictly for 'Boot', but are for booting the | |
1249 * system. | |
1250 * | |
1251 Bt.Start EQU $EE00 Start address of the boot track in memory | |
1252 | |
1253 * Boot area size on Dragon is only 16 sectors=4K | |
1254 IFNE DRAGON | |
1255 Bt.Size EQU $1000 Max size of boot file | |
1256 ELSE | |
1257 Bt.Size EQU $1080 Maximum size of bootfile | |
1258 ENDC | |
1259 | |
1260 ELSE | |
1261 | |
1262 ****************************************** | |
1263 * Boot defs for NitrOS-9 Level 2 and above | |
1264 * | |
1265 * These defs are not strictly for 'Boot', but are for booting the | |
1266 * system. | |
1267 * | |
1268 Bt.Block EQU $3B Block to map in for the 'OS9BOOT' screen | |
1269 Bt.Flag EQU $8A34 Flag in Bt.Block to verify that it's unchanged | |
1270 Bt.Offst EQU 2 Offset into the screen where the current ptr is | |
1271 Bt.Start EQU $ED00 Start address of the boot track in memory | |
1272 | |
1273 ENDC | |
1274 | |
1275 * Boot area on the Dragon starts on track 0 sector 2, imediatly | |
1276 * after the blockmap. | |
1277 * On the CoCo, the boot track is all of track 34 | |
1278 | |
1279 IFNE DRAGON | |
1280 Bt.Track EQU 0 Boot track | |
1281 Bt.Sec EQU 2 Start LSN of boot area on boot track | |
1282 ELSE | |
1283 Bt.Track EQU 34 Boot track | |
1284 Bt.Sec EQU 0 Start LSN of boot area on boot track | |
1285 ENDC | |
1286 | |
1287 | |
1288 IFGT Level-2 | |
1289 *************************** | |
1290 * Level 3 Defs | |
1291 * | |
1292 * These definitions apply to NitrOS-9 Level 3 | |
1293 * | |
1294 L3.Start EQU $2000 Start off at slot 1 | |
1295 L3.Size EQU $40 Go for 64 pages: 2 slots total | |
1296 L3.Blks EQU L3.Size/$20 Number of slots | |
1297 L3.End EQU L3.Start+L3.Size*$0100 end of L3 memory | |
1298 L3.SCF EQU $0660 SCF block ptr | |
1299 L3.RBF EQU L3.SCF+1 RBF block ptr | |
1300 ENDC | |
1301 | |
1302 ENDC |