vtech2: Add I/O expansion slot

This adds support for the joystick and printer.
This commit is contained in:
Dirk Best 2018-12-24 16:12:37 +01:00
parent d75c6a9b3b
commit 6bdcef6f17
3 changed files with 10 additions and 5 deletions

View File

@ -61,7 +61,6 @@
TODO:
- Ram pak
- undumped DOS ROM
- joystick
- need software
Cartslot works, even though it seems there were no game carts made
@ -75,14 +74,12 @@
#include "emu.h"
#include "includes/vtech2.h"
#include "cpu/z80/z80.h"
#include "sound/wave.h"
#include "formats/vt_cas.h"
#include "screen.h"
#include "speaker.h"
#include "formats/vt_cas.h"
void vtech2_state::mem_map(address_map &map)
@ -525,6 +522,8 @@ MACHINE_CONFIG_START(vtech2_state::laser350)
MCFG_CASSETTE_FORMATS(vtech2_cassette_formats)
MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_PLAY)
MCFG_IOEXP_SLOT_ADD("io")
/* cartridge */
MCFG_GENERIC_CARTSLOT_ADD("cartslot", generic_plain_slot, "vtech_cart")
MCFG_GENERIC_EXTENSIONS("rom,bin")

View File

@ -12,6 +12,7 @@
#include "machine/bankdev.h"
#include "bus/generic/carts.h"
#include "bus/generic/slot.h"
#include "bus/vtech/ioexp/ioexp.h"
#include "imagedev/cassette.h"
#include "imagedev/flopdrv.h"
#include "sound/spkrdev.h"
@ -37,6 +38,7 @@ public:
, m_bankb(*this, "bankb")
, m_bankc(*this, "bankc")
, m_bankd(*this, "bankd")
, m_ioexp(*this, "io")
{ }
void laser350(machine_config &config);
@ -84,6 +86,7 @@ private:
required_device<address_map_bank_device> m_bankb;
required_device<address_map_bank_device> m_bankc;
required_device<address_map_bank_device> m_bankd;
required_device<vtech_ioexp_slot_device> m_ioexp;
char m_laser_frame_message[64+1];
int m_laser_frame_time;

View File

@ -8,7 +8,7 @@
Davide Moretti <dave@rimini.com> ROM dump and hardware description
TODO:
Printer and RS232 support.
RS232 support.
Check if the FDC is really the same as in the
Laser 210/310 (aka VZ200/300) series.
@ -43,6 +43,9 @@ void vtech2_state::init_laser()
// check ROM expansion
std::string region_tag;
m_cart_rom = memregion(region_tag.assign(m_cart->tag()).append(GENERIC_ROM_REGION_TAG).c_str());
// setup expansion slot
m_ioexp->set_io_space(&m_maincpu->space(AS_IO));
}