diff options
author | B. Watson <yalhcru@gmail.com> | 2016-09-06 16:40:38 -0400 |
---|---|---|
committer | B. Watson <yalhcru@gmail.com> | 2016-09-06 16:40:38 -0400 |
commit | 6c7911db17388131973b8ca50691f0173b7e5f26 (patch) | |
tree | 97e9361f28588f8c95968584288a10a7122286aa | |
parent | 89311623faea2da01481be7f96704a4c2b7ccc16 (diff) | |
download | jumpmanjr-6c7911db17388131973b8ca50691f0173b7e5f26.tar.gz |
get rid of .inc file, convert to labels in main.info
-rw-r--r-- | inc2info.pl | 19 | ||||
-rw-r--r-- | jumpmanjr.dasm | 12 | ||||
-rw-r--r-- | jumpmanjr.inc | 68 | ||||
-rw-r--r-- | jumpmanjr.info | 63 | ||||
-rw-r--r-- | main.info | 62 |
5 files changed, 148 insertions, 76 deletions
diff --git a/inc2info.pl b/inc2info.pl new file mode 100644 index 0000000..e6d9153 --- /dev/null +++ b/inc2info.pl @@ -0,0 +1,19 @@ +#!/usr/bin/perl -w + +while(<>) { + chomp; + + s/;.*//; + next if /^\s*$/; + + ($label, $addr) = (/^(\S+)\s+=\s+\$(\S+)/); + $addr = eval "0x$addr"; + $got{$addr} = $label; +} + +for (sort { $a <=> $b } keys %got) { + $addr = sprintf("%04x", $_); + print <<EOF; +label { name "$got{$_}"; addr \$$addr; }; +EOF +} diff --git a/jumpmanjr.dasm b/jumpmanjr.dasm index dde3f36..4213a44 100644 --- a/jumpmanjr.dasm +++ b/jumpmanjr.dasm @@ -1,5 +1,5 @@ ; da65 V2.15 - Git 104f898 -; Created: 2016-09-06 14:33:25 +; Created: 2016-09-06 16:39:32 ; Input file: jumpmanjr.rom ; Page: 1 @@ -34,7 +34,7 @@ num_color := $00D5 ; print_number adds this to nume demo_map_ptr := $00E0 ; points to level_desc of each map in turn, during the 'show all levels' demo demo_name_offset:= $00E2 ; offset from level_names to the name of each level in turn, during the 'show all levels' demo VDSLST := $0200 -VKEYBD := $0208 +VKEYBD := $0208 ; === page 2 OS equates VKEYBD_hi := $0209 SDMCTL := $022F GPRIOR := $026F @@ -196,7 +196,7 @@ cur_level_offs_60:= $07FC ; unknown, level06 (walls) has $ game_display_list:= $0881 ; display list for game board pm_memory := $2800 HPOSP0_minus_two:= $CFFE -HPOSP3 := $D003 +HPOSP3 := $D003 ; === GTIA equates HPOSM0 := $D004 HPOSM1 := $D005 HPOSM2 := $D006 @@ -217,9 +217,9 @@ PRIOR := $D01B GRACTL := $D01D HITCLR := $D01E CONSOL := $D01F -AUDF1_minus_two := $D1FE +AUDF1_minus_two := $D1FE ; AUDF/AUDC regs are indexed from here AUDC1_minus_two := $D1FF -AUDF1 := $D200 +AUDF1 := $D200 ; === POKEY equates AUDC1 := $D201 AUDF2 := $D202 AUDC2 := $D203 @@ -233,7 +233,7 @@ RANDOM := $D20A IRQEN := $D20E SKCTL := $D20F PORTA := $D300 -DMACTL := $D400 +DMACTL := $D400 ; === ANTIC equates DLISTL := $D402 DLISTH := $D403 HSCROL := $D404 diff --git a/jumpmanjr.inc b/jumpmanjr.inc deleted file mode 100644 index ba992fe..0000000 --- a/jumpmanjr.inc +++ /dev/null @@ -1,68 +0,0 @@ -; DO NOT put jumpman-specific addresses here (ROM or working RAM), -; this is only for Atari hardware and OS equates. - -; HW addresses -AUDCTL = $D208 -PMBASE = $D407 -DMACTL = $D400 -PRIOR = $D01B -SKCTL = $D20F -GRACTL = $D01D -DLISTL = $D402 -DLISTH = $D403 -NMIEN = $D40E -IRQEN = $D20E -PORTA = $D300 -TRIG0 = $D010 -CHBASE = $D409 -WSYNC = $D40A -COLPF2 = $D018 -HSCROL = $D404 -COLBK = $D01A -AUDF1_minus_two = $D1FE -AUDC1_minus_two = $D1FF -AUDF1 = $D200 -AUDC1 = $D201 -AUDF2 = $D202 -AUDC2 = $D203 -AUDF3 = $D204 -AUDC3 = $D205 -AUDF4 = $D206 -AUDC4 = $D207 -AUDCTL = $D208 -RANDOM = $D20A -KBCODE = $D209 -CONSOL = $D01F -SDMCTL = $022F -HPOSP3 = $D003 -HPOSM3 = $D007 -HPOSM2 = $D006 -HPOSM1 = $D005 -HPOSM0 = $D004 -GRAFM = $D011 -HITCLR = $D01E -COLPF0 = $D016 -COLPF1 = $D017 -COLPF3 = $D019 -COLPM1 = $D013 -COLPM0 = $D012 -SIZEM = $D00C -SIZEP2 = $D00A -SIZEP3 = $D00B - -; OS addresses -COLOR0 = $02C4 -COLOR1 = $02C5 -COLOR2 = $02C6 -COLOR3 = $02C7 -COLOR4 = $02C8 -PCOLR0 = $02C0 -PCOLR1 = $02C1 -PCOLR2 = $02C2 -PCOLR3 = $02C3 -GPRIOR = $026F -CHBAS = $02F4 -VKEYBD = $0208 -VKEYBD_hi = $0209 -SETVBV = $E45C -XITVBV = $E462 diff --git a/jumpmanjr.info b/jumpmanjr.info index d3f2e51..24f0eac 100644 --- a/jumpmanjr.info +++ b/jumpmanjr.info @@ -11,7 +11,68 @@ GLOBAL { COMMENTS 4; }; -ASMINC { FILE "jumpmanjr.inc"; }; # TODO: get rid of +#ASMINC { FILE "jumpmanjr.inc"; }; # TODO: get rid of +label { name "VKEYBD"; addr $0208; comment "=== page 2 OS equates"; }; +label { name "VKEYBD_hi"; addr $0209; }; +label { name "SDMCTL"; addr $022f; }; +label { name "GPRIOR"; addr $026f; }; +label { name "PCOLR0"; addr $02c0; }; +label { name "PCOLR1"; addr $02c1; }; +label { name "PCOLR2"; addr $02c2; }; +label { name "PCOLR3"; addr $02c3; }; +label { name "COLOR0"; addr $02c4; }; +label { name "COLOR1"; addr $02c5; }; +label { name "COLOR2"; addr $02c6; }; +label { name "COLOR3"; addr $02c7; }; +label { name "COLOR4"; addr $02c8; }; +label { name "CHBAS"; addr $02f4; }; +label { name "HPOSP3"; addr $d003; comment "=== GTIA equates"; }; +label { name "HPOSM0"; addr $d004; }; +label { name "HPOSM1"; addr $d005; }; +label { name "HPOSM2"; addr $d006; }; +label { name "HPOSM3"; addr $d007; }; +label { name "SIZEP2"; addr $d00a; }; +label { name "SIZEP3"; addr $d00b; }; +label { name "SIZEM"; addr $d00c; }; +label { name "TRIG0"; addr $d010; }; +label { name "GRAFM"; addr $d011; }; +label { name "COLPM0"; addr $d012; }; +label { name "COLPM1"; addr $d013; }; +label { name "COLPF0"; addr $d016; }; +label { name "COLPF1"; addr $d017; }; +label { name "COLPF2"; addr $d018; }; +label { name "COLPF3"; addr $d019; }; +label { name "COLBK"; addr $d01a; }; +label { name "PRIOR"; addr $d01b; }; +label { name "GRACTL"; addr $d01d; }; +label { name "HITCLR"; addr $d01e; }; +label { name "CONSOL"; addr $d01f; }; +label { name "AUDF1_minus_two"; addr $d1fe; comment "AUDF/AUDC regs are indexed from here"; }; +label { name "AUDC1_minus_two"; addr $d1ff; }; +label { name "AUDF1"; addr $d200; comment "=== POKEY equates"; }; +label { name "AUDC1"; addr $d201; }; +label { name "AUDF2"; addr $d202; }; +label { name "AUDC2"; addr $d203; }; +label { name "AUDF3"; addr $d204; }; +label { name "AUDC3"; addr $d205; }; +label { name "AUDF4"; addr $d206; }; +label { name "AUDC4"; addr $d207; }; +label { name "AUDCTL"; addr $d208; }; +label { name "KBCODE"; addr $d209; }; +label { name "RANDOM"; addr $d20a; }; +label { name "IRQEN"; addr $d20e; }; +label { name "SKCTL"; addr $d20f; }; +label { name "PORTA"; addr $d300; }; +label { name "DMACTL"; addr $d400; comment "=== ANTIC equates"; }; +label { name "DLISTL"; addr $d402; }; +label { name "DLISTH"; addr $d403; }; +label { name "HSCROL"; addr $d404; }; +label { name "PMBASE"; addr $d407; }; +label { name "CHBASE"; addr $d409; }; +label { name "WSYNC"; addr $d40a; }; +label { name "NMIEN"; addr $d40e; }; +label { name "SETVBV"; addr $e45c; }; +label { name "XITVBV"; addr $e462; }; label { name "zero_filler_9a48"; addr $9a48; }; range { name "zero_filler_8588"; start $B588; end $B58f; type bytetable; }; @@ -9,7 +9,67 @@ GLOBAL { COMMENTS 4; }; -ASMINC { FILE "jumpmanjr.inc"; }; # TODO: get rid of +label { name "VKEYBD"; addr $0208; comment "=== page 2 OS equates"; }; +label { name "VKEYBD_hi"; addr $0209; }; +label { name "SDMCTL"; addr $022f; }; +label { name "GPRIOR"; addr $026f; }; +label { name "PCOLR0"; addr $02c0; }; +label { name "PCOLR1"; addr $02c1; }; +label { name "PCOLR2"; addr $02c2; }; +label { name "PCOLR3"; addr $02c3; }; +label { name "COLOR0"; addr $02c4; }; +label { name "COLOR1"; addr $02c5; }; +label { name "COLOR2"; addr $02c6; }; +label { name "COLOR3"; addr $02c7; }; +label { name "COLOR4"; addr $02c8; }; +label { name "CHBAS"; addr $02f4; }; +label { name "HPOSP3"; addr $d003; comment "=== GTIA equates"; }; +label { name "HPOSM0"; addr $d004; }; +label { name "HPOSM1"; addr $d005; }; +label { name "HPOSM2"; addr $d006; }; +label { name "HPOSM3"; addr $d007; }; +label { name "SIZEP2"; addr $d00a; }; +label { name "SIZEP3"; addr $d00b; }; +label { name "SIZEM"; addr $d00c; }; +label { name "TRIG0"; addr $d010; }; +label { name "GRAFM"; addr $d011; }; +label { name "COLPM0"; addr $d012; }; +label { name "COLPM1"; addr $d013; }; +label { name "COLPF0"; addr $d016; }; +label { name "COLPF1"; addr $d017; }; +label { name "COLPF2"; addr $d018; }; +label { name "COLPF3"; addr $d019; }; +label { name "COLBK"; addr $d01a; }; +label { name "PRIOR"; addr $d01b; }; +label { name "GRACTL"; addr $d01d; }; +label { name "HITCLR"; addr $d01e; }; +label { name "CONSOL"; addr $d01f; }; +label { name "AUDF1_minus_two"; addr $d1fe; comment "AUDF/AUDC regs are indexed from here"; }; +label { name "AUDC1_minus_two"; addr $d1ff; }; +label { name "AUDF1"; addr $d200; comment "=== POKEY equates"; }; +label { name "AUDC1"; addr $d201; }; +label { name "AUDF2"; addr $d202; }; +label { name "AUDC2"; addr $d203; }; +label { name "AUDF3"; addr $d204; }; +label { name "AUDC3"; addr $d205; }; +label { name "AUDF4"; addr $d206; }; +label { name "AUDC4"; addr $d207; }; +label { name "AUDCTL"; addr $d208; }; +label { name "KBCODE"; addr $d209; }; +label { name "RANDOM"; addr $d20a; }; +label { name "IRQEN"; addr $d20e; }; +label { name "SKCTL"; addr $d20f; }; +label { name "PORTA"; addr $d300; }; +label { name "DMACTL"; addr $d400; comment "=== ANTIC equates"; }; +label { name "DLISTL"; addr $d402; }; +label { name "DLISTH"; addr $d403; }; +label { name "HSCROL"; addr $d404; }; +label { name "PMBASE"; addr $d407; }; +label { name "CHBASE"; addr $d409; }; +label { name "WSYNC"; addr $d40a; }; +label { name "NMIEN"; addr $d40e; }; +label { name "SETVBV"; addr $e45c; }; +label { name "XITVBV"; addr $e462; }; label { name "zero_filler_9a48"; addr $9a48; }; range { name "zero_filler_8588"; start $B588; end $B58f; type bytetable; }; |