Diff for /np2/cbus/pcm86io.c between versions 1.5 and 1.6

version 1.5, 2004/03/28 19:50:25 version 1.6, 2004/03/30 07:12:03
Line 46  static void IOOUTCALL pcm86_oa468(UINT p Line 46  static void IOOUTCALL pcm86_oa468(UINT p
                 pcm86.wrtpos = 0;                  pcm86.wrtpos = 0;
                 pcm86.realbuf = 0;                  pcm86.realbuf = 0;
                 pcm86.virbuf = 0;                  pcm86.virbuf = 0;
                 pcm86.write = 0;  
                 pcm86.reqirq = 0;  
                 pcm86.lastclock = CPU_CLOCK + CPU_BASECLOCK - CPU_REMCLOCK;                  pcm86.lastclock = CPU_CLOCK + CPU_BASECLOCK - CPU_REMCLOCK;
                 pcm86.lastclock <<= 6;                  pcm86.lastclock <<= 6;
         }          }
           if ((xchgbit & 0x10) && (!(val & 0x10))) {
                   pcm86.write = 0;
                   pcm86.reqirq = 0;
           }
         // サンプリングレート変更          // サンプリングレート変更
         if (xchgbit & 7) {          if (xchgbit & 7) {
                 pcm86.rescue = pcm86rescue[val & 7] << pcm86.stepbit;                  pcm86.rescue = pcm86rescue[val & 7] << pcm86.stepbit;
Line 61  static void IOOUTCALL pcm86_oa468(UINT p Line 63  static void IOOUTCALL pcm86_oa468(UINT p
                 pcm86.lastclock = CPU_CLOCK + CPU_BASECLOCK - CPU_REMCLOCK;                  pcm86.lastclock = CPU_CLOCK + CPU_BASECLOCK - CPU_REMCLOCK;
                 pcm86.lastclock <<= 6;                  pcm86.lastclock <<= 6;
         }          }
         pcm86.write = 1;  
         pcm86_setnextintr();          pcm86_setnextintr();
         (void)port;          (void)port;
 }  }
Line 154  static REG8 IOINPCALL pcm86_ia468(UINT p Line 155  static REG8 IOINPCALL pcm86_ia468(UINT p
         REG8    ret;          REG8    ret;
   
         ret = pcm86.fifo & (~0x10);          ret = pcm86.fifo & (~0x10);
   #if 1
           if (pcm86gen_intrq()) {
                   ret |= 0x10;
           }
   #elif 1         // むしろこう?
           if (pcm86.fifo & 0x20) {
                   sound_sync();
                   if (pcm86.virbuf <= pcm86.fifosize) {
                           if (pcm86.write) {
                                   pcm86.write = 0;
                           }
                           else {
                                   ret |= 0x10;
                           }
                   }
           }
   #else
         if ((pcm86.write) && (pcm86.fifo & 0x20)) {          if ((pcm86.write) && (pcm86.fifo & 0x20)) {
 //              pcm86.write = 0;  //              pcm86.write = 0;
                 sound_sync();                  sound_sync();
Line 162  static REG8 IOINPCALL pcm86_ia468(UINT p Line 180  static REG8 IOINPCALL pcm86_ia468(UINT p
                         ret |= 0x10;                          ret |= 0x10;
                 }                  }
         }          }
   #endif
         (void)port;          (void)port;
         return(ret);          return(ret);
 }  }

Removed from v.1.5  
changed lines
  Added in v.1.6


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