diff --git a/scripts/target/mame/mess.lua b/scripts/target/mame/mess.lua index 2a9322a87ae..c2c819adbe1 100644 --- a/scripts/target/mame/mess.lua +++ b/scripts/target/mame/mess.lua @@ -3698,6 +3698,8 @@ files { createMESSProjects(_target, _subtarget, "wyse") files { MAME_DIR .. "src/mame/drivers/wy100.cpp", + MAME_DIR .. "src/mame/drivers/wy150.cpp", + MAME_DIR .. "src/mame/drivers/wy30p.cpp", MAME_DIR .. "src/mame/drivers/wy50.cpp", MAME_DIR .. "src/mame/drivers/wy85.cpp", MAME_DIR .. "src/mame/drivers/wyse.cpp", diff --git a/src/mame/drivers/wy150.cpp b/src/mame/drivers/wy150.cpp new file mode 100644 index 00000000000..fca77aa8f85 --- /dev/null +++ b/src/mame/drivers/wy150.cpp @@ -0,0 +1,122 @@ +// license:BSD-3-Clause +// copyright-holders:AJR +/*********************************************************************************************************************************** + + Skeleton driver for Wyse WY-150 and related terminals. + + The WY-150, originally introduced in Nov. 1988, was the first of the "terminals of the future" that Wyse sold well into the + 1990s. The WY-160 is a graphical terminal that runs on different but clearly related hardware. + + All video functions in these terminals are integrated into ASICs (e.g. 211009-01, 211009-02). The 8032 generates all active + signals for both the main serial port and the serial keyboard. Three 8Kx8 SRAMs are used to store characters, attributes and + font data; the second is also battery-backed. + +************************************************************************************************************************************/ + +#include "emu.h" +#include "cpu/mcs51/mcs51.h" +#include "machine/nvram.h" +#include "screen.h" + +class wy150_state : public driver_device +{ +public: + wy150_state(const machine_config &mconfig, device_type type, const char *tag) + : driver_device(mconfig, type, tag) + , m_screen(*this, "screen") + { + } + + void wy150(machine_config &config); + +protected: + virtual void machine_start() override; + virtual void driver_start() override; + +private: + u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); + + void prog_map(address_map &map); + void ext_map(address_map &map); + + required_device m_screen; +}; + + +void wy150_state::machine_start() +{ +} + +u32 wy150_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) +{ + return 0; +} + +void wy150_state::prog_map(address_map &map) +{ + map(0x0000, 0xffff).rom().region("program", 0); +} + +void wy150_state::ext_map(address_map &map) +{ + map(0x0000, 0x1fff).ram().share("nvram"); + map(0x2000, 0x3fff).ram(); + map(0x4000, 0x5fff).ram(); +} + + +static INPUT_PORTS_START(wy150) +INPUT_PORTS_END + + +void wy150_state::wy150(machine_config &config) +{ + i80c32_device &maincpu(I80C32(config, "maincpu", 11_MHz_XTAL)); // Philips P80C32SBPN (e.g.) + maincpu.set_addrmap(AS_PROGRAM, &wy150_state::prog_map); + maincpu.set_addrmap(AS_IO, &wy150_state::ext_map); + + NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0); // 8464 or 5564 or similar (e.g. Winbond W2465-70LL) + battery + + SCREEN(config, m_screen, SCREEN_TYPE_RASTER); + m_screen->set_raw(48_MHz_XTAL, 1530, 0, 1200, 523, 0, 416); // 31.372 kHz horizontal + //m_screen->set_raw(48_MHz_XTAL, 1530, 0, 1188, 402, 0, 338); + // TBD: WY-160 should have different parameters (has 76 Hz refresh rate rather than 78 Hz) + m_screen->set_screen_update(FUNC(wy150_state::screen_update)); +} + + +ROM_START(wy150) + ROM_REGION(0x10000, "program", 0) + ROM_LOAD("251167-01.bin", 0x00000, 0x10000, CRC(4f425b11) SHA1(e44f54aa98d9f9c668a6ad674ec07e47879fc2a0)) + + ROM_REGION(0x20000, "link", 0) + ROM_LOAD("link_mc3.bin", 0x00000, 0x10000, CRC(9e1d37d9) SHA1(d74c0faf6cf1eb06243607931967cf35a633ac8e)) + ROM_LOAD("link_mc5_xerox-wy30.bin", 0x10000, 0x10000, CRC(1aa00cb4) SHA1(6a7267132fe35c8e07deccd67c0fb4fe5a240c99)) +ROM_END + +ROM_START(wy120) // b&w + ROM_REGION(0x10000, "program", 0) + ROM_LOAD("wy120_ver1.4.bin", 0x00000, 0x10000, CRC(6de23624) SHA1(ad90087237347662b5ae4fcc8a05d66d76c46a26)) +ROM_END + +ROM_START(wy160) + ROM_REGION(0x10000, "program", 0) + ROM_LOAD("251167-06.bin", 0x00000, 0x10000, CRC(36e920df) SHA1(8fb7f51b4f47ef63b21d421227d6fef98001e4e9)) +ROM_END + +void wy150_state::driver_start() +{ + uint8_t *rom = memregion("program")->base(); + for (offs_t base = 0x00000; base < 0x10000; base += 0x4000) + { + std::vector orig(&rom[base], &rom[base + 0x4000]); + + // Line swap is provided by schematic in WY-120 Maintenance Manual + for (offs_t offset = 0; offset < 0x4000; offset++) + rom[base | offset] = bitswap<8>(orig[bitswap<14>(offset, 7, 8, 6, 5, 4, 3, 9, 10, 11, 12, 13, 2, 1, 0)], 3, 4, 2, 5, 1, 6, 0, 7); + } +} + +COMP(1991, wy150, 0, 0, wy150, wy150, wy150_state, empty_init, "Wyse Technology", "WY-150 (v1.0)", MACHINE_IS_SKELETON) +COMP(1992, wy120, 0, 0, wy150, wy150, wy150_state, empty_init, "Wyse Technology", "WY-120 (v1.4)", MACHINE_IS_SKELETON) +COMP(1994, wy160, 0, 0, wy150, wy150, wy150_state, empty_init, "Wyse Technology", "WY-160 (v1.7)", MACHINE_IS_SKELETON) diff --git a/src/mame/drivers/wy30p.cpp b/src/mame/drivers/wy30p.cpp new file mode 100644 index 00000000000..dfdf3f45873 --- /dev/null +++ b/src/mame/drivers/wy30p.cpp @@ -0,0 +1,128 @@ +// license:BSD-3-Clause +// copyright-holders:AJR +/******************************************************************************* + + Skeleton driver for Wyse WY-30+ terminal. + + This low-end video terminal is the successor to the WY-30, whose control + board features an entirely different hardware configuration. + +*******************************************************************************/ + +#include "emu.h" +#include "cpu/mcs51/mcs51.h" +#include "machine/eepromser.h" +#include "screen.h" + +class wy30p_state : public driver_device +{ +public: + wy30p_state(const machine_config &mconfig, device_type type, const char *tag) + : driver_device(mconfig, type, tag) + , m_eeprom(*this, "eeprom") + , m_screen(*this, "screen") + { + } + + void wy30p(machine_config &config); + +protected: + virtual void machine_start() override; + virtual void driver_start() override; + +private: + u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); + + u8 p3_r(); + u8 de00_r(); + + void prog_map(address_map &map); + void ext_map(address_map &map); + + required_device m_eeprom; + required_device m_screen; +}; + + +void wy30p_state::machine_start() +{ +} + +u32 wy30p_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) +{ + return 0; +} + +u8 wy30p_state::p3_r() +{ + return 0xdf | (m_eeprom->do_read() << 5); +} + +u8 wy30p_state::de00_r() +{ + return m_screen->vblank() << 7; // probably not correct +} + +void wy30p_state::prog_map(address_map &map) +{ + map(0x0000, 0x3fff).mirror(0xc000).rom().region("program", 0); +} + +void wy30p_state::ext_map(address_map &map) +{ + map(0x0000, 0x1fff).ram(); + map(0xa000, 0xa7ff).ram(); + map(0xde00, 0xde00).mirror(0xff).r(FUNC(wy30p_state::de00_r)); +} + + +static INPUT_PORTS_START(wy30p) +INPUT_PORTS_END + + +void wy30p_state::wy30p(machine_config &config) +{ + i8031_device &maincpu(I8031(config, "maincpu", 7.3728_MHz_XTAL)); + maincpu.set_addrmap(AS_PROGRAM, &wy30p_state::prog_map); + maincpu.set_addrmap(AS_IO, &wy30p_state::ext_map); + maincpu.port_in_cb<3>().set(FUNC(wy30p_state::p3_r)); + maincpu.port_out_cb<3>().set(m_eeprom, FUNC(eeprom_serial_er5911_device::cs_write)).bit(3); + maincpu.port_out_cb<3>().append(m_eeprom, FUNC(eeprom_serial_er5911_device::clk_write)).bit(4); + maincpu.port_out_cb<3>().append(m_eeprom, FUNC(eeprom_serial_er5911_device::di_write)).bit(5); + + EEPROM_ER5911_8BIT(config, m_eeprom); + + SCREEN(config, m_screen, SCREEN_TYPE_RASTER); + m_screen->set_raw(31.2795_MHz_XTAL * 2 / 3, 1050, 0, 800, 331, 0, 300); // divider and dimensions guessed + m_screen->set_screen_update(FUNC(wy30p_state::screen_update)); +} + + +// PCB: "© 1989 990710-01 REV.B1" +// CPU: Intel P8031AH +// Program EPROM: 250971-02 (M27128MFI) "© WYSE TECH 92' REV.A" +// Nonvolatile memory: CSI CAT59C11P +// RAM: TC5565APL-12, HY6116AP-15 +// QFP gate array: 211019-02 (Oki M76V020) "© WYSE,1989" +// Jumper near gate array: "FONT SIZE" = "8Kx8" or "2Kx8" (J3) +// XTALs: 31.2795 (dot clock?), 7.3728 (for CPU) +// DB-25 connectors: "MDM" & "AUX" +ROM_START(wy30p) + ROM_REGION(0x4000, "program", 0) + ROM_LOAD("250971-02.u4", 0x0000, 0x4000, CRC(3666549c) SHA1(23c432da2083df4b355daf566dd6514d1f9a7690)) +ROM_END + +void wy30p_state::driver_start() +{ + uint8_t *rom = memregion("program")->base(); + for (offs_t base = 0x0000; base < 0x4000; base += 0x2000) + { + std::vector orig(&rom[base], &rom[base + 0x2000]); + + // Line swaps can be confusing... + for (offs_t offset = 0; offset < 0x2000; offset++) + rom[base | offset] = bitswap<8>(orig[bitswap<13>(offset, 8, 5, 0, 4, 3, 9, 7, 10, 11, 12, 2, 6, 1)], 3, 4, 5, 6, 7, 2, 1, 0); + } +} + +COMP(1992, wy30p, 0, 0, wy30p, wy30p, wy30p_state, empty_init, "Wyse Technology", "WY-30+ (v1.8)", MACHINE_IS_SKELETON) diff --git a/src/mame/drivers/wyse.cpp b/src/mame/drivers/wyse.cpp index d99891b5292..5929fde143f 100644 --- a/src/mame/drivers/wyse.cpp +++ b/src/mame/drivers/wyse.cpp @@ -6,18 +6,11 @@ Wyse terminals. -WY-30+: P8031AH, OKI M76V020, TC5565APL-12, HY6116AP-15, Beeper, 31.2795, 7.3728 (for CPU) - WY-60: SC67336P, P8051AN-40196, SCN2661B, 7219-0629, 4.9152, 11.000, 39.710, 26.580, Beeper -WY-150: Philips P80C32SBPN, Toshiba 211009-02, Winbond ??, unknown crystal - CPU EPROM VIDEO RAM Row Buffer Font RAM NVRAM Serial Dot Clk CPU Clk Ser Clk -WY-30+ 8031 27128(250971-02) 211019-02 5565 6116 CAT59C11 31.2795 7.3728 WY-55 8032 (251352-12) 211019-05 8k (8kx2) battery 16C452 49.423 14.7456 WY-60 8051(202008-03) 27512(193003-01) 211003-02/205001-02 2064 ( 2064/2016/2016/2064) X24C04 2661 39.710/26.580 11.000 4.9152 -WY-120 8032 27256(250412-01) SLA7490(211009-01) 6264/5564 6264 battery - 48.000 11.000 -WY-150 8032 27512(251167-06) 211009-02 6264 (2x6264) battery - 48.000 11.000 ************************************************************************************************************************************/ @@ -44,7 +37,7 @@ private: void wyse_state::mem_map(address_map &map) { - map(0x0000, 0x3fff).rom(); + map(0x0000, 0xffff).rom(); } void wyse_state::io_map(address_map &map) @@ -61,11 +54,6 @@ void wyse_state::wyse(machine_config &config) maincpu.set_addrmap(AS_IO, &wyse_state::io_map); } -ROM_START( wy30p ) - ROM_REGION( 0x10000, "maincpu", 0 ) - ROM_LOAD( "250971-02.u4", 0x0000, 0x4000, CRC(3666549c) SHA1(23c432da2083df4b355daf566dd6514d1f9a7690) ) -ROM_END - ROM_START( wy55 ) ROM_REGION( 0x20000, "maincpu", 0 ) ROM_LOAD( "251352-12.bin", 0x0000, 0x20000, CRC(efe41862) SHA1(52ee76d636b166fa10a37356aef81011a9b079cc) ) // v2.1 @@ -78,27 +66,5 @@ ROM_START( wy60 ) ROM_LOAD( "wy-60_4k.u6", 0x0000, 0x10000, CRC(6daf2824) SHA1(23cd039ec7ae71b0742e8eebf75be8cd5992e3fd) ) ROM_END -ROM_START( wy120 ) // b&w - ROM_REGION( 0x10000, "maincpu", 0 ) - ROM_LOAD( "wy120_ver1.4.bin", 0x000000, 0x010000, CRC(6de23624) SHA1(ad90087237347662b5ae4fcc8a05d66d76c46a26) ) -ROM_END - -ROM_START( wy150 ) - ROM_REGION( 0x10000, "maincpu", 0 ) - ROM_LOAD( "251167-01.bin", 0x00000, 0x10000, CRC(4f425b11) SHA1(e44f54aa98d9f9c668a6ad674ec07e47879fc2a0) ) - ROM_REGION( 0x20000, "link", 0 ) - ROM_LOAD( "link_mc3.bin", 0x00000, 0x10000, CRC(9e1d37d9) SHA1(d74c0faf6cf1eb06243607931967cf35a633ac8e) ) - ROM_LOAD( "link_mc5_xerox-wy30.bin", 0x10000, 0x10000, CRC(1aa00cb4) SHA1(6a7267132fe35c8e07deccd67c0fb4fe5a240c99) ) -ROM_END - -ROM_START( wy160 ) - ROM_REGION( 0x10000, "maincpu", 0 ) - ROM_LOAD( "251167-06.bin", 0x00000, 0x10000, CRC(36e920df) SHA1(8fb7f51b4f47ef63b21d421227d6fef98001e4e9) ) -ROM_END - COMP( 1986, wy60, 0, 0, wyse, wyse, wyse_state, empty_init, "Wyse Technology", "WY-60", MACHINE_IS_SKELETON ) -COMP( 1987, wy120, 0, 0, wyse, wyse, wyse_state, empty_init, "Wyse Technology", "WY-120", MACHINE_IS_SKELETON ) -COMP( 1988, wy150, 0, 0, wyse, wyse, wyse_state, empty_init, "Wyse Technology", "WY-150", MACHINE_IS_SKELETON ) -COMP( 1990, wy160, 0, 0, wyse, wyse, wyse_state, empty_init, "Wyse Technology", "WY-160", MACHINE_IS_SKELETON ) -COMP( 1991, wy30p, 0, 0, wyse, wyse, wyse_state, empty_init, "Wyse Technology", "WY-30+", MACHINE_IS_SKELETON ) COMP( 1993, wy55, 0, 0, wyse, wyse, wyse_state, empty_init, "Wyse Technology", "WY-55", MACHINE_IS_SKELETON ) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 3307cd15c7e..58794f5e61a 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -39825,6 +39825,14 @@ wwfsstaru4 // TA-0024 (c) 1989 (US) @source:wy100.cpp wy100 // WY-100 +@source:wy150.cpp +wy120 // WY-120 +wy150 // WY-150 +wy160 // WY-160 + +@source:wy30p.cpp +wy30p // WY-30+ + @source:wy50.cpp wy50 // WY-50 wy75 // WY-75 @@ -39835,10 +39843,6 @@ wy85 // WY-85 @source:wyse.cpp wy55 // WY-55 wy60 // WY-60 -wy120 // WY-120 -wy150 // WY-150 -wy160 // WY-160 -wy30p // WY-30+ @source:wyvernf0.cpp wyvernf0 // A39 (c) 1985 Taito Corporation (Japan) diff --git a/src/mame/mess.flt b/src/mame/mess.flt index 7da09bd3b08..f7270561950 100644 --- a/src/mame/mess.flt +++ b/src/mame/mess.flt @@ -876,6 +876,8 @@ wangpc.cpp wicat.cpp wswan.cpp wy100.cpp +wy150.cpp +wy30p.cpp wy50.cpp wy85.cpp wyse.cpp