Previous 199869 Revisions Next

r30638 Saturday 24th May, 2014 at 18:28:39 UTC by Wilbert Pol
(MESS) msx.c: Some small msx audio related updates (nw)
[hash]msx1_cart.xml
[src/emu/bus/msx_cart]msx_audio.c msx_audio.h msx_audio_kb.c

trunk/hash/msx1_cart.xml
r30637r30638
1453714537   </software>
1453814538
1453914539   <software name="nms1205">
14540      <description>Philips NMS-1205 Music Module</description>
14540      <description>Philips NMS-1205 Music Module v1.2</description>
1454114541      <year>198?</year>
1454214542      <publisher>Philips</publisher>
1454314543      <part name="cart" interface="msx_cart">
1454414544         <feature name="slot" value="msxaud_nms1205" />
1454514545         <dataarea name="rom" size="32768">
14546            <!-- SUM16 should be DE54, not verified -->
1454614547            <rom name="nms1205.bin" size="32768" crc="5ecaeef0" sha1="c7463e1fd0433c5d41b70670d6c10fd781b66426" offset="0" />
1454714548         </dataarea>
14549<!--
14550This memory is currently declared as a memory region inside the nms1205 implementation otherwise the
14551legacy FM implementations cannot find it.
1454814552         <dataarea name="ram" size="32768">
1454914553         </dataarea>
14554-->
1455014555      </part>
1455114556   </software>
1455214557
14558   <!-- Unsure about the correctness of this dump. It boots straight into basic and you have to stasrt the internal software by doing 'call musicbox' -->
14559   <software name="nms1205v11" cloneof="nms1205">
14560      <description>Philips NMS-1205 Music Module v1.1</description>
14561      <year>198?</year>
14562      <publisher>Philips</publisher>
14563      <part name="cart" interface="msx_cart">
14564         <feature name="slot" value="msxaud_nms1205" />
14565         <dataarea name="rom" size="32768">
14566            <!-- SUM16: DE5C -->
14567            <rom name="nms1205_de5c.bin" size="32768" crc="d8a17006" sha1="f081a884505af9a1080b2b57e86b6da93b784301" offset="0" />
14568         </dataarea>
14569<!--
14570This memory is currently declared as a memory region inside the nms1205 implementation otherwise the
14571legacy FM implementations cannot find it.
14572         <dataarea name="ram" size="32768">
14573         </dataarea>
14574-->
14575      </part>
14576   </software>
14577
14578<!--
14579   <software name="nms1205v10" cloneof="nms1205" supported="no">
14580   <description>Philips NMS-1205 Music Module v1.0</description>
14581      <year>198?</year>
14582      <publisher>Philips</publisher>
14583      <part name="cart" interface="msx_cart">
14584         <feature name="slot" value="msxaud_nms1205" />
14585         <dataarea name="rom" size="32768">
14586            <!-- SUM16: 53BF -->
14587            <rom name="nms1205_53bf.bin" size="32768" crc="6e68bd44" sha1="146d9738b6d534277dab9b41a07556ffec9065b9" status="baddump" offset="0" />
14588         </dataarea>
14589<!- -
14590This memory is currently declared as a memory region inside the nms1205 implementation otherwise the
14591legacy FM implementations cannot find it.
14592         <dataarea name="ram" size="32768">
14593         </dataarea>
14594- ->
14595      </part>
14596   </software>
14597-->
14598
1455314599<!-- Dictionary ROMs? -->
1455414600   <software name="natjis" supported="no">
1455514601      <description>National FS-SR022 MSX-Jisho (Jpn)</description>
trunk/src/emu/bus/msx_cart/msx_audio.h
r30637r30638
3939   // device-level overrides
4040   virtual void device_start();
4141   virtual machine_config_constructor device_mconfig_additions() const;
42   virtual const rom_entry *device_rom_region() const;
4243
4344   virtual void initialize_cartridge();
4445
trunk/src/emu/bus/msx_cart/msx_audio_kb.c
r30637r30638
179179      : device_t(mconfig, MSX_AUDIO_KB_NMS1160, "Philips NMS-1160", tag, owner, clock, "nms1160", __FILE__)
180180      , msx_audio_kb_port_interface(mconfig, *this)
181181      , m_row(0)
182      , m_keyboard(*this, "KEY")
182183   { };
183184
184//   virtual ioport_constructor device_input_ports() const;
185   virtual ioport_constructor device_input_ports() const;
185186
186187   virtual DECLARE_READ8_MEMBER(read)
187188   {
188      return 0xff;
189      UINT8 result = 0xff;
190
191      for (int i = 0; i < 8; i++)
192      {
193         if (BIT(m_row,i))
194         {
195            result &= m_keyboard[i]->read();
196         }
197      }
198      return result;
189199   }
190200
191201   virtual DECLARE_WRITE8_MEMBER(write)
192202   {
193      printf("msx_nms1160::write %02x\n", data);
203      logerror("msx_nms1160::write %02x\n", data);
194204      m_row = data;
195205   }
196206
r30637r30638
199209
200210private:
201211   UINT8 m_row;
212   required_ioport_array<8> m_keyboard;
202213};
203214
204215
216static INPUT_PORTS_START( nms1160 )
217   PORT_START("KEY.0")
218   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C1")
219   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C#1")
220   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D1")
221   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D#1")
222   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E1")
223   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F1")
224   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F#1")
225   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G1")
226
227   PORT_START("KEY.1")
228   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G#1")
229   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A1")
230   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A#1")
231   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B1")
232   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C2")
233   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C#2")
234   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D2")
235   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D#2")
236
237   PORT_START("KEY.2")
238   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E2")
239   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F2")
240   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F#2")
241   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G2")
242   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G#2")
243   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A2")
244   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A#2")
245   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B2")
246
247   PORT_START("KEY.3")
248   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C3")
249   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C#3")
250   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D3")
251   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D#3")
252   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E3")
253   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F3")
254   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F#3")
255   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G3")
256
257   PORT_START("KEY.4")
258   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G#3")
259   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A3")
260   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A#3")
261   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B3")
262   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C4")
263   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C#4")
264   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D4")
265   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D#4")
266
267   PORT_START("KEY.5")
268   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E4")
269   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F4")
270   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F#4")
271   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G4")
272   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G#4")
273   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A4")
274   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A#4")
275   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B4")
276
277   PORT_START("KEY.6")
278   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C5")
279   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C#5")
280   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D5")
281   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D#5")
282   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E5")
283   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F5")
284   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F#5")
285   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G5")
286
287   PORT_START("KEY.7")
288   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G#5")
289   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A5")
290   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A#5")
291   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B5")
292   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C6")
293   PORT_BIT(0xe0, IP_ACTIVE_LOW, IPT_UNUSED)
294INPUT_PORTS_END
295
296
297ioport_constructor msx_nms1160::device_input_ports() const
298{
299   return INPUT_PORTS_NAME( nms1160 );
300}
301
302
303
205304const device_type MSX_AUDIO_KB_HXMU901 = &device_creator<msx_hxmu901>;
206305const device_type MSX_AUDIO_KB_NMS1160 = &device_creator<msx_nms1160>;
207306
trunk/src/emu/bus/msx_cart/msx_audio.c
r30637r30638
2929
3030- Philips NMS-1160
3131
32
33
34TODO:
35- Implement MIDI in/out/through
36- Sample RAM
37- Implement NMS-1160 keyboard
38- HX-MU901: ENTER/SELECT keys and multi sensors
39- NMS1160: Test the keyboard
40
3241**********************************************************************************/
3342
3443#include "emu.h"
r30637r30638
108117
109118
110119static MACHINE_CONFIG_FRAGMENT( msx_audio_nms1205 )
111   // There is a 2 MHz crystal on the PCB, where does it go?
112
113120   // This is actually incorrect. The sound output is passed back into the MSX machine where it is mixed internally and output through the system 'speaker'.
114121   MCFG_SPEAKER_STANDARD_MONO("mono")
115122   MCFG_SOUND_ADD("y8950", Y8950, XTAL_3_579545MHz)
r30637r30638
119126
120127   MCFG_MSX_AUDIO_KBDC_PORT_ADD("kbdc", msx_audio_keyboards, NULL)
121128
129   // There is a 2 MHz crystal on the PCB, the 6850 TX and RX clocks are derived from it
122130   MCFG_DEVICE_ADD("acia6850", ACIA6850, 0)
123131MACHINE_CONFIG_END
124132
r30637r30638
129137}
130138
131139
140ROM_START( msx_nms1205 )
141   ROM_REGION(0x8000, "y8950", ROMREGION_ERASE00)
142ROM_END
143
144
145const rom_entry *msx_cart_msx_audio_nms1205::device_rom_region() const
146{
147   return ROM_NAME( msx_nms1205 );
148}
149
150
132151void msx_cart_msx_audio_nms1205::device_start()
133152{
134153   // Install IO read/write handlers

Previous 199869 Revisions Next


© 1997-2024 The MAME Team