annotate level1/cmds/pd.asm @ 1891:5f8822fb42e0

shortened H6309L2 code to fit within $1D0 bytes
author robert
date Fri, 14 Oct 2005 01:53:05 +0000
parents 20841f236e32
children 1b7bc08e2e25
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
1 ********************************************************************
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
2 * p[wx]d - Print work/execution directory
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
3 *
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
4 * $Id$
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
5 *
1325
84ea83668304 Redid comments, reset all rev nibbles that weren't explictly set to 0
boisy
parents: 1166
diff changeset
6 * Edt/Rev YYYY/MM/DD Modified by
84ea83668304 Redid comments, reset all rev nibbles that weren't explictly set to 0
boisy
parents: 1166
diff changeset
7 * Comment
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
8 * ------------------------------------------------------------------
1325
84ea83668304 Redid comments, reset all rev nibbles that weren't explictly set to 0
boisy
parents: 1166
diff changeset
9 * 1 ????/??/??
84ea83668304 Redid comments, reset all rev nibbles that weren't explictly set to 0
boisy
parents: 1166
diff changeset
10 * From Tandy OS-9 Level One VR 02.00.00.
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
11
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
12 nam p[wx]d
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
13 ttl Print work/execution directory
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
14
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
15 * Disassembled 98/09/10 23:50:10 by Disasm v1.6 (C) 1988 by RML
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
16
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
17 ifp1
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
18 use defsfile
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
19 endc
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
20
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
21 tylg set Prgrm+Objct
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
22 atrv set ReEnt+rev
1325
84ea83668304 Redid comments, reset all rev nibbles that weren't explictly set to 0
boisy
parents: 1166
diff changeset
23 rev set $00
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
24 edition set 1
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
25
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
26 mod eom,name,tylg,atrv,start,size
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
27
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
28 org 0
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
29 fildes rmb 1
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
30 bufptr rmb 2
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
31 dotdotfd rmb 3 LSN of ..
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
32 dotfd rmb 3 LSN of .
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
33 ddcopy rmb 5
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
34 dentry rmb 160
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
35 buffer rmb 1
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
36 sttbuf rmb 282
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
37 size equ .
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
38
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
39 IFNE PXD
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
40 name fcs /pxd/
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
41 ELSE
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
42 IFNE PWD
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
43 name fcs /pwd/
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
44 ENDC
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
45 ENDC
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
46 fcb edition
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
47
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
48 IFNE PXD
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 950
diff changeset
49 badnam fcc "pxd"
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
50 ELSE
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
51 IFNE PWD
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 950
diff changeset
52 badnam fcc "pwd"
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
53 ENDC
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
54 ENDC
1166
bb618bed0bdc Miscellaneous source improvements
boisy
parents: 950
diff changeset
55 fcc ": bad name in path"
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
56 fcb C$CR
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
57 dotdot fcc "."
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
58 dot fcc "."
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
59 cr fcb C$CR
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
60 rdmsg fcc "read error"
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
61 fcb C$CR
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
62
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
63 start leax >buffer,u point X to buffer
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
64 lda #C$CR get CR
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
65 sta ,x store at start of buffer
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
66 stx <bufptr store buffer pointer
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
67 leax >dot,pcr point to '.'
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
68 bsr open open directory
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
69 sta <fildes save path
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
70 lbsr rdtwo read '.' and '..' entries
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
71 ldd <dotdotfd get 24 bit LSN of ..
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
72 std <ddcopy
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
73 lda <dotdotfd+2
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
74 sta <ddcopy+2 and save copy
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
75 L0052 bsr AtRoot are we at root?
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
76 beq L0079 branch if so
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
77 leax >dotdot,pcr else point to '..'
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
78 bsr chdir change directory
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
79 lda <fildes get path to previous dir
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
80 os9 I$Close close it
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
81 bcs Exit branch if error
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
82 leax >dot,pcr point X to new current dir
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
83 bsr open open it
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
84 bsr rdtwo read . and .. entires of this dir
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
85 bsr FindMtch search for match
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
86 bsr L00E2
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
87 ldd <dotdotfd
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
88 std <ddcopy
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
89 lda <dotdotfd+2
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
90 sta <ddcopy+2
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
91 bra L0052
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
92 L0079 lbsr GetDevNm get device name
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
93 ldx <bufptr point to buffer
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
94 ldy #$0081 get bytes to write
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
95 lda #$01 to stdout
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
96 os9 I$WritLn write
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
97 lda <fildes get path
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
98 os9 I$Close close
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
99 clrb
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
100 Exit os9 F$Exit and exit
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
101
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
102 IFNE PXD
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
103 chdir lda #DIR.+EXEC.+READ.
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
104 ELSE
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
105 IFNE PWD
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
106 chdir lda #DIR.+READ.
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
107 ENDC
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
108 ENDC
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
109 os9 I$ChgDir
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
110 rts
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
111
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
112 IFNE PXD
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
113 open lda #DIR.+EXEC.+READ.
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
114 ELSE
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
115 IFNE PWD
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
116 open lda #DIR.+READ.
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
117 ENDC
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
118 ENDC
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
119 os9 I$Open
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
120 rts
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
121
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
122 * Read directory entry
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
123 read32 lda <fildes
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
124 leax dentry,u
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
125 ldy #DIR.SZ
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
126 os9 I$Read
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
127 rts
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
128
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
129 FindMtch lda <fildes get path to current dir
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
130 bsr read32 read entry
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
131 bcs CantRead branch if error
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
132 leax dentry,u point to entry buffer
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
133 leax <DIR.FD,x point X to FD LSN
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
134 leay ddcopy,u point Y to copy of LSN
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
135 bsr attop compare the two
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
136 bne FindMtch keep reading until we find match
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
137 rts
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
138
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
139 * Compare 3 bytes at X and Y
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
140 attop ldd ,x++
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
141 cmpd ,y++
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
142 bne L00C5
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
143 lda ,x
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
144 cmpa ,y
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
145 L00C5 rts
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
146
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
147 AtRoot leax dotdotfd,u point X at .. entry
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
148 leay dotfd,u point Y at . entry
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
149 bsr attop check if we're at the top
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
150 rts
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
151
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
152 rdtwo bsr read32 * read "." from directory
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
153 ldd <dentry+DIR.FD
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
154 std <dotfd
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
155 lda <dentry+DIR.FD+2
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
156 sta <dotfd+2
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
157 bsr read32 * read ".." from directory
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
158 ldd <dentry+DIR.FD
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
159 std <dotdotfd
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
160 lda <dentry+DIR.FD+2
924
c155aac72190 Made cosmetic changes
boisy
parents: 689
diff changeset
161 sta <dotdotfd+2
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
162 rts
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
163
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
164 * Get name from directory entry
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
165 L00E2 leax dentry,u
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
166 prsnam os9 F$PrsNam
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
167 bcs IlglName
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
168 ldx <bufptr
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
169 L00EB lda ,-y
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
170 anda #$7F mask hi bit
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
171 sta ,-x save
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
172 decb
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
173 bne L00EB
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
174 lda #PDELIM
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
175 sta ,-x
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
176 stx <bufptr
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
177 rts
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
178
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
179 GetDevNm lda <fildes
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
180 ldb #SS.DevNm
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
181 leax >sttbuf,u
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
182 os9 I$GetStt
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
183 bsr prsnam
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
184 rts
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
185
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
186 IlglName leax >badnam,pcr
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
187 bra wrerr
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
188
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
189 CantRead leax >rdmsg,pcr
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
190 wrerr lda #$02
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
191 os9 I$WritLn
950
dbf9a6e913f4 Removed seemlingly useless code
boisy
parents: 924
diff changeset
192 os9 F$Exit
689
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
193
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
194 emod
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
195 eom equ *
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
196 end
92b575ffa143 Folded pxd.asm and pwd.asm into pd.asm for simplicity since almost all code
boisy
parents:
diff changeset
197