Previous 199869 Revisions Next

r25478 Tuesday 1st October, 2013 at 19:26:41 UTC by Michael Zapf
(MESS) ti99: Constrain debugger access.
[src/mess/machine/ti99]datamux.c

trunk/src/mess/machine/ti99/datamux.c
r25477r25478
134134   }
135135}
136136
137// FIXME: Allow for a separate debugger access, or it will spoil the whole
138// addressing process!
139
137140/*
138141    Read access. We are using two loops because the delay between both
139142    accesses must not occur within the loop. So we have one access on the bus,
r25477r25478
142145*/
143146READ16_MEMBER( ti99_datamux_device::read )
144147{
148   if (space.debugger_access())
149   {
150      // FIXME, or the debugger will become blind for addresses outside
151      // ROM and scratch pad RAM.
152      return 0;
153   }
154
145155   // Looks ugly, but this is close to the real thing. If the 16bit
146156   // memory expansion is installed in the console, and the access hits its
147157   // space, just respond to the memory access and don't bother the
148158   // datamux in any way. In particular, do not make the datamux insert wait
149159   // states.
160
150161   if (m_base32k != 0)
151162   {
152163      UINT16 reply = m_ram16b[offset-m_base32k];
r25477r25478
169180*/
170181WRITE16_MEMBER( ti99_datamux_device::write )
171182{
172   // Although MESS allows for using mem_mask to address parts of the
173   // data bus, this is not used in the TMS implementation. In fact, all
174   // accesses are true 16-bit accesses. We check for mem_mask always
175   // being ffff.
183   // Addresses below 0x2000 are ROM and should be handled in the address map
184   // by the ROM entry, but as the write handler for ROM is not mapped, we end up
185   // here when there are invalid accesses, and this will mess up everything.
186   if (offset < 0x1000) return;
176187
188   if (space.debugger_access())
189   {
190      // Do not accept write operations from the debugger (later maybe).
191      return;
192   }
193
177194   // Handle the internal 32K expansion
178195   if (m_base32k != 0)
179196   {
r25477r25478
277294void ti99_datamux_device::dbin_in(int state)
278295{
279296   m_read_mode = (state==ASSERT_LINE);
280   if (VERBOSE>6) LOG("datamux: data bus in = %d\n", m_read_mode? 1:0 );
297   if (VERBOSE>7) LOG("datamux: data bus in = %d\n", m_read_mode? 1:0 );
281298}
282299
283300/***************************************************************************

Previous 199869 Revisions Next


© 1997-2024 The MAME Team