BESM6: Output to Baudot TTYs works; fixed attaching of disks without -e; added DejaVu font option.

This commit is contained in:
Leo Broukhis 2015-01-07 02:03:32 -08:00
parent 0f1e233366
commit d6d13a8c08
5 changed files with 15 additions and 10 deletions

View file

@ -1694,8 +1694,10 @@ t_stat sim_instr (void)
t_stat fast_clk (UNIT * this)
{
static unsigned counter;
static unsigned tty_counter;
++counter;
++tty_counter;
/*besm6_debug ("*** таймер 20 мсек");*/
GRP |= GRP_TIMER;
@ -1713,6 +1715,14 @@ t_stat fast_clk (UNIT * this)
redraw_panel = 1;
}
/* Baudot TTYs are synchronised to the main timer rather than the
* serial line clock. Their baud rate is 50.
*/
if (tty_counter == CLK_TPS/50) {
tt_print();
tty_counter = 0;
}
tmr_poll = sim_rtcn_calb (CLK_TPS, 0); /* calibrate clock */
return sim_activate_after (this, 1000000/CLK_TPS); /* reactivate unit */
}

View file

@ -334,6 +334,7 @@ void printer_hammer (int num, int pos, uint32 mask);
void tty_send (uint32 mask);
int tty_query (void);
void vt_print (void);
void tt_print (void);
void vt_receive (void);
void consul_print (int num, uint32 cmd);
uint32 consul_read (int num);

View file

@ -213,7 +213,9 @@ t_stat disk_attach (UNIT *u, char *cptr)
}
return SCPE_OK;
}
if (saved_switches & SWMASK ('E'))
if (s == SCPE_OK ||
(saved_switches & SWMASK ('E')) ||
(sim_switches & SWMASK('N')))
return s;
sim_switches |= SWMASK ('N');
}

View file

@ -184,8 +184,6 @@ t_stat vt_clk (UNIT * this)
{
int num;
/* Baudot TTYs work at 10 baud */
static int clk_divider = 1<<29;
GRP |= MGRP & GRP_SERIAL;
/* Polling receiving from sockets */
@ -195,12 +193,6 @@ t_stat vt_clk (UNIT * this)
vt_receive();
consul_receive();
if (! (clk_divider >>= 1)) {
tt_print();
/* Input from Baudot TTYs not implemented */
clk_divider = 1<<29;
}
/* Are there any new network connections? */
num = tmxr_poll_conn (&tty_desc);
if (num > 0 && num <= LINES_MAX) {

View file

@ -1175,7 +1175,7 @@ ifneq (,${VIDEO_LDFLAGS})
ifeq (,${FONTFILE})
FONTPATH += /usr/share/fonts /Library/Fonts /usr/lib/jvm /System/Library/Frameworks/JavaVM.framework/Versions
FONTPATH := $(dir $(foreach dir,$(strip $(FONTPATH)),$(wildcard $(dir)/.)))
FONTNAME += LucidaSansRegular.ttf FreeSans.ttf
FONTNAME += DejaVuSans.ttf LucidaSansRegular.ttf FreeSans.ttf
$(info font paths are: $(FONTPATH))
$(info font names are: $(FONTNAME))
find_fontfile = $(strip $(firstword $(foreach dir,$(strip $(FONTPATH)),$(wildcard $(dir)/$(1))$(wildcard $(dir)/*/$(1))$(wildcard $(dir)/*/*/$(1))$(wildcard $(dir)/*/*/*/$(1)))))