|
|
| version 1.18, 2003/12/26 03:41:05 | version 1.21, 2004/01/05 11:46:56 |
|---|---|
| Line 14 | Line 14 |
| #include "keytable.res" | #include "keytable.res" |
| #include "itfrom.res" | #include "itfrom.res" |
| #include "startup.res" | #include "startup.res" |
| #include "sxsibios.res" | |
| #define BIOS_SIMULATE | #define BIOS_SIMULATE |
| Line 134 void bios_init(void) { | Line 135 void bios_init(void) { |
| fh = file_open_rb(path); | fh = file_open_rb(path); |
| if (fh != FILEH_INVALID) { | if (fh != FILEH_INVALID) { |
| if (file_read(fh, mem + 0x0e8000, 0x18000) == 0x18000) { | if (file_read(fh, mem + 0x0e8000, 0x18000) == 0x18000) { |
| TRACEOUT(("load bios.rom")); | |
| biosrom = TRUE; | biosrom = TRUE; |
| } | } |
| file_close(fh); | file_close(fh); |
| Line 175 void bios_init(void) { | Line 177 void bios_init(void) { |
| mem[0xffff0] = 0xea; | mem[0xffff0] = 0xea; |
| STOREINTELDWORD(mem + 0xffff1, 0xfd800000); | STOREINTELDWORD(mem + 0xffff1, 0xfd800000); |
| CopyMemory(mem + ITF_ADRS, itfrom, sizeof(itfrom)); | |
| mem[ITF_ADRS + 0x7ff0] = 0xea; | |
| STOREINTELDWORD(mem + ITF_ADRS + 0x7ff1, 0xf8000000); | |
| if ((!biosrom) && (!(pc.model & PCMODEL_EPSON))) { | if ((!biosrom) && (!(pc.model & PCMODEL_EPSON))) { |
| CopyMemory(mem + 0xe8dd8, neccheck, 0x25); | CopyMemory(mem + 0xe8dd8, neccheck, 0x25); |
| pos = LOADINTELWORD(itfrom + 2); | pos = LOADINTELWORD(itfrom + 2); |
| Line 196 void bios_init(void) { | Line 194 void bios_init(void) { |
| CopyMemory(mem + 0x0fde00, keytable[0], 0x300); | CopyMemory(mem + 0x0fde00, keytable[0], 0x300); |
| bios0x09_init(); | bios0x09_init(); |
| CopyMemory(mem + ITF_ADRS, itfrom, sizeof(itfrom)); | |
| mem[ITF_ADRS + 0x7ff0] = 0xea; | |
| STOREINTELDWORD(mem + ITF_ADRS + 0x7ff1, 0xf8000000); | |
| if (pc.model & PCMODEL_EPSON) { | |
| mem[ITF_ADRS + 0x7ff1] = 0x04; | |
| } | |
| else if ((pc.model & PCMODELMASK) == PCMODEL_VM) { | |
| mem[ITF_ADRS + 0x7ff1] = 0x08; | |
| } | |
| #else | #else |
| fh = file_open_c("itf.rom"); | fh = file_open_c("itf.rom"); |
| if (fh != FILEH_INVALID) { | if (fh != FILEH_INVALID) { |
| Line 204 void bios_init(void) { | Line 212 void bios_init(void) { |
| } | } |
| extmem_init(np2cfg.EXTMEM); | extmem_init(np2cfg.EXTMEM); |
| #endif | #endif |
| // CopyMemory(mem + 0xd0000, sxsibios, sizeof(sxsibios)); | |
| CopyMemory(mem + 0x1c0000, mem + 0x1f8000, 0x08000); | |
| CopyMemory(mem + 0x1e8000, mem + 0x0e8000, 0x10000); | |
| } | } |
| static void bios_boot(void) { | static void bios_boot(void) { |