fox32+fox32rom: Rename "mount"/"unmount" to "insert"/"remove"
This commit is contained in:
parent
73a109415a
commit
4be89373f6
2
boot.asm
2
boot.asm
|
@ -9,7 +9,7 @@
|
||||||
; none (doesn't return)
|
; none (doesn't return)
|
||||||
start_boot_process:
|
start_boot_process:
|
||||||
; in the future, this will check the header for various different types of disk types
|
; in the future, this will check the header for various different types of disk types
|
||||||
; but for now, just assume the user mounted a raw binary
|
; but for now, just assume the user inserted a raw binary
|
||||||
; load it to 0x00000800 (immediately after the interrupt vectors) and jump
|
; load it to 0x00000800 (immediately after the interrupt vectors) and jump
|
||||||
|
|
||||||
; r0 contains the size of the disk in bytes
|
; r0 contains the size of the disk in bytes
|
||||||
|
|
18
main.asm
18
main.asm
|
@ -108,8 +108,8 @@ event_loop:
|
||||||
cmp r0, MENU_CLICK_EVENT_TYPE
|
cmp r0, MENU_CLICK_EVENT_TYPE
|
||||||
ifz call menu_click_event
|
ifz call menu_click_event
|
||||||
|
|
||||||
; check if a disk is mounted as disk 0
|
; check if a disk is inserted as disk 0
|
||||||
; if port 0x8000100n returns a non-zero value, then a disk is mounted as disk n
|
; if port 0x8000100n returns a non-zero value, then a disk is inserted as disk n
|
||||||
in r0, 0x80001000
|
in r0, 0x80001000
|
||||||
cmp r0, 0
|
cmp r0, 0
|
||||||
ifnz call start_boot_process
|
ifnz call start_boot_process
|
||||||
|
@ -123,9 +123,9 @@ menu_click_event:
|
||||||
cmp r3, 0
|
cmp r3, 0
|
||||||
;
|
;
|
||||||
|
|
||||||
; mount disk
|
; insert disk
|
||||||
cmp r3, 1
|
cmp r3, 1
|
||||||
ifz jmp mount_boot_disk
|
ifz jmp insert_boot_disk
|
||||||
|
|
||||||
; halt
|
; halt
|
||||||
cmp r3, 2
|
cmp r3, 2
|
||||||
|
@ -134,7 +134,7 @@ menu_click_event:
|
||||||
|
|
||||||
ret
|
ret
|
||||||
|
|
||||||
mount_boot_disk:
|
insert_boot_disk:
|
||||||
mov r0, 0x80001000
|
mov r0, 0x80001000
|
||||||
out r0, 0
|
out r0, 0
|
||||||
ret
|
ret
|
||||||
|
@ -254,10 +254,10 @@ menu_items_system_name:
|
||||||
data.8 6 data.str "System" data.8 0x00 ; text length, text, null-terminator
|
data.8 6 data.str "System" data.8 0x00 ; text length, text, null-terminator
|
||||||
menu_items_system_list:
|
menu_items_system_list:
|
||||||
data.8 3 ; number of items
|
data.8 3 ; number of items
|
||||||
data.8 12 ; menu width (usually longest item + 2)
|
data.8 13 ; menu width (usually longest item + 2)
|
||||||
data.8 5 data.str "About" data.8 0x00 ; text length, text, null-terminator
|
data.8 5 data.str "About" data.8 0x00 ; text length, text, null-terminator
|
||||||
data.8 10 data.str "Mount Disk" data.8 0x00 ; text length, text, null-terminator
|
data.8 11 data.str "Insert Disk" data.8 0x00 ; text length, text, null-terminator
|
||||||
data.8 4 data.str "Halt" data.8 0x00 ; text length, text, null-terminator
|
data.8 4 data.str "Halt" data.8 0x00 ; text length, text, null-terminator
|
||||||
|
|
||||||
; pad out to 512 KiB
|
; pad out to 512 KiB
|
||||||
org.pad 0xF0080000
|
org.pad 0xF0080000
|
||||||
|
|
Loading…
Reference in New Issue
Block a user