source: buchla-68k/alcyon/vtyper.s@ 7bb1284

Last change on this file since 7bb1284 was 7bf3856, checked in by Thomas Lopatic <thomas@…>, 7 years ago

Added Alcyon C reference output.

  • Property mode set to 100644
File size: 6.3 KB
Line 
1.globl _ebflag
2.globl _ebuf
3.globl _curfet
4.globl _cfetp
5.globl _infetp
6.globl _io_time
7.globl _io_lcd
8.globl _io_ser
9.globl _io_midi
10.globl _io_disk
11.globl _io_tone
12.globl _io_leds
13.globl _io_kbrd
14.globl _lcd_a0
15.globl _lcd_a1
16.globl _io_vreg
17.globl _io_vraw
18.globl _io_vram
19.globl _io_fpu
20.globl _v_regs
21.globl _v_odtab
22.globl _v_actab
23.globl _v_ct0
24.globl _v_gt1
25.globl _v_score
26.globl _v_cgtab
27.globl _v_curs0
28.globl _v_curs1
29.globl _v_curs2
30.globl _v_curs3
31.globl _v_curs4
32.globl _v_curs5
33.globl _v_curs6
34.globl _v_curs7
35.globl _v_tcur
36.globl _v_kbobj
37.globl _v_lnobj
38.globl _v_win0
39.globl _v_cur
40.globl _fc_sw
41.globl _fc_val
42.globl _cxrate
43.globl _cyrate
44.globl _stccol
45.globl _stcrow
46.globl _vtccol
47.globl _vtcrow
48.globl _vtdecol
49.globl _vtxval
50.globl _vtyval
51.globl _vtdeptr
52.globl _vtdechr
53.globl _bfs
54.globl _vtwrow
55.globl _vtwcol
56.globl _vt_adv
57.globl _vt_bsp
58.globl _vt_cdn
59.globl _vt_cup
60.globl _vt_stop
61.globl _vt_dsp
62.globl _vtobj
63.globl _vtfgval
64.globl _vtbgval
65.globl _vtlin1
66.data
67_vtlin1:
68.dc.b $41,$42,$43,$44,$45,$46,$47,$48,$49,$4A,$4B,$4C,$4D,$4E,$4F,$50,$51,$52,$53,$54,$55,$56,$57,$58,$59,$5A,$20,$20,$7C,$20,$0
69.even
70.globl _vtlin2
71.data
72_vtlin2:
73.dc.b $61,$62,$63,$64,$65,$66,$67,$68,$69,$6A,$6B,$6C,$6D,$6E,$6F,$70,$71,$72,$73,$74,$75,$76,$77,$78,$79,$7A,$20,$2D,$2A,$2D,$0
74.even
75.globl _vtlin3
76.data
77_vtlin3:
78.dc.b $20,$30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$2B,$2D,$2F,$23,$28,$29,$2E,$2C,$3A,$3B,$21,$3F,$26,$3C,$3E,$20,$20,$7C,$20,$0
79.even
80.globl _vtsetup
81.text
82_vtsetup:
83~~vtsetup:
84~obj=8
85~dsp=12
86~col=16
87~ptr=18
88~tr=22
89~tc=24
90~adv=26
91~bsp=30
92~cup=34
93~cdn=38
94~stop=42
95~fg=46
96~bg=48
97link R14,#-4
98*line 89
99move.l 8(R14),_vtobj
100*line 90
101move.l 26(R14),_vt_adv
102*line 91
103move.l 30(R14),_vt_bsp
104*line 92
105move.l 34(R14),_vt_cup
106*line 93
107move.l 38(R14),_vt_cdn
108*line 94
109move.l 12(R14),_vt_dsp
110*line 95
111move.l 42(R14),_vt_stop
112*line 96
113move 22(R14),_vtwrow
114*line 97
115move 24(R14),_vtwcol
116*line 98
117move 16(R14),_vtdecol
118*line 99
119move.l 18(R14),_vtdeptr
120*line 100
121move 46(R14),(sp)
122jsr _exp_c
123move R0,_vtfgval
124*line 101
125move 48(R14),(sp)
126jsr _exp_c
127move R0,_vtbgval
128*line 102
129move #14,(sp)
130move #2,-(sp)
131jsr _SetPri
132addq.l #2,sp
133*line 103
134move 24(R14),R0
135asl #3,R0
136move R0,_vtxval
137*line 104
138move 22(R14),R0
139ext.l R0
140divs #14,R0
141move R0,_vtyval
142*line 105
143move 24(R14),(sp)
144move 22(R14),-(sp)
145jsr _ttcpos
146addq.l #2,sp
147L4:unlk R14
148rts
149.globl _vtcxupd
150.text
151_vtcxupd:
152~~vtcxupd:
153link R14,#-4
154*line 124
155move _cxrate,R0
156add R0,_vtxval
157move _vtxval,R0
158asr #3,R0
159move R0,_vtccol
160*line 126
161*line 127
162move _vtwcol,R0
163add #29,R0
164cmp _vtccol,R0
165bge L6
166*line 127
167move _vtwcol,R0
168add #29,R0
169move R0,_vtccol
170asl #3,R0
171move R0,_vtxval
172bra L7
173L6:
174*line 128
175*line 129
176move _vtccol,R0
177cmp _vtwcol,R0
178bge L8
179*line 129
180move _vtwcol,R0
181move R0,_vtccol
182asl #3,R0
183move R0,_vtxval
184L8:L7:L5:unlk R14
185rts
186.globl _vtcyupd
187.text
188_vtcyupd:
189~~vtcyupd:
190link R14,#-4
191*line 145
192move _cyrate,R0
193add R0,_vtyval
194move _vtyval,R0
195ext.l R0
196divs #14,R0
197move R0,_vtcrow
198*line 147
199*line 148
200move _vtwrow,R0
201add #2,R0
202cmp _vtcrow,R0
203bge L10
204*line 148
205move _vtwrow,R0
206add #2,R0
207move R0,_vtcrow
208muls #14,R0
209move R0,_vtyval
210bra L11
211L10:
212*line 149
213*line 150
214move _vtcrow,R0
215cmp _vtwrow,R0
216bge L12
217*line 150
218move _vtwrow,R0
219move R0,_vtcrow
220muls #14,R0
221move R0,_vtyval
222L12:L11:L9:unlk R14
223rts
224.globl _vtdisp
225.text
226_vtdisp:
227~~vtdisp:
228~obj=8
229~fg=12
230~bg=14
231~row=16
232~col=18
233~buf=20
234link R14,#-4
235*line 172
236*line 173
237clr R0
238move 10+_v_regs,R0
239and #384,R0
240beq L14
241*line 173
242clr (sp)
243jsr _vbank
244*line 174
245L14:
246*line 175
247move #14,(sp)
248move.l 20(R14),-(sp)
249move 18(R14),-(sp)
250move 16(R14),-(sp)
251move 14(R14),-(sp)
252move 12(R14),-(sp)
253move #64,-(sp)
254move.l 8(R14),-(sp)
255jsr _vcputsv
256adda.l #18,sp
257L13:unlk R14
258rts
259.globl _vtyper
260.text
261_vtyper:
262~~vtyper:
263link R14,#-4
264*line 194
265*line 194
266move _vtwcol,R0
267add #26,R0
268cmp _vtccol,R0
269ble L16
270*line 195
271*line 196
272*line 197
273*line 198
274*line 199
275move _vtcrow,R0
276cmp _vtwrow,R0
277bne L17
278*line 199
279move _vtccol,R8
280sub _vtwcol,R8
281add.l #_vtlin1,R8
282move.b (R8),_vtdechr
283bra L18
284L17:
285*line 200
286*line 201
287move _vtwrow,R0
288add #1,R0
289cmp _vtcrow,R0
290bne L19
291*line 201
292move _vtccol,R8
293sub _vtwcol,R8
294add.l #_vtlin2,R8
295move.b (R8),_vtdechr
296bra L20
297L19:
298*line 202
299*line 203
300move _vtwrow,R0
301add #2,R0
302cmp _vtcrow,R0
303bne L21
304*line 203
305move _vtccol,R8
306sub _vtwcol,R8
307add.l #_vtlin3,R8
308move.b (R8),_vtdechr
309bra L22
310L21:
311*line 204
312*line 205
313*line 206
314move.b #42,_vtdechr
315*line 207
316clr R0
317bra L15
318L22:L20:L18:
319*line 208
320*line 209
321*line 210
322move _stccol,R8
323sub _vtdecol,R8
324add.l _vtdeptr,R8
325move.b _vtdechr,(R8)
326*line 211
327*line 212
328*line 213
329*line 214
330move.b _vtdechr,_bfs
331*line 215
332clr.b 1+_bfs
333*line 216
334*line 217
335move.l #_bfs,-(sp)
336move _stccol,-(sp)
337move _stcrow,-(sp)
338move _vtbgval,-(sp)
339move _vtfgval,-(sp)
340move.l _vtobj,-(sp)
341move.l _vt_dsp,R8
342jsr (R8)
343adda.l #16,sp
344*line 218
345*line 219
346move.l _vt_adv,R8
347jsr (R8)
348*line 220
349move #1,R0
350bra L15
351*line 221
352*line 222
353*line 223
354*line 224
355bra L23
356L16:
357*line 225
358*line 226
359move _vtwrow,R0
360add #1,R0
361cmp _vtcrow,R0
362bne L24
363move _vtwcol,R0
364add #28,R0
365cmp _vtccol,R0
366bne L24
367*line 227
368*line 228
369move #14,(sp)
370jsr _objclr
371*line 229
372move.l _vt_stop,R8
373jsr (R8)
374*line 230
375clr R0
376bra L15
377*line 231
378bra L25
379L24:
380*line 232
381*line 233
382move _vtcrow,R0
383cmp _vtwrow,R0
384bne L26
385move _vtwcol,R0
386add #28,R0
387cmp _vtccol,R0
388bne L26
389*line 234
390*line 235
391move.l _vt_cup,R8
392jsr (R8)
393*line 236
394clr R0
395bra L15
396*line 237
397bra L27
398L26:
399*line 238
400*line 239
401move _vtwrow,R0
402add #2,R0
403cmp _vtcrow,R0
404bne L28
405move _vtwcol,R0
406add #28,R0
407cmp _vtccol,R0
408bne L28
409*line 240
410*line 241
411move.l _vt_cdn,R8
412jsr (R8)
413*line 242
414clr R0
415bra L15
416*line 243
417bra L29
418L28:
419*line 244
420*line 245
421move _vtwrow,R0
422add #1,R0
423cmp _vtcrow,R0
424bne L30
425move _vtwcol,R0
426add #27,R0
427cmp _vtccol,R0
428bne L30
429*line 246
430*line 247
431move.l _vt_bsp,R8
432jsr (R8)
433*line 248
434clr R0
435bra L15
436*line 249
437bra L31
438L30:
439*line 250
440*line 251
441move _vtwrow,R0
442add #1,R0
443cmp _vtcrow,R0
444bne L32
445move _vtwcol,R0
446add #29,R0
447cmp _vtccol,R0
448bne L32
449*line 252
450*line 253
451move.l _vt_adv,R8
452jsr (R8)
453*line 254
454clr R0
455bra L15
456*line 255
457L32:L31:L29:L27:L25:L23:L15:unlk R14
458rts
459.data
Note: See TracBrowser for help on using the repository browser.