aboutsummaryrefslogtreecommitdiff
path: root/src/loadmenu.dasm
blob: 71cbdfc63fedd2460b6bafe95b97a4b66e5319a4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69

; Load MENU.COM

; This will be part of AUTORUN.SYS on the disk. Without it,
; I'd have to make AUTORUN.SYS a copy of MENU.COM :(

 processor 6502
 include "equates.inc"

atari_exec = $0600
main = $2E00 ; same place as cc65

; segment header
 org main-6
 word $FFFF
 word main
 word endmain-1

 org main

; do this so pressing Reset give us DOS
; ldx #1
; stx BOOTQ
; dex
; stx COLDST

; remove later: see if FujiChat can work with only 44K
;; lda #$B0
;; sta RAMTOP
;; lda #12 ; CIO CLOSE
;; sta ICCOM
;; ldx #0
;; jsr CIOV
;;
;;
;; lda #3        ; Command 3=OPEN
;; sta ICCOM
;; lda #12       ; 12=R/W access
;; sta ICAX1
;; lda #0
;; sta ICAX2
;; lda #<e_dev   ; E: device
;; sta ICBAL
;; lda #>e_dev
;; sta ICBAH
;; lda #e_dev_len
;; sta ICBLL
;; lda #0
;; tax
;; sta ICBLH
;; jsr CIOV      ; call CIO


; our raison d'etre...
 lda #<menu_filename
 ldx #>menu_filename
 jmp atari_exec

menu_filename .byte "D:FUJIMENU.COM", 0

e_dev byte "E:",0
e_dev_len equ *-e_dev+1

endmain

; segment header
 word RUNAD
 word RUNAD+1
 word main