Diff for /np2/trap/inttrap.c between versions 1.1 and 1.4

version 1.1, 2005/03/03 06:59:42 version 1.4, 2005/05/20 13:59:48
Line 6 Line 6
   
 void CPUCALL softinttrap(UINT cs, UINT32 eip, UINT vect) {  void CPUCALL softinttrap(UINT cs, UINT32 eip, UINT vect) {
   
   
 // ---- ここにトラップ条件コードを書きます  // ---- ここにトラップ条件コードを書きます
 //      return;          if (vect == 0x7f) {
                   switch(CPU_AH) {
                           case 0:
                                   TRACEOUT(("INT-7F AH=00 Load data DS:DX = %.4x:%.4x", CPU_DS, CPU_DX));
                                   break;
   
                           case 1:
                                   TRACEOUT(("INT-7F AH=01 Play data AL=%.2x", CPU_AL));
                                   break;
   
                           case 2:
                                   TRACEOUT(("INT-7F AH=02 Stop Data"));
                                   break;
   
   //                      case 3:
   //                              TRACEOUT(("INT-7F AH=03 Get Status"));
   //                              break;
   
                           case 4:
                                   TRACEOUT(("INT-7F AH=04 Set Parameter AL=%.2x", CPU_AL));
                                   break;
                   }
           }
           return;
   
           if (vect == 0x50) {
                   if (CPU_AX != 9)
                   TRACEOUT(("%.4x:%.4x INT-50 AX=%.4x BX=%.4x DX=%.4x", cs, eip, CPU_AX, CPU_BX, CPU_DX));
           }
           if (vect == 0x51) {
                   TRACEOUT(("%.4x:%.4x INT-51 AX=%.4x BX=%.4x DX=%.4x", cs, eip, CPU_AX, CPU_BX, CPU_DX));
           }
           return;
   
 #if 0  #if 0
 //      if (vect == 0x2f) {  //      if (vect == 0x2f) {
Line 120  void CPUCALL softinttrap(UINT cs, UINT32 Line 151  void CPUCALL softinttrap(UINT cs, UINT32
         if (vect == 0x40) {          if (vect == 0x40) {
                 TRACEOUT(("%.4x:%.4x INT-40 SI=%.4x %.4x:%.4x:%.4x",                  TRACEOUT(("%.4x:%.4x INT-40 SI=%.4x %.4x:%.4x:%.4x",
                                                                         cs, eip, CPU_SI,                                                                          cs, eip, CPU_SI,
                                                                         MEML_READ16(CPU_DS, CPU_SI + 0),                                                                          MEMR_READ16(CPU_DS, CPU_SI + 0),
                                                                         MEML_READ16(CPU_DS, CPU_SI + 2),                                                                          MEMR_READ16(CPU_DS, CPU_SI + 2),
                                                                         MEML_READ16(CPU_DS, CPU_SI + 4)));                                                                          MEMR_READ16(CPU_DS, CPU_SI + 4)));
         }          }
         if (vect == 0xd2) {          if (vect == 0xd2) {
                 TRACEOUT(("%.4x:%.4x INT-D2 AX=%.4x", cs, eip, CPU_AX));                  TRACEOUT(("%.4x:%.4x INT-D2 AX=%.4x", cs, eip, CPU_AX));
Line 141  void CPUCALL softinttrap(UINT cs, UINT32 Line 172  void CPUCALL softinttrap(UINT cs, UINT32
                 switch(CPU_AH) {                  switch(CPU_AH) {
                         case 0x3d:                          case 0x3d:
                                 for (i=0; i<127; i++) {                                  for (i=0; i<127; i++) {
                                         c = MEML_READ8(CPU_DS, CPU_DX + i);                                          c = MEMR_READ8(CPU_DS, CPU_DX + i);
                                         if (c == '\0') break;                                          if (c == '\0') break;
                                         f[i] = c;                                          f[i] = c;
                                 }                                  }
Line 162  void CPUCALL softinttrap(UINT cs, UINT32 Line 193  void CPUCALL softinttrap(UINT cs, UINT32
 #if 0  #if 0
         if (vect == 0xf5) {          if (vect == 0xf5) {
                 TRACEOUT(("%.4x:%.4x INT-F5 AH=%.2x STACK=%.4x", cs, eip,                  TRACEOUT(("%.4x:%.4x INT-F5 AH=%.2x STACK=%.4x", cs, eip,
                                                                 CPU_AH, MEML_READ16(CPU_SS, CPU_SP + 2)));                                                                  CPU_AH, MEMR_READ16(CPU_SS, CPU_SP + 2)));
         }          }
 #endif  #endif
 #if 0  #if 0
Line 210  void CPUCALL softinttrap(UINT cs, UINT32 Line 241  void CPUCALL softinttrap(UINT cs, UINT32
                                         char buf[256];                                          char buf[256];
                                         for (j=0; j<4; j++) {                                          for (j=0; j<4; j++) {
                                                 sprintf(buf + (j * 6), "0x%.2x, ",                                                  sprintf(buf + (j * 6), "0x%.2x, ",
                                                                                 MEML_READ8(CPU_DS, CPU_DX + i + j));                                                                                  MEMR_READ8(CPU_DS, CPU_DX + i + j));
                                         }                                          }
                                         TRACEOUT(("%s", buf));                                          TRACEOUT(("%s", buf));
                                 }                                  }

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


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