move boot roms

This commit is contained in:
optixx 2009-10-16 07:43:22 +02:00
parent 08a1c0b3e0
commit ea3113142e
10 changed files with 3611 additions and 3901 deletions

View File

@ -76,6 +76,9 @@ fuse:
flash: main.hex flash: main.hex
$(AVRDUDE) -U flash:w:main.hex:i $(AVRDUDE) -U flash:w:main.hex:i
loader:
python ../../scripts/conv_rle.py ../../snes/qd16/qd16boot.smc
.c.o: .c.o:
$(COMPILE) -c $< -o $@ $(COMPILE) -c $< -o $@

File diff suppressed because it is too large Load Diff

View File

@ -1,9 +0,0 @@
#ifndef __FIFO_H__
#define __FIFO_H__
#define ROM_BUFFER_SIZE 31091
#define ROM_HUFFMAN_SIZE 0
#define ROM_RLE_SIZE 31091
#endif

BIN
roms/qd16boot01.smc Normal file

Binary file not shown.

BIN
roms/qd16boot02.smc Normal file

Binary file not shown.

View File

@ -2,14 +2,17 @@ import binascii
import os import os
import sys import sys
import time import time
import shutil
LEN = 2**16 LEN = 2**16
huffman = False huffman = False
TARGET="/Users/david/Devel/arch/avr/code/quickdev16/avr/usbload" TARGET=os.getcwd()
SOURCE=sys.argv[1]
HUFFMAN_ENCODER="/Users/david/Devel/arch/avr/code/quickdev16/tools/huffman/huffman-encode" HUFFMAN_ENCODER="/Users/david/Devel/arch/avr/code/quickdev16/tools/huffman/huffman-encode"
data = open(sys.argv[1],"r").read()
print "Load %s, %i bytes" % (sys.argv[1],len(data)) data = open(SOURCE,"r").read()
print "Load %s, %i bytes" % (SOURCE,len(data))
data = data[:LEN] data = data[:LEN]
print "Use %i bytes" % (len(data)) print "Use %i bytes" % (len(data))
data = binascii.rlecode_hqx(data) data = binascii.rlecode_hqx(data)
@ -68,6 +71,6 @@ cfile.write('''
''') ''')
cfile.close() cfile.close()
os.rename("/tmp/loader.c", os.path.join(TARGET,"loader.c")) shutil.copy("/tmp/loader.c", os.path.join(TARGET,"loader.c"))
os.rename("/tmp/loader.h", os.path.join(TARGET,"loader.h")) shutil.copy("/tmp/loader.h", os.path.join(TARGET,"loader.h"))

View File

@ -1,36 +0,0 @@
import binascii
data = open("rom.smc","r").read()
data = binascii.rlecode_hqx(data)
cfile = open("loader.c","w")
hfile = open("loader.h","w")
hfile.write('''
#ifndef __FIFO_H__
#define __FIFO_H__
#define ROM_SIZE %i
#endif
''' % len(data))
cfile.write('''
#include <avr/pgmspace.h>
#include <loader.h>
const char _rom[ROM_SIZE] PROGMEM = {
''')
for idx,c in enumerate(data):
c = ord(c)
if idx<len(data)-1:
cfile.write("0x%02x," % c)
else:
cfile.write("0x%02x" % c)
if idx and idx%16==0:
cfile.write("\n")
cfile.write('''
};
''')
cfile.close()

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +0,0 @@
#ifndef __FIFO_H__
#define __FIFO_H__
#define ROM_SIZE 30346
#endif

View File

@ -1,24 +0,0 @@
# 65816 stuff
AC = wla-65816
AFLAGS = -o
LD = wlalink
LDFLAGS = -vsr
FL = snesflash
FLFLAGS = -wf
UCON = ucon64
UCONFLAGS = --port=usb --xsnesram
SFILES = main.asm
OFILES = $(SFILES:.asm=.o)
ROMFILE = main.smc
EMU = zsnes
# spc stuff
SPCAC = wla-spc700
SPCSFILES = data/apu/apucode.asm
SPCOFILES = $(SPCSFILES:.asm=.o)
SPCFILE = $(SPCSFILES:.asm=.bin)
all:
mv -v main.smc main.smc.last
wget http://dforce3000.de/main.smc
python ../../scripts/conv_rle.py main.smc