summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/machine/netlist.c
diff options
context:
space:
mode:
author Couriersud <couriersud@users.noreply.github.com>2013-10-09 18:23:22 +0000
committer Couriersud <couriersud@users.noreply.github.com>2013-10-09 18:23:22 +0000
commit35876ea66415f26306629b9aa52a143c8c9223ec (patch)
treeb9ded48364221d9d1c075424a6eaad87106a1fbf /src/emu/machine/netlist.c
parentafed55a2132f78055bd5a360235240214ec65913 (diff)
All netlist device setup now takes place in constructors.
Diffstat (limited to 'src/emu/machine/netlist.c')
-rw-r--r--src/emu/machine/netlist.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/emu/machine/netlist.c b/src/emu/machine/netlist.c
index b92f68e2ef3..1b0326cc651 100644
--- a/src/emu/machine/netlist.c
+++ b/src/emu/machine/netlist.c
@@ -51,7 +51,7 @@
// DEBUGGING
//============================================================
-#define VERBOSE (0)
+#define VERBOSE (1)
#define KEEP_STATISTICS (0)
#define FATAL_ERROR_AFTER_NS (0) //(1000)
@@ -332,7 +332,7 @@ public:
// netdev_const
// ----------------------------------------------------------------------------------------
-NETLIB_START(netdev_ttl_const)
+NETLIB_CONSTRUCTOR(netdev_ttl_const)
{
register_output("Q", m_Q);
register_param("CONST", m_const, 0.0);
@@ -347,7 +347,7 @@ NETLIB_UPDATE_PARAM(netdev_ttl_const)
m_Q.setTo(m_const.ValueInt(), NLTIME_IMMEDIATE);
}
-NETLIB_START(netdev_analog_const)
+NETLIB_CONSTRUCTOR(netdev_analog_const)
{
register_output("Q", m_Q);
register_param("CONST", m_const, 0.0);
@@ -494,7 +494,6 @@ net_device_t *netlist_setup_t::register_dev(net_device_t *dev)
{
if (!(m_devices.add(dev->name(), dev, false)==TMERR_NONE))
fatalerror("Error adding %s to device list\n", dev->name());
- dev->start();
return dev;
}
@@ -632,6 +631,9 @@ void netlist_setup_t::resolve_inputs(void)
astring sin = entry->tag();
net_input_t *in = m_inputs.find(sin);
+ if (in == NULL)
+ fatalerror("Unable to find %s\n", sin.cstr());
+
net_output_t &out = find_output(sout->cstr());
if (out.object_type(net_output_t::SIGNAL_MASK) == net_output_t::SIGNAL_ANALOG
&& in->object_type(net_output_t::SIGNAL_MASK) == net_output_t::SIGNAL_DIGITAL)