1
0
mirror of https://github.com/rcornwell/sims.git synced 2026-01-21 18:15:04 +00:00

KA10: Merged DPY Idling.

This commit is contained in:
Richard Cornwell 2019-08-15 23:10:56 -04:00
commit b61d009dc7
3 changed files with 20 additions and 1 deletions

View File

@ -246,6 +246,8 @@ t_stat dpy_devio(uint32 dev, uint64 *data) {
dpy_update_status( uptr, ty340_reset(&dpy_dev), 1);
sim_debug(DEBUG_CONO, &dpy_dev, "DPY %03o CONO %06o PC=%06o %06o\n",
dev, (uint32)*data, PC, uptr->STAT_REG & ~STAT_VALID);
if (!sim_is_active(uptr))
sim_activate_after(uptr, DPY_CYCLE_US);
break;
case DATAO:
@ -262,6 +264,8 @@ t_stat dpy_devio(uint32 dev, uint64 *data) {
inst = (uint32)RRZ(*data);
dpy_update_status(uptr, ty340_instruction(inst), 1);
}
if (!sim_is_active(uptr))
sim_activate_after(uptr, DPY_CYCLE_US);
break;
case DATAI:
@ -276,7 +280,8 @@ t_stat dpy_devio(uint32 dev, uint64 *data) {
/* Timer service - */
t_stat dpy_svc (UNIT *uptr)
{
sim_activate_after(uptr, DPY_CYCLE_US); /* requeue! */
if (!display_is_blank() || uptr->INT_COUNTDOWN > 0)
sim_activate_after(uptr, DPY_CYCLE_US); /* requeue! */
display_age(DPY_CYCLE_US, 0); /* age the display */

View File

@ -439,6 +439,15 @@ queue_point(struct point *p)
p->delay = d;
}
/*
* Return true if the display is blank, i.e. no active points in list.
*/
int
display_is_blank(void)
{
return head->next == head;
}
/*
* here to to dynamically adjust interval for examination
* of elapsed vs. simulated time, and fritter away

View File

@ -83,6 +83,11 @@ extern int display_scale(void);
*/
extern int display_age(int,int);
/*
* Return true if the display is blank.
*/
extern int display_is_blank(void);
/*
* display intensity levels.
* always at least 8 (for VT11/VS60) -- may be mapped internally