Commit graph

239 commits

Author SHA1 Message Date
Mark Pizzolato
796cbd2796 Merge branch 'master' of github.com:simh/simh 2013-11-03 13:10:16 -08:00
Mark Pizzolato
f0d41f15d7 PDP11: Fix to correctly set PS value on CPU reset to reflect the model specific ways real hardware behaved. (from Bob Supnik)
Here's a PDP11 SIMH bug as old as the simulator itself: the reset_cpu routine sets the PS to 340 (interrupts disabled). This causes some versions of Lunar Lander not to work. In fact, the initial state of the PS is not architecturally standardized:

      04: cleared (from schematics)
      05: cleared (from manual)
      20: cleared (from schematics)
      34: cleared (from schematics), set to 340 on boot?
      40: cleared (from schematics)
      44: cleared on init, set to 340 on boot (from schematics, manual)
      45: cleared (from schematics)
      60: cleared (from schematics)
      70: cleared (from schematics)
      T11: set to 340 (from spec)
      LSI11, F11: 4 mode behavior (from memory on power recovery, cleared on GO, 340 on boot, mode 3 undefined)
      J11: 4 mode behavior (from memory on power recovery, cleared on GO, 340 on boot, 340 on jump to  custom PROM)

The story seems to be this. All non-VLSI PDP11s used TTL chips to implement the PS, either discrete flip-flops, or 4b registers, or both.
Starting with the first system, the 11/20, they were wired clear on the processor INIT signal (power-up or front panel START switch), so that all internal state started as 0. This worked fine, because START also reset the Unibus and cleared all interrupt enables. So even though the processor was as IPL = 0, no interrupts were possible. Then along came the LSI11...

The LSI11 implemented a line-time clock with NO INTERRUPT DISABLE. Thus, if IPL was left at 0 and a bootstrap routine from a slow device was started (e.g., a floppy drive), the clock would tick, and an interrupt would occur, before the bootstrap routine finished. Because no vectors were set up, the processor would crash. So the LSI11 started the practice, carried over to all later PDP11 VLSI chips, of setting the PS to 340 before jumping to a boot ROM.

The T11 did this in all modes of startup, because its only startup behavior was to jump to a "boot" routine. It did not have a console of any kind.

Accordingly, it appears that the cpu_reset routine needs to set the PS based on the processor model. Further, all boot routines need to set the PS to 0 or 340 based on the processor model. (It's probably safe for boot routines just to set the PS to 340, but it's not technically
accurate.)
2013-10-27 05:30:13 -07: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
1e3586ec91 DISPLAY: Latest version of display code from Phil Budne and Doug Gwyn including initial pdp1_dpy and pdp11_vt 2013-10-16 01:02:12 -07:00
Mark Pizzolato
026dd98d83 Merge latest from Bob Supnik 2013-10-12 13:33:01 -07:00
Mark Pizzolato
63e05c77be PDP11: Fix DL help attach regression and missing SHOW IOSPACE details 2013-10-02 08:37:09 -07:00
Bill Heaton
99b4730dc0 Fix build warning on OS/X
PDP11/pdp11_io_lib.c: In function 'show_iospace':
PDP11/pdp11_io_lib.c:363: warning: too few arguments for format

PDP10/pdp10_lp20.c: In function 'lp20_set_vfu_type':
PDP10/pdp10_lp20.c:1038: warning: implicit declaration of function
'toupper'
PDP10/pdp10_lp20.c:1121: warning: implicit declaration of function
'isspace'
2013-09-30 12:10:11 -07:00
Mark Pizzolato
c9844951f7 PDP11/VAX: Make sure that semi-unique drive serial numbers have a zero msb to avoid issues in some operating systems. 2013-09-10 16:27:00 -07:00
Mark Pizzolato
01b3179d93 PDP11: Added help to KE, KG, RF, TA, TC and TM devices. Fixed DECtape documentation. 2013-09-09 05:36:17 -07:00
Mark Pizzolato
786cda7c1b PDP11/VAX: Use semi-unique drive serial numbers when writing BAD144 bad block info to newly created disk images
The 32 bit drive serial number is determined by hashing the newly create filename.
2013-09-09 03:39:00 -07:00
Mark Pizzolato
e18d7e86e4 PDP11/VAX: Use unique drive serial numbers when writing BAD144 bad block info to newly created disk images 2013-09-08 19:42:46 -07:00
Mark Pizzolato
cc0ccb43b6 PDP11: Updating doc for RS03/RS04 and RHC from Bob Supnik 2013-09-07 16:36:00 -07:00
Mark Pizzolato
4387c5bc6d PDP11: report RK05 drive presence more reasonably. Add historical information in RK help. 2013-09-07 14:08:23 -07:00
Mark Pizzolato
b1fc298ff3 PDP11/VAX: Add register descriptions and bitfields to register declarations 2013-09-06 09:38:12 -07:00
Mark Pizzolato
d61409889b PDP11: Added formatted register display for HK and RK devices 2013-09-06 08:31:33 -07:00
Mark Pizzolato
ddc9398f90 PDP11: fix RK device unit detection when some units are disabled. 2013-09-05 19:03:06 -07:00
Mark Pizzolato
59232fed53 PDP11: fixed auto configure for RL and HK devices 2013-09-05 18:56:08 -07:00
Mark Pizzolato
b1b9aa3510 PDP11: Added help to RK device 2013-09-05 12:10:09 -07:00
Mark Pizzolato
1141339e5b PDP11: Addition of the RS03/RS04 disk devices from Bob Supnik
Note that this is not the fully general Massbus implementation people were dreaming of. MB#1 is for RP/RM, MB#2 is for TU, and MB#3 is for RS.
I know that there were requests for four Massbus channels and multiple RP/RP subcontrollers, but if people want more disks, they can use the RQ.
2013-09-05 07:59:11 -07:00
Mark Pizzolato
4e5f910fed Compiler nits for void * assignments from Bob Supnik 2013-09-04 19:50:47 -07:00
Mark Pizzolato
89024724d4 PDP11/VAX: pdp11_hk Fix by Bob Supnik for issue #47
Revised error handling to command-response model
Revised interrupt logic to follow the hardware
2013-09-03 05:15:23 -07:00
Timothe Litt
91c7d26095 SHOW IOSPACE, again
Show IOSPACE doesn't always get the number of devices right due to device creativity.

o The distinction between UNIT and DEVICE has blurred
o MUX devices merge several physical devices into one device/unit
o Dynamic device sizing has made things more volatile.

This edit solves the problem for SHOW IOSPACE by adding an (optional) word to the DIBs.
The word contains the amount of IO space consumed by each instance of the physical device that's being emulated.
E.G., if it's a DZ11, the device is the DZ11 module, or 8 lines, even though the MUX device may support 32.

This enables SHOW IOSPACE to determine the number of physical devices being emulated, which is what folks need when configuring software.  The word may have other uses - in a generic dynamic device sizing routine - which is why the amount of IOSPACE per device was chosen rather than the 'number of physical devices.'

The edit should not make any existing device regress.  If the new word (ulnt) is zero (not initialized), SHOW IOSPACE will default to the number of units in the device, or if there's no device (CPUs), 1 as before.  If it is present, the number of devices is the calculated as total allocation/allocation-per-device.

The edit updates all the devices that seem to require this treatment, and all the processors that define the UNIBUS/QBUS DIBs.
2013-07-11 15:39:15 -04:00
Mark Pizzolato
95e54dc60e Merge remote-tracking branch 'origin/master' 2013-07-10 12:04:23 -10:00
Mark Pizzolato
071b8e5cd0 Fix attach help for pdp11_dl (reported by Reindert Voorhorst) 2013-07-08 06:17:08 -10:00
Timothe Litt
6a9c60c7e7 Fix CR builds
On platforms where the translation code default is dynamic, the default table pointer can't be const.

Remove const from the table pointer.
2013-07-08 07:22:29 -04:00
Timothe Litt
0cc3783711 PDP-11/VAX Update: NPR to/from IO Space
Matches PDP-10 change.  Necessary for KDP, harmless otherwise.
2013-07-05 00:48:10 -04:00
Timothe Litt
4497bba48f PDP-11/VAX update: SHOW IOSPACE
Teach SHOW IOSPACE to output vector and BR addresses as well as CSR addresses.
2013-07-05 00:23:33 -04:00
Timothe Litt
1bfc2bc57e PDP-10 update: CD20
Make the card reader work on TOPS-10 and TOPS-20.
Augmented Image ECO was not implemented.
Simplify UI by defining commands for the various options/models emulated based on the simulator being built.
Document, and make the help conditional on model where that reduces clutter.
Deal with <CR><LF> reading ASCII files (file is opened 'rb' in scp's attach ; it shouldn't be.
Add translation support for DEC 026/029 full 7-bit ASCII, an ANSI standard & used by TOPS-10/20.
Deliver EOF at the correct time(s).
Preliminary support for update to card image spec being negotiated with the author.
2013-07-05 00:16:11 -04:00
Mark Pizzolato
fa0086ab74 change QVSS device to autoconfigure its vector so other autoconfigured devices get correct vector assignments when the QVSS device is enabled 2013-07-01 09:47:54 -10:00
Mark Pizzolato
b3a9a0d79c Add sim_video and VAX QVSS (VCB01) Monochrome Video Board from Matt Burke 2013-06-12 17:10:23 -07:00
Mark Pizzolato
feeea1e9d2 Remove unused definitions 2013-06-12 16:01:44 -07:00
Mark Pizzolato
43e5647e96 Fix short block writes on RK06/RK07 devices to write zero filled buffer data. (Oleg Safiullin) 2013-06-10 05:09:45 -07:00
Mark Pizzolato
eb921d2ea4 Fix bug in PDP11 SET CPU <model> which inadvertently disabled some devices improperly. - Bob Supnik 2013-06-07 18:20:59 -07:00
Mark Pizzolato
a145d5362b CAPS11 now runs on SimH. The key bug was in the reset routine. Change by Bob Supnik.
Thanks to Ian Hammond, Lou Ernst, Malcolm Macloud, and Jack Rubin,

In addition, I've added the CAPS11 bootstrap into the emulator module, so no more toggle-in required.

Lou Ernst reported that RT11 V5 does not work with the TA11, even on real hardware. The simulated TA11 does work under RT11 V4; it's included in the stock FB monitor.

One anomaly with RT11 V4 - after writing files to CT0: and then doing a DIRECTORY, all the files lengths are 0. The files are there. I can type them and DIFF them against their source.
2013-06-07 16:02:17 -07:00
Mark Pizzolato
651780c481 Remove stray tab characters which crept in over time 2013-06-03 06:29:01 -07:00
Mark Pizzolato
780adc3ca9 Added missing STRSYN from DDCMP dup setup 2013-06-02 16:08:06 -07:00
Mark Pizzolato
596cb3f580 Added needed DUP interfaces to allow use by KMC11/KDP. 2013-06-02 13:19:23 -07:00
Mark Pizzolato
4064cc079a This fixes the problem that MMR1 is recording changes to R7 (PC), which it should not. (issue #44)
It does not fix the problem that MMR1 is not used for floating point instructions.

I don't know if I will fix the FP MMR1 problem. It does not seem to impact running software. It is consistent with the architecture spec - just not with the actual J11 implementation. The J11 microcode has a variety of exception exits for FP conditions, and I have to trace which ones invoke fix-up, and which do not.
2013-06-02 06:52:32 -07:00
Mark Pizzolato
486ef58595 Compiler warning cleanup 2013-06-01 23:04:45 -07:00
Mark Pizzolato
4d34547b05 Cleanup DUP11 implementation and refactor for shared use by another device (KMC11). 2013-05-31 11:58:09 -07:00
Mark Pizzolato
a61dec6544 Add initial sharable DDCMP support 2013-05-29 12:37:51 -07:00
Mark Pizzolato
27dac1ade2 Added rate limit support (SET DUPn SPEED=bps). 2013-05-29 05:33:51 -07:00
Mark Pizzolato
4ba152db79 Fix packet transmit overrun behaviors which caused DECnet circuit failures. 2013-05-28 17:35:49 -07:00
Mark Pizzolato
4019e670e0 Fixed CRC implementation, CRC state bit presentation and added register declarations 2013-05-28 12:18:32 -07:00
Mark Pizzolato
c3750e6444 Added logic to act on the state and transitions of the RCVEN bit of the receiver CSR. 2013-05-28 01:03:58 -07:00
Mark Pizzolato
89bd58a6fa Addition of DUP11 simulation to all Unibus simulators (PDP11, PDP10, and all Unibus VAXen) 2013-05-27 16:24:18 -07:00
Mark Pizzolato
76fccce27d Fix for Issue #53 for DC, DL, and VH multiplexer devices 2013-05-16 11:04:43 -07:00
Mark Pizzolato
e82507d9c8 Fixed DZ bug which referenced the wrong dz device when the number of DZ multiplexers configured was not a power of 2 (i.e.3, 5, 7, etc.) 2013-05-16 10:18:07 -07:00
Mark Pizzolato
d964df4eea Compiler suggested cleanups 2013-05-09 14:02:48 -07:00
Mark Pizzolato
9faef6ea89 Added separate debugging ability to trace line connect/disconnect activities to better debug virtual null modem cable activities. 2013-05-06 07:50:09 -07:00