OSDN Git Service

[VM][DATAREC][FDD] Add sounds of SEEK/CMT, excepts either pseudo devices / bios.
[csp-qt/common_source_project-fm7.git] / source / src / vm / mz2500 / timer.cpp
1 /*
2         SHARP MZ-2200 Emulator 'EmuZ-2200'
3         SHARP MZ-2500 Emulator 'EmuZ-2500'
4
5         Author : Takeda.Toshiya
6         Date   : 2006.12.03 -
7
8         [ timer ]
9 */
10
11 #include "timer.h"
12 #include "../i8253.h"
13
14 void TIMER::write_io8(uint32_t addr, uint32_t data)
15 {
16         switch(addr & 0xff) {
17         case 0xf0:
18         case 0xf1:
19         case 0xf2:
20         case 0xf3:
21                 // input gate signal H->L->H to i8253 ch0 and ch1
22                 d_pit->write_signal(SIG_I8253_GATE_0, 1, 1);
23                 d_pit->write_signal(SIG_I8253_GATE_1, 1, 1);
24                 d_pit->write_signal(SIG_I8253_GATE_0, 0, 1);
25                 d_pit->write_signal(SIG_I8253_GATE_1, 0, 1);
26                 d_pit->write_signal(SIG_I8253_GATE_0, 1, 1);
27                 d_pit->write_signal(SIG_I8253_GATE_1, 1, 1);
28                 break;
29         }
30 }
31