mirror of
https://github.com/a2-4am/4cade.git
synced 2024-11-26 17:49:43 +00:00
add ProBoot bootloader
This commit is contained in:
parent
c21dbf84b5
commit
cc76275366
20
Makefile
20
Makefile
@ -35,14 +35,12 @@ asm: md
|
|||||||
dsk: md asm
|
dsk: md asm
|
||||||
$(CADIUS) CREATEVOLUME build/"$(DISK)" "${VOLUME}" 32766KB >>build/log
|
$(CADIUS) CREATEVOLUME build/"$(DISK)" "${VOLUME}" 32766KB >>build/log
|
||||||
cp res/_FileInformation.txt build/ >>build/log
|
cp res/_FileInformation.txt build/ >>build/log
|
||||||
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/PRODOS" >>build/log
|
# $(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/PRODOS" >>build/log
|
||||||
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "build/LAUNCHER.SYSTEM" >>build/log
|
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "build/LAUNCHER.SYSTEM" >>build/log
|
||||||
$(CADIUS) CREATEFOLDER build/"$(DISK)" "/${VOLUME}/X/" >>build/log
|
$(CADIUS) CREATEFOLDER build/"$(DISK)" "/${VOLUME}/X/" >>build/log
|
||||||
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/GAMES.CONF" >>build/log
|
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/GAMES.CONF" >>build/log
|
||||||
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/ATTRACT.CONF" >>build/log
|
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/ATTRACT.CONF" >>build/log
|
||||||
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/FX.CONF" >>build/log
|
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/FX.CONF" >>build/log
|
||||||
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/COVER" >>build/log
|
|
||||||
$(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/" "res/COVER.A2FC" >>build/log
|
|
||||||
rsync -aP res/hgr/* build/HGR >>build/log
|
rsync -aP res/hgr/* build/HGR >>build/log
|
||||||
bin/buildfileinfo.py build/HGR >>build/log
|
bin/buildfileinfo.py build/HGR >>build/log
|
||||||
$(CADIUS) ADDFOLDER build/"$(DISK)" "/${VOLUME}/HGR" "build/HGR" >>build/log
|
$(CADIUS) ADDFOLDER build/"$(DISK)" "/${VOLUME}/HGR" "build/HGR" >>build/log
|
||||||
@ -58,15 +56,11 @@ dsk: md asm
|
|||||||
bin/do2po.py res/dsk/ build/po/
|
bin/do2po.py res/dsk/ build/po/
|
||||||
# rsync -a res/dsk/*.po build/po/
|
# rsync -a res/dsk/*.po build/po/
|
||||||
# bin/extract.py build/po/ | sh >build/log
|
# bin/extract.py build/po/ | sh >build/log
|
||||||
# rm -f build/X/**/.DS_Store
|
rm -f build/X/**/.DS_Store
|
||||||
# rm -f build/X/**/PRODOS
|
rm -f build/X/**/PRODOS
|
||||||
# rm -f build/X/**/LOADER.SYSTEM
|
rm -f build/X/**/LOADER.SYSTEM
|
||||||
# $(CADIUS) ADDFOLDER build/"$(DISK)" "/${VOLUME}/X" "build/X" >build/log
|
$(CADIUS) ADDFOLDER build/"$(DISK)" "/${VOLUME}/X" "build/X" >build/log
|
||||||
|
bin/changebootloader.py build/"$(DISK)" res/proboothd
|
||||||
artwork: dsk
|
|
||||||
# $(CADIUS) ADDFOLDER build/"$(DISK)" "/${VOLUME}/ARTWORK" "res/artwork"
|
|
||||||
# $(CADIUS) ADDFILE build/"$(DISK)" "/${VOLUME}/ARTWORK/" "res/DHRSLIDE.SYSTEM"
|
|
||||||
# $(CADIUS) ADDFOLDER build/"$(DISK)" "/${VOLUME}/ARTWORKGS" "res/artworkgs"
|
|
||||||
|
|
||||||
mount: dsk
|
mount: dsk
|
||||||
osascript bin/V2Make.scpt "`pwd`" bin/4cade.vii build/"$(DISK)"
|
osascript bin/V2Make.scpt "`pwd`" bin/4cade.vii build/"$(DISK)"
|
||||||
@ -83,4 +77,4 @@ md:
|
|||||||
clean:
|
clean:
|
||||||
rm -rf build/
|
rm -rf build/
|
||||||
|
|
||||||
all: clean asm dsk artwork mount
|
all: clean asm dsk mount
|
||||||
|
15
bin/changebootloader.py
Executable file
15
bin/changebootloader.py
Executable file
@ -0,0 +1,15 @@
|
|||||||
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
|
import sys
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
target_2mg_file, bootloader = sys.argv[1:]
|
||||||
|
assert(os.path.splitext(target_2mg_file)[-1].lower() == ".2mg")
|
||||||
|
with open(bootloader, 'rb') as f:
|
||||||
|
boot = f.read()
|
||||||
|
assert(len(boot) == 512)
|
||||||
|
with open(target_2mg_file, 'rb') as f:
|
||||||
|
data = bytearray(f.read())
|
||||||
|
data[64:64+len(boot)] = boot
|
||||||
|
with open(target_2mg_file, 'wb') as f:
|
||||||
|
f.write(data)
|
24
src/4cade.a
24
src/4cade.a
@ -212,7 +212,9 @@ HGRLoad
|
|||||||
|
|
||||||
DHGRLoad
|
DHGRLoad
|
||||||
ldx $C000
|
ldx $C000
|
||||||
bmi Exit
|
bpl +
|
||||||
|
rts
|
||||||
|
+
|
||||||
+STAY PTR
|
+STAY PTR
|
||||||
jsr ResetPath
|
jsr ResetPath
|
||||||
+LDADDR kDHGRScreenshotDirectory
|
+LDADDR kDHGRScreenshotDirectory
|
||||||
@ -224,21 +226,15 @@ DHGRLoad
|
|||||||
jsr LoadDHRFile
|
jsr LoadDHRFile
|
||||||
!word gPathname
|
!word gPathname
|
||||||
jsr FizzleDHGR
|
jsr FizzleDHGR
|
||||||
|
; note: execution falls through here
|
||||||
WaitOnScreenshot
|
WaitOnScreenshot
|
||||||
ldx #0
|
ldx #$20
|
||||||
ldy #0
|
- lda #0
|
||||||
@wait lda $C000
|
jsr WaitForKeyWithTimeout
|
||||||
bmi Exit
|
bmi +
|
||||||
jsr @burn
|
|
||||||
dey
|
|
||||||
bne @wait
|
|
||||||
dex
|
dex
|
||||||
bne @wait
|
bpl -
|
||||||
rts
|
+ rts
|
||||||
@burn jsr @burn2
|
|
||||||
@burn2 jsr @burn3
|
|
||||||
@burn3 jsr Exit
|
|
||||||
Exit rts
|
|
||||||
|
|
||||||
LoadTransition
|
LoadTransition
|
||||||
jsr okvs_nth ; get filename of transition effect code
|
jsr okvs_nth ; get filename of transition effect code
|
||||||
|
Loading…
Reference in New Issue
Block a user