diff options
24 files changed, 1496 insertions, 180 deletions
diff --git a/plugins/boot.lua b/plugins/boot.lua index 5ed1ac803ad..98eb14baa86 100644 --- a/plugins/boot.lua +++ b/plugins/boot.lua @@ -26,27 +26,11 @@ local dir = lfs.env_replace(manager:options().entries.pluginspath:value()) package.path = dir .. "/?.lua;" .. dir .. "/?/init.lua" -local json = require('json') -local function readAll(file) - local f = io.open(file, "rb") - local content = f:read("*all") - f:close() - return content -end - -for file in lfs.dir(dir) do - if (file~="." and file~=".." and lfs.attributes(dir .. "/" .. file,"mode")=="directory") then - local filename = dir .. "/" .. file .. "/plugin.json" - local meta = json.parse(readAll(filename)) - if (meta["plugin"]["type"]=="plugin") and (mame_manager:plugins().entries[meta["plugin"]["name"]]~=nil) then - local entry = mame_manager:plugins().entries[meta["plugin"]["name"]] - if (entry:value()==true) then - emu.print_verbose("Starting plugin " .. meta["plugin"]["name"] .. "...") - plugin = require(meta["plugin"]["name"]) - if plugin.set_folder~=nil then plugin.set_folder(dir .. "/" .. file) end - plugin.startplugin(); - end - end +for _,entry in pairs(manager:plugins()) do + if (entry.type == "plugin" and entry.start) then + emu.print_verbose("Starting plugin " .. entry.name .. "...") + plugin = require(entry.name) + if plugin.set_folder~=nil then plugin.set_folder(entry.directory) end + plugin.startplugin(); end end - diff --git a/scripts/target/mame/mess.lua b/scripts/target/mame/mess.lua index 867c1ef0ab2..325283f6f92 100644 --- a/scripts/target/mame/mess.lua +++ b/scripts/target/mame/mess.lua @@ -1851,6 +1851,7 @@ createMESSProjects(_target, _subtarget, "cccp") files { MAME_DIR .. "src/mame/drivers/argo.cpp", MAME_DIR .. "src/mame/drivers/cm1800.cpp", + MAME_DIR .. "src/mame/drivers/debut.cpp", MAME_DIR .. "src/mame/drivers/intellect02.cpp", MAME_DIR .. "src/mame/drivers/lviv.cpp", MAME_DIR .. "src/mame/includes/lviv.h", diff --git a/src/devices/cpu/f2mc16/f2mc16.cpp b/src/devices/cpu/f2mc16/f2mc16.cpp index fb4dbd10fff..4707c38aaf2 100644 --- a/src/devices/cpu/f2mc16/f2mc16.cpp +++ b/src/devices/cpu/f2mc16/f2mc16.cpp @@ -105,6 +105,12 @@ void f2mc16_device::device_reset() m_dpr = 0x01; m_dtb = 0; + for (int &entry : m_vector_level) + { + entry = 7; + } + m_outstanding_irqs = 0; + m_pc = read_16_vector(0xffffdc); m_pcb = read_8_vector(0xffffde); @@ -205,12 +211,23 @@ void f2mc16_device::execute_run() { while (m_icount > 0) { - u8 opcode = read_8((m_pcb<<16) | m_pc); + if (m_outstanding_irqs) + { + int cpulevel = m_ps >> 13; - debugger_instruction_hook((m_pcb<<16) | m_pc); + for (int irq = 0; irq < 256; irq++) + { + if (m_vector_level[irq] < cpulevel) + { + take_irq(irq, m_vector_level[irq]); + break; + } + } + } - // m_icount--; + u8 opcode = read_8((m_pcb<<16) | m_pc); + debugger_instruction_hook((m_pcb<<16) | m_pc); switch (opcode) { case 0x00: // NOP @@ -322,8 +339,39 @@ void f2mc16_device::execute_run() m_icount -= 2; break; + // ASRW A case 0x0e: - // stream << "ASRW A"; + m_tmp16 = m_acc & 0xffff; + + // T is set if either carry or T are set beforehand + if ((m_ps & F_C) || (m_ps & F_T)) + { + m_ps |= F_T; + } + // C becomes the previous LSB + m_ps &= ~F_C; + if (m_tmp16 & 1) + { + m_ps |= F_C; + } + + if (m_tmp16 & 0x8000) + { + m_tmp16 >>= 1; + m_tmp16 |= 0x8000; + } + else + { + m_tmp16 >>= 1; + m_tmp16 &= ~0x8000; + } + setNZ_16(m_tmp16); + + m_acc &= 0xffff0000; + m_acc |= m_tmp16; + + m_pc++; + m_icount -= 2; break; // LSRW A @@ -633,8 +681,13 @@ void f2mc16_device::execute_run() m_icount -= 2; break; + // NOT A case 0x37: - // stream << "NOT A"; + m_acc ^= 0xff; + setNZ_8(m_acc & 0xff); + m_ps &= ~F_V; + m_pc++; + m_icount -= 2; break; // ADDW A, #imm16 @@ -697,8 +750,13 @@ void f2mc16_device::execute_run() m_icount -= 2; break; + // NOTW A case 0x3f: - // stream << "NOTW A"; + m_acc ^= 0xffff; + setNZ_16(m_acc & 0xffff); + m_ps &= ~F_V; + m_pc++; + m_icount -= 2; break; // MOV A, dir @@ -1004,8 +1062,44 @@ void f2mc16_device::execute_run() // stream << "RET"; break; + // RETI case 0x6b: - // stream << "RETI"; + // there's an IRQ chaining facility, let's do it + if (m_outstanding_irqs) + { + int cpulevel = m_ps >> 13; + + for (int irq = 0; irq < 256; irq++) + { + if (m_vector_level[irq] < cpulevel) + { + m_ps = read_16((m_ssb << 16) | m_ssp); + m_ps |= F_S; + m_ps &= ~0x7000; + m_ps |= (m_vector_level[irq] & 7) << 13; + + u32 uVecAddr = 0xfffffc - (irq * 4); + m_pc = read_16(uVecAddr); + m_pcb = read_8(uVecAddr + 2); + break; + } + } + } + else + { + m_ps = pull_16_ssp(); + m_pc = pull_16_ssp(); + m_tmp16 = pull_16_ssp(); + m_pcb = m_tmp16 & 0xff; + m_dtb = m_tmp16 >> 8; + m_tmp16 = pull_16_ssp(); + m_adb = m_tmp16 & 0xff; + m_dpr = m_tmp16 >> 8; + m_acc = 0; + m_acc = pull_16_ssp(); + m_acc |= (pull_16_ssp() << 16); + m_icount -= 17; + } break; case 0x6c: // bit operation instructions @@ -2111,10 +2205,9 @@ void f2mc16_device::opcodes_ea76(u8 operand) m_icount -= 10; break; - // ORW A, @RWx + // ORW A, RWx case 0xa0: case 0xa1: case 0xa2: case 0xa3: case 0xa4: case 0xa5: case 0xa6: case 0xa7: m_tmp16 = read_rwX(operand & 7); - m_tmp16 = read_16(getRWbank(operand & 7, m_tmp16)); m_acc |= m_tmp16; setNZ_16(m_acc & 0xffff); m_ps &= ~F_V; @@ -2169,3 +2262,38 @@ void f2mc16_device::opcodes_ea78(u8 operand) void f2mc16_device::execute_set_input(int inputnum, int state) { } + +void f2mc16_device::set_irq(int vector, int level) +{ + m_outstanding_irqs++; + m_vector_level[vector] = level; + //printf("set_irq: vec %d level %d\n", vector, level); +} + +void f2mc16_device::clear_irq(int vector) +{ + m_outstanding_irqs--; + m_vector_level[vector] = 7; + //printf("clear_irq: vec %d\n", vector); +} + +// note: this function must not use m_tmp16 unless you change RETI +void f2mc16_device::take_irq(int vector, int level) +{ + //printf("take_irq: vector %d, level %d, old PC = %02x%04x\n", vector, level, m_pcb, m_pc); + push_16_ssp(m_acc>>16); + push_16_ssp(m_acc & 0xffff); + push_16_ssp((m_dpr<<8) | m_adb); + push_16_ssp((m_dtb<<8) | m_pcb); + push_16_ssp(m_pc); + push_16_ssp(m_ps); + + m_ps |= F_S; + m_ps &= ~0x7000; + m_ps |= (level & 7) << 13; + + u32 uVecAddr = 0xfffffc - (vector * 4); + m_pc = read_16(uVecAddr); + m_pcb = read_8(uVecAddr + 2); + //printf("New PC = %02x%04x\n", m_pcb, m_pc); +} diff --git a/src/devices/cpu/f2mc16/f2mc16.h b/src/devices/cpu/f2mc16/f2mc16.h index edc0dda4148..e4c57953ea4 100644 --- a/src/devices/cpu/f2mc16/f2mc16.h +++ b/src/devices/cpu/f2mc16/f2mc16.h @@ -14,6 +14,8 @@ class f2mc16_device : public cpu_device { public: + friend class mb9061x_device; + enum { F2MC16_PC, F2MC16_PS, F2MC16_USP, F2MC16_SSP, F2MC16_ACC, @@ -223,6 +225,12 @@ private: } } + inline void push_16_ssp(u16 val) + { + m_ssp-=2; + write_16((m_ssb << 16) | m_ssp, val); + } + inline void push_32(u32 val) { if (m_ps & F_S) @@ -271,6 +279,14 @@ private: return rv; } + inline u16 pull_16_ssp() + { + u16 rv = read_16((m_ssb << 16) | m_ssp); + m_ssp += 2; + + return rv; + } + inline u32 pull_32() { u32 rv = 0; @@ -431,6 +447,13 @@ private: void opcodes_ea76(u8 operand); void opcodes_ea77(u8 operand); void opcodes_ea78(u8 operand); + + void set_irq(int vector, int level); + void clear_irq(int vector); + void take_irq(int vector, int level); + + int m_vector_level[256]; + int m_outstanding_irqs; }; DECLARE_DEVICE_TYPE(F2MC16, f2mc16_device) diff --git a/src/devices/cpu/f2mc16/f2mc16dasm.cpp b/src/devices/cpu/f2mc16/f2mc16dasm.cpp index 12799dec0f5..95b287b625e 100644 --- a/src/devices/cpu/f2mc16/f2mc16dasm.cpp +++ b/src/devices/cpu/f2mc16/f2mc16dasm.cpp @@ -1192,7 +1192,7 @@ offs_t f2mc16_disassembler::disassemble(std::ostream &stream, offs_t pc, const d break; case 0xa0: case 0xa1: case 0xa2: case 0xa3: case 0xa4: case 0xa5: case 0xa6: case 0xa7: - util::stream_format(stream, "ORW A, @RW%d", (operand & 0x1)); + util::stream_format(stream, "ORW A, RW%d", (operand & 0x1)); bytes = 2; break; diff --git a/src/devices/cpu/f2mc16/mb9061x.cpp b/src/devices/cpu/f2mc16/mb9061x.cpp index 7576f8287ea..aea77406f79 100644 --- a/src/devices/cpu/f2mc16/mb9061x.cpp +++ b/src/devices/cpu/f2mc16/mb9061x.cpp @@ -39,6 +39,9 @@ mb9061x_device::mb9061x_device(const machine_config &mconfig, device_type type, void mb9061x_device::device_start() { f2mc16_device::device_start(); + + m_tbtc_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(mb9061x_device::tbtc_tick), this)); + m_tbtc_timer->adjust(attotime::never); } @@ -65,6 +68,8 @@ void mb9061x_device::execute_set_input(int inputnum, int state) /* MB90610 - "Evaluation device" with extra RAM */ void mb90610_device::mb90610_map(address_map &map) { + map(0x00a9, 0x00a9).rw(FUNC(mb9061x_device::tbtc_r), FUNC(mb9061x_device::tbtc_w)); + map(0x00b0, 0x00bf).rw(FUNC(mb9061x_device::intc_r), FUNC(mb9061x_device::intc_w)); map(0x0100, 0x10ff).ram(); // 4K of internal RAM from 0x100 to 0x1100 } @@ -78,9 +83,107 @@ mb90610_device::mb90610_device(const machine_config &mconfig, device_type type, { } +/* TBTC: timebase counter */ +enum +{ + TBTC_TEST = 0x80, // test, must always write 1 + TBTC_TBIE = 0x10, // interrupt enable + TBTC_TBOF = 0x08, // expire flag + TBTC_TBR = 0x04, // write 0 to restart + TBTC_TBC1 = 0x02, // rate select bit 1 + TBTC_TBC0 = 0x01 // rate select bit 0 +}; + +READ8_MEMBER(mb9061x_device::tbtc_r) +{ + return m_tbtc; +} + +WRITE8_MEMBER(mb9061x_device::tbtc_w) +{ + static const float periods[4] = { 1.024, 4.096, 16.384, 131.072 }; + + //printf("%02x to TBTC\n", data); + if ((!(data & TBTC_TBR)) || ((data & (TBTC_TBC1|TBTC_TBC0)) != (m_tbtc & (TBTC_TBC1|TBTC_TBC0)))) + { + m_tbtc_timer->adjust(attotime(0, ATTOSECONDS_IN_MSEC(periods[data & (TBTC_TBC1|TBTC_TBC0)]))); + + if (!(data & TBTC_TBR)) + { + intc_clear_irq(11, 0x22); + } + } + + if (!(data & TBTC_TBOF) && (m_tbtc & TBTC_TBOF)) + { + intc_clear_irq(11, 0x22); + } + + m_tbtc = data; +} + +/* INTC: Interrupt controller */ +TIMER_CALLBACK_MEMBER(mb9061x_device::tbtc_tick) +{ + //printf("TBTC tick\n"); + m_tbtc_timer->adjust(attotime::never); + m_tbtc |= TBTC_TBOF; + if (m_tbtc & TBTC_TBIE) + { + intc_trigger_irq(11, 0x22); + } +} + +READ8_MEMBER(mb9061x_device::intc_r) +{ + return m_intc[offset]; +} + +WRITE8_MEMBER(mb9061x_device::intc_w) +{ + //printf("INTC ICR %d to %02x\n", offset, data); + m_intc[offset] = data; +} + +void mb9061x_device::intc_trigger_irq(int icr, int vector) +{ + int level = m_intc[icr] & 7; + + //printf("trigger_irq: ICR %d, level %d\n", icr, level); + + // Extended Intelligent I/O Service? + if (m_intc[icr] & 8) + { + fatalerror("MB9061X: ICR %d (vector %x) calls for EI2OS, not implemented\n", icr, vector); + } + else + { + if (level != 7) + { + set_irq(vector, level); + } + } +} + +void mb9061x_device::intc_clear_irq(int icr, int vector) +{ + int level = m_intc[icr] & 7; + + // Make sure this isn't the Extended Intelligent I/O Service + if (!(m_intc[icr] & 8)) + { + if (level != 7) + { + clear_irq(vector); + } + } +} + /* MB90611 - Production version of this series */ void mb90611_device::mb90611_map(address_map &map) { + map(0x00a9, 0x00a9).rw(FUNC(mb9061x_device::tbtc_r), FUNC(mb9061x_device::tbtc_w)); + map(0x00b0, 0x00bf).rw(FUNC(mb9061x_device::intc_r), FUNC(mb9061x_device::intc_w)); map(0x0100, 0x04ff).ram(); // 1K of internal RAM from 0x100 to 0x500 } diff --git a/src/devices/cpu/f2mc16/mb9061x.h b/src/devices/cpu/f2mc16/mb9061x.h index 7a463577402..e79d0202601 100644 --- a/src/devices/cpu/f2mc16/mb9061x.h +++ b/src/devices/cpu/f2mc16/mb9061x.h @@ -25,6 +25,12 @@ class mb9061x_device : public f2mc16_device public: const address_space_config m_program_config; + // interrupts handled by the interrupt controller + enum + { + ICR0 = 0, ICR1, ICR2, ICR3, ICR4, ICR5, ICR6, ICR7, ICR8, ICR9, ICR10, ICR11, ICR12, ICR13, ICR14, ICR15 + }; + protected: // construction/destruction mb9061x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map); @@ -36,6 +42,21 @@ protected: virtual space_config_vector memory_space_config() const override; private: + // TBC + TIMER_CALLBACK_MEMBER(tbtc_tick); + READ8_MEMBER(tbtc_r); + WRITE8_MEMBER(tbtc_w); + + // INTC + READ8_MEMBER(intc_r); + WRITE8_MEMBER(intc_w); + void intc_trigger_irq(int icr, int vector); + void intc_clear_irq(int icr, int vector); + + u8 m_tbtc; + emu_timer *m_tbtc_timer; + + u8 m_intc[0x10]; }; class mb90610_device : public mb9061x_device diff --git a/src/frontend/mame/clifront.cpp b/src/frontend/mame/clifront.cpp index 7a364f4996a..3c0e5c21544 100644 --- a/src/frontend/mame/clifront.cpp +++ b/src/frontend/mame/clifront.cpp @@ -1666,7 +1666,8 @@ void cli_frontend::execute_commands(const char *exename) std::string pluginpath; while (iter.next(pluginpath)) { - plugin_opts.parse_json(pluginpath); + osd_subst_env(pluginpath, pluginpath); + plugin_opts.scan_directory(pluginpath, true); } emu_file file_plugin(OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS); if (file_plugin.open("plugin.ini") != osd_file::error::NONE) diff --git a/src/frontend/mame/luaengine.cpp b/src/frontend/mame/luaengine.cpp index 8ca06e1459e..77345cc53f2 100644 --- a/src/frontend/mame/luaengine.cpp +++ b/src/frontend/mame/luaengine.cpp @@ -2507,7 +2507,20 @@ void lua_engine::initialize() sol().registry().new_usertype<mame_machine_manager>("manager", "new", sol::no_constructor, "machine", &machine_manager::machine, "options", [](mame_machine_manager &m) { return static_cast<core_options *>(&m.options()); }, - "plugins", [](mame_machine_manager &m) { return static_cast<core_options *>(&m.plugins()); }, + "plugins", [this](mame_machine_manager &m) { + sol::table table = sol().create_table(); + for (auto &curentry : m.plugins().plugins()) + { + sol::table plugin_table = sol().create_table(); + plugin_table["name"] = curentry.m_name; + plugin_table["description"] = curentry.m_description; + plugin_table["type"] = curentry.m_type; + plugin_table["directory"] = curentry.m_directory; + plugin_table["start"] = curentry.m_start; + table[curentry.m_name] = plugin_table; + } + return table; + }, "ui", &mame_machine_manager::ui); sol()["manager"] = std::ref(*mame_machine_manager::instance()); sol()["mame_manager"] = std::ref(*mame_machine_manager::instance()); diff --git a/src/frontend/mame/mame.cpp b/src/frontend/mame/mame.cpp index f3c08f661e9..9334cb3445b 100644 --- a/src/frontend/mame/mame.cpp +++ b/src/frontend/mame/mame.cpp @@ -88,6 +88,11 @@ void mame_machine_manager::schedule_new_driver(const game_driver &driver) /*************************************************************************** CORE IMPLEMENTATION ***************************************************************************/ + +//------------------------------------------------- +// update_machine +//------------------------------------------------- + void mame_machine_manager::update_machine() { m_lua->set_machine(m_machine); @@ -95,7 +100,11 @@ void mame_machine_manager::update_machine() } -std::vector<std::string> split(const std::string &text, char sep) +//------------------------------------------------- +// split +//------------------------------------------------- + +static std::vector<std::string> split(const std::string &text, char sep) { std::vector<std::string> tokens; std::size_t start = 0, end = 0; @@ -110,18 +119,27 @@ std::vector<std::string> split(const std::string &text, char sep) return tokens; } + +//------------------------------------------------- +// start_luaengine +//------------------------------------------------- + void mame_machine_manager::start_luaengine() { if (options().plugins()) { + // scan all plugin directories path_iterator iter(options().plugins_path()); std::string pluginpath; while (iter.next(pluginpath)) { - m_plugins->parse_json(pluginpath); + // user may specify environment variables; subsitute them + osd_subst_env(pluginpath, pluginpath); + + // and then scan the directory recursively + m_plugins->scan_directory(pluginpath, true); } - std::vector<std::string> include = split(options().plugin(), ','); - std::vector<std::string> exclude = split(options().no_plugin(), ','); + { // parse the file // attempt to open the output file @@ -130,7 +148,7 @@ void mame_machine_manager::start_luaengine() { try { - m_plugins->parse_ini_file((util::core_file&)file, OPTION_PRIORITY_MAME_INI, OPTION_PRIORITY_MAME_INI < OPTION_PRIORITY_DRIVER_INI, false); + m_plugins->parse_ini_file((util::core_file&)file); } catch (options_exception &) { @@ -138,31 +156,34 @@ void mame_machine_manager::start_luaengine() } } } - for (auto &curentry : m_plugins->entries()) + + // process includes + for (const std::string &incl : split(options().plugin(), ',')) { - if (curentry->type() != core_options::option_type::HEADER) - { - if (std::find(include.begin(), include.end(), curentry->name()) != include.end()) - { - m_plugins->set_value(curentry->name(), "1", OPTION_PRIORITY_CMDLINE); - } - if (std::find(exclude.begin(), exclude.end(), curentry->name()) != exclude.end()) - { - m_plugins->set_value(curentry->name(), "0", OPTION_PRIORITY_CMDLINE); - } - } + plugin *p = m_plugins->find(incl); + if (!p) + fatalerror("Could not load plugin: %s\n", incl.c_str()); + p->m_start = true; + } + + // process excludes + for (const std::string &excl : split(options().no_plugin(), ',')) + { + plugin *p = m_plugins->find(excl); + if (!p) + fatalerror("Unknown plugin: %s\n", excl.c_str()); + p->m_start = false; } } + + // we have a special way to open the console plugin if (options().console()) { - if (m_plugins->exists(OPTION_CONSOLE)) - { - m_plugins->set_value(OPTION_CONSOLE, "1", OPTION_PRIORITY_CMDLINE); - } - else - { + plugin *p = m_plugins->find(OPTION_CONSOLE); + if (!p) fatalerror("Console plugin not found.\n"); - } + + p->m_start = true; } m_lua->initialize(); @@ -179,9 +200,10 @@ void mame_machine_manager::start_luaengine() } } -/*------------------------------------------------- - execute - run the core emulation --------------------------------------------------*/ + +//------------------------------------------------- +// execute - run the core emulation +//------------------------------------------------- int mame_machine_manager::execute() { diff --git a/src/frontend/mame/pluginopts.cpp b/src/frontend/mame/pluginopts.cpp index cfb04af21a4..ef30cf917f3 100644 --- a/src/frontend/mame/pluginopts.cpp +++ b/src/frontend/mame/pluginopts.cpp @@ -7,8 +7,10 @@ Plugin options manager. ***************************************************************************/ + #include "emu.h" #include "pluginopts.h" +#include "options.h" #include <rapidjson/document.h> #include <rapidjson/error/en.h> @@ -21,77 +23,157 @@ // PLUGIN OPTIONS //************************************************************************** -const options_entry plugin_options::s_option_entries[] = -{ - { nullptr, nullptr, OPTION_HEADER, "PLUGINS OPTIONS" }, - { nullptr } -}; - //------------------------------------------------- // plugin_options - constructor //------------------------------------------------- plugin_options::plugin_options() -: core_options() { - add_entries(plugin_options::s_option_entries); } -void plugin_options::parse_json(std::string path) +//------------------------------------------------- +// scan_directory +//------------------------------------------------- + +void plugin_options::scan_directory(const std::string &path, bool recursive) { // first try to open as a directory - osd_subst_env(path, path); osd::directory::ptr directory = osd::directory::open(path); if (directory) { // iterate over all files in the directory for (const osd::directory::entry *entry = directory->read(); entry != nullptr; entry = directory->read()) { - if (entry->type == osd::directory::entry::entry_type::FILE) + if (entry->type == osd::directory::entry::entry_type::FILE && !strcmp(entry->name, "plugin.json")) { - std::string name = entry->name; - if (name == "plugin.json") - { - std::string curfile = std::string(path).append(PATH_SEPARATOR).append(entry->name); - std::ifstream ifs(curfile); - rapidjson::IStreamWrapper isw(ifs); - rapidjson::Document document; - document.ParseStream<0>(isw); - - if (document.HasParseError()) { - std::string error(GetParseError_En(document.GetParseError())); - osd_printf_error("Unable to parse plugin definition file %s. Errors returned:\n", curfile.c_str()); - osd_printf_error("%s\n", error.c_str()); - return; - } - - if (document["plugin"].IsObject()) - { - std::string plugin_name = document["plugin"]["name"].GetString(); - std::string description = document["plugin"]["description"].GetString(); - std::string type = document["plugin"]["type"].GetString(); - bool start = false; - if (document["plugin"].HasMember("start") && (std::string(document["plugin"]["start"].GetString()) == "true")) - start = true; - - if (type=="plugin") - { - auto const it = m_descriptions.emplace(m_descriptions.end(), std::move(description)); - add_entry({ std::move(plugin_name) }, it->c_str(), option_type::BOOLEAN, start ? "1" : "0"); - } - } - - } + std::string curfile = std::string(path).append(PATH_SEPARATOR).append(entry->name); + load_plugin(curfile); } else if (entry->type == osd::directory::entry::entry_type::DIR) { - std::string name = entry->name; - if (!(name == "." || name == "..")) - { - parse_json(path + PATH_SEPARATOR + name); - } + if (recursive && strcmp(entry->name, ".") && strcmp(entry->name, "..")) + scan_directory(path + PATH_SEPARATOR + entry->name, recursive); } } } } + + +//------------------------------------------------- +// load_plugin +//------------------------------------------------- + +bool plugin_options::load_plugin(const std::string &path) +{ + std::ifstream ifs(path); + rapidjson::IStreamWrapper isw(ifs); + rapidjson::Document document; + document.ParseStream<0>(isw); + + if (document.HasParseError()) + { + std::string error(GetParseError_En(document.GetParseError())); + osd_printf_error("Unable to parse plugin definition file %s. Errors returned:\n", path.c_str()); + osd_printf_error("%s\n", error.c_str()); + return false; + } + + if (!document["plugin"].IsObject()) + { + osd_printf_error("Bad plugin definition file %s:\n", path.c_str()); + return false; + } + + size_t last_path_sep = path.find_last_of(PATH_SEPARATOR[0]); + std::string dir = last_path_sep != std::string::npos + ? path.substr(0, last_path_sep) + : "."; + + plugin p; + p.m_name = document["plugin"]["name"].GetString(); + p.m_description = document["plugin"]["description"].GetString(); + p.m_type = document["plugin"]["type"].GetString(); + p.m_directory = std::move(dir); + p.m_start = false; + if (document["plugin"].HasMember("start") && (std::string(document["plugin"]["start"].GetString()) == "true")) + p.m_start = true; + + m_plugins.push_back(std::move(p)); + return true; +} + + +//------------------------------------------------- +// find +//------------------------------------------------- + +plugin *plugin_options::find(const std::string &name) +{ + auto iter = std::find_if( + m_plugins.begin(), + m_plugins.end(), + [&name](const plugin &p) { return name == p.m_name; }); + + return iter != m_plugins.end() + ? &*iter + : nullptr; +} + + +//------------------------------------------------- +// create_core_options +//------------------------------------------------- + +static void create_core_options(core_options &opts, const plugin_options &plugin_opts) +{ + // we're sort of abusing core_options to just get INI file parsing, so we'll build a + // core_options structure for the sole purpose of parsing an INI file, and then reflect + // the data back + static const options_entry s_option_entries[] = + { + { nullptr, nullptr, OPTION_HEADER, "PLUGINS OPTIONS" }, + { nullptr } + }; + opts.add_entries(s_option_entries); + + // create an entry for each option + for (const plugin &p : plugin_opts.plugins()) + { + opts.add_entry( + { p.m_name }, + nullptr, + core_options::option_type::BOOLEAN, + p.m_start ? "1" : "0"); + } +} + + +//------------------------------------------------- +// parse_ini_file +//------------------------------------------------- + +void plugin_options::parse_ini_file(util::core_file &inifile) +{ + core_options opts; + create_core_options(opts, *this); + + // parse the INI file + opts.parse_ini_file(inifile, OPTION_PRIORITY_NORMAL, true, true); + + // and reflect these options back + for (plugin &p : m_plugins) + p.m_start = opts.bool_value(p.m_name.c_str()); +} + + +//------------------------------------------------- +// output_ini +//------------------------------------------------- + +std::string plugin_options::output_ini() const +{ + core_options opts; + create_core_options(opts, *this); + return opts.output_ini(); +} diff --git a/src/frontend/mame/pluginopts.h b/src/frontend/mame/pluginopts.h index 27e57104293..c722fb8e2a2 100644 --- a/src/frontend/mame/pluginopts.h +++ b/src/frontend/mame/pluginopts.h @@ -7,27 +7,50 @@ Plugin options manager. ***************************************************************************/ + #ifndef MAME_FRONTEND_PLUGINOPTS_H #define MAME_FRONTEND_PLUGINOPTS_H #pragma once -#include "options.h" - #include <list> #include <string> -class plugin_options : public core_options +// ======================> plugin + +struct plugin +{ + std::string m_name; + std::string m_description; + std::string m_type; + std::string m_directory; + bool m_start; +}; + + +// ======================> plugin_options + +class plugin_options { public: plugin_options(); - void parse_json(std::string path); + // accessors + std::list<plugin> &plugins() { return m_plugins; } + const std::list<plugin> &plugins() const { return m_plugins; } + + // methods + void scan_directory(const std::string &path, bool recursive); + bool load_plugin(const std::string &path); + plugin *find(const std::string &name); + + // INI functionality + void parse_ini_file(util::core_file &inifile); + std::string output_ini() const; private: - static const options_entry s_option_entries[]; - std::list<std::string> m_descriptions; + std::list<plugin> m_plugins; }; #endif // MAME_FRONTEND_PLUGINOPTS_H diff --git a/src/frontend/mame/ui/miscmenu.cpp b/src/frontend/mame/ui/miscmenu.cpp index fbb84d0aec3..3591a2a0ae3 100644 --- a/src/frontend/mame/ui/miscmenu.cpp +++ b/src/frontend/mame/ui/miscmenu.cpp @@ -880,9 +880,12 @@ void menu_plugins_configure::handle() { if (menu_event->iptkey == IPT_UI_LEFT || menu_event->iptkey == IPT_UI_RIGHT || menu_event->iptkey == IPT_UI_SELECT) { - int oldval = plugins.int_value((const char*)menu_event->itemref); - plugins.set_value((const char*)menu_event->itemref, oldval == 1 ? 0 : 1, OPTION_PRIORITY_CMDLINE); - changed = true; + plugin *p = plugins.find((const char*)menu_event->itemref); + if (p) + { + p->m_start = !p->m_start; + changed = true; + } } } if (changed) @@ -897,13 +900,10 @@ void menu_plugins_configure::populate(float &customtop, float &custombottom) { plugin_options& plugins = mame_machine_manager::instance()->plugins(); - for (auto &curentry : plugins.entries()) + for (auto &curentry : plugins.plugins()) { - if (curentry->type() != OPTION_HEADER) - { - auto enabled = !strcmp(curentry->value(), "1"); - item_append_on_off(curentry->description(), enabled, 0, (void *)(uintptr_t)curentry->name().c_str()); - } + bool enabled = curentry.m_start; + item_append_on_off(curentry.m_description, enabled, 0, (void *)(uintptr_t)curentry.m_name.c_str()); } item_append(menu_item_type::SEPARATOR); customtop = ui().get_line_height() + (3.0f * ui().box_tb_border()); diff --git a/src/mame/drivers/debut.cpp b/src/mame/drivers/debut.cpp new file mode 100644 index 00000000000..20e87429000 --- /dev/null +++ b/src/mame/drivers/debut.cpp @@ -0,0 +1,276 @@ +// license:BSD-3-Clause +// copyright-holders:hap +/****************************************************************************** + +Дебют / Дебют-М (Debut) Chess Computer + +Released in 1994 in Russian Federation by ЭНЕРГОПРИБОР (Energopribor), Moscow. +It's running the Mirage chess engine by Vladimir Rybinkin, originally made for MS-DOS. + +TODO: +- where is lcd segments common active state? (see m_lcd_data), current implementation + is wrong, it will occasionally display wrong (inverted) digits +- where does the interrupt come from? +- Debut-M is an updated version? Or is it the same program as Debut with a redesigned case? + +******************************************************************************* + +Hardware notes: +- КР1810ВМ86 (i8086 clone), 16200K XTAL +- КР1810ГФ84 (i8284 clock divider /3) +- 2*КР537РУ10 (2KB*8 RAM), 2*8KB ROM +- lcd panel (4 7seg digits), 64 chessboard buttons, 16 leds + +A bit more detailed, list of other Soviet standard TTL chips used and their equivalents: +- 2*КР580ИР82 = Intel 8282, aka 74573 +- 2*К555ЛЛ1 = 7432 +- К555ИЛ7 = 74138 +- К555ИД10В = 74145 +- КМ555КЛ15 = 74251 +- К561ЛЕ5А = CD4001 +- PC74HC259P = the odd one out + +keypad legend: + +АН - анализ (analysis, switches view info) +ХОД - ходи (force move) +ИНТ - интерактивность (interactivity, switches 1P vs CPU, or 2P) +ПОЗ - позиция (position mode) +ВФ - выбор фигуры (select piece) +ВП - возврат (take back 2 plies) +УР - уровень игры (level) +ВВ - ввод позиции (enter position) +СБ - сброс / новая игра (reset / new game) + +******************************************************************************/ + +#include "emu.h" +#include "cpu/i86/i86.h" +#include "machine/sensorboard.h" +#include "sound/dac.h" +#include "sound/volt_reg.h" +#include "video/pwm.h" +#include "speaker.h" + +// internal artwork +#include "debutm.lh" // clickable + + +namespace { + +class debut_state : public driver_device +{ +public: + debut_state(const machine_config &mconfig, device_type type, const char *tag) : + driver_device(mconfig, type, tag), + m_maincpu(*this, "maincpu"), + m_board(*this, "board"), + m_display(*this, "display"), + m_dac(*this, "dac"), + m_out_digit(*this, "digit%u", 0U), + m_inputs(*this, "IN.0") + { } + + // assume that RESET button is tied to CPU RESET pin + DECLARE_INPUT_CHANGED_MEMBER(reset_button) { m_maincpu->set_input_line(INPUT_LINE_RESET, newval ? ASSERT_LINE : CLEAR_LINE); } + + // machine drivers + void debutm(machine_config &config); + +protected: + virtual void machine_start() override; + +private: + // devices/pointers + required_device<cpu_device> m_maincpu; + required_device<sensorboard_device> m_board; + required_device<pwm_display_device> m_display; + required_device<dac_bit_interface> m_dac; + output_finder<4> m_out_digit; + required_ioport m_inputs; + + // address maps + void main_map(address_map &map); + void main_io(address_map &map); + + // I/O handlers + INTERRUPT_GEN_MEMBER(interrupt); + DECLARE_READ8_MEMBER(input_r); + DECLARE_WRITE8_MEMBER(control_w); + + u8 m_select; + u8 m_dac_data; + u8 m_lcd_data; + u8 m_digit_data[4]; +}; + +void debut_state::machine_start() +{ + // resolve handlers + m_out_digit.resolve(); + + // zerofill + m_select = 0; + m_dac_data = 0; + m_lcd_data = 0; + memset(m_digit_data, 0, sizeof(m_digit_data)); + + // register for savestates + save_item(NAME(m_select)); + save_item(NAME(m_dac_data)); + save_item(NAME(m_lcd_data)); + save_item(NAME(m_digit_data)); +} + + + +/****************************************************************************** + I/O +******************************************************************************/ + +INTERRUPT_GEN_MEMBER(debut_state::interrupt) +{ + m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0xff); // I8086 +} + +READ8_MEMBER(debut_state::input_r) +{ + u8 data = 0; + u8 sel = m_select & 0xf; + + // a1-a3,d0: multiplexed inputs + // read keypad + if (sel == 0) + data = BIT(m_inputs->read(), offset); + + // read chessboard sensors + else if (sel < 9) + data = BIT(m_board->read_rank(sel - 1), offset); + + return ~data; +} + +WRITE8_MEMBER(debut_state::control_w) +{ + u8 mask = 1 << offset; + u8 prev = m_select; + + // a1-a3,d0: 74259 + m_select = (m_select & ~mask) | ((data & 1) ? mask : 0); + + // 74259 q0-q3: input mux/led select + // 74259 q4,q5: led data + m_display->matrix(~m_select >> 4 & 3, 1 << (m_select & 0xf)); + + // 74259 q7: toggle speaker + if (~m_select & prev & 0x80) + { + m_dac_data ^= 1; + m_dac->write(m_dac_data); + } + + // a1-a3,d1-d4 go to lcd panel + // clock lcd digit segments + for (int i = 0; i < 4; i++) + { + if (BIT(~data, i + 1)) + m_digit_data[i] = (m_digit_data[i] & ~mask) | (m_lcd_data << offset); + + m_out_digit[i] = bitswap<8>(m_digit_data[i],0,7,4,3,2,1,6,5); + } + + // where is lcd common state? + if (offset == 0) + m_lcd_data = BIT(~data, 4); +} + + + +/****************************************************************************** + Address Maps +******************************************************************************/ + +void debut_state::main_map(address_map &map) +{ + map.global_mask(0x7fff); + map(0x0000, 0x0fff).mirror(0x3000).ram(); + map(0x4000, 0x7fff).rom(); +} + +void debut_state::main_io(address_map &map) +{ + map(0x00, 0x0f).rw(FUNC(debut_state::input_r), FUNC(debut_state::control_w)).umask16(0x00ff); +} + + + +/****************************************************************************** + Input Ports +******************************************************************************/ + +static INPUT_PORTS_START( debutm ) + PORT_START("IN.0") + PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_A) PORT_NAME("АН (Analysis)") + PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_F) PORT_NAME("ХОД (Force Move)") + PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_1) PORT_NAME("ИНТ (Switch 1P/2P)") + PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_M) PORT_NAME("ПОЗ (Position Mode)") + PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_S) PORT_NAME("ВФ (Select Piece)") + PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_B) PORT_NAME("ВП (Take Back)") + PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_L) PORT_NAME("УР (Level)") + PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_E) PORT_NAME("ВВ (Enter Position)") + + PORT_START("RESET") + PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_R) PORT_CHANGED_MEMBER(DEVICE_SELF, debut_state, reset_button, nullptr) PORT_NAME("СБ (Reset)") +INPUT_PORTS_END + + + +/****************************************************************************** + Machine Configs +******************************************************************************/ + +void debut_state::debutm(machine_config &config) +{ + /* basic machine hardware */ + I8086(config, m_maincpu, 16.2_MHz_XTAL / 3); + m_maincpu->set_periodic_int(FUNC(debut_state::interrupt), attotime::from_hz(400)); + m_maincpu->set_addrmap(AS_PROGRAM, &debut_state::main_map); + m_maincpu->set_addrmap(AS_IO, &debut_state::main_io); + + SENSORBOARD(config, m_board).set_type(sensorboard_device::BUTTONS); + m_board->init_cb().set(m_board, FUNC(sensorboard_device::preset_chess)); + m_board->set_delay(attotime::from_msec(150)); + + /* video hardware */ + PWM_DISPLAY(config, m_display).set_size(2, 9); + m_display->set_bri_maximum(0.5); + config.set_default_layout(layout_debutm); + + /* sound hardware */ + SPEAKER(config, "speaker").front_center(); + DAC_1BIT(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.25); + VOLTAGE_REGULATOR(config, "vref").add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT); +} + + + +/****************************************************************************** + ROM Definitions +******************************************************************************/ + +ROM_START( debutm ) + ROM_REGION( 0x10000, "maincpu", 0 ) + ROM_LOAD16_BYTE("dd12", 0x4000, 0x2000, CRC(0f64ebab) SHA1(e069c387ec01e8786e4fb720630196ac27fac449) ) // no ROM labels, PCB ICs location = "DDxx" + ROM_LOAD16_BYTE("dd13", 0x4001, 0x2000, CRC(c171f5ac) SHA1(62dc030e3d60172f31f0d14944437b0fd4b53a2a) ) // " +ROM_END + +} // anonymous namespace + + + +/****************************************************************************** + Drivers +******************************************************************************/ + +// YEAR NAME PARENT CMP MACHINE INPUT CLASS INIT COMPANY, FULLNAME, FLAGS +CONS( 1994, debutm, 0, 0, debutm, debutm, debut_state, empty_init, "Energopribor", "Debut-M", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_CLICKABLE_ARTWORK ) diff --git a/src/mame/drivers/intellect02.cpp b/src/mame/drivers/intellect02.cpp index dc75a6ebf5d..bca6af48a0b 100644 --- a/src/mame/drivers/intellect02.cpp +++ b/src/mame/drivers/intellect02.cpp @@ -200,27 +200,27 @@ void intel02_state::main_io(address_map &map) static INPUT_PORTS_START( intel02 ) PORT_START("IN.0") PORT_BIT(0x0007, IP_ACTIVE_HIGH, IPT_UNUSED) - PORT_BIT(0x0008, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("View Position") PORT_CODE(KEYCODE_V) - PORT_BIT(0x0010, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("Game Level") PORT_CODE(KEYCODE_L) - PORT_BIT(0x0020, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("9") PORT_CODE(KEYCODE_9) PORT_CODE(KEYCODE_9_PAD) - PORT_BIT(0x0040, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("H8") PORT_CODE(KEYCODE_8) PORT_CODE(KEYCODE_8_PAD) PORT_CODE(KEYCODE_H) - PORT_BIT(0x0080, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("G7") PORT_CODE(KEYCODE_7) PORT_CODE(KEYCODE_7_PAD) PORT_CODE(KEYCODE_G) - PORT_BIT(0x0100, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("F6") PORT_CODE(KEYCODE_6) PORT_CODE(KEYCODE_6_PAD) PORT_CODE(KEYCODE_F) - PORT_BIT(0x0200, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("E5") PORT_CODE(KEYCODE_5) PORT_CODE(KEYCODE_5_PAD) PORT_CODE(KEYCODE_E) - PORT_BIT(0x0400, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("D4") PORT_CODE(KEYCODE_4) PORT_CODE(KEYCODE_4_PAD) PORT_CODE(KEYCODE_D) - PORT_BIT(0x0800, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("C3") PORT_CODE(KEYCODE_3) PORT_CODE(KEYCODE_3_PAD) PORT_CODE(KEYCODE_C) - PORT_BIT(0x1000, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("B2") PORT_CODE(KEYCODE_2) PORT_CODE(KEYCODE_2_PAD) PORT_CODE(KEYCODE_B) - PORT_BIT(0x2000, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("A1") PORT_CODE(KEYCODE_1) PORT_CODE(KEYCODE_1_PAD) PORT_CODE(KEYCODE_A) - PORT_BIT(0x4000, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("0") PORT_CODE(KEYCODE_0) PORT_CODE(KEYCODE_0_PAD) + PORT_BIT(0x0008, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_V) PORT_NAME("ПП (View Position)") + PORT_BIT(0x0010, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_L) PORT_NAME("УИ (Game Level)") + PORT_BIT(0x0020, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_9) PORT_CODE(KEYCODE_9_PAD) PORT_NAME("9") + PORT_BIT(0x0040, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_8) PORT_CODE(KEYCODE_8_PAD) PORT_CODE(KEYCODE_H) PORT_NAME("H8") + PORT_BIT(0x0080, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_7) PORT_CODE(KEYCODE_7_PAD) PORT_CODE(KEYCODE_G) PORT_NAME("G7") + PORT_BIT(0x0100, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_6) PORT_CODE(KEYCODE_6_PAD) PORT_CODE(KEYCODE_F) PORT_NAME("F6") + PORT_BIT(0x0200, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_5) PORT_CODE(KEYCODE_5_PAD) PORT_CODE(KEYCODE_E) PORT_NAME("E5") + PORT_BIT(0x0400, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_4) PORT_CODE(KEYCODE_4_PAD) PORT_CODE(KEYCODE_D) PORT_NAME("D4") + PORT_BIT(0x0800, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_3) PORT_CODE(KEYCODE_3_PAD) PORT_CODE(KEYCODE_C) PORT_NAME("C3") + PORT_BIT(0x1000, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_2) PORT_CODE(KEYCODE_2_PAD) PORT_CODE(KEYCODE_B) PORT_NAME("B2") + PORT_BIT(0x2000, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_1) PORT_CODE(KEYCODE_1_PAD) PORT_CODE(KEYCODE_A) PORT_NAME("A1") + PORT_BIT(0x4000, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_0) PORT_CODE(KEYCODE_0_PAD) PORT_NAME("0") PORT_START("IN.1") PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED) - PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("Input") PORT_CODE(KEYCODE_ENTER) PORT_CODE(KEYCODE_ENTER_PAD) - PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("Game Select") PORT_CODE(KEYCODE_S) - PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("Erase") PORT_CODE(KEYCODE_DEL) PORT_CODE(KEYCODE_BACKSPACE) + PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_ENTER) PORT_CODE(KEYCODE_ENTER_PAD) PORT_NAME("ВВ (Input)") + PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_S) PORT_NAME("ВИ (Game Select)") + PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_DEL) PORT_CODE(KEYCODE_BACKSPACE) PORT_NAME("СТ (Erase)") PORT_START("RESET") - PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("Reset") PORT_CODE(KEYCODE_R) PORT_CHANGED_MEMBER(DEVICE_SELF, intel02_state, reset_button, nullptr) + PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_R) PORT_CHANGED_MEMBER(DEVICE_SELF, intel02_state, reset_button, nullptr) PORT_NAME("СБ (Reset)") INPUT_PORTS_END diff --git a/src/mame/drivers/saitek_corona.cpp b/src/mame/drivers/saitek_corona.cpp index 10bd5eb3293..2c7c6118fb6 100644 --- a/src/mame/drivers/saitek_corona.cpp +++ b/src/mame/drivers/saitek_corona.cpp @@ -1,5 +1,6 @@ // license:BSD-3-Clause // copyright-holders:hap +// thanks-to:Berger /*************************************************************************** Saitek Corona. Please refer to saitek_stratos.cpp for driver notes. diff --git a/src/mame/drivers/saitek_stratos.cpp b/src/mame/drivers/saitek_stratos.cpp index 94ab80bd05a..a0b08af41bd 100644 --- a/src/mame/drivers/saitek_stratos.cpp +++ b/src/mame/drivers/saitek_stratos.cpp @@ -1,5 +1,6 @@ // license:BSD-3-Clause // copyright-holders:Olivier Galibert, hap +// thanks-to:Berger /*************************************************************************** SciSys/Saitek Stratos chesscomputer family (1987-1990) @@ -342,8 +343,11 @@ READ8_MEMBER(stratos_state::control_r) { // d5: lcd status flag? if (m_lcd_ready) + { data |= 0x20; - m_lcd_ready = false; + if (!machine().side_effects_disabled()) + m_lcd_ready = false; + } // d7: battery low data |= m_inputs[8]->read(); @@ -379,7 +383,9 @@ WRITE8_MEMBER(stratos_state::control_w) READ8_MEMBER(stratos_state::lcd_data_r) { // reset lcd? - lcd_reset_w(); + if (!machine().side_effects_disabled()) + lcd_reset_w(); + return 0; } diff --git a/src/mame/layout/debutm.lay b/src/mame/layout/debutm.lay new file mode 100644 index 00000000000..bcabfdeaddb --- /dev/null +++ b/src/mame/layout/debutm.lay @@ -0,0 +1,594 @@ +<?xml version="1.0"?> +<mamelayout version="2"> + +<!-- define elements --> + + <element name="blackb"><rect><color red="0" green="0" blue="0" /></rect></element> + <element name="gray"><rect><color red="0.5" green="0.54" blue="0.52" /></rect></element> + + <!-- our digit element is bright-on-dark, this means the lcd panel is the wrong colour here --> + + <element name="digit" defstate="0"> + <led7seg><color red="1.0" green="1.0" blue="1.0" /></led7seg> + </element> + + <element name="led" defstate="0"> + <rect state="1"><color red="1.0" green="0.15" blue="0.2" /></rect> + <rect state="0"><color red="0.3" green="0.25" blue="0.25" /></rect> + </element> + + <element name="but" defstate="0"> + <rect state="1"><color red="0.35" green="0.33" blue="0.33" /></rect> + <rect state="0"><color red="0.17" green="0.15" blue="0.15" /></rect> + </element> + + <element name="text_1"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="1" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_2"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="2" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_3"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="3" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_4"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="4" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_5"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="5" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_6"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="6" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_7"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="7" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_8"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="8" align="1"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + + <element name="text_a"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="A"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="B"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_c"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="C"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_d"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="D"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_e"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="E"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_f"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="F"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_g"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="G"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_h"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="H"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + + <element name="text_b1"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="АН"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b2"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ХОД"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b3"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ИНТ"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b4"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ПОЗ"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b5"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ВФ"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b6"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ВП"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b7"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="УР"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b8"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ВВ"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_b9"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="СБ"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + + <element name="text_tb1"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ANALYSIS"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb2a"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="FORCE"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb2b"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="MOVE"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb3"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="1P/2P"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb4a"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="POS."><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb4b"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="MODE"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb5a"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="SELECT"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb5b"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="PIECE"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb6a"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="TAKE"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb6b"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="BACK"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb7"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="LEVEL"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb8a"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="ENTER"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb8b"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="POS."><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_tb9"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="RESET"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + + +<!-- sb board --> + + <element name="cblack"><rect><color red="0.41" green="0.4" blue="0.39" /></rect></element> + <element name="cwhite"><rect><color red="0.88" green="0.84" blue="0.65" /></rect></element> + + <element name="hlbb" defstate="0"> + <text string=" "><bounds x="0" y="0" width="1" height="1" /></text> + <disk state="1"> + <bounds x="0.12" y="0.12" width="0.76" height="0.76" /> + <color red="0" green="0" blue="0" /> + </disk> + </element> + + <element name="piece" defstate="0"> + <image file="chess/wp.png" state="1"/> + <image file="chess/wn.png" state="2"/> + <image file="chess/wb.png" state="3"/> + <image file="chess/wr.png" state="4"/> + <image file="chess/wq.png" state="5"/> + <image file="chess/wk.png" state="6"/> + + <image file="chess/bp.png" state="7"/> + <image file="chess/bn.png" state="8"/> + <image file="chess/bb.png" state="9"/> + <image file="chess/br.png" state="10"/> + <image file="chess/bq.png" state="11"/> + <image file="chess/bk.png" state="12"/> + + <!-- selected pieces --> + <image file="chess/wp.png" state="13"><color alpha="0.5" /></image> + <image file="chess/wn.png" state="14"><color alpha="0.5" /></image> + <image file="chess/wb.png" state="15"><color alpha="0.5" /></image> + <image file="chess/wr.png" state="16"><color alpha="0.5" /></image> + <image file="chess/wq.png" state="17"><color alpha="0.5" /></image> + <image file="chess/wk.png" state="18"><color alpha="0.5" /></image> + + <image file="chess/bp.png" state="19"><color alpha="0.5" /></image> + <image file="chess/bn.png" state="20"><color alpha="0.5" /></image> + <image file="chess/bb.png" state="21"><color alpha="0.5" /></image> + <image file="chess/br.png" state="22"><color alpha="0.5" /></image> + <image file="chess/bq.png" state="23"><color alpha="0.5" /></image> + <image file="chess/bk.png" state="24"><color alpha="0.5" /></image> + </element> + + <group name="sb_board"> + <bounds x="0" y="0" width="80" height="80" /> + + <!-- squares (avoid seams) --> + <bezel element="cwhite"><bounds x="0" y="0" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="10" y="0" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="20" y="0" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="30" y="0" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="40" y="0" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="50" y="0" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="60" y="0" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="70" y="0" width="10" height="11" /></bezel> + + <bezel element="cblack"><bounds x="0" y="10" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="10" y="10" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="20" y="10" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="30" y="10" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="40" y="10" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="50" y="10" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="60" y="10" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="70" y="10" width="10" height="11" /></bezel> + + <bezel element="cwhite"><bounds x="0" y="20" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="10" y="20" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="20" y="20" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="30" y="20" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="40" y="20" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="50" y="20" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="60" y="20" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="70" y="20" width="10" height="11" /></bezel> + + <bezel element="cblack"><bounds x="0" y="30" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="10" y="30" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="20" y="30" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="30" y="30" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="40" y="30" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="50" y="30" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="60" y="30" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="70" y="30" width="10" height="11" /></bezel> + + <bezel element="cwhite"><bounds x="0" y="40" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="10" y="40" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="20" y="40" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="30" y="40" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="40" y="40" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="50" y="40" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="60" y="40" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="70" y="40" width="10" height="11" /></bezel> + + <bezel element="cblack"><bounds x="0" y="50" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="10" y="50" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="20" y="50" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="30" y="50" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="40" y="50" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="50" y="50" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="60" y="50" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="70" y="50" width="10" height="11" /></bezel> + + <bezel element="cwhite"><bounds x="0" y="60" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="10" y="60" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="20" y="60" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="30" y="60" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="40" y="60" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="50" y="60" width="11" height="11" /></bezel> + <bezel element="cwhite"><bounds x="60" y="60" width="11" height="11" /></bezel> + <bezel element="cblack"><bounds x="70" y="60" width="10" height="11" /></bezel> + + <bezel element="cblack"><bounds x="0" y="70" width="11" height="10" /></bezel> + <bezel element="cwhite"><bounds x="10" y="70" width="11" height="10" /></bezel> + <bezel element="cblack"><bounds x="20" y="70" width="11" height="10" /></bezel> + <bezel element="cwhite"><bounds x="30" y="70" width="11" height="10" /></bezel> + <bezel element="cblack"><bounds x="40" y="70" width="11" height="10" /></bezel> + <bezel element="cwhite"><bounds x="50" y="70" width="11" height="10" /></bezel> + <bezel element="cblack"><bounds x="60" y="70" width="11" height="10" /></bezel> + <bezel element="cwhite"><bounds x="70" y="70" width="10" height="10" /></bezel> + + <!-- sensors, pieces --> + <repeat count="8"> + <param name="y" start="0" increment="10" /> + <param name="i" start="8" increment="-1" /> + + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x01"><bounds x="0" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x02"><bounds x="10" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x04"><bounds x="20" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x08"><bounds x="30" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x10"><bounds x="40" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x20"><bounds x="50" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x40"><bounds x="60" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + <bezel element="hlbb" inputtag="board:RANK.~i~" inputmask="0x80"><bounds x="70" y="~y~" width="10" height="10" /><color alpha="0.04" /></bezel> + + <bezel name="piece_a~i~" element="piece"><bounds x="0" y="~y~" width="10" height="10" /></bezel> + <bezel name="piece_b~i~" element="piece"><bounds x="10" y="~y~" width="10" height="10" /></bezel> + <bezel name="piece_c~i~" element="piece"><bounds x="20" y="~y~" width="10" height="10" /></bezel> + <bezel name="piece_d~i~" element="piece"><bounds x="30" y="~y~" width="10" height="10" /></bezel> + <bezel name="piece_e~i~" element="piece"><bounds x="40" y="~y~" width="10" height="10" /></bezel> + <bezel name="piece_f~i~" element="piece"><bounds x="50" y="~y~" width="10" height="10" /></bezel> + <bezel name="piece_g~i~" element="piece"><bounds x="60" y="~y~" width="10" height="10" /></bezel> + <bezel name="piece_h~i~" element="piece"><bounds x="70" y="~y~" width="10" height="10" /></bezel> + </repeat> + </group> + + +<!-- sb ui --> + + <element name="hlub" defstate="0"> + <rect state="1"><color red="0" green="0" blue="0" /></rect> + </element> + + <element name="text_uit1"><text string="S.BOARD"><color red="0.81" green="0.8" blue="0.79" /></text></element> + <element name="text_uit2"><text string="INTERFACE"><color red="0.81" green="0.8" blue="0.79" /></text></element> + <element name="text_uib1"><text string="BOARD:"><color red="0.81" green="0.8" blue="0.79" /></text></element> + <element name="text_uib2"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="RESET"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_uib3"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="CLEAR"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_uis1"><text string="SPAWN:"><color red="0.81" green="0.8" blue="0.79" /></text></element> + <element name="text_uih1"><text string="HAND:"><color red="0.81" green="0.8" blue="0.79" /></text></element> + <element name="text_uih2"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string="REMOVE"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_uiu1"><text string="UNDO:"><color red="0.81" green="0.8" blue="0.79" /></text></element> + <element name="text_uiu2a"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string=" <<"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_uiu2b"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string=" < "><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_uiu2c"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string=" >"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_uiu2d"> + <rect><color red="0.88" green="0.84" blue="0.65" /></rect> + <text string=" >>"><color red="0.01" green="0.01" blue="0.01" /></text> + </element> + <element name="text_uiu3a" defstate="0"> + <simplecounter maxstate="999" digits="1" align="2"> + <color red="0.81" green="0.8" blue="0.79" /> + </simplecounter> + </element> + <element name="text_uiu3b"><text string="/"><color red="0.81" green="0.8" blue="0.79" /></text></element> + <element name="text_uiu3c" defstate="0"> + <simplecounter maxstate="999" digits="1" align="1"> + <color red="0.81" green="0.8" blue="0.79" /> + </simplecounter> + </element> + + <group name="sb_ui"> + <bounds x="0" y="0" width="10" height="80" /> + <bezel element="cblack"><bounds x="0" y="0" width="10" height="1" /></bezel> + <bezel element="cblack"><bounds x="0" y="7" width="10" height="1" /></bezel> + <bezel element="cblack"><bounds x="0" y="79" width="10" height="1" /></bezel> + <bezel element="text_uit1"><bounds x="0" y="2" width="10" height="2" /></bezel> + <bezel element="text_uit2"><bounds x="0" y="4" width="10" height="2" /></bezel> + + <!-- board --> + <bezel element="text_uib1"><bounds x="0" y="9" width="10" height="2" /></bezel> + <bezel element="cwhite"><bounds x="1" y="11.5" width="8" height="2.5" /></bezel> + <bezel element="cwhite"><bounds x="1" y="15" width="8" height="2.5" /></bezel> + + <bezel element="text_uib2"><bounds x="1.5" y="11.75" width="7" height="2" /></bezel> + <bezel element="text_uib3"><bounds x="1.5" y="15.25" width="7" height="2" /></bezel> + + <bezel element="hlub" inputtag="board:UI" inputmask="0x200"><bounds x="1" y="11.5" width="8" height="2.5" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:UI" inputmask="0x100"><bounds x="1" y="15" width="8" height="2.5" /><color alpha="0.25" /></bezel> + + <!-- spawn --> + <bezel element="text_uis1"><bounds x="0" y="20.5" width="10" height="2" /></bezel> + <bezel element="cwhite"><bounds x="1" y="23" width="8" height="12" /></bezel> + <bezel element="cwhite"><bounds x="1" y="36" width="8" height="12" /></bezel> + + <bezel name="piece_ui1" element="piece"><bounds x="1" y="23" width="4" height="4" /></bezel> + <bezel name="piece_ui2" element="piece"><bounds x="1" y="27" width="4" height="4" /></bezel> + <bezel name="piece_ui3" element="piece"><bounds x="1" y="31" width="4" height="4" /></bezel> + <bezel name="piece_ui4" element="piece"><bounds x="5" y="23" width="4" height="4" /></bezel> + <bezel name="piece_ui5" element="piece"><bounds x="5" y="27" width="4" height="4" /></bezel> + <bezel name="piece_ui6" element="piece"><bounds x="5" y="31" width="4" height="4" /></bezel> + <bezel name="piece_ui7" element="piece"><bounds x="1" y="36" width="4" height="4" /></bezel> + <bezel name="piece_ui8" element="piece"><bounds x="1" y="40" width="4" height="4" /></bezel> + <bezel name="piece_ui9" element="piece"><bounds x="1" y="44" width="4" height="4" /></bezel> + <bezel name="piece_ui10" element="piece"><bounds x="5" y="36" width="4" height="4" /></bezel> + <bezel name="piece_ui11" element="piece"><bounds x="5" y="40" width="4" height="4" /></bezel> + <bezel name="piece_ui12" element="piece"><bounds x="5" y="44" width="4" height="4" /></bezel> + + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0001"><bounds x="1" y="23" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0002"><bounds x="1" y="27" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0004"><bounds x="1" y="31" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0008"><bounds x="5" y="23" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0010"><bounds x="5" y="27" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0020"><bounds x="5" y="31" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0040"><bounds x="1" y="36" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0080"><bounds x="1" y="40" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0100"><bounds x="1" y="44" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0200"><bounds x="5" y="36" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0400"><bounds x="5" y="40" width="4" height="4" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:SPAWN" inputmask="0x0800"><bounds x="5" y="44" width="4" height="4" /><color alpha="0.25" /></bezel> + + <!-- hand --> + <bezel element="text_uih1"><bounds x="0" y="51" width="10" height="2" /></bezel> + <bezel element="cblack"><bounds x="1" y="53.5" width="8" height="6" /></bezel> + <bezel name="piece_ui0" element="piece"><bounds x="2" y="53.5" width="6" height="6" /></bezel> + + <bezel element="cwhite"><bounds x="1" y="60.5" width="8" height="2.5" /></bezel> + <bezel element="text_uih2"><bounds x="1.5" y="60.75" width="7" height="2" /></bezel> + <bezel element="hlub" inputtag="board:UI" inputmask="0x08"><bounds x="1" y="60.5" width="8" height="2.5" /><color alpha="0.25" /></bezel> + + <!-- undo --> + <bezel element="text_uiu1"><bounds x="0" y="66" width="10" height="2" /></bezel> + <bezel element="cwhite"><bounds x="1" y="68.5" width="1.7" height="6" /></bezel> + <bezel element="cwhite"><bounds x="3.1" y="68.5" width="1.7" height="6" /></bezel> + <bezel element="cwhite"><bounds x="5.2" y="68.5" width="1.7" height="6" /></bezel> + <bezel element="cwhite"><bounds x="7.3" y="68.5" width="1.7" height="6" /></bezel> + <bezel element="text_uiu2a"><bounds x="1" y="69.5" width="1.7" height="4" /></bezel> + <bezel element="text_uiu2b"><bounds x="3.1" y="69.5" width="1.7" height="4" /></bezel> + <bezel element="text_uiu2c"><bounds x="5.2" y="69.5" width="1.7" height="4" /></bezel> + <bezel element="text_uiu2d"><bounds x="7.3" y="69.5" width="1.7" height="4" /></bezel> + + <bezel element="hlub" inputtag="board:UI" inputmask="0x10"><bounds x="1" y="68.5" width="1.7" height="6" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:UI" inputmask="0x20"><bounds x="3.1" y="68.5" width="1.7" height="6" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:UI" inputmask="0x40"><bounds x="5.2" y="68.5" width="1.7" height="6" /><color alpha="0.25" /></bezel> + <bezel element="hlub" inputtag="board:UI" inputmask="0x80"><bounds x="7.3" y="68.5" width="1.7" height="6" /><color alpha="0.25" /></bezel> + + <bezel name="count_ui0" element="text_uiu3a"><bounds x="0" y="75" width="4" height="2" /></bezel> + <bezel name="count_ui1" element="text_uiu3c"><bounds x="6" y="75" width="4" height="2" /></bezel> + <bezel element="text_uiu3b"><bounds x="4" y="75" width="2" height="2" /></bezel> + </group> + + +<!-- shared view --> + + <group name="shared"> + <bounds x="-0.5" y="6.5" width="83" height="94.9" /> + + <bezel element="gray"><bounds x="3" y="89.4" width="27" height="12" /></bezel> + <bezel element="blackb"><bounds x="5" y="91.4" width="23" height="8" /></bezel> + <bezel name="digit0" element="digit"><bounds x="7" y="92.4" width="4" height="6" /></bezel> + <bezel name="digit1" element="digit"><bounds x="12" y="92.4" width="4" height="6" /></bezel> + <bezel name="digit2" element="digit"><bounds x="17" y="92.4" width="4" height="6" /></bezel> + <bezel name="digit3" element="digit"><bounds x="22" y="92.4" width="4" height="6" /></bezel> + + <bezel element="text_8"><bounds x="-0.5" y="6.5" width="3" height="3" /></bezel> + <bezel element="text_7"><bounds x="-0.5" y="16.5" width="3" height="3" /></bezel> + <bezel element="text_6"><bounds x="-0.5" y="26.5" width="3" height="3" /></bezel> + <bezel element="text_5"><bounds x="-0.5" y="36.5" width="3" height="3" /></bezel> + <bezel element="text_4"><bounds x="-0.5" y="46.5" width="3" height="3" /></bezel> + <bezel element="text_3"><bounds x="-0.5" y="56.5" width="3" height="3" /></bezel> + <bezel element="text_2"><bounds x="-0.5" y="66.5" width="3" height="3" /></bezel> + <bezel element="text_1"><bounds x="-0.5" y="76.5" width="3" height="3" /></bezel> + + <bezel element="text_a"><bounds x="7" y="85.5" width="3" height="3" /></bezel> + <bezel element="text_b"><bounds x="17" y="85.5" width="3" height="3" /></bezel> + <bezel element="text_c"><bounds x="27" y="85.5" width="3" height="3" /></bezel> + <bezel element="text_d"><bounds x="37" y="85.5" width="3" height="3" /></bezel> + <bezel element="text_e"><bounds x="47" y="85.5" width="3" height="3" /></bezel> + <bezel element="text_f"><bounds x="57" y="85.5" width="3" height="3" /></bezel> + <bezel element="text_g"><bounds x="67" y="85.5" width="3" height="3" /></bezel> + <bezel element="text_h"><bounds x="77" y="85.5" width="3" height="3" /></bezel> + + <bezel element="blackb"><bounds x="1.1" y="6.7" width="1.6" height="2.6" /></bezel> + <bezel element="blackb"><bounds x="1.1" y="16.7" width="1.6" height="2.6" /></bezel> + <bezel element="blackb"><bounds x="1.1" y="26.7" width="1.6" height="2.6" /></bezel> + <bezel element="blackb"><bounds x="1.1" y="36.7" width="1.6" height="2.6" /></bezel> + <bezel element="blackb"><bounds x="1.1" y="46.7" width="1.6" height="2.6" /></bezel> + <bezel element="blackb"><bounds x="1.1" y="56.7" width="1.6" height="2.6" /></bezel> + <bezel element="blackb"><bounds x="1.1" y="66.7" width="1.6" height="2.6" /></bezel> + <bezel element="blackb"><bounds x="1.1" y="76.7" width="1.6" height="2.6" /></bezel> + + <bezel name="0.8" element="led"><bounds x="1.4" y="7" width="1" height="2" /></bezel> + <bezel name="0.7" element="led"><bounds x="1.4" y="17" width="1" height="2" /></bezel> + <bezel name="0.6" element="led"><bounds x="1.4" y="27" width="1" height="2" /></bezel> + <bezel name="0.5" element="led"><bounds x="1.4" y="37" width="1" height="2" /></bezel> + <bezel name="0.4" element="led"><bounds x="1.4" y="47" width="1" height="2" /></bezel> + <bezel name="0.3" element="led"><bounds x="1.4" y="57" width="1" height="2" /></bezel> + <bezel name="0.2" element="led"><bounds x="1.4" y="67" width="1" height="2" /></bezel> + <bezel name="0.1" element="led"><bounds x="1.4" y="77" width="1" height="2" /></bezel> + + <bezel element="blackb"><bounds x="7.2" y="83.8" width="2.6" height="1.6" /></bezel> + <bezel element="blackb"><bounds x="17.2" y="83.8" width="2.6" height="1.6" /></bezel> + <bezel element="blackb"><bounds x="27.2" y="83.8" width="2.6" height="1.6" /></bezel> + <bezel element="blackb"><bounds x="37.2" y="83.8" width="2.6" height="1.6" /></bezel> + <bezel element="blackb"><bounds x="47.2" y="83.8" width="2.6" height="1.6" /></bezel> + <bezel element="blackb"><bounds x="57.2" y="83.8" width="2.6" height="1.6" /></bezel> + <bezel element="blackb"><bounds x="67.2" y="83.8" width="2.6" height="1.6" /></bezel> + <bezel element="blackb"><bounds x="77.2" y="83.8" width="2.6" height="1.6" /></bezel> + + <bezel name="1.1" element="led"><bounds x="7.5" y="84.1" width="2" height="1" /></bezel> + <bezel name="1.2" element="led"><bounds x="17.5" y="84.1" width="2" height="1" /></bezel> + <bezel name="1.3" element="led"><bounds x="27.5" y="84.1" width="2" height="1" /></bezel> + <bezel name="1.4" element="led"><bounds x="37.5" y="84.1" width="2" height="1" /></bezel> + <bezel name="1.5" element="led"><bounds x="47.5" y="84.1" width="2" height="1" /></bezel> + <bezel name="1.6" element="led"><bounds x="57.5" y="84.1" width="2" height="1" /></bezel> + <bezel name="1.7" element="led"><bounds x="67.5" y="84.1" width="2" height="1" /></bezel> + <bezel name="1.8" element="led"><bounds x="77.5" y="84.1" width="2" height="1" /></bezel> + + <bezel element="but" inputtag="IN.0" inputmask="0x01"><bounds x="33.5" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="IN.0" inputmask="0x02"><bounds x="39.0" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="IN.0" inputmask="0x04"><bounds x="44.5" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="IN.0" inputmask="0x08"><bounds x="50.0" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="IN.0" inputmask="0x10"><bounds x="55.5" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="IN.0" inputmask="0x20"><bounds x="61.0" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="IN.0" inputmask="0x40"><bounds x="66.5" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="IN.0" inputmask="0x80"><bounds x="72.0" y="93" width="4.2" height="6.4" /></bezel> + <bezel element="but" inputtag="RESET" inputmask="0x01"><bounds x="79.3" y="93" width="4.2" height="6.4" /></bezel> + </group> + + +<!-- build screen --> + + <view name="Internal Layout (Russian)"> <!-- original --> + <bounds left="-14" right="88" top="-1.5" bottom="103.5" /> + + <bezel element="cwhite"><bounds x="-1" y="-1.5" width="89" height="105" /></bezel> + <bezel element="cblack"><bounds x="3" y="2.5" width="81" height="81" /></bezel> + + <group ref="sb_board"><bounds x="3.5" y="3" width="80" height="80" /></group> + <group ref="sb_ui"><bounds x="-12.5" y="3" width="10" height="80" /></group> + + <bezel element="text_b1"><bounds x="33.0" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b2"><bounds x="38.5" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b3"><bounds x="44.0" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b4"><bounds x="49.5" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b5"><bounds x="55.0" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b6"><bounds x="60.5" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b7"><bounds x="66.0" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b8"><bounds x="71.5" y="90" width="5.2" height="2.5" /></bezel> + <bezel element="text_b9"><bounds x="78.8" y="90" width="5.2" height="2.5" /></bezel> + + <group ref="shared"><bounds x="-0.5" y="6.5" width="83" height="94.9" /></group> + </view> + + <view name="Internal Layout (English)"> <!-- translated --> + <bounds left="-14" right="88" top="-1.5" bottom="103.5" /> + + <bezel element="cwhite"><bounds x="-1" y="-1.5" width="89" height="105" /></bezel> + <bezel element="cblack"><bounds x="3" y="2.5" width="81" height="81" /></bezel> + + <group ref="sb_board"><bounds x="3.5" y="3" width="80" height="80" /></group> + <group ref="sb_ui"><bounds x="-12.5" y="3" width="10" height="80" /></group> + + <bezel element="text_tb1"><bounds x="32.0" y="90.7" width="7.2" height="1.8" /></bezel> + <bezel element="text_tb2a"><bounds x="38.5" y="89.0" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb2b"><bounds x="38.5" y="90.7" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb3"><bounds x="44.0" y="90.7" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb4a"><bounds x="49.5" y="89.0" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb4b"><bounds x="49.5" y="90.7" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb5a"><bounds x="55.0" y="89.0" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb5b"><bounds x="55.0" y="90.7" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb6a"><bounds x="60.5" y="89.0" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb6b"><bounds x="60.5" y="90.7" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb7"><bounds x="66.0" y="90.7" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb8a"><bounds x="71.5" y="89.0" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb8b"><bounds x="71.5" y="90.7" width="5.2" height="1.8" /></bezel> + <bezel element="text_tb9"><bounds x="78.8" y="90.7" width="5.2" height="1.8" /></bezel> + + <group ref="shared"><bounds x="-0.5" y="6.5" width="83" height="94.9" /></group> + </view> + +</mamelayout> diff --git a/src/mame/layout/intellect02.lay b/src/mame/layout/intellect02.lay index 4f23cb0bc5c..d39de00ea30 100644 --- a/src/mame/layout/intellect02.lay +++ b/src/mame/layout/intellect02.lay @@ -1,7 +1,7 @@ <?xml version="1.0"?> <mamelayout version="2"> -<!-- NOTE: no chesspieces simulation here, Intellect-2 is a multiple boardgame console, not just chess --> +<!-- NOTE: no chesspieces simulation here, Intellect-02 is a multiple boardgame console, not just chess --> <!-- define elements --> @@ -22,64 +22,62 @@ <disk state="0"><color red="0.1" green="0.01" blue="0.015" /></disk> </element> - <element name="text_l1"><text string="PROGRESS INDICATOR" align="1"><color red="0.2" green="0.2" blue="0.2" /></text></element> - <element name="text_l2"><text string="YOU WIN" align="1"><color red="0.8" green="0.8" blue="0.8" /></text></element> - <element name="text_l3"><text string="YOU LOSE" align="1"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_l1"><text string="ИНДИКАЦИЯ ХОДА" align="1"><color red="0.2" green="0.2" blue="0.2" /></text></element> + <element name="text_l2"><text string="ВЫ ВЫИГРАЛИ" align="1"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_l3"><text string="ВЫ ПРОИГРАЛИ" align="1"><color red="0.8" green="0.8" blue="0.8" /></text></element> - <element name="text_b1"><text string="RESET"><color red="0.8" green="0.8" blue="0.8" /></text></element> - <element name="text_b2"><text string="SELECT"><color red="0.8" green="0.8" blue="0.8" /></text></element> - <element name="text_b3"><text string="V. POS."><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_b1"><text string="СБ"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_b2"><text string="ВИ"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_b3"><text string="ПП"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b4"><text string="A1"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b5"><text string="B2"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b6"><text string="C3"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b7"><text string="D4"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b8"><text string="E5"><color red="0.8" green="0.8" blue="0.8" /></text></element> - <element name="text_b9"><text string="INPUT"><color red="0.8" green="0.8" blue="0.8" /></text></element> - <element name="text_b10"><text string="ERASE"><color red="0.8" green="0.8" blue="0.8" /></text></element> - <element name="text_b11"><text string="LEVEL"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_b9"><text string="ВВ"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_b10"><text string="СТ"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_b11"><text string="УИ"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b12"><text string="F6"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b13"><text string="G7"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b14"><text string="H8"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b15"><text string="9"><color red="0.8" green="0.8" blue="0.8" /></text></element> <element name="text_b16"><text string="0"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_tl1"><text string="PROGRESS INDICATOR" align="1"><color red="0.2" green="0.2" blue="0.2" /></text></element> + <element name="text_tl2"><text string="YOU WIN" align="1"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_tl3"><text string="YOU LOSE" align="1"><color red="0.8" green="0.8" blue="0.8" /></text></element> + + <element name="text_tb1"><text string="RESET"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_tb2"><text string="SELECT"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_tb3"><text string="V. POS."><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_tb9"><text string="INPUT"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_tb10"><text string="ERASE"><color red="0.8" green="0.8" blue="0.8" /></text></element> + <element name="text_tb11"><text string="LEVEL"><color red="0.8" green="0.8" blue="0.8" /></text></element> -<!-- build screen --> - <view name="Internal Layout"> - <bounds left="7.5" right="43" top="7" bottom="30.2" /> +<!-- shared view --> - <!-- display --> + <group name="shared"> + <bounds x="7.5" y="7.6" width="26" height="21.6" /> + <!-- display --> <bezel element="static_black2"><bounds x="8.5" y="8" width="33.5" height="11.5" /></bezel> <bezel element="static_black"><bounds x="8.1" y="7.6" width="33.5" height="11.5" /></bezel> - <bezel element="text_l1"><bounds x="21" y="7.9" width="20" height="1.5" /></bezel> - <bezel element="text_l2"><bounds x="8.5" y="7.9" width="8" height="1.5" /></bezel> - <bezel element="text_l3"><bounds x="8.5" y="16.4" width="8" height="1.5" /></bezel> - - <bezel name="5.a" element="led"><bounds x="16" y="8" width="1.5" height="1.5" /></bezel> - <bezel name="4.a" element="led"><bounds x="16" y="16.5" width="1.5" height="1.5" /></bezel> + <bezel name="5.a" element="led"><bounds x="16.5" y="8" width="1.5" height="1.5" /></bezel> + <bezel name="4.a" element="led"><bounds x="16.5" y="16.5" width="1.5" height="1.5" /></bezel> <bezel name="digit0" element="digit"><bounds x="20" y="10" width="4" height="6" /></bezel> <bezel name="digit1" element="digit"><bounds x="24" y="10" width="4" height="6" /></bezel> <bezel name="digit2" element="digit"><bounds x="32" y="10" width="4" height="6" /></bezel> <bezel name="digit3" element="digit"><bounds x="36" y="10" width="4" height="6" /></bezel> - <!-- buttons --> - - <bezel element="text_b1"><bounds x="7.5" y="20.7" width="5" height="1.2" /></bezel> - <bezel element="text_b2"><bounds x="11.86" y="20.7" width="5" height="1.2" /></bezel> - <bezel element="text_b3"><bounds x="16.21" y="20.7" width="5" height="1.2" /></bezel> + <!-- buttons --> <bezel element="text_b4"><bounds x="20.57" y="20.7" width="5" height="1.2" /></bezel> <bezel element="text_b5"><bounds x="24.93" y="20.7" width="5" height="1.2" /></bezel> <bezel element="text_b6"><bounds x="29.27" y="20.7" width="5" height="1.2" /></bezel> <bezel element="text_b7"><bounds x="33.64" y="20.7" width="5" height="1.2" /></bezel> <bezel element="text_b8"><bounds x="38" y="20.7" width="5" height="1.2" /></bezel> - - <bezel element="text_b9"><bounds x="7.5" y="25.4" width="5" height="1.2" /></bezel> - <bezel element="text_b10"><bounds x="11.86" y="25.4" width="5" height="1.2" /></bezel> - <bezel element="text_b11"><bounds x="16.21" y="25.4" width="5" height="1.2" /></bezel> <bezel element="text_b12"><bounds x="20.57" y="25.4" width="5" height="1.2" /></bezel> <bezel element="text_b13"><bounds x="24.93" y="25.4" width="5" height="1.2" /></bezel> <bezel element="text_b14"><bounds x="29.27" y="25.4" width="5" height="1.2" /></bezel> @@ -103,6 +101,41 @@ <bezel element="button" inputtag="IN.0" inputmask="0x0040"><bounds x="30.27" y="26.7" width="3" height="2.5" /></bezel> <bezel element="button" inputtag="IN.0" inputmask="0x0020"><bounds x="34.64" y="26.7" width="3" height="2.5" /></bezel> <bezel element="button" inputtag="IN.0" inputmask="0x4000"><bounds x="39" y="26.7" width="3" height="2.5" /></bezel> + </group> + + +<!-- build screen --> + <view name="Internal Layout (Russian)"> <!-- original --> + <bounds x="7.5" y="7" width="35.5" height="23.2" /> + <group ref="shared"><bounds x="7.5" y="7.6" width="26" height="21.6" /></group> + + <bezel element="text_l1"><bounds x="21" y="8.05" width="20" height="1.2" /></bezel> + <bezel element="text_l2"><bounds x="8.5" y="8.05" width="8" height="1.2" /></bezel> + <bezel element="text_l3"><bounds x="8.5" y="16.55" width="8" height="1.2" /></bezel> + + <bezel element="text_b1"><bounds x="7.5" y="20.7" width="5" height="1.2" /></bezel> + <bezel element="text_b2"><bounds x="11.86" y="20.7" width="5" height="1.2" /></bezel> + <bezel element="text_b3"><bounds x="16.21" y="20.7" width="5" height="1.2" /></bezel> + <bezel element="text_b9"><bounds x="7.5" y="25.4" width="5" height="1.2" /></bezel> + <bezel element="text_b10"><bounds x="11.86" y="25.4" width="5" height="1.2" /></bezel> + <bezel element="text_b11"><bounds x="16.21" y="25.4" width="5" height="1.2" /></bezel> + </view> + + <view name="Internal Layout (English)"> <!-- translated --> + <bounds x="7.5" y="7" width="35.5" height="23.2" /> + <group ref="shared"><bounds x="7.5" y="7.6" width="26" height="21.6" /></group> + + <bezel element="text_tl1"><bounds x="21" y="8.05" width="20" height="1.2" /></bezel> + <bezel element="text_tl2"><bounds x="11" y="8.05" width="8" height="1.2" /></bezel> + <bezel element="text_tl3"><bounds x="11" y="16.55" width="8" height="1.2" /></bezel> + + <bezel element="text_tb1"><bounds x="7.5" y="20.7" width="5" height="1.2" /></bezel> + <bezel element="text_tb2"><bounds x="11.86" y="20.7" width="5" height="1.2" /></bezel> + <bezel element="text_tb3"><bounds x="16.21" y="20.7" width="5" height="1.2" /></bezel> + <bezel element="text_tb9"><bounds x="7.5" y="25.4" width="5" height="1.2" /></bezel> + <bezel element="text_tb10"><bounds x="11.86" y="25.4" width="5" height="1.2" /></bezel> + <bezel element="text_tb11"><bounds x="16.21" y="25.4" width="5" height="1.2" /></bezel> </view> + </mamelayout> diff --git a/src/mame/layout/saitek_corona.lay b/src/mame/layout/saitek_corona.lay index 40c9d96618c..83b6cae4983 100644 --- a/src/mame/layout/saitek_corona.lay +++ b/src/mame/layout/saitek_corona.lay @@ -497,7 +497,7 @@ <!-- lcd panel --> <group name="lcd1"> - <bounds x="15.5" y="0" width="22.5" height="14" /> + <bounds x="15" y="0" width="23" height="14" /> <bezel name="digit0" element="digit"><bounds x="15" y="0" width="4" height="6" /></bezel> <bezel name="digit1" element="digit"><bounds x="20" y="0" width="4" height="6" /></bezel> @@ -586,7 +586,7 @@ <group ref="sb_board"><bounds x="10" y="10" width="80" height="80" /></group> <group ref="sb_ui"><bounds x="-1.5" y="10" width="10" height="80" /></group> - <group ref="lcd1"><bounds x="26.64" y="92" width="12.86" height="8" /></group> + <group ref="lcd1"><bounds x="26.36" y="92" width="13.14" height="8" /></group> <group ref="lcd2"><bounds x="25.14" y="96.5714" width="3.42857" height="3.42857" /></group> <bezel element="whitew"><bounds x="24.64" y="91.5" width="15.36" height="9" /><color alpha="0.125" /></bezel> diff --git a/src/mame/layout/saitek_stratos.lay b/src/mame/layout/saitek_stratos.lay index 0cf489d7928..f5d60655d05 100644 --- a/src/mame/layout/saitek_stratos.lay +++ b/src/mame/layout/saitek_stratos.lay @@ -476,7 +476,7 @@ <!-- lcd panel --> <group name="lcd1"> - <bounds x="15.5" y="0" width="22.5" height="14" /> + <bounds x="15" y="0" width="23" height="14" /> <bezel name="digit0" element="digit"><bounds x="15" y="0" width="4" height="6" /></bezel> <bezel name="digit1" element="digit"><bounds x="20" y="0" width="4" height="6" /></bezel> @@ -565,7 +565,7 @@ <group ref="sb_board"><bounds x="10" y="10" width="80" height="80" /></group> <group ref="sb_ui"><bounds x="-3" y="10" width="10" height="80" /></group> - <group ref="lcd1"><bounds x="26.64" y="93" width="12.86" height="8" /></group> + <group ref="lcd1"><bounds x="26.36" y="93" width="13.14" height="8" /></group> <group ref="lcd2"><bounds x="25.14" y="97.5714" width="3.42857" height="3.42857" /></group> <bezel element="whitew"><bounds x="24.64" y="92.5" width="15.36" height="9" /><color alpha="0.125" /></bezel> diff --git a/src/mame/layout/sc2.lay b/src/mame/layout/sc2.lay index 86f280ebce2..b1638a7b728 100644 --- a/src/mame/layout/sc2.lay +++ b/src/mame/layout/sc2.lay @@ -398,6 +398,7 @@ <group name="sb_ui"> <bounds x="0" y="0" width="10" height="80" /> + <bezel element="cblack"><bounds x="0" y="0" width="10" height="1" /></bezel> <bezel element="cblack"><bounds x="0" y="7" width="10" height="1" /></bezel> <bezel element="cblack"><bounds x="0" y="79" width="10" height="1" /></bezel> @@ -480,7 +481,7 @@ <!-- display, buttons --> <group name="panel"> - <bounds x="0" y="5" width="270" height="390" /> + <bounds x="5" y="15" width="270" height="370" /> <bezel name="digit0" element="digit"><bounds x="10" y="15" width="50" height="75" /></bezel> <bezel name="digit1" element="digit"><bounds x="70" y="15" width="50" height="75" /></bezel> @@ -555,9 +556,9 @@ <!-- build screen --> <view name="Internal Layout (Full)"> - <bounds left="-13" right="131.8" top="-1.5" bottom="87.5" /> + <bounds left="-13" right="131.14" top="-1.5" bottom="87.5" /> - <group ref="panel"><bounds x="91" y="29.4" width="38.0769" height="55" /></group> + <group ref="panel"><bounds x="91.297" y="31" width="37.946" height="52" /></group> <bezel element="white"><bounds x="-1" y="-1.5" width="89" height="89" /></bezel> <bezel element="black2"><bounds x="3" y="2.5" width="81" height="81" /></bezel> @@ -587,7 +588,7 @@ <view name="Internal Layout (Buttons)"> <bounds left="0" right="270" top="0" bottom="390" /> - <group ref="panel"><bounds x="0" y="0" width="270" height="390" /></group> + <group ref="panel"><bounds x="5" y="10" width="270" height="370" /></group> </view> </mamelayout> diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 777fc9b18c8..7671bb4df34 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -11410,6 +11410,9 @@ leadang // (c) 1988 Seibu Kaihatsu popnrun // (c) 1987 Seibu Kaihatsu + Yukai Tsukai popnruna // (c) 1987 Seibu Kaihatsu + Yukai Tsukai +@source:debut.cpp +debutm + @source:dec0.cpp automat // bootleg baddudes // EI (c) 1988 Data East USA (US) diff --git a/src/mame/mess.flt b/src/mame/mess.flt index f3566081cb3..0276d5c4545 100644 --- a/src/mame/mess.flt +++ b/src/mame/mess.flt @@ -185,6 +185,7 @@ datum.cpp dbox.cpp dccons.cpp dct11em.cpp +debut.cpp decstation.cpp dectalk.cpp decwritr.cpp |