Previous 15994 Revisions Next

r9576 Sunday 14th November, 2010 at 02:27:59 UTC by Robbbert
[D6800] Added rtc pulse. Confirmed address of PIA.
[src/mess/drivers]d6800.c

src/mess/drivers/d6800.c
r9575r9576
2323
2424    TODO:
2525   - It doesn't boot up
26   - Find correct address of pia
2726   - Cassette
28   - RTC (vertical pulse)
2927   - CPU should freeze while screen is being drawn
3028   - Confirm if screen is being drawn the right way
3129   - Confirm keyboard configuration
r9575r9576
4341static UINT8 d6800_keylatch;
4442static UINT8 d6800_keydown;
4543static UINT8 d6800_screen;
44static UINT8 d6800_rtc;
4645static running_device *d6800_cassette;
4746static running_device *d6800_speaker;
4847
r9575r9576
5958/* Memory Maps */
6059
6160static ADDRESS_MAP_START( d6800_map, ADDRESS_SPACE_PROGRAM, 8 )
62   AM_RANGE(0x0000, 0x03ff) AM_MIRROR(0x7c00) AM_RAM AM_REGION("maincpu", 0x0000)
61   AM_RANGE(0x0000, 0x07ff) AM_RAM AM_REGION("maincpu", 0x0000)
6362   AM_RANGE(0x8010, 0x8013) AM_MIRROR(0x3cec) AM_DEVREADWRITE("pia", pia6821_r, pia6821_w)
6463   AM_RANGE(0xc000, 0xc3ff) AM_MIRROR(0x3c00) AM_ROM
6564ADDRESS_MAP_END
r9575r9576
126125
127126/* PIA6821 Interface */
128127
128static INTERRUPT_GEN( d6800_interrupt )
129{
130   d6800_rtc = 1;
131}
132
129133static READ_LINE_DEVICE_HANDLER( d6800_rtc_pulse )
130134{
131   return 0;
135   UINT8 res = d6800_rtc;
136   d6800_rtc = 0;
137   return res;
132138}
133139
134140static READ_LINE_DEVICE_HANDLER( d6800_keydown_r )
r9575r9576
163169   /*
164170   Cassette circuit consists of a 566 and a transistor. The 556 runs at 2400
165171   or 1200 Hz depending on the state of the transistor. This is controlled by
166   bit 0 of the PIA. Bit 6 controls the speaker.
172   bit 0 of the PIA. Bit 6 drives the speaker.
167173   */
168174
169175   speaker_level_w(d6800_speaker, (data & 0x40) ? 0 : 1);
r9575r9576
248254   /* basic machine hardware */
249255   MDRV_CPU_ADD("maincpu",M6800, XTAL_4MHz/4)
250256   MDRV_CPU_PROGRAM_MAP(d6800_map)
257   MDRV_CPU_VBLANK_INT("screen", d6800_interrupt)
251258
252259   MDRV_MACHINE_START(d6800)
253260   MDRV_MACHINE_RESET(d6800)

Previous 15994 Revisions Next


© 1998-2018 The MESS Team