Minor fix

This commit is contained in:
transistor 2022-01-16 10:56:32 -08:00
parent a60e72fc04
commit 1413225463
2 changed files with 6 additions and 3 deletions

View File

@ -56,7 +56,7 @@ impl GenesisControllerPort {
(true, 2) => self.outputs | ((inputs & 0x0030) as u8) | (((inputs & 0x0F00) >> 8) as u8),
(false, 3) => self.outputs | (((inputs & 0x00C0) >> 2) as u8) | 0x0F,
(true, 3) => self.outputs | ((inputs & 0x003F) as u8),
(false, 1) => self.outputs | (((inputs & 0x00C0) >> 2) as u8) | ((inputs & 0x0003) as u8),
(false, 0) => self.outputs | (((inputs & 0x00C0) >> 2) as u8) | ((inputs & 0x0003) as u8),
_ => 0,
}
}

View File

@ -47,6 +47,7 @@ const STATUS_IN_VBLANK: u16 = 0x0008;
//const STATUS_FIFO_FULL: u16 = 0x0100;
const STATUS_FIFO_EMPTY: u16 = 0x0200;
const MODE1_BF_DISABLE_DISPLAY: u8 = 0x01;
//const MODE1_BF_ENABLE_HV_COUNTER: u8 = 0x02;
const MODE1_BF_HSYNC_INTERRUPT: u8 = 0x10;
@ -652,8 +653,10 @@ impl Steppable for Ym7101 {
}
self.swapper.swap();
let mut frame = self.swapper.current.lock().unwrap();
self.state.draw_frame(&mut frame);
if (self.state.mode_1 & MODE1_BF_DISABLE_DISPLAY) == 0 {
let mut frame = self.swapper.current.lock().unwrap();
self.state.draw_frame(&mut frame);
}
self.frame_complete.signal();
}