mirror of https://github.com/zxdos/zxuno.git
Añado generador de ROMs
This commit is contained in:
parent
61a8a3c5d2
commit
95effcdec6
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,38 @@
|
|||
genMenu
|
||||
rcs screen.scr screen.rcs
|
||||
fcut screen.rcs 0 1800 screen.cut
|
||||
zx7b screen.cut screen.cut.zx7b
|
||||
sjasmplus kartusho.asm
|
||||
copy /b kartusho.rom+ ^
|
||||
48.rom+ ^
|
||||
lechesaa.rom+ ^
|
||||
sinleches.rom+ ^
|
||||
testrom.rom+ ^
|
||||
testrom48.rom+ ^
|
||||
se2.rom+ ^
|
||||
inves.rom+ ^
|
||||
seachange.rom+ ^
|
||||
gw03.rom+ ^
|
||||
JetSetWilly.rom+ ^
|
||||
Pssst.rom+ ^
|
||||
Gyruss.rom+ ^
|
||||
JetPac.rom+ ^
|
||||
Chess.rom+ ^
|
||||
Planetoids.rom+ ^
|
||||
HoraceSpiders.rom+ ^
|
||||
SpaceRaiders.rom+ ^
|
||||
TranzAm.rom+ ^
|
||||
ShadowUnicorn.rom+ ^
|
||||
HungryHorace.rom+ ^
|
||||
LocoMotion.rom+ ^
|
||||
PanamaJoe.rom+ ^
|
||||
Popeye.rom+ ^
|
||||
MiscoJones.rom+ ^
|
||||
ReturnJedi.rom+ ^
|
||||
StarWars.rom+ ^
|
||||
Deathchase.rom+ ^
|
||||
Cookie.rom+ ^
|
||||
LalaPrologue.rom+ ^
|
||||
Backgammon.rom+ ^
|
||||
QBert.rom ^
|
||||
kartusho.bin
|
||||
|
|
@ -0,0 +1,49 @@
|
|||
; -----------------------------------------------------------------------------
|
||||
; ZX7 Backwards by Einar Saukas, Antonio Villena
|
||||
; "Standard" version (67 bytes only)
|
||||
; -----------------------------------------------------------------------------
|
||||
; Parameters:
|
||||
; HL: source address (compressed data)
|
||||
; DE: destination address (decompressing)
|
||||
; -----------------------------------------------------------------------------
|
||||
dzx7 ld bc, $8000
|
||||
ld a, b
|
||||
copyby inc c
|
||||
ldd
|
||||
mainlo add a, a
|
||||
call z, getbit
|
||||
jr nc, copyby
|
||||
push de
|
||||
ld d, c
|
||||
defb $30
|
||||
lenval add a, a
|
||||
call z, getbit
|
||||
rl c
|
||||
rl b
|
||||
add a, a
|
||||
call z, getbit
|
||||
jr nc, lenval
|
||||
inc c
|
||||
jr z, exitdz
|
||||
ld e, (hl)
|
||||
dec hl
|
||||
sll e
|
||||
jr nc, offend
|
||||
ld d, $10
|
||||
nexbit add a, a
|
||||
call z, getbit
|
||||
rl d
|
||||
jr nc, nexbit
|
||||
inc d
|
||||
srl d
|
||||
offend rr e
|
||||
ex (sp), hl
|
||||
ex de, hl
|
||||
adc hl, de
|
||||
lddr
|
||||
exitdz pop hl
|
||||
jr nc, mainlo
|
||||
getbit ld a, (hl)
|
||||
dec hl
|
||||
adc a, a
|
||||
ret
|
||||
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,50 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
unsigned char image[0xc000], font[0x1000];
|
||||
char tmpstr[50];
|
||||
unsigned short i, j, k, pos;
|
||||
FILE *fh;
|
||||
|
||||
int main(int argc, char *argv[]){
|
||||
fh= fopen("fuente6x8.bin", "r");
|
||||
fread(font+0x80, 1, 0x380, fh);
|
||||
fclose(fh);
|
||||
for ( i= 0x400; i<0x1000; i++ )
|
||||
font[i]= (font[i-0x400] >> 2) | (font[i-0x400] << 6);
|
||||
fh= fopen("menu.txt", "r");
|
||||
for ( i= 0; i<17; i++ ){
|
||||
fgets(tmpstr, 50, fh);
|
||||
k= 0;
|
||||
pos= i<<5&0xf0 | i<<8&0x1800;
|
||||
while ( 1 ){
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= font[j|tmpstr[k]<<3];
|
||||
pos-= 0x800;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= image[pos]&0xfc | font[0xc00|j|tmpstr[k]<<3]&0x3,
|
||||
image[pos+1]= font[0xc00|j|tmpstr[k]<<3]&0xfc;
|
||||
pos-= 0x7ff;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= image[pos]&0xf0 | font[0x800|j|tmpstr[k]<<3]&0xf,
|
||||
image[pos+1]= font[0x800|j|tmpstr[k]<<3]&0xf0;
|
||||
pos-= 0x7ff;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= image[pos] | font[0x400|j|tmpstr[k]<<3];
|
||||
pos-= 0x7ff;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
}
|
||||
}
|
||||
fclose(fh);
|
||||
fh= fopen("screen.scr", "wb+");
|
||||
memset(image+0x1800, 0x38, 0x300);
|
||||
fwrite(image, 1, 0x1b00, fh);
|
||||
fclose(fh);
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,6 @@
|
|||
echo define version 0 > version.asm
|
||||
call _make.bat
|
||||
copy /y kartusho.bin kartusho4.rom
|
||||
echo define version 1 > version.asm
|
||||
call _make.bat
|
||||
copy /y kartusho.bin kartushoROM.rom
|
||||
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,17 @@
|
|||
GAME SELECTION MENU by AntonioVillena 2017
|
||||
1.Manic Miner U.Horace & Spiders
|
||||
2.Original 48 ROM I.Space Raiders
|
||||
3.Cargando Leches O.Tranz Am
|
||||
4.R&Play no tokens P.Shadow of Unicorn
|
||||
5.Alford ROM Test A.Hungry Horace
|
||||
6.McLeod ROM Test S.Loco Motion
|
||||
7.SE Basic IV 4.0 D.Montezuma's Revenge
|
||||
8.Inves Spectrum+ F.Popeye
|
||||
9.Sea Change ROM G.Misco Jones
|
||||
0.Gosh Wonderful H.Return of the Jedi
|
||||
Q.Jet Set Willy J.Star Wars
|
||||
W.Pssst K.Death Chase
|
||||
E.Gyrus L.Cookie
|
||||
R.Jet Pac Z.Lala Prologue
|
||||
T.Chess X.Backgammon
|
||||
Y.Planetoids C.QBert
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,46 @@
|
|||
@echo off
|
||||
SETLOCAL
|
||||
if "%1"=="" goto Help
|
||||
set _method=%1
|
||||
set _forw=0
|
||||
if f==%_method:~0,1% set _forw=1
|
||||
if -==%_method:~2,1% set _lit=-c
|
||||
|
||||
:Loop
|
||||
if "%3"=="" goto Continue
|
||||
if 1==%_forw% (
|
||||
echo.
|
||||
echo ^>^> exomizer raw %3 %_lit% -o %3.exo
|
||||
echo.
|
||||
exomizer raw %3 %_lit% -o %3.exo
|
||||
) else (
|
||||
echo.
|
||||
echo ^>^> exomizer raw %3 %_lit% -b -r -o %3.exo
|
||||
echo.
|
||||
exomizer raw %3 %_lit% -b -r -o %3.exo
|
||||
)
|
||||
set _result=%_result% %3.exo
|
||||
shift /3
|
||||
goto Loop
|
||||
|
||||
:Help
|
||||
echo.
|
||||
echo compress plain files with exomizer and exoopt, same syntax as exoopt
|
||||
echo.
|
||||
echo compress ^<type^> ^<table_address^> ^<file1^> ^<file2^> .. ^<fileN^>
|
||||
echo.
|
||||
echo ^<type^> Target decruncher
|
||||
echo ^<table_address^> Hexadecimal address for the temporal 156 bytes table
|
||||
echo ^<file1..N^> Origin files
|
||||
echo.
|
||||
echo A dash after ^<type^> (without space) forces the -c command in exomizer
|
||||
goto :eof
|
||||
|
||||
:Continue
|
||||
echo.
|
||||
echo ^>^> exoopt %_method:~0,2% %2 %_result%
|
||||
exoopt %_method:~0,2% %2 %_result%
|
||||
echo.
|
||||
echo ^>^> del %_result%
|
||||
del %_result%
|
||||
ENDLOCAL
|
||||
|
|
@ -0,0 +1,82 @@
|
|||
; b1 [f0..87] nolit= 148 bytes
|
||||
ld iy, 23408
|
||||
ld a, 128
|
||||
ld b, 52
|
||||
push de
|
||||
cp a
|
||||
exinit: ld c, 16
|
||||
jr nz, exget4
|
||||
ld de, 1
|
||||
ld ixl, c
|
||||
exget4: add a, a
|
||||
call z, exgetb
|
||||
rl c
|
||||
jr nc, exget4
|
||||
ld (iy-112), c
|
||||
push hl
|
||||
ld hl, 1
|
||||
defb 210
|
||||
exsetb: add hl, hl
|
||||
dec c
|
||||
jr nz, exsetb
|
||||
ld (iy-60), e
|
||||
ld (iy-8), d
|
||||
add hl, de
|
||||
ex de, hl
|
||||
inc iyl
|
||||
pop hl
|
||||
dec ixl
|
||||
djnz exinit
|
||||
pop de
|
||||
exlit: ldd
|
||||
exloop: add a, a
|
||||
call z, exgetb
|
||||
jr c, exlit
|
||||
ld c, 111
|
||||
exgeti: add a, a
|
||||
call z, exgetb
|
||||
exgbic: inc c
|
||||
jr c, exgeti
|
||||
ret m
|
||||
push de
|
||||
ld iyl, c
|
||||
call expair
|
||||
push de
|
||||
ld bc, 672
|
||||
dec e
|
||||
jr z, exgoit
|
||||
dec e
|
||||
ld bc, 1168
|
||||
jr z, exgoit
|
||||
ld c, 128
|
||||
exgoit: call exgbts
|
||||
ld iyl, c
|
||||
add iy, de
|
||||
call expair
|
||||
pop bc
|
||||
ex (sp), hl
|
||||
ex de, hl
|
||||
add hl, de
|
||||
lddr
|
||||
pop hl
|
||||
jr exloop
|
||||
expair: ld b, (iy-112)
|
||||
call exgbts
|
||||
ex de, hl
|
||||
ld c, (iy-60)
|
||||
ld b, (iy-8)
|
||||
add hl, bc
|
||||
ex de, hl
|
||||
ret
|
||||
exgbts: ld de, 0
|
||||
excont: dec b
|
||||
ret m
|
||||
add a, a
|
||||
call z, exgetb
|
||||
rl e
|
||||
rl d
|
||||
jr excont
|
||||
exgetb: ld a, (hl)
|
||||
dec hl
|
||||
adc a, a
|
||||
ret
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
define LREG 61
|
||||
define LOFF 32
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,91 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
unsigned char image[0xc000], font[0x1000];
|
||||
char tmpstr[50];
|
||||
unsigned short i, j, k, af, pos, lreg, loff;
|
||||
FILE *fi, *fo, *ft;
|
||||
|
||||
int main(int argc, char *argv[]){
|
||||
if( argv[1][0]=='1' )
|
||||
lreg= 61,
|
||||
loff= 32;
|
||||
else
|
||||
lreg= 35,
|
||||
loff= 8;
|
||||
ft= fopen("fuente6x8.bin", "r");
|
||||
fread(font+0x80, 1, 0x380, ft);
|
||||
for ( i= 0x400; i<0x1000; i++ )
|
||||
font[i]= (font[i-0x400] >> 2) | (font[i-0x400] << 6);
|
||||
fi= fopen("menu.txt", "r");
|
||||
for ( i= 0; i<12; i++ ){
|
||||
fgets(tmpstr, 50, fi);
|
||||
k= 0;
|
||||
pos= i<<5&0xf0 | i<<8&0x800;
|
||||
while ( 1 ){
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= font[j|tmpstr[k]<<3];
|
||||
pos-= 0x800;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= image[pos]&0xfc | font[0xc00|j|tmpstr[k]<<3]&0x3,
|
||||
image[pos+1]= font[0xc00|j|tmpstr[k]<<3]&0xfc;
|
||||
pos-= 0x7ff;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= image[pos]&0xf0 | font[0x800|j|tmpstr[k]<<3]&0xf,
|
||||
image[pos+1]= font[0x800|j|tmpstr[k]<<3]&0xf0;
|
||||
pos-= 0x7ff;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
for ( j= 0; j<8; j++, pos+= 0x100 )
|
||||
image[pos]= image[pos] | font[0x400|j|tmpstr[k]<<3];
|
||||
pos-= 0x7ff;
|
||||
if( tmpstr[++k]<14 )
|
||||
break;
|
||||
}
|
||||
}
|
||||
fo= fopen("screen.scr", "wb+");
|
||||
memset(image+0x1800, 0x38, 0x300);
|
||||
fwrite(image, 1, 0x1b00, fo);
|
||||
fclose(fi);
|
||||
fclose(fo);
|
||||
memset(font, 0, lreg*10);
|
||||
fo= fopen("rest.bin", "wb+");
|
||||
for ( i= 0; i<10; i++ ){
|
||||
sprintf(tmpstr, "game%d.sna", i);
|
||||
fi= fopen(tmpstr, "rb");
|
||||
fread(font+lreg*10, 1, 0x1b, fi);
|
||||
fread(image, 1, 0xc000, fi);
|
||||
pos= *(unsigned short*)(font+lreg*10+23); // SP
|
||||
af= *(unsigned short*)(font+lreg*10+21); // AF
|
||||
if( loff==8 )
|
||||
pos-= 2,
|
||||
*(unsigned short*)(image+pos-0x4000)= af,
|
||||
fwrite(image, 1, 0xc000, fo);
|
||||
else
|
||||
fwrite(image, 1, 0x4000, fo),
|
||||
fwrite(image+0x3ffc, 1, 0x4000, fo),
|
||||
fwrite(image+0x7ff8, 1, 0x4000, fo);
|
||||
memcpy(font+i*lreg, image+0xc000-loff, loff);
|
||||
font[i*lreg+loff]= font[lreg*10]; // I
|
||||
font[i*lreg+loff+1]= font[lreg*10+25]-1; // IM
|
||||
memcpy(font+i*lreg+loff+2, font+lreg*10+1, 8); // HL',DE',BC',AF'
|
||||
memcpy(font+i*lreg+loff+10, font+lreg*10+11, 8); // DE,BC,IY,IX
|
||||
*(unsigned short*)(font+i*lreg+loff+18)= af;
|
||||
font[i*lreg+loff+18+(loff>>3&2)]= 0x21; // HL
|
||||
*(unsigned short*)(font+i*lreg+loff+19+(loff>>3&2))= *(unsigned short*)(font+lreg*10+9);
|
||||
font[i*lreg+loff+21+(loff>>3&2)]= 0x31; // SP
|
||||
*(unsigned short*)(font+i*lreg+loff+22+(loff>>3&2))= pos;
|
||||
font[i*lreg+loff+24+(loff>>3&2)]= 0xf3|font[lreg*10+19]<<1&8; // IFF
|
||||
font[i*lreg+loff+25+(loff>>3&2)]= 0x18; // jr rel
|
||||
font[i*lreg+loff+26+(loff>>3&2)]= i<9 ? lreg-2 : 0;
|
||||
fclose(fi);
|
||||
}
|
||||
fclose(fo);
|
||||
fo= fopen("regs.bin", "wb+");
|
||||
fwrite(font, 1, lreg*10, fo);
|
||||
fclose(fo);
|
||||
}
|
||||
Binary file not shown.
|
|
@ -0,0 +1,7 @@
|
|||
genMenu 1
|
||||
rcs screen.scr screen.rcs
|
||||
fcut screen.rcs 0 1000 screen.cut
|
||||
call compress b1 5b00 screen.cut
|
||||
echo define LREG 61 > define.asm
|
||||
echo define LOFF 32 >> define.asm
|
||||
sjasmplus genFlash.asm
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
genMenu 0
|
||||
rcs screen.scr screen.rcs
|
||||
fcut screen.rcs 0 1000 screen.cut
|
||||
call compress b1 5b00 screen.cut
|
||||
echo define LREG 35 > define.asm
|
||||
echo define LOFF 8 >> define.asm
|
||||
sjasmplus genFlash.asm
|
||||
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,12 @@
|
|||
Atic Atac 1983 Tim & Chris Stamper
|
||||
Cobra 1983 Jonathan M. Smith
|
||||
Commando 1985 Burkhill, Alderton
|
||||
Knight Lore 1984 Tim & Chris Stamper
|
||||
Mario Bros 1987 Choice Software
|
||||
Nebulus 1987 John M. Phillips
|
||||
Saboteur 1985 Clive Townsend
|
||||
Super Stuntman 1988 Williamson, Wilson
|
||||
Three Weeks 1986 D.Perry, Nick Jones
|
||||
Underwurlde 1984 Tim & Chris Stamper
|
||||
Manic Miner 1983 Matthew Smith
|
||||
Pokemon+RP+easy 2013 Antonio Villena
|
||||
Binary file not shown.
|
|
@ -0,0 +1,18 @@
|
|||
How it works?
|
||||
1. Replace the game?.sna for your owns. Only 48K SNAs are valid.
|
||||
2. Modify menu.txt according the new snapshots.
|
||||
3. Launch makev4.bat or makevROM.bat, depends if you want to
|
||||
generate for kartusho v4 or Interface ROM respectively.
|
||||
4. Burn the generated file "flash.rom" with your EEPROM programmer.
|
||||
|
||||
----------
|
||||
¿Cómo funciona?
|
||||
1. Reemplaza los juegos game?.sna por los juegos que quieras. Sólo
|
||||
es válido el formato SNA para 48K.
|
||||
2. Modifica menu.txt de acuerdo a los snapshots que hayas puesto.
|
||||
3. Ejecuta makev4.bat o makevROM.bat dependiendo de si quieres
|
||||
crear para kartusho v4 o para Interface ROM respectivamente.
|
||||
4. Graba el archivo generado "flash.rom" con tu programador EEPROM.
|
||||
|
||||
----------
|
||||
Created by AntonioVillena under CC by-SA license
|
||||
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue