summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices
diff options
context:
space:
mode:
authorGravatarGravatar couriersud <couriersud@gmx.org>2019-11-16 16:08:48 +0100
committerGravatarGravatar couriersud <couriersud@gmx.org>2019-11-16 16:09:04 +0100
commit67dc264e22edad3f2b67bcc3573587ca3b2eb2a0 (patch)
tree134b83957f7fd545f7ade6df54d24d3b3b8ceb45 /src/devices
parentdbe7b978ae9e3c2316878384fd549568e4918f89 (diff)
netlist: more code maintenance. (nw)
- refactor error messages. - Fix some drivers to cope with outputted added my the mame driver for video and sound. - Fix validation.
Diffstat (limited to 'src/devices')
-rw-r--r--src/devices/machine/netlist.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/devices/machine/netlist.cpp b/src/devices/machine/netlist.cpp
index 73194b47459..886510ea24f 100644
--- a/src/devices/machine/netlist.cpp
+++ b/src/devices/machine/netlist.cpp
@@ -216,6 +216,13 @@ private:
// ----------------------------------------------------------------------------------------
// logic_callback
+//
+// This device must be connected to a logic net. It has no power terminals
+// and conversion with proxies will not work.
+//
+// Background: This is inserted later into the driver and should not modify
+// the resulting analog representation of the netlist.
+//
// ----------------------------------------------------------------------------------------
class NETLIB_NAME(logic_callback) : public netlist::device_t
@@ -226,7 +233,7 @@ public:
, m_in(*this, "IN")
, m_cpu_device(nullptr)
, m_last(*this, "m_last", 0)
- , m_supply(*this)
+// , m_supply(*this)
{
auto *nl = dynamic_cast<netlist_mame_device::netlist_mame_t *>(&state());
if (nl != nullptr)
@@ -263,7 +270,7 @@ private:
std::unique_ptr<netlist_mame_logic_output_device::output_delegate> m_callback; // TODO: change to std::optional for C++17
netlist_mame_cpu_device *m_cpu_device;
netlist::state_var<netlist::netlist_sig_t> m_last;
- netlist::devices::NETLIB_NAME(power_pins) m_supply;
+ //netlist::devices::NETLIB_NAME(power_pins) m_supply;
};
@@ -383,6 +390,7 @@ plib::unique_ptr<std::istream> netlist_data_memregions_t::stream(const pstring &
/* validation */
if (rom_exists(m_dev.mconfig().root_device(), pstring(m_dev.tag()) + ":" + name))
{
+ // Create an empty stream.
auto ret(plib::make_unique<std::istringstream>(std::ios_base::binary));
ret->imbue(std::locale::classic());
return MOVE_UNIQUE_PTR(ret);
@@ -1089,7 +1097,7 @@ plib::unique_ptr<netlist::netlist_state_t> netlist_mame_device::base_validity_ch
//netlist_mame_t lnetlist(*this, "netlist", plib::make_unique<netlist_validate_callbacks_t>());
auto lnetlist = plib::make_unique<netlist::netlist_state_t>("netlist", plib::make_unique<netlist_validate_callbacks_t>());
// enable validation mode
- lnetlist->setup().set_extended_validation(true);
+ lnetlist->set_extended_validation(true);
common_dev_start(lnetlist.get());
for (device_t &d : subdevices())