Commit graph

51 commits

Author SHA1 Message Date
Olaf Seibert
3a95ba4b34 Replace standard in32_t by local int32 type. 2022-10-13 22:29:06 +02:00
Olaf Seibert
7b494542ef Harmonize calibration code amongst VAXen.
Take the version of the code from VAX/vax4nn_stddev.c and vax4xx_stddev.c,
and apply it to 730, 750, 780, 820 and 860.
If we can assume that clk_tps always remains 100, this can be simplified
further.
2022-10-05 18:53:16 +02:00
Mark Pizzolato
243951a791 Unibus and Qbus VAX systems: Update TODR help information 2021-07-14 11:00:23 -07:00
Mark Pizzolato
68e407ba0f ALL: Correct help text in "SET <unit> LOCKED" MTAB entries 2021-04-19 15:22:15 -07:00
Mark Pizzolato
a015e44c10 ALL: Standardize writelock behavior adding global UNIT_WLK & UNIT_WPRT
Historically this functionality was reimplemented within each
DEVICE simulator often with slightly different implementations
and inconsistencies.  Solving this globally within SCP required
changes in many places, but should henceforth be reasonably
managed.

As discussed in #1034
2021-04-19 10:58:51 -07:00
Mark Pizzolato
0d6f1ce362 All VAX: Remove redundant include of time.h 2020-10-30 14:17:24 -07:00
Mark Pizzolato
4db4f90429 VAX, Unibus VAX: Record explicit TODR set immediately to backing store
- Only if backing store is used (i.e. OS Agnostic mode)
- Previously this was only done on a clean simulator exit.  That could
  result in inconsistent timing information in operating system images vs
  the saved TODR baseline data
- Always return TODR values rounded to the TODR granularity (10ms).
2020-10-09 05:10:34 -07:00
Mark Pizzolato
027c1de446 Unibus VAXen: Clock Coschedule interval timers when intervals are 10ms
Record 10ms tick acknowledgements
2020-01-10 08:19:27 -08:00
Mark Pizzolato
f9e4e9efba Unibus VAXen: Avoid trying to make interval timers calibrated clocks
Programmatic interval timers are not proper candidates for calibrated
clocks since the interval values can change arbitrarily under program
control and then interfer with attempts at proper calibration.
2020-01-09 23:37:06 -08:00
Mark Pizzolato
74a640d04a All VAX: Properly record clock tick acknowledgments 2018-10-08 22:33:00 -07:00
Matt Burke
f6d4e92c6d VAX8600: Marked intentional fall through of case statement CID: 1415576 2017-04-26 15:27:44 -07:00
Bob Supnik
3eb4598456 SCP: Removed KBD_WAIT and friends 2017-03-20 22:33:38 -07:00
Mark Pizzolato
724b23844c VAX730, VAX750, VAX780, VAX8600: Fix rounding with interval timer tick rate
As discussed in #390
2017-01-31 18:15:38 -08:00
Mark Pizzolato
acbb92091b VAX: Add slightly more precise TODR initialization logic with debug support 2017-01-19 16:56:40 -08:00
Mark Pizzolato
1bb42b83ef VAX730, VAX750, VAX780, VAX8600: Make TODR a little more precise
Add consistent debug options to track TODR activities and the values which
are set.  Debug data will display the VMS time related to the values set and
read.
2017-01-19 15:25:08 -08:00
Mark Pizzolato
5cd0ea4d59 VAX730, VAX750, VAX780, VAX8600: Fix interval timer ics value
- When the running timer is explicitly stopped the ics value needs to be
    determined before canceling the active unit.
2017-01-18 23:57:14 -08:00
Mark Pizzolato
d456bac8fc All VAX: Simplify interval timers to leverage new usec timing APIs 2016-12-30 10:34:29 -08:00
Mark Pizzolato
75901333e5 VAX780, VAX730, VAX750, VAX8600: Moved the TPS register to the TMR device
Clock ticks for these simulatrs are performed by programmatic setup of the
interval timer device (TMR) and have nothing to do with the TODR which
increments at 100Hz, but doesn't generate ticks to the simulated system.
2016-12-29 06:05:53 -08:00
Mark Pizzolato
372231dd3a VAX8600, VAX750: Pass correct delay to TTI device sim_clock_coschedule 2016-12-17 11:51:05 -08:00
Mark Pizzolato
76103cf760 VAX730, VAX750, VAX8600: Update Interval Timer and TODR to align with VAX780 2016-12-16 18:32:26 -08:00
Mark Pizzolato
eea394422e VAX, VAX750, VAX780, VAX8600: Properly coschedule console input with TMXR_MULT
The timer specific coscheduling routines take ticks as the delay argument
2016-12-12 01:53:49 -08:00
Mark Pizzolato
1c3c50fd26 VAX, VAX780, VAX750, VAX8600: Make TODR state file endian independent
When the TODR device (CLK) is attached to a state file, it operates in OS
agnostic mode.  This file can now be ported between hosts with different
endianness and work consistently to track the time of year.

Additionally, the VAX and VAX750 TODR values now properly don't
progress when they have zero values (or when they overflow back to zero).
2016-12-09 18:01:21 -08:00
Mark Pizzolato
39d2944ede TIMER: Add support for catchup clock ticks and cleaned up asynchronous clocks
Asynchronous clocks are now built for all simulators which are built with
SIM_ASYNCH_IO defined.  The default behavior has asynchronous clocks
disabled since this is still experimental, but it can be enabled with
SET TIMER ASYNC.

Catchup clock ticks are now available, but since they're experimental,
they aren't enabled by default.  Catchup ticks are only available if the
simulators clock device calls sim_rtcn_tick_ack to acknowledge processing
of clock ticks.  The VAX simulators have been modified to leverage this.
Catchup clock ticks can be enabled with SET TIMER CATCHUP

Additionally, an idle threshold is provided which can be used to
influence when clock calibration may be suppressed.  The default is not
to suppress calibration activities.

The various timer behaviors are visible with the SHOW TIMER command.

The state of the operating timer facilities is visible with: SHOW CLOCK

Timer events which are queued are visible with the SHOW QUEUE command.
2016-11-16 23:50:53 -08:00
Mark Pizzolato
32bf2629b1 VAX8600: Changed console input polling
Polling is now done at least every 500ms even if the prior input
character hasn't been processed yet.   This allows ^E to provide a way
to exit a simulator which otherwise isn't reading from the console port.
2016-11-16 20:35:35 -08:00
Mark Pizzolato
da3f5359bb VAX, PDP11, PDP8, PDP1: Properly declare timer with clock unit 2016-09-26 15:55:50 -07:00
Mark Pizzolato
5531ccb175 ALL: Massive 'const' cleanup
These changes facilitate more robust parameter type checking and helps
to identify unexpected coding errors.

Most simulators can now also be compiled with a C++ compiler without
warnings.

Additionally, these changes have also been configured to facilitate easier
backporting of simulator and device simulation modules to run under the
simh v3.9+ SCP framework.
2016-05-15 15:25:33 -07:00
Mark Pizzolato
253f8a8dcf VAX: Move CPU register and routine declarations into vax_defs.h
Avoid redundant declarations in every simulator module that uses them
and allow compiler to validate consistency of declarations and definitions.
2016-02-29 16:37:18 -08:00
Mark Pizzolato
66dba79418 ALPHA, ALTAIR, AltairZ80, I7094, NOVA, PDP1, PDP10, PDP11, PDP18B, PDP8, SAGE, sigma, swtp6800, TX-0, VAX: Change tabs to spaces which had crept in over time 2015-03-30 10:24:24 -07:00
Mark Pizzolato
947fe4a031 VAX8600: Fix 8600 reboot
The reboot command code was not defined, and even when defined, it didn't get executed before the simulated code executed a HALT instruction.  Solved by scheduling immediate execution of reboot command.
2015-02-27 14:38:35 -08:00
Mark Pizzolato
ef9d1adce1 PDP10, PDP11, VAX: const cleanup 2015-02-13 06:18:24 -08:00
Mark Pizzolato
3116ce5265 VAX8600: Fix for console I/O from Johnny Billquist
Writing to the TXCS register always updated the transmit enable mask, even when the "Write Mask Now" bit was not set. That bit needs to be set for the write to the register to actually update the transmit enable mask.
2014-07-23 15:28:26 -07:00
Mark Pizzolato
6ce8d99cd8 SCP: Added generic output routine sim_printf to output to stdout and sim_log (and sim_deb when enabled)
The goals here being to simplify calling code while getting consistent output delivered everywhere it may be useful.

Modified most places which explicitly used sim_log or merely called printf to now avoid doing that and merely call sim_printf().
2014-03-28 08:20:05 -07:00
Mark Pizzolato
304ad39a2b VAX: Avoid potential VAX simulator hangs when code may poll for console input without being interrupted 2013-11-07 08:02:00 -08:00
Mark Pizzolato
be46bac750 PDP8/PDP11/VAX: Support high speed character input on console and other multiplexer ports instead of limiting input data rate to 1 character per clock tick. 2013-10-23 07:50:39 -07:00
Mark Pizzolato
651780c481 Remove stray tab characters which crept in over time 2013-06-03 06:29:01 -07:00
Mark Pizzolato
1936f7ff75 Fixed VAX8600 simulator boot from console without an attach disk to report a useful error instead of crashing 2013-04-11 08:46:09 -07:00
Mark Pizzolato
ce41ac867a Fixed the non-functional VAX 8600 boot and use of the console RL02 disk. 2013-03-21 12:05:10 -07:00
Mark Pizzolato
960c5b5873 Fix issues observed by Sun C compiler 2013-03-18 12:52:43 -07:00
Mark Pizzolato
8f9a14c5a1 Fixed clk_help to display the correct device name for the VAX TODR implementations 2013-03-09 12:16:35 -08:00
Mark Pizzolato
a91b6db21e Adding help to VAX system devices 2013-02-06 06:34:31 -08:00
Mark Pizzolato
28b90552b7 Revised all VAX simulator devices to have proper help information defined to make "HELP dev SHOW" and "HELP dev SET" most useful. 2013-02-02 16:29:38 -08:00
Mark Pizzolato
cbe11147fc Created a way for devices to have a description presentation routine and if it is supplied for its output to be visible with a SHOW SYSTEM command. Provided device description routines for devices used in the VAX simulators 2013-01-25 12:04:25 -08:00
Mark Pizzolato
9091330a5f Compiler suggested fixes 2013-01-23 12:36:03 -08:00
Mark Pizzolato
71fcfacafc Added calls to sim_register_clock_unit for simulators with clock devices 2013-01-22 16:07:23 -08:00
Mark Pizzolato
9fc6aa73d6 Finish migration for simulators to use generic clock co-scheduling and sim_activate_after for scheduled delays 2013-01-22 05:41:27 -08:00
Mark Pizzolato
83c1d80194 Merge branch 'master' into AsyncTmxr
Conflicts merged and missing changes in new modules added as needed for clock co-scheduling.
2013-01-21 16:52:42 -08:00
Mark Pizzolato
95033cee15 Declare the console port input and output polling units for most simulators to potentially allow asynchronous console I/O. 2013-01-21 11:31:29 -08:00
Mark Pizzolato
a60d9070db Adding register descriptions to VAX processor devices 2013-01-16 17:26:30 -08:00
Mark Pizzolato
dac73b9381 Migrating scp and library global variables to be declared as extern in the appropriate library include file and remove repetitive declarations in referencing modules. 2013-01-10 13:29:15 -08:00
Mark Pizzolato
2751a22725 VAX 8600 compiler warning cleanups
Addition of DMC11 to the VAX 8600
2012-12-27 07:02:23 -08:00