1 // license:BSD-3-Clause
2 // copyright-holders:Curt Coder
3 /**********************************************************************
4
5 PS-64 speech cartridge emulation
6
7 **********************************************************************/
8
9 /*
10
11 PCB Layout
12 ----------
13
14 |===========================|
15 |=| |
16 |=| SW1|
17 |=| SC02 |
18 |=| |
19 |=| CN1|
20 |=| ROM LF347 |
21 |=| |
22 |=| |
23 |===========================|
24
25 SC02 - Votrax SSI-263AP Speech Synthesizer
26 ROM - Hynix Semiconductor HY27C64D-20 8Kx8 EPROM
27 LF347 - National Instruments LF347N JFET Operational Amplifier
28 SW1 - Module on/off switch
29 CN1 - connector to C64 video/audio port
30
31 */
32
33 /*
34
35 TODO:
36
37 - Votrax SC02 emulation
38 - route sound to SID audio input
39 - on/off switch
40
41 */
42
43 #include "emu.h"
44 #include "ps64.h"
45
46
47
48 //**************************************************************************
49 // MACROS/CONSTANTS
50 //**************************************************************************
51
52 #define SSI263_TAG "ssi263"
53
54
55
56 //**************************************************************************
57 // DEVICE DEFINITIONS
58 //**************************************************************************
59
60 DEFINE_DEVICE_TYPE(C64_PS64, c64_ps64_cartridge_device, "c64_ps64", "C64 PS-64")
61
62
63 //-------------------------------------------------
64 // device_add_mconfig - add device configuration
65 //-------------------------------------------------
66
device_add_mconfig(machine_config & config)67 void c64_ps64_cartridge_device::device_add_mconfig(machine_config &config)
68 {
69 //SPEAKER(config, "speaker").front_center();
70 //VOTRAX_SC02(config, SSI263_TAG, 2000000).add_route(ALL_OUTPUTS, "mono", 1.00);
71 }
72
73
74
75 //**************************************************************************
76 // LIVE DEVICE
77 //**************************************************************************
78
79 //-------------------------------------------------
80 // c64_ps64_cartridge_device - constructor
81 //-------------------------------------------------
82
c64_ps64_cartridge_device(const machine_config & mconfig,const char * tag,device_t * owner,uint32_t clock)83 c64_ps64_cartridge_device::c64_ps64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
84 device_t(mconfig, C64_PS64, tag, owner, clock),
85 device_c64_expansion_card_interface(mconfig, *this)
86 {
87 }
88
89
90 //-------------------------------------------------
91 // device_start - device-specific startup
92 //-------------------------------------------------
93
device_start()94 void c64_ps64_cartridge_device::device_start()
95 {
96 }
97
98
99 //-------------------------------------------------
100 // device_reset - device-specific reset
101 //-------------------------------------------------
102
device_reset()103 void c64_ps64_cartridge_device::device_reset()
104 {
105 }
106
107
108 //-------------------------------------------------
109 // c64_cd_r - cartridge data read
110 //-------------------------------------------------
111
c64_cd_r(offs_t offset,uint8_t data,int sphi2,int ba,int roml,int romh,int io1,int io2)112 uint8_t c64_ps64_cartridge_device::c64_cd_r(offs_t offset, uint8_t data, int sphi2, int ba, int roml, int romh, int io1, int io2)
113 {
114 if (!roml)
115 {
116 data = m_roml[offset & 0x1fff];
117 }
118 else if (!io1)
119 {
120 //sc02->read(offset & 0x07);
121 }
122
123 return data;
124 }
125
126
127 //-------------------------------------------------
128 // c64_cd_w - cartridge data write
129 //-------------------------------------------------
130
c64_cd_w(offs_t offset,uint8_t data,int sphi2,int ba,int roml,int romh,int io1,int io2)131 void c64_ps64_cartridge_device::c64_cd_w(offs_t offset, uint8_t data, int sphi2, int ba, int roml, int romh, int io1, int io2)
132 {
133 if (!io1)
134 {
135 // sc02->write(offset & 0x07, data);
136 }
137 }
138