From f2ca388f9c33848ffdf8205c2cf3dd7cabaf63cd Mon Sep 17 00:00:00 2001 From: Mark Pizzolato Date: Fri, 3 Apr 2015 19:53:39 -0700 Subject: [PATCH] GRI, PDP1, S3, SDS: Forwardport of Bob Supnik's merge from the master branch (change to sim_printf) --- GRI/gri_cpu.c | 2 +- GRI/gri_defs.h | 2 +- GRI/gri_stddev.c | 3 ++- GRI/gri_sys.c | 2 +- PDP1/pdp1_cpu.c | 10 +++++----- PDP1/pdp1_dt.c | 3 ++- PDP1/pdp1_stddev.c | 3 ++- PDP1/pdp1_sys.c | 3 ++- S3/s3_cd.c | 2 +- S3/s3_cpu.c | 6 +++--- S3/s3_disk.c | 2 +- S3/s3_lp.c | 2 +- S3/s3_pkb.c | 2 +- SDS/sds_mux.c | 2 +- 14 files changed, 24 insertions(+), 20 deletions(-) diff --git a/GRI/gri_cpu.c b/GRI/gri_cpu.c index c3b35d5c..65cbb45c 100644 --- a/GRI/gri_cpu.c +++ b/GRI/gri_cpu.c @@ -1,6 +1,6 @@ /* gri_cpu.c: GRI-909 CPU simulator - Copyright (c) 2001-2008, Robert M. Supnik + Copyright (c) 2001-2015, Robert M. Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/GRI/gri_defs.h b/GRI/gri_defs.h index 0f199c33..82e8fb7e 100644 --- a/GRI/gri_defs.h +++ b/GRI/gri_defs.h @@ -1,6 +1,6 @@ /* gri_defs.h: GRI-909 simulator definitions - Copyright (c) 2001-2010, Robert M. Supnik + Copyright (c) 2001-2015, Robert M. Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/GRI/gri_stddev.c b/GRI/gri_stddev.c index 80373b52..b05fc6cd 100644 --- a/GRI/gri_stddev.c +++ b/GRI/gri_stddev.c @@ -1,6 +1,6 @@ /* gri_stddev.c: GRI-909 standard devices - Copyright (c) 2001-2008, Robert M Supnik + Copyright (c) 2001-2015, Robert M Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -29,6 +29,7 @@ hsp S42-006 high speed punch rtc real time clock + 28-Mar-15 RMS Revised to use sim_printf 31-May-08 RMS Fixed declarations (Peter Schorn) 30-Sep-06 RMS Fixed handling of non-printable characters in KSR mode 22-Nov-05 RMS Revised for new terminal processing routines diff --git a/GRI/gri_sys.c b/GRI/gri_sys.c index 5ef2c248..65da9cbd 100644 --- a/GRI/gri_sys.c +++ b/GRI/gri_sys.c @@ -1,6 +1,6 @@ /* gri_sys.c: GRI-909 simulator interface - Copyright (c) 2001-2008, Robert M Supnik + Copyright (c) 2001-2015, Robert M Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/PDP1/pdp1_cpu.c b/PDP1/pdp1_cpu.c index b59c469e..2a9953bb 100644 --- a/PDP1/pdp1_cpu.c +++ b/PDP1/pdp1_cpu.c @@ -1,6 +1,6 @@ /* pdp1_cpu.c: PDP-1 CPU simulator - Copyright (c) 1993-2012, Robert M. Supnik + Copyright (c) 1993-2015, Robert M. Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -25,6 +25,7 @@ cpu PDP-1 central processor + 27-Mar-15 RMS Backported changed from GitHub master 21-Mar-12 RMS Fixed & vs && in Ea_ch (Michael Bloom) 30-May-07 RMS Fixed typo in SBS clear (Norm Lastovica) 28-Dec-06 RMS Added 16-channel SBS support, PDP-1D support @@ -1703,15 +1704,14 @@ return SCPE_OK; #ifdef USE_DISPLAY /* set "test switches"; from display code */ -void -cpu_set_switches(unsigned long bits) + +void cpu_set_switches(unsigned long bits) { /* just what we want; smaller CPUs might want to shift down? */ TW = bits; } -unsigned long -cpu_get_switches(void) +unsigned long cpu_get_switches(void) { return TW; } diff --git a/PDP1/pdp1_dt.c b/PDP1/pdp1_dt.c index 602d0dd1..f9bd69a5 100644 --- a/PDP1/pdp1_dt.c +++ b/PDP1/pdp1_dt.c @@ -1,6 +1,6 @@ /* pdp1_dt.c: 18b DECtape simulator - Copyright (c) 1993-2008, Robert M Supnik + Copyright (c) 1993-2015, Robert M Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -25,6 +25,7 @@ dt Type 550/555 DECtape + 28-Mar-15 RMS Revised to use sim_printf 21-Dec-06 RMS Added 16-channel SBS support 23-Jun-06 RMS Fixed conflict in ATTACH switches Revised header format diff --git a/PDP1/pdp1_stddev.c b/PDP1/pdp1_stddev.c index f5e5ab8c..a2f64cef 100644 --- a/PDP1/pdp1_stddev.c +++ b/PDP1/pdp1_stddev.c @@ -1,6 +1,6 @@ /* pdp1_stddev.c: PDP-1 standard devices - Copyright (c) 1993-2012, Robert M. Supnik + Copyright (c) 1993-2015, Robert M. Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -28,6 +28,7 @@ tti keyboard tto teleprinter + 28-Mar-15 RMS Revised to use sim_printf 21-Mar-12 RMS Fixed unitialized variable in tto_svc (Michael Bloom) 21-Dec-06 RMS Added 16-channel sequence break support 29-Oct-03 RMS Added PTR FIODEC-to-ASCII translation (Phil Budne) diff --git a/PDP1/pdp1_sys.c b/PDP1/pdp1_sys.c index 3880c7af..b9dc6a60 100644 --- a/PDP1/pdp1_sys.c +++ b/PDP1/pdp1_sys.c @@ -1,6 +1,6 @@ /* pdp1_sys.c: PDP-1 simulator interface - Copyright (c) 1993-2008, Robert M. Supnik + Copyright (c) 1993-2015, Robert M. Supnik Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -23,6 +23,7 @@ used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from Robert M Supnik. + 27-Mar-15 RMS Backported changes from GitHub master 03-Jan-07 RMS Fixed bugs in block loader, char input 21-Dec-06 RMS Added 16-channel sequence break support, PDP-1D support 06-Apr-04 RMS Fixed bug in binary loader (found by Mark Crispin) diff --git a/S3/s3_cd.c b/S3/s3_cd.c index 87f6af40..7c5b2423 100644 --- a/S3/s3_cd.c +++ b/S3/s3_cd.c @@ -264,7 +264,7 @@ int32 crd (int32 op, int32 m, int32 n, int32 data) default: break; } - printf (">>CRD non-existent function %d\n", op); + sim_printf (">>CRD non-existent function %d\n", op); return SCPE_OK; } diff --git a/S3/s3_cpu.c b/S3/s3_cpu.c index b732cbe1..e4a37400 100644 --- a/S3/s3_cpu.c +++ b/S3/s3_cpu.c @@ -609,12 +609,12 @@ if (opaddr == 0xf0) { /* Is it command format? if (qbyte & 0x01) display[2][3] = '|' ; if (rbyte & 0x01) display[2][7] = '|' ; /* Print display segment array */ - printf("\n\r"); + sim_printf("\n"); for (i = 0; i < 3; i++) { for (j = 0; j < 9; j++) { - printf ("%c", display[i][j]); + sim_printf ("%c", display[i][j]); } - printf ("\n\r"); + sim_printf ("\n"); } reason = STOP_HALT; break; diff --git a/S3/s3_disk.c b/S3/s3_disk.c index f0a2ed20..1faea2e5 100644 --- a/S3/s3_disk.c +++ b/S3/s3_disk.c @@ -610,7 +610,7 @@ int32 dsk (int32 disk, int32 op, int32 m, int32 n, int32 data) default: break; } - printf (">>DSK%d non-existent function %d\n", disk, op); + sim_printf (">>DSK%d non-existent function %d\n", disk, op); return SCPE_OK; } diff --git a/S3/s3_lp.c b/S3/s3_lp.c index 99f85af4..a0507f50 100644 --- a/S3/s3_lp.c +++ b/S3/s3_lp.c @@ -203,7 +203,7 @@ int32 lpt (int32 op, int32 m, int32 n, int32 data) default: break; } - printf (">>LPT non-existent function %d\n", op); + sim_printf (">>LPT non-existent function %d\n", op); return SCPE_OK; } diff --git a/S3/s3_pkb.c b/S3/s3_pkb.c index 461fc736..7dcdd4d4 100644 --- a/S3/s3_pkb.c +++ b/S3/s3_pkb.c @@ -231,7 +231,7 @@ int32 pkb (int32 op, int32 m, int32 n, int32 data) default: break; } - printf (">>PKB non-existent function %d\n", op); + sim_printf (">>PKB non-existent function %d\n", op); return SCPE_OK; } diff --git a/SDS/sds_mux.c b/SDS/sds_mux.c index e5cc0aec..64e22794 100644 --- a/SDS/sds_mux.c +++ b/SDS/sds_mux.c @@ -113,7 +113,7 @@ uint32 mux_tps = 100; /* polls/second */ uint32 mux_scan = 0; /* scanner */ uint32 mux_slck = 0; /* scanner locked */ -TMLN mux_ldsc[MUX_LINES] = { {0} }; /* line descriptors */ +TMLN mux_ldsc[MUX_LINES] = { {0} }; /* line descriptors */ TMXR mux_desc = { MUX_LINES, 0, 0, mux_ldsc }; /* mux descriptor */ t_stat mux (uint32 fnc, uint32 inst, uint32 *dat);