Previous 199869 Revisions Next

r20536 Sunday 27th January, 2013 at 16:00:40 UTC by Phil Bennett
(MAME) xtheball.c: Reduce tag lookups [Phil Bennett]
[src/mame/drivers]xtheball.c

trunk/src/mame/drivers/xtheball.c
r20535r20536
2121      : driver_device(mconfig, type, tag) ,
2222        m_tlc34076(*this, "tlc34076"),
2323        m_vram_bg(*this, "vrabg"),
24        m_vram_fg(*this, "vrafg")
24        m_vram_fg(*this, "vrafg"),
25        m_analog_x(*this, "ANALOGX"),
26        m_analog_y(*this, "ANALOGY")
2527      { }
2628
2729   required_device<tlc34076_device> m_tlc34076;
2830   required_shared_ptr<UINT16> m_vram_bg;
2931   required_shared_ptr<UINT16> m_vram_fg;
32   required_ioport m_analog_x;
33   required_ioport m_analog_y;
3034   UINT8 m_bitvals[32];
3135   DECLARE_WRITE16_MEMBER(bit_controls_w);
3236   DECLARE_READ16_MEMBER(analogx_r);
r20535r20536
194198
195199READ16_MEMBER(xtheball_state::analogx_r)
196200{
197   return (ioport("ANALOGX")->read() << 8) | 0x00ff;
201   return (m_analog_x->read() << 8) | 0x00ff;
198202}
199203
200204
r20535r20536
202206{
203207   /* doubles as a watchdog address */
204208   watchdog_reset_w(space,0,0);
205   return (ioport("ANALOGY")->read() << 8) | 0x00ff;
209   return (m_analog_y->read() << 8) | 0x00ff;
206210}
207211
208212

Previous 199869 Revisions Next


© 1997-2024 The MAME Team