src/mess/machine/cbmb.c
| r7371 | r7372 | |
| 14 | 14 | #include "machine/ieee488.h" |
| 15 | 15 | |
| 16 | 16 | #include "includes/cbmb.h" |
| 17 | #include "crsshair.h" |
| 17 | 18 | |
| 18 | 19 | #include "devices/cartslot.h" |
| 19 | 20 | |
| r7371 | r7372 | |
| 367 | 368 | } |
| 368 | 369 | |
| 369 | 370 | |
| 371 | static TIMER_CALLBACK( p500_lightpen_tick ) |
| 372 | { |
| 373 | if ((input_port_read_safe(machine, "CTRLSEL", 0x00) & 0x07) == 0x04) |
| 374 | { |
| 375 | /* enable lightpen crosshair */ |
| 376 | crosshair_set_screen(machine, 0, CROSSHAIR_SCREEN_ALL); |
| 377 | } |
| 378 | else |
| 379 | { |
| 380 | /* disable lightpen crosshair */ |
| 381 | crosshair_set_screen(machine, 0, CROSSHAIR_SCREEN_NONE); |
| 382 | } |
| 383 | } |
| 384 | |
| 370 | 385 | static TIMER_CALLBACK(cbmb_frame_interrupt) |
| 371 | 386 | { |
| 372 | 387 | static int level = 0; |
| r7371 | r7372 | |
| 469 | 484 | // 128u4 FIXME |
| 470 | 485 | // vic2_frame_interrupt (device); |
| 471 | 486 | |
| 487 | /* for p500, check if lightpen has been chosen as input: if so, enable crosshair (but c64-like inputs for p500 are not working atm) */ |
| 488 | timer_set(machine, attotime_zero, NULL, 0, p500_lightpen_tick); |
| 489 | |
| 472 | 490 | set_led_status(machine, 1, input_port_read(machine, "SPECIAL") & 0x04 ? 1 : 0); /* Shift Lock */ |
| 473 | 491 | } |
| 474 | 492 | |