I am still trying to relocate addresses, to avoid typing errors I prepared a small shell script, that computes offsets and values. It reads the dissassembly text file, and puts out respective DATA statements to be merged with S*BASIC relocation program posted here earlier.
Code: Select all
#!/bin/sh
# reports addresses [C000-10000] to relocate
# of QLC_ROM disassembly in file 'qlc_asm'
# origin at 3C000
num=1000
grep \$0000[C-F] qlc_asm |
while read ln
do
# adr start >|< here
# 0003C068 247C0000C000 move.l #$0000C000,a2
off=$(echo $ln | cut -c-8)
off=$(( 0x${off} - 0x3c000 + 2 ))
val=$(echo $ln | cut -c14-21)
val=$(( 0x${val} - 0xc000 ))
printf '%d DATA "%x","%x"\n' $num $off $val
num=$((num+10))
done
e.g.
lc1 'mdv2_' should bring copyright message and 'file not found' error, instead it reports 'out of memory'.
I wonder what tricks QLC_ROM does with binary files P1 or P2 containing the compiler code in order to execute them?
Tom