Previous 15994 Revisions Next

r2816 Thursday 5th June, 2008 at 15:26:16 UTC by Curt Coder
[COP400] Synced with MAME.
[src/emu/cpu/cop400]cop420.c

src/emu/cpu/cop400/cop420.c
r2815r2816
226226
227227static TIMER_CALLBACK(cop420_counter_tick)
228228{
229   cpuintrf_push_context(param);
229230   R.counter++;
230231
231232   if (R.counter == 1024)
r2815r2816
233234      R.counter = 0;
234235      R.timerlatch = 1;
235236   }
237   cpuintrf_pop_context();
236238}
237239
238240/* IN Latches */
239241
240242static TIMER_CALLBACK(cop420_inil_tick)
241243{
242   UINT8 in = IN_IN();
244   UINT8 in;
243245   int i;
244246
247   cpuintrf_push_context(param);
248   in = IN_IN();
245249   for (i = 0; i < 4; i++)
246250   {
247251      R.in[i] = (R.in[i] << 1) | BIT(in, i);
r2815r2816
251255         IL |= (1 << i);
252256      }
253257   }
258   cpuintrf_pop_context();
254259}
255260
256261/* Microbus */
257262
258263static TIMER_CALLBACK(cop420_microbus_tick)
259264{
260   UINT8 in = IN_IN();
265   UINT8 in;
261266
267   cpuintrf_push_context(param);
268   in = IN_IN();
262269   if (!BIT(in, 2))
263270   {
264271      // chip select
r2815r2816
280287         R.microbus_int = 0;
281288      }
282289   }
290   cpuintrf_pop_context();
283291}
284292
285293/****************************************************************************

Previous 15994 Revisions Next


© 1998-2018 The MESS Team