static TIMER_CALLBACK( interrupt_timer ) { /* 128V, 64V and 32V go to D */ TTL7474_d_w(0, (param & 0xe0) != 0xe0); /* 16V clocks the flip-flop */ TTL7474_clock_w(0, param & 0x10); param = (param + 0x10) & 0xff; timer_adjust(int_timer, video_screen_get_time_until_pos(0, param, 0), param, attotime_zero); TTL7474_update(0); }
static void interrupt_timer(int param) { /* 128V, 64V and 32V go to D */ TTL7474_d_w(0, (param & 0xe0) != 0xe0); /* 16V clocks the flip-flop */ TTL7474_clock_w(0, param & 0x10); param = (param + 0x10) & 0xff; timer_adjust(int_timer, cpu_getscanlinetime(param), param, 0); TTL7474_update(0); }
static void machine_reset_common( int line ) { irq_line = line; /* initalize main CPU interrupt generator flip-flops */ TTL7474_config(0, &galaxian_7474_9M_2_intf); TTL7474_preset_w(0, 1); TTL7474_clear_w (0, 1); TTL7474_config(1, &galaxian_7474_9M_1_intf); TTL7474_clear_w (1, 1); TTL7474_d_w (1, 0); TTL7474_preset_w(1, 0); /* start a timer to generate interrupts */ int_timer = timer_alloc(interrupt_timer, NULL); timer_adjust(int_timer, video_screen_get_time_until_pos(0, 0, 0), 0, attotime_zero); }
static void machine_reset_common( int line ) { irq_line = line; /* initalize main CPU interrupt generator flip-flops */ TTL7474_config(0, &galaxian_7474_9M_2_intf); TTL7474_preset_w(0, 1); TTL7474_clear_w (0, 1); TTL7474_config(1, &galaxian_7474_9M_1_intf); TTL7474_clear_w (1, 1); TTL7474_d_w (1, 0); TTL7474_preset_w(1, 0); /* start a timer to generate interrupts */ int_timer = timer_alloc(interrupt_timer); timer_adjust(int_timer, cpu_getscanlinetime(0), 0, 0); }
static void machine_reset_common(running_machine *machine, int line) { irq_line = line; /* initalize main CPU interrupt generator flip-flops */ TTL7474_config(0, &galaxold_7474_9M_2_intf); TTL7474_preset_w(0, 1); TTL7474_clear_w (0, 1); TTL7474_config(1, &galaxold_7474_9M_1_intf); TTL7474_clear_w (1, 1); TTL7474_d_w (1, 0); TTL7474_preset_w(1, 0); /* start a timer to generate interrupts */ int_timer = timer_alloc(interrupt_timer, NULL); timer_adjust_oneshot(int_timer, video_screen_get_time_until_pos(machine->primary_screen, 0, 0), 0); }