Diff for /xmil/debugsub.c between versions 1.4 and 1.12

version 1.4, 2004/08/03 12:50:53 version 1.12, 2004/08/20 23:01:13
Line 6 Line 6
 #include        "vram.h"  #include        "vram.h"
 #include        "debugsub.h"  #include        "debugsub.h"
   
 #include        "x1_io.h"  
 #include        "x1_crtc.h"  
   
   
 //      状態吐き出し げろりんこ  //      状態吐き出し げろりんこ
   
Line 17  static int  filenum = 0; Line 14  static int  filenum = 0;
 void debugsub_status(void) {  void debugsub_status(void) {
   
         FILEH   fh;          FILEH   fh;
         OEMCHAR work[512];          OEMCHAR path[32];
           char    work[512];
   
         SPRINTF(work, OEMTEXT("z80reg.%.3d"), filenum);          OEMSPRINTF(path, OEMTEXT("z80reg.%.3d"), filenum);
         fh = file_create_c(work);          fh = file_create_c(path);
         if (fh != FILEH_INVALID) {          if (fh != FILEH_INVALID) {
                 SPRINTF(work,   OEMTEXT("PC = %04x\nAF = %04x\nBC = %04x\n")    \                  SPRINTF(work,   "PC = %04x\nAF = %04x\nBC = %04x\n"             \
                                                 OEMTEXT("DE = %04x\nHL = %04x\nIX = %04x\n")    \                                                  "DE = %04x\nHL = %04x\nIX = %04x\n"             \
                                                 OEMTEXT("IY = %04x\nSP = %04x\nAF'= %04x\n")    \                                                  "IY = %04x\nSP = %04x\nAF'= %04x\n"             \
                                                 OEMTEXT("BC'= %04x\nDE'= %04x\nHL'= %04x\n\n")  \                                                  "BC'= %04x\nDE'= %04x\nHL'= %04x\n\n"   \
                                                 OEMTEXT("IM = %2d\nADRS = %02x%02x\n\n")                \                                                  "IFF = %.2x\n"                                                  \
                                                 OEMTEXT("CRT_YL = %3d\nCRT_VS = %3d\n\n")               \                                                  "IM = %2d\nADRS = %02x%02x\n\n"                 \
                                                 OEMTEXT("FNT_YL = %3d\nTXT_YL = %3d\nSCRN_b = %02x\n"),                                                  "FNT_YL = %3d\nTXT_YL = %3d\nSCRN_b = %02x\n",
                                                 Z80_PC, Z80_AF, Z80_BC, Z80_DE,                                                  Z80_PC, Z80_AF, Z80_BC, Z80_DE,
                                                 Z80_HL, Z80_IX, Z80_IY, Z80_SP,                                                  Z80_HL, Z80_IX, Z80_IY, Z80_SP,
                                                 Z80_AF2, Z80_BC2, Z80_DE2, Z80_HL2,                                                  Z80_AF2, Z80_BC2, Z80_DE2, Z80_HL2,
                                                   Z80_IFF,
                                                 Z80_IM, Z80_I, subcpu.Ex[4][0],                                                  Z80_IM, Z80_I, subcpu.Ex[4][0],
                                                 crtc.CRT_YL, crtc.CRT_VS,                                                  crtc.e.fonty, crtc.e.yl, crtc.s.SCRN_BITS);
                                                 crtc.FNT_YL, crtc.TXT_YL, crtc.SCRN_BITS);                  file_write(fh, work, STRLEN(work));
                 file_write(fh, work, STRLEN(work) * sizeof(OEMCHAR));  
                 file_close(fh);                  file_close(fh);
         }          }
   
         SPRINTF(work, OEMTEXT("z80ram.%.3d"), filenum);          OEMSPRINTF(path, OEMTEXT("z80ram.%.3d"), filenum);
         fh = file_create_c(work);          fh = file_create_c(path);
         if (fh != FILEH_INVALID) {          if (fh != FILEH_INVALID) {
                 file_write(fh, mMAIN, 0x10000);                  file_write(fh, mainmem, 0x10000);
                 file_close(fh);                  file_close(fh);
         }          }
         SPRINTF(work, OEMTEXT("x1vram1.%.3d"), filenum);          OEMSPRINTF(path, OEMTEXT("x1vram1.%.3d"), filenum);
         fh = file_create_c(work);          fh = file_create_c(path);
         if (fh != FILEH_INVALID) {          if (fh != FILEH_INVALID) {
                 file_write(fh, &GRP_RAM[GRAM_BANK0 + 0x0000], 0x8000);                  file_write(fh, gram + GRAM_BANK0 + 0x0000, 0x8000);
                 file_write(fh, &GRP_RAM[GRAM_BANK0 + 0x8000], 0x8000);                  file_write(fh, gram + GRAM_BANK0 + 0x8000, 0x8000);
                 file_close(fh);                  file_close(fh);
         }          }
         SPRINTF(work, OEMTEXT("x1vram2.%.3d"), filenum);          OEMSPRINTF(path, OEMTEXT("x1vram2.%.3d"), filenum);
         fh = file_create_c(work);          fh = file_create_c(path);
         if (fh != FILEH_INVALID) {          if (fh != FILEH_INVALID) {
                 file_write(fh, &GRP_RAM[GRAM_BANK1 + 0x0000], 0x8000);                  file_write(fh, gram + GRAM_BANK1 + 0x0000, 0x8000);
                 file_write(fh, &GRP_RAM[GRAM_BANK1 + 0x8000], 0x8000);                  file_write(fh, gram + GRAM_BANK1 + 0x8000, 0x8000);
                 file_close(fh);                  file_close(fh);
         }          }
         SPRINTF(work, OEMTEXT("x1tram.%.3d"), filenum);          OEMSPRINTF(path, OEMTEXT("x1tram.%.3d"), filenum);
         fh = file_create_c(work);          fh = file_create_c(path);
         if (fh != FILEH_INVALID) {          if (fh != FILEH_INVALID) {
                 file_write(fh, tram, 0x1800);                  file_write(fh, tram, 0x1800);
                 file_close(fh);                  file_close(fh);

Removed from v.1.4  
changed lines
  Added in v.1.12


RetroPC.NET-CVS <cvs@retropc.net>