From 6fa8f6012c63d0b2f00ed8825bb0960cdf0a6fb5 Mon Sep 17 00:00:00 2001 From: Mark Pizzolato Date: Sat, 15 Dec 2018 12:55:54 -0800 Subject: [PATCH] PDP8: Add device descriptions to all devices --- PDP8/pdp8_clk.c | 10 +++++++++- PDP8/pdp8_ct.c | 10 +++++++++- PDP8/pdp8_df.c | 10 +++++++++- PDP8/pdp8_dt.c | 9 ++++++++- PDP8/pdp8_fpp.c | 10 +++++++++- PDP8/pdp8_lp.c | 10 +++++++++- PDP8/pdp8_mt.c | 10 +++++++++- PDP8/pdp8_pt.c | 21 +++++++++++++++++++-- PDP8/pdp8_rf.c | 10 +++++++++- PDP8/pdp8_rk.c | 10 +++++++++- PDP8/pdp8_rl.c | 10 +++++++++- PDP8/pdp8_rx.c | 10 +++++++++- PDP8/pdp8_td.c | 9 ++++++++- PDP8/pdp8_tsc.c | 10 +++++++++- PDP8/pdp8_tt.c | 20 ++++++++++++++++++-- PDP8/pdp8_ttx.c | 17 +++++++++++++++-- 16 files changed, 167 insertions(+), 19 deletions(-) diff --git a/PDP8/pdp8_clk.c b/PDP8/pdp8_clk.c index 08fe879e..1f21c70e 100644 --- a/PDP8/pdp8_clk.c +++ b/PDP8/pdp8_clk.c @@ -49,6 +49,7 @@ t_stat clk_svc (UNIT *uptr); t_stat clk_reset (DEVICE *dptr); t_stat clk_set_freq (UNIT *uptr, int32 val, CONST char *cptr, void *desc); t_stat clk_show_freq (FILE *st, UNIT *uptr, int32 val, CONST void *desc); +const char *clk_description (DEVICE *dptr); /* CLK data structures @@ -86,7 +87,9 @@ DEVICE clk_dev = { 1, 0, 0, 0, 0, 0, NULL, NULL, &clk_reset, NULL, NULL, NULL, - &clk_dib, 0 + &clk_dib, 0, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &clk_description }; /* IOT routine @@ -181,3 +184,8 @@ t_stat clk_show_freq (FILE *st, UNIT *uptr, int32 val, CONST void *desc) fprintf (st, (clk_tps == 50)? "50Hz": "60Hz"); return SCPE_OK; } + +const char *clk_description (DEVICE *dptr) +{ +return "real time clock"; +} diff --git a/PDP8/pdp8_ct.c b/PDP8/pdp8_ct.c index 1db5942d..8015cba9 100644 --- a/PDP8/pdp8_ct.c +++ b/PDP8/pdp8_ct.c @@ -162,6 +162,7 @@ t_stat ct_reset (DEVICE *dptr); t_stat ct_attach (UNIT *uptr, CONST char *cptr); t_stat ct_detach (UNIT *uptr); t_stat ct_boot (int32 unitno, DEVICE *dptr); +const char *ct_description (DEVICE *dptr); uint32 ct_updsta (UNIT *uptr); int32 ct_go_start (int32 AC); int32 ct_go_cont (UNIT *uptr, int32 AC); @@ -225,7 +226,9 @@ DEVICE ct_dev = { CT_NUMDR, 10, 31, 1, 8, 8, NULL, NULL, &ct_reset, &ct_boot, &ct_attach, &ct_detach, - &ct_dib, DEV_DISABLE | DEV_DIS | DEV_DEBUG | DEV_TAPE + &ct_dib, DEV_DISABLE | DEV_DIS | DEV_DEBUG | DEV_TAPE, + 0, NULL, NULL, NULL, NULL, NULL, NULL, + &ct_description }; /* IOT routines */ @@ -727,3 +730,8 @@ for (i = 0; i < BOOT_LEN; i++) cpu_set_bootpc (BOOT_START); return SCPE_OK; } + +const char *ct_description (DEVICE *dptr) +{ +return "TA8E/TU60 cassette tape"; +} diff --git a/PDP8/pdp8_df.c b/PDP8/pdp8_df.c index b7b386af..52e644b9 100644 --- a/PDP8/pdp8_df.c +++ b/PDP8/pdp8_df.c @@ -117,6 +117,7 @@ t_stat df_reset (DEVICE *dptr); t_stat df_boot (int32 unitno, DEVICE *dptr); t_stat df_attach (UNIT *uptr, CONST char *cptr); t_stat df_set_size (UNIT *uptr, int32 val, CONST char *cptr, void *desc); +const char *df_description (DEVICE *dptr); /* DF32 data structures @@ -164,7 +165,9 @@ DEVICE df_dev = { 1, 8, 17, 1, 8, 12, NULL, NULL, &df_reset, &df_boot, &df_attach, NULL, - &df_dib, DEV_DISABLE + &df_dib, DEV_DISABLE, + 0, NULL, NULL, NULL, NULL, NULL, NULL, + &df_description }; /* IOT routines */ @@ -380,3 +383,8 @@ uptr->capac = UNIT_GETP (val) * DF_DKSIZE; uptr->flags = uptr->flags & ~UNIT_AUTO; return SCPE_OK; } + +const char *df_description (DEVICE *dptr) +{ +return "DF32 fixed head disk"; +} diff --git a/PDP8/pdp8_dt.c b/PDP8/pdp8_dt.c index 7685fa74..2e29f394 100644 --- a/PDP8/pdp8_dt.c +++ b/PDP8/pdp8_dt.c @@ -282,6 +282,7 @@ int32 dt77 (int32 IR, int32 AC); t_stat dt_svc (UNIT *uptr); t_stat dt_reset (DEVICE *dptr); t_stat dt_attach (UNIT *uptr, CONST char *cptr); +const char *dt_description (DEVICE *dptr); void dt_flush (UNIT *uptr); t_stat dt_detach (UNIT *uptr); t_stat dt_boot (int32 unitno, DEVICE *dptr); @@ -372,7 +373,8 @@ DEVICE dt_dev = { NULL, NULL, &dt_reset, &dt_boot, &dt_attach, &dt_detach, &dt_dib, DEV_DISABLE | DEV_DEBUG, 0, - dt_deb, NULL, NULL + dt_deb, NULL, NULL, NULL, NULL, NULL, + &dt_description }; /* IOT routines */ @@ -1347,3 +1349,8 @@ uptr->flags = (uptr->flags | UNIT_8FMT) & ~UNIT_11FMT; /* default fmt */ uptr->capac = DT_CAPAC; /* default size */ return detach_unit (uptr); } + +const char *dt_description (DEVICE *dptr) +{ +return "TC08/TU56 DECtape"; +} diff --git a/PDP8/pdp8_fpp.c b/PDP8/pdp8_fpp.c index 550f5a3a..18501c11 100644 --- a/PDP8/pdp8_fpp.c +++ b/PDP8/pdp8_fpp.c @@ -208,6 +208,7 @@ uint32 apt_read (uint32 ea); void apt_write (uint32 ea, uint32 val); t_stat fpp_svc (UNIT *uptr); t_stat fpp_reset (DEVICE *dptr); +const char *fpp_description (DEVICE *dptr); /* FPP data structures @@ -246,7 +247,9 @@ DEVICE fpp_dev = { 1, 10, 31, 1, 8, 8, NULL, NULL, &fpp_reset, NULL, NULL, NULL, - &fpp_dib, DEV_DISABLE | DEV_DIS + &fpp_dib, DEV_DISABLE | DEV_DIS, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &fpp_description }; /* IOT routines */ @@ -1511,3 +1514,8 @@ else { return SCPE_OK; } + +const char *fpp_description (DEVICE *dptr) +{ +return "FPP8A floating point processor"; +} diff --git a/PDP8/pdp8_lp.c b/PDP8/pdp8_lp.c index 9e1588e9..c1f40534 100644 --- a/PDP8/pdp8_lp.c +++ b/PDP8/pdp8_lp.c @@ -44,6 +44,7 @@ t_stat lpt_svc (UNIT *uptr); t_stat lpt_reset (DEVICE *dptr); t_stat lpt_attach (UNIT *uptr, CONST char *cptr); t_stat lpt_detach (UNIT *uptr); +const char *lpt_description (DEVICE *dptr); /* LPT data structures @@ -82,7 +83,9 @@ DEVICE lpt_dev = { 1, 10, 31, 1, 8, 8, NULL, NULL, &lpt_reset, NULL, &lpt_attach, &lpt_detach, - &lpt_dib, DEV_DISABLE + &lpt_dib, DEV_DISABLE, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &lpt_description }; /* IOT routine */ @@ -186,3 +189,8 @@ t_stat lpt_detach (UNIT *uptr) lpt_err = 1; return detach_unit (uptr); } + +const char *lpt_description (DEVICE *dptr) +{ +return "LP8E line printer"; +} diff --git a/PDP8/pdp8_mt.c b/PDP8/pdp8_mt.c index 3a0edb51..3a9ea66c 100644 --- a/PDP8/pdp8_mt.c +++ b/PDP8/pdp8_mt.c @@ -152,6 +152,7 @@ t_stat mt_svc (UNIT *uptr); t_stat mt_reset (DEVICE *dptr); t_stat mt_attach (UNIT *uptr, CONST char *cptr); t_stat mt_detach (UNIT *uptr); +const char *mt_description (DEVICE *dptr); int32 mt_updcsta (UNIT *uptr); int32 mt_ixma (int32 xma); t_stat mt_map_err (UNIT *uptr, t_stat st); @@ -216,7 +217,9 @@ DEVICE mt_dev = { MT_NUMDR, 10, 31, 1, 8, 8, NULL, NULL, &mt_reset, NULL, &mt_attach, &mt_detach, - &mt_dib, DEV_DISABLE | DEV_TAPE + &mt_dib, DEV_DISABLE | DEV_TAPE, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &mt_description }; /* IOT routines */ @@ -659,3 +662,8 @@ if (u == GET_UNIT (mt_cu)) mt_updcsta (uptr); return SCPE_OK; } + +const char *mt_description (DEVICE *dptr) +{ +return "TM8E/TU10 magtape"; +} diff --git a/PDP8/pdp8_pt.c b/PDP8/pdp8_pt.c index 70bb9605..404a2524 100644 --- a/PDP8/pdp8_pt.c +++ b/PDP8/pdp8_pt.c @@ -47,6 +47,8 @@ t_stat ptp_svc (UNIT *uptr); t_stat ptr_reset (DEVICE *dptr); t_stat ptp_reset (DEVICE *dptr); t_stat ptr_boot (int32 unitno, DEVICE *dptr); +const char *ptr_description (DEVICE *dptr); +const char *ptp_description (DEVICE *dptr); /* PTR data structures @@ -83,7 +85,10 @@ DEVICE ptr_dev = { 1, 10, 31, 1, 8, 8, NULL, NULL, &ptr_reset, &ptr_boot, NULL, NULL, - &ptr_dib, 0 }; + &ptr_dib, 0, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &ptr_description + }; /* PTP data structures @@ -119,7 +124,9 @@ DEVICE ptp_dev = { 1, 10, 31, 1, 8, 8, NULL, NULL, &ptp_reset, NULL, NULL, NULL, - &ptp_dib, 0 + &ptp_dib, 0, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &ptp_description }; /* Paper tape reader: IOT routine */ @@ -291,3 +298,13 @@ for (i = 0; i < BOOT_LEN; i++) cpu_set_bootpc (BOOT_START); return SCPE_OK; } + +const char *ptr_description (DEVICE *dptr) +{ +return "PC8E paper tape reader"; +} + +const char *ptp_description (DEVICE *dptr) +{ +return "PC8E paper tape punch"; +} diff --git a/PDP8/pdp8_rf.c b/PDP8/pdp8_rf.c index 4ea1dc61..b9072545 100644 --- a/PDP8/pdp8_rf.c +++ b/PDP8/pdp8_rf.c @@ -127,6 +127,7 @@ t_stat rf_reset (DEVICE *dptr); t_stat rf_boot (int32 unitno, DEVICE *dptr); t_stat rf_attach (UNIT *uptr, CONST char *cptr); t_stat rf_set_size (UNIT *uptr, int32 val, CONST char *cptr, void *desc); +const char *rf_description (DEVICE *dptr); /* RF08 data structures @@ -177,7 +178,9 @@ DEVICE rf_dev = { 1, 8, 20, 1, 8, 12, NULL, NULL, &rf_reset, &rf_boot, &rf_attach, NULL, - &rf_dib, DEV_DISABLE | DEV_DIS + &rf_dib, DEV_DISABLE | DEV_DIS, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &rf_description }; /* IOT routines */ @@ -446,3 +449,8 @@ uptr->capac = UNIT_GETP (val) * RF_DKSIZE; uptr->flags = uptr->flags & ~UNIT_AUTO; return SCPE_OK; } + +const char *rf_description (DEVICE *dptr) +{ +return "RF08 fixed head disk"; +} diff --git a/PDP8/pdp8_rk.c b/PDP8/pdp8_rk.c index 5a350c18..1074d703 100644 --- a/PDP8/pdp8_rk.c +++ b/PDP8/pdp8_rk.c @@ -142,6 +142,7 @@ int32 rk (int32 IR, int32 AC); t_stat rk_svc (UNIT *uptr); t_stat rk_reset (DEVICE *dptr); t_stat rk_boot (int32 unitno, DEVICE *dptr); +const char *rk_description (DEVICE *dptr); void rk_go (int32 function, int32 cylinder); /* RK-8E data structures @@ -192,7 +193,9 @@ DEVICE rk_dev = { RK_NUMDR, 8, 24, 1, 8, 12, NULL, NULL, &rk_reset, &rk_boot, NULL, NULL, - &rk_dib, DEV_DISABLE + &rk_dib, DEV_DISABLE, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &rk_description }; /* IOT routine */ @@ -461,3 +464,8 @@ M[BOOT_UNIT] = (unitno & RK_M_NUMDR) << 1; cpu_set_bootpc (BOOT_START); return SCPE_OK; } + +const char *rk_description (DEVICE *dptr) +{ +return "RK8E/RK05 cartridge disk"; +} diff --git a/PDP8/pdp8_rl.c b/PDP8/pdp8_rl.c index d559a58c..aec1220f 100644 --- a/PDP8/pdp8_rl.c +++ b/PDP8/pdp8_rl.c @@ -183,6 +183,7 @@ t_stat rl_boot (int32 unitno, DEVICE *dptr); t_stat rl_attach (UNIT *uptr, CONST char *cptr); t_stat rl_set_size (UNIT *uptr, int32 val, CONST char *cptr, void *desc); t_stat rl_set_bad (UNIT *uptr, int32 val, CONST char *cptr, void *desc); +const char *rl_description (DEVICE *dptr); /* RL8A data structures @@ -251,7 +252,9 @@ DEVICE rl_dev = { RL_NUMDR, 8, 24, 1, 8, 8, NULL, NULL, &rl_reset, &rl_boot, &rl_attach, NULL, - &rl_dib, DEV_DISABLE | DEV_DIS + &rl_dib, DEV_DISABLE | DEV_DIS, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &rl_description }; /* IOT routines */ @@ -701,3 +704,8 @@ for (i = 0; i < BOOT_LEN; i++) cpu_set_bootpc (BOOT_START); return SCPE_OK; } + +const char *rl_description (DEVICE *dptr) +{ +return "RL8A cartridge disk"; +} diff --git a/PDP8/pdp8_rx.c b/PDP8/pdp8_rx.c index 6aea2f85..27c84650 100644 --- a/PDP8/pdp8_rx.c +++ b/PDP8/pdp8_rx.c @@ -147,6 +147,7 @@ void rx_cmd (void); void rx_done (int32 esr_flags, int32 new_ecode); t_stat rx_settype (UNIT *uptr, int32 val, CONST char *cptr, void *desc); t_stat rx_showtype (FILE *st, UNIT *uptr, int32 val, CONST void *desc); +const char *rx_description (DEVICE *dptr); /* RX8E data structures @@ -215,7 +216,9 @@ DEVICE rx_dev = { RX_NUMDR, 8, 20, 1, 8, 8, NULL, NULL, &rx_reset, &rx_boot, &rx_attach, NULL, - &rx_dib, DEV_DISABLE + &rx_dib, DEV_DISABLE, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &rx_description }; /* IOT routine */ @@ -752,3 +755,8 @@ else { } return SCPE_OK; } + +const char *rx_description (DEVICE *dptr) +{ +return "RX8E/RX01, RX28/RX02 floppy disk"; +} diff --git a/PDP8/pdp8_td.c b/PDP8/pdp8_td.c index 7cfaa942..7ae902f0 100644 --- a/PDP8/pdp8_td.c +++ b/PDP8/pdp8_td.c @@ -208,6 +208,7 @@ int32 td_read (UNIT *uptr, int32 blk, int32 line); void td_write (UNIT *uptr, int32 blk, int32 line, int32 datb); int32 td_set_mtk (int32 code, int32 u, int32 k); t_stat td_show_pos (FILE *st, UNIT *uptr, int32 val, CONST void *desc); +const char *td_description (DEVICE *dptr); extern uint16 M[]; @@ -267,7 +268,9 @@ DEVICE td_dev = { DT_NUMDR, 8, 24, 1, 8, 12, NULL, NULL, &td_reset, &td_boot, &td_attach, &td_detach, - &td_dib, DEV_DISABLE | DEV_DIS + &td_dib, DEV_DISABLE | DEV_DIS, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &td_description }; /* IOT routines */ @@ -953,3 +956,7 @@ else fprintf (st, "Forward end zone\n"); /* fwd end zone */ return SCPE_OK; } +const char *td_description (DEVICE *dptr) +{ +return "TD8E/TU56 DECtape"; +} diff --git a/PDP8/pdp8_tsc.c b/PDP8/pdp8_tsc.c index 8ae91948..33d5aa93 100644 --- a/PDP8/pdp8_tsc.c +++ b/PDP8/pdp8_tsc.c @@ -62,6 +62,7 @@ extern int32 tsc_enb; /* enable */ int32 tsc (int32 IR, int32 AC); t_stat tsc_reset (DEVICE *dptr); +const char *tsc_description (DEVICE *dptr); /* TSC data structures @@ -94,7 +95,9 @@ DEVICE tsc_dev = { 1, 10, 31, 1, 8, 8, NULL, NULL, &tsc_reset, NULL, NULL, NULL, - &tsc_dib, DEV_DISABLE | DEV_DIS + &tsc_dib, DEV_DISABLE | DEV_DIS, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &tsc_description }; /* IOT routine */ @@ -156,3 +159,8 @@ tsc_enb = 0; int_req = int_req & ~INT_TSC; return SCPE_OK; } + +const char *tsc_description (DEVICE *dptr) +{ +return "TSC8-75 option board"; +} diff --git a/PDP8/pdp8_tt.c b/PDP8/pdp8_tt.c index fa2a6025..2a13dc8e 100644 --- a/PDP8/pdp8_tt.c +++ b/PDP8/pdp8_tt.c @@ -55,6 +55,8 @@ t_stat tto_svc (UNIT *uptr); t_stat tti_reset (DEVICE *dptr); t_stat tto_reset (DEVICE *dptr); t_stat tty_set_mode (UNIT *uptr, int32 val, CONST char *cptr, void *desc); +const char *tti_description (DEVICE *dptr); +const char *tto_description (DEVICE *dptr); /* TTI data structures @@ -92,7 +94,9 @@ DEVICE tti_dev = { 1, 10, 31, 1, 8, 8, NULL, NULL, &tti_reset, NULL, NULL, NULL, - &tti_dib, 0 + &tti_dib, 0, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &tti_description }; uint32 tti_buftime; /* time input character arrived */ @@ -132,7 +136,9 @@ DEVICE tto_dev = { 1, 10, 31, 1, 8, 8, NULL, NULL, &tto_reset, NULL, NULL, NULL, - &tto_dib, 0 + &tto_dib, 0, 0, + NULL, NULL, NULL, NULL, NULL, NULL, + &tti_description }; /* Terminal input: IOT routine */ @@ -283,3 +289,13 @@ tti_unit.flags = (tti_unit.flags & ~TT_MODE) | val; tto_unit.flags = (tto_unit.flags & ~TT_MODE) | val; return SCPE_OK; } + +const char *tti_description (DEVICE *dptr) +{ +return "console terminal input"; +} + +const char *tto_description (DEVICE *dptr) +{ +return "console terminal output"; +} diff --git a/PDP8/pdp8_ttx.c b/PDP8/pdp8_ttx.c index fa29c6bf..251e6dfe 100644 --- a/PDP8/pdp8_ttx.c +++ b/PDP8/pdp8_ttx.c @@ -88,6 +88,8 @@ void ttx_new_flags (uint32 newi, uint32 newo, uint32 newe); t_stat ttx_reset (DEVICE *dptr); t_stat ttx_attach (UNIT *uptr, CONST char *cptr); t_stat ttx_detach (UNIT *uptr); +const char *ttix_description (DEVICE *dptr); +const char *ttox_description (DEVICE *dptr); void ttx_reset_ln (int32 i); t_stat ttx_vlines (UNIT *uptr, int32 val, CONST char *cptr, void *desc); t_stat ttx_show_devno (FILE *st, UNIT *uptr, int32 val, CONST void *desc); @@ -176,7 +178,8 @@ DEVICE ttix_dev = { &tmxr_ex, &tmxr_dep, &ttx_reset, NULL, &ttx_attach, &ttx_detach, &ttx_dib, DEV_MUX | DEV_DISABLE | DEV_DEBUG, - 0, ttx_debug + 0, ttx_debug, NULL, NULL, NULL, NULL, NULL, + &ttix_description }; /* TTOx data structures @@ -237,7 +240,8 @@ DEVICE ttox_dev = { NULL, NULL, &ttx_reset, NULL, NULL, NULL, NULL, DEV_DISABLE | DEV_DEBUG, - 0, ttx_debug + 0, ttx_debug, NULL, NULL, NULL, NULL, NULL, + &ttox_description }; /* Terminal input: IOT routine */ @@ -544,3 +548,12 @@ for (i = 0; i < ttx_lines; i++) { return SCPE_OK; } +const char *ttix_description (DEVICE *dptr) +{ +return "PT08/KL8JA terminal input"; +} + +const char *ttox_description (DEVICE *dptr) +{ +return "PT08/KL8JA terminal output"; +}