Add v4th-x16e target with x16edit invocation

This commit is contained in:
Philip Zembrod 2023-12-02 09:55:17 +01:00
parent b863a5b11f
commit d51c2cfc05
3 changed files with 61 additions and 1 deletions

View File

@ -9,7 +9,7 @@ vf_fth_files = $(wildcard src/vf-*.fth src/v4th*.fth)
vf_fth_files_petscii = $(patsubst src/%, cbmfiles/%, $(vf_fth_files))
vf_flavours = \
v4thblk-c64 v4thblk-c16+ v4thblk-c16- \
v4th-c64 v4th-c16+ v4th-c16- v4th-x16
v4th-c64 v4th-c16+ v4th-c16- v4th-x16 v4th-x16e
vf_binaries = $(patsubst %, cbmfiles/%, $(vf_flavours))
test_files = $(wildcard tests/*.f*)
@ -88,6 +88,9 @@ cbmfiles/v4th-c16-:
cbmfiles/v4th-x16:
emulator/build-vf.sh v4th-x16
cbmfiles/v4th-x16e:
emulator/build-vf.sh v4th-x16e
# Core test targets
@ -138,6 +141,13 @@ test-v4th-x16.log: cbmfiles/v4th-x16 emulator/sdcard.img
mcopy -i emulator/sdcard.img ::TEST.LOG cbmfiles/test.log
petscii2ascii cbmfiles/test.log $@
test-v4th-x16e.log: cbmfiles/v4th-x16e emulator/sdcard.img
rm -f cbmfiles/test.log
emulator/run-in-x16emu.sh v4th-x16e \
"include run-std-tests.fth\n1234567890"
mcopy -i emulator/sdcard.img ::TEST.LOG cbmfiles/test.log
petscii2ascii cbmfiles/test.log $@
test-v4th-x16-39.log: $(test_files_petscii) emulator/run-in-vice.sh
test-v4th-x16-39.log: cbmfiles/v4th-x16 emulator/sdcard.img
@ -201,6 +211,10 @@ test-v4th-x16.golden: $(patsubst %, tests/golden/%.golden, \
prelim core coreext double report-noblk)
cat $^ > $@
test-v4th-x16e.golden: $(patsubst %, tests/golden/%.golden, \
prelim core coreext double report-noblk)
cat $^ > $@
# Rules for building Forth binaries on top of the plain vanilla
# c64-volksforth83.

View File

@ -0,0 +1,30 @@
\ with build log:
' noop alias \log
\ without build log:
\ ' \ alias \log
\log include logtofile.fth
include vf-tc-prep.fth
\log logopen" v4th-x16e.log"
include vf-trg-x16.fth
\ The actual volksForth sources
include vf-head-x16.fth
include vf-cbm-core.fth
include vf-sys-x16.fth
include vf-cbm-file.fth
include vf-x16edit.fth
include vf-finalize.fth
9f00 ' limit >body ! 9b00 s0 ! 9f00 r0 !
include vf-memsetup.fth
include vf-pr-target.fth
.( target compile complete) cr
\log logclose
quit

View File

@ -0,0 +1,16 @@
$0001 | constant RomBank
| Code (xed? ( -- n )
$c000 lda pha $c003 lda Push jmp end-code
| Code (xed ( -- )
2 # ldx $ff # ldy
$4 lda 0= ?[ $c000 jsr ][ $c003 jsr ]?
xyNext jmp end-code
: xed ( -- )
bl word count $4 c! $2 !
RomBank c@ $d RomBank c!
(xed? $4c4c = IF (xed RomBank c!
ELSE RomBank c! ." no x16edit" THEN ;