annotate level1/modules/sysgo.asm @ 2958:77500452de1c

bootman: Rename assembler files to .as
author Tormod Volden <debian.tormod@gmail.com>
date Sun, 09 Feb 2014 22:53:29 +0100
parents 41313184bd78
children 5944d79e3fe5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
1 ********************************************************************
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
2 * SysGo - Kickstart program module
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
3 *
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
4 * $Id$
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
5 *
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
6 * Edt/Rev YYYY/MM/DD Modified by
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
7 * Comment
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
8 * ------------------------------------------------------------------
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
9 * 5 1998/10/12 Boisy G. Pitre
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
10 * Taken from OS-9 L2 Tandy distribution and modified banner for V3.
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
11 *
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
12 * 5r2 2003/01/08 Boisy G. Pitre
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
13 * Fixed fork behavior so that if 'shell startup' fails, system doesn't
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
14 * jmp to Crash, but tries AutoEx instead. Also changed /DD back to /H0
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
15 * for certain boot floppy cases.
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
16 *
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
17 * 2003/09/04 Boisy G. Pitre
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
18 * Back-ported to OS-9 Level One.
1462
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
19 *
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
20 * 5r3 2003/12/14 Boisy G. Pitre
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
21 * Added SHIFT key check to prevent startup/autoex from starting if
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
22 * held down. Gene Heskett, this Bud's for you.
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
23
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
24 nam SysGo
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
25 ttl Kickstart program module
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
26
588
e70529a05aca Cleanup for Phoenix Release
boisy
parents: 365
diff changeset
27 IFP1
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
28 use defsfile
588
e70529a05aca Cleanup for Phoenix Release
boisy
parents: 365
diff changeset
29 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
30
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
31 tylg set Prgrm+Objct
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
32 atrv set ReEnt+rev
1462
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
33 rev set $03
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
34 edition set $05
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
35
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
36 mod eom,name,tylg,atrv,start,size
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
37
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
38
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
39 org 0
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
40 InitAddr rmb 2
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
41 rmb 250
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
42 size equ .
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
43
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
44 name fcs /SysGo/
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
45 fcb edition
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
46
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
47 * Default process priority
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
48 DefPrior set 128
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
49
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
50 Banner equ *
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
51 fcc /(C) 2012 The NitrOS-9 Project/
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
52 CrRtn fcb C$CR,C$LF
2609
9dd4f422aac7 Added NitrOS-9 ROM Kit from Cloud-9
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2198
diff changeset
53 IFEQ ROM
1803
6b0d1027e4e0 Removed NITROS9VERSION, NITROS9MAJOR, NITROS9MINOR environment vars from
boisy
parents: 1801
diff changeset
54 IFNE NOS9DBG
1651
d696f50c0c67 updated standard.bl files with emulator clocks.
boisy
parents: 1642
diff changeset
55 fcc "** DEVELOPMENT BUILD **"
d696f50c0c67 updated standard.bl files with emulator clocks.
boisy
parents: 1642
diff changeset
56 fcb C$CR,C$LF
d696f50c0c67 updated standard.bl files with emulator clocks.
boisy
parents: 1642
diff changeset
57 fcc "** NOT FOR DISTRIBUTION! **"
1615
dc3272e71faa rb1773.asm: updated comments
boisy
parents: 1587
diff changeset
58 fcb C$CR,C$LF
dc3272e71faa rb1773.asm: updated comments
boisy
parents: 1587
diff changeset
59 ENDC
1787
0af3f5f84033 Tons 'o changes
boisy
parents: 1701
diff changeset
60 dts
591
40cc40e9ff5f New sysgo
boisy
parents: 588
diff changeset
61 fcb C$CR,C$LF
1419
98ae4a4b3e1c Makefiles now use -q with os9 format
boisy
parents: 1364
diff changeset
62 fcc !http://www.nitros9.org!
591
40cc40e9ff5f New sysgo
boisy
parents: 588
diff changeset
63 fcb C$CR,C$LF
588
e70529a05aca Cleanup for Phoenix Release
boisy
parents: 365
diff changeset
64 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
65 fcb C$LF
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
66 BannLen equ *-Banner
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
67
1228
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
68 IFEQ ROM
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
69 DefDev equ *
1228
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
70 IFNE DD
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
71 fcc "/DD"
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
72 ELSE
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
73 fcc "/H0"
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
74 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
75 fcb C$CR
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
76 HDDev equ *
1228
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
77 IFNE DD
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
78 fcc "/DD/"
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
79 ELSE
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
80 fcc "/H0/"
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
81 ENDC
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
82 ExecDir fcc "CMDS"
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
83 fcb C$CR
588
e70529a05aca Cleanup for Phoenix Release
boisy
parents: 365
diff changeset
84 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
85
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
86 Shell fcc "Shell"
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
87 fcb C$CR
274
00fe04149e6e Added AutoEx feature, ala Level Two
boisy
parents: 272
diff changeset
88 AutoEx fcc "AutoEx"
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
89 fcb C$CR
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
90 AutoExPr fcc ""
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
91 fcb C$CR
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
92 AutoExPrL equ *-AutoExPr
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
93
1228
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
94 IFEQ ROM
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
95 Startup fcc "startup -p"
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
96 fcb C$CR
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
97 StartupL equ *-Startup
588
e70529a05aca Cleanup for Phoenix Release
boisy
parents: 365
diff changeset
98 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
99
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
100 ShellPrm equ *
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
101 IFGT Level-1
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
102 fcc "i=/1"
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
103 ENDC
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
104 CRtn fcb C$CR
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
105 ShellPL equ *-ShellPrm
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
106
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
107 * Default time packet
1642
31cba223dc92 sysgo.asm has new dts and dtb pseudo ops
boisy
parents: 1623
diff changeset
108 DefTime dtb
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
109
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
110 IFEQ atari
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
111 IFEQ Level-1
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
112 * BASIC reset code (CoCo port only)
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
113 BasicRst fcb $55
252
06775bf93f3a sysgo source commented additionally
boisy
parents: 201
diff changeset
114 neg <$0074
76
6f72b77131c0 Disassembled reset code a little
boisy
parents: 0
diff changeset
115 nop
1300
636cabe76c6e Now Bt.Size is defined for Level One
boisy
parents: 1287
diff changeset
116 clr >PIA0Base+3
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
117 nop
76
6f72b77131c0 Disassembled reset code a little
boisy
parents: 0
diff changeset
118 nop
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
119 sta >$FFDF turn off ROM mode
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
120 jmp >Bt.Start+2 jump to boot
252
06775bf93f3a sysgo source commented additionally
boisy
parents: 201
diff changeset
121 BasicRL equ *-BasicRst
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
122 ENDC
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
123 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
124
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
125 Init fcs /Init/
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
126
2061
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
127 * Entry: X = pointer to start of nul terminated string
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
128 * Exit: D = length of string
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
129 strlen pshs x
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
130 ldd #-1
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
131 go@ addd #$0001
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
132 tst ,x+
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
133 bne go@
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
134 puls x,pc
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
135
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
136 WriteCR pshs y
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
137 leax CrRtn,pcr
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
138 ldy #$0001
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
139 os9 I$WritLn
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
140 puls y,pc
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
141
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
142 * SysGo Entry Point
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
143 start leax >IcptRtn,pcr
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
144 os9 F$Icpt
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
145 * Set priority of this process
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
146 os9 F$ID
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
147 ldb #DefPrior
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
148 os9 F$SPrior
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
149
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
150 * Write OS name and Machine name strings
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
151 leax Init,pcr
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
152 clra
2060
1a29c44561b3 Fixed sysgo issue for level 2
boisy
parents: 2059
diff changeset
153 pshs u
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
154 os9 F$Link
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
155 bcs SignOn
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
156 stx <InitAddr
2061
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
157 ldd OSName,u point to OS name in INIT module
2063
5215fb9c6f0f Fixed minor issue in ordering of code
boisy
parents: 2061
diff changeset
158 leax d,u point to install name in INIT module
2061
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
159 bsr strlen
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
160 tfr d,y
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
161 lda #$01
2061
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
162 os9 I$Write
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
163 bsr WriteCR
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
164 ldd InstallName,u
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
165 leax d,u point to install name in INIT module
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
166 bsr strlen
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
167 tfr d,y
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
168 lda #$01
2061
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
169 os9 I$Write
b17559c279fe sysgo strings now nul terminated
boisy
parents: 2060
diff changeset
170 bsr WriteCR
2060
1a29c44561b3 Fixed sysgo issue for level 2
boisy
parents: 2059
diff changeset
171
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
172 * Show rest of banner
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
173 SignOn
2060
1a29c44561b3 Fixed sysgo issue for level 2
boisy
parents: 2059
diff changeset
174 puls u
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
175 leax >Banner,pcr
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
176 ldy #BannLen
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
177 lda #$01 standard output
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
178 os9 I$Write write out banner
2059
46aa4db8204e More changes
boisy
parents: 2047
diff changeset
179
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
180 * Set default time
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
181 leax >DefTime,pcr
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
182 os9 F$STime set time to default
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
183 IFEQ ROM
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
184 * Change EXEC and DATA dirs
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
185 leax >ExecDir,pcr
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
186 lda #EXEC.
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
187 os9 I$ChgDir change exec. dir
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
188 leax >DefDev,pcr
2614
d9e5c4629696 sysgo no longer I$ChgDir's with write mode
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2609
diff changeset
189 * Made READ. so that no write occurs at boot (Boisy on Feb 5, 2012)
d9e5c4629696 sysgo no longer I$ChgDir's with write mode
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2609
diff changeset
190 * lda #READ.+WRITE.
d9e5c4629696 sysgo no longer I$ChgDir's with write mode
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2609
diff changeset
191 lda #READ.
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
192 os9 I$ChgDir change data dir.
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
193 bcs L0125
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
194 leax >HDDev,pcr
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
195 lda #EXEC.
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
196 os9 I$ChgDir change exec. dir to HD
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
197 ENDC
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
198
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
199 L0125 equ *
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
200 pshs u,y
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
201 IFEQ atari
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
202 IFEQ Level-1
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
203 * Setup BASIC code (CoCo port only)
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
204 leax >BasicRst,pcr
252
06775bf93f3a sysgo source commented additionally
boisy
parents: 201
diff changeset
205 ldu #D.CBStrt
06775bf93f3a sysgo source commented additionally
boisy
parents: 201
diff changeset
206 ldb #BasicRL
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
207 CopyLoop lda ,x+
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
208 sta ,u+
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
209 decb
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
210 bne CopyLoop
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
211 ELSE
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
212 os9 F$ID
1467
6f2feac7ae28 Fixed problem with branch
boisy
parents: 1464
diff changeset
213 lbcs L01A9
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
214 leax ,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
215 os9 F$GPrDsc
1467
6f2feac7ae28 Fixed problem with branch
boisy
parents: 1464
diff changeset
216 lbcs L01A9
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
217 leay ,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
218 ldx #$0000
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
219 ldb #$01
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
220 os9 F$MapBlk
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
221 bcs L01A9
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
222
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
223 lda #$55 set flag for Color BASIC
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
224 sta <D.CBStrt,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
225 * Copy our default I/O ptrs to the system process
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
226 ldd <D.SysPrc,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
227 leau d,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
228 leau <P$DIO,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
229 leay <P$DIO,y
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
230 ldb #DefIOSiz-1
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
231 L0151 lda b,y
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
232 sta b,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
233 decb
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
234 bpl L0151
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
235 ENDC
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
236 ENDC
274
00fe04149e6e Added AutoEx feature, ala Level Two
boisy
parents: 272
diff changeset
237
1228
0a49ee6bbd40 sysgo_dd and sysgo_h0 are now made
boisy
parents: 1222
diff changeset
238 IFEQ ROM
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
239 * Fork shell startup here
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
240 IFEQ atari
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
241 * Added 12/14/03: If SHIFT is held down, startup is not run (CoCo only)
1464
eeaf8ff6420d stdout is needed, not stdin for SS.KySns
boisy
parents: 1462
diff changeset
242 lda #$01 standard output
1462
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
243 ldb #SS.KySns
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
244 os9 I$GetStt
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
245 bcs DoStartup
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
246 bita #SHIFTBIT SHIFT key down?
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
247 bne L0186 Yes, don't to startup or autoex
2633
41313184bd78 Expanded makefile... aded TODO, merged sysgo.asm into level1/modules file
Boisy Pitre <boisy.pitre@nuance.com>
parents: 2614
diff changeset
248 ENDC
1462
062d65d5c132 Added check for SHIFT key which, if down, bypasses startup and AutoEx
boisy
parents: 1449
diff changeset
249 DoStartup leax >Shell,pcr
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
250 leau >Startup,pcr
252
06775bf93f3a sysgo source commented additionally
boisy
parents: 201
diff changeset
251 ldd #256
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
252 ldy #StartupL
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
253 os9 F$Fork
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
254 bcs DoAuto
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
255 os9 F$Wait
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
256 ENDC
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
257 * Fork AutoEx here
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
258 DoAuto leax >AutoEx,pcr
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
259 leau >CRtn,pcr
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
260 ldd #$0100
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
261 ldy #$0001
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
262 os9 F$Fork
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
263 bcs L0186
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
264 os9 F$Wait
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
265 L0186 equ *
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
266 puls u,y
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
267 FrkShell leax >ShellPrm,pcr
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
268 leay ,u
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
269 ldb #ShellPL
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
270 L0190 lda ,x+
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
271 sta ,y+
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
272 decb
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
273 bne L0190
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
274 * Fork final shell here
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
275 leax >Shell,pcr
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
276 lda #$01 D = 256 (B already 0 from above)
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
277 ldy #ShellPL
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
278 IFGT Level-1
1315
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
279 os9 F$Chain
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
280 ldb #$06
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
281 bra Crash
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
282 L01A9 ldb #$04
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
283 Crash clr >DPort+$08 turn off disk motor
23c681a015e1 cc3go has been renamed to SysGo
boisy
parents: 1300
diff changeset
284 jmp <D.Crash
1316
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
285 ELSE
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
286 os9 F$Fork
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
287 bcs DeadEnd
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
288 os9 F$Wait
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
289 bcc FrkShell
50e9ec54e7e6 Fixed a problem in OS-9 Level One SysGo
boisy
parents: 1315
diff changeset
290 DeadEnd bra DeadEnd
588
e70529a05aca Cleanup for Phoenix Release
boisy
parents: 365
diff changeset
291 ENDC
0
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
292
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
293 IcptRtn rti
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
294
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
295 emod
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
296 eom equ *
6641a883d6b0 Initial revision
boisy
parents:
diff changeset
297 end