Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run MAZE #1330

Closed
larsbrinkhoff opened this issue Oct 10, 2018 · 74 comments
Closed

Run MAZE #1330

larsbrinkhoff opened this issue Oct 10, 2018 · 74 comments

Comments

@larsbrinkhoff
Copy link
Member

larsbrinkhoff commented Oct 10, 2018

Use @livingcomputermuseum's sImlac to run MAZE.

coeurl

@larsbrinkhoff
Copy link
Member Author

larsbrinkhoff commented Oct 10, 2018

Josh wrote (about Maze War):

It also requires that SSV's font still be resident in memory

So I got SSV from @tuban's Imlac software library and tested it. It runs, but I can't seem to do anything through the keyboard.

ssv

@jh95468, do you remember anything about SSV?

@livingcomputermuseum
Copy link

livingcomputermuseum commented Oct 10, 2018 via email

@larsbrinkhoff
Copy link
Member Author

Sounds great, Josh!

SSV is also described in some places as a monitor, and as part of the Dynamic Modeling editor, IMEDIT. I also believe it could display graphics sent from the host, using an ARDS-like protocol.

@larsbrinkhoff
Copy link
Member Author

We have a binary version of IMEDIT, so we can try that on occasion.

Information from PDL is that the Imlac runtime was eventually changed to a VT52 emulator. I don't know if that's a newer version of SSV, or if it's named something else.

@jh95468
Copy link

jh95468 commented Oct 11, 2018

I wrote IMEDIT, in PDP-10 assembler. It didn't have any graphics functionality, but was solely intended for editting ascii documents, instead of using TECO. The overriding requirement for IMEDIT was that it fit into a single block of PDP-10 memory (in contrast to TECO which took 6 or 7 IIRC).

As we received more Imlacs and hooked them up as ITS terminals, the PDP-10 became overloaded and it was hard to get anything done. There was no 'virtual memory' at that time, so whatever programs you were using consumed real physical memory, which was in very limited supply. Even TECO was a problem with all of the terminals that could be active at one time.

IMEDIT allowed us to use all of the Imlacs we had, by designating some (most?) of them as "Imedit-only" terminals, where the only program you were allowed to use was IMEDIT. We were all constrained to use signup sheets, and allowed to reserve only 2 hours maximum at a time, with (IIRC) another 2 hours on an IMEDIT-only terminal. One of the staff (like me) was assigned in shifts to enforce this, although anybody could see the paper signup sheets and do TTY^F to see what programs and more importantly memory you were using - regardless of whether or not the program you started happened to be named IMEDIT.

IMEDIT was a simple program that simply passed ascii from a file to an Imlac and back, except for control characters which were used to issue commands like 'open a file'. If you try to run IMEDIT from a normal non-IMLAC TTY you can see what it does by typing control-commands and watching what it sends you. Of course you needed the right software on ths IMLAC side to make it operate as an editor.

@jh95468
Copy link

jh95468 commented Oct 11, 2018

Forgot to mention...

I don't remember the term 'SSV', or remember what we called the everyday program that ran in all the Imlacs. It might have been 'SSV', but the everyday program was just a terminal emulator, with an extra feature or two. In particular, it responded to the 'Page Xmit' key, and when you pushed that, whatever was on the Imlac screen (even off the top or bottom) was sent to the TTY output. Assuming IMEDIT was running on the PDP-10 at the other end of that TTY line, it would read all the input from the Imlac and just write it to the output file. Typing a command, e.g., ^Y (Yank) would then instruct IMEDIT to read some more characters from the input file, and send them down the TTY connection to the Imlac.

So, assuming SSV was that Imlac-side program, and you can somehow push the virtual keyboard's Page-XMIT key, you should be able to use IMEDIT to edit files. I think...

@larsbrinkhoff
Copy link
Member Author

Thanks, Jack. Apparently the Imlac situation is more complicated than I thought.

  • I believe SSV worked with IMEDIT.
  • Later a VT52 emulator supplanted SSV.
  • I don't know anything about SST.
  • DECUUO can display vector graphics using the same protocol as GT40. Yet another Imlac program?

Anyway, for Maze War I guess the most important thing is that the SSV fonts are resident in core.

@tuban
Copy link

tuban commented Oct 12, 2018 via email

@jh95468
Copy link

jh95468 commented Oct 12, 2018

Since a VT52, as far as I remember, didn't have a 'Page Xmit' key, an Imlac strictly emulating it wouldn't have ben very useful with IMEDIT. As DM got more memory, paging, swapping, etc., IMEDIT became less necessary, so I can believe they might have been turned into simple VT emulators for everyday use (and the Maze program for the wee hours). In the later part of the 70s, it was common to spend your entire terminal time in Muddle, editting, running, and debugging programs, so IMEDIT and even TECO weren't used as much as earlier in DM history.

@jh95468
Copy link

jh95468 commented Oct 12, 2018

One other detail from memory... Each Imlac had an operator's console which sat on its desk and contained the usual array of lights switches and buttons that were common on minicomputers of the day. There must have been some kind of boot loader in a protected memory, because I can still remember flipping those switches and pushing those big square buttons to get the Imlac back into a usable state after it had crashed or left dead by some previous user - pretty common in mornings after a night of Maze...

I don't recall that the Imlacs had any disk storage, so if the core memory image was corrupted a new image would have had to come from the ITS machine down the TTY line by working the buttons and switches. Not sure what that boot software was called.

@tuban
Copy link

tuban commented Oct 12, 2018 via email

@livingcomputermuseum
Copy link

livingcomputermuseum commented Oct 12, 2018 via email

@larsbrinkhoff
Copy link
Member Author

Update.

I have now run @livingcomputermuseum's Imlac simulator with the added TELNET support. I can load SSV, and then login to ITS and start MAZE. The initial top view of the maze works, but the 3D view from inside the maze doesn't.

@tuban
Copy link

tuban commented Oct 30, 2018 via email

@larsbrinkhoff
Copy link
Member Author

We now have a newer version of SSV we can try on the Imlac.

And something called SST that probably isn't related to the one at Purdue.

@larsbrinkhoff
Copy link
Member Author

I have started both SSV 52 and SST 21 on the sImlac. I have not yet tried them with ITS.

Next, check MAZE. Is it happier about SSV 52 than 22 or 24? Will it be OK with SST?

@larsbrinkhoff
Copy link
Member Author

MAZE source code explicitly says:

; ALL CHARACTERS SUBROUTINES AND THE DJMS TABLE IS UP IN THE CONSOLE PROGRAM (SSV).

The characters are in the file SSV CHARS, which is .INSRTed into SSV 52. SST does that too.

@larsbrinkhoff
Copy link
Member Author

Inching forward. I have ITS loading programs onto the Imlac emulator, and @tuban's "SSV 22" works ok. However, there's a suspicion the MIT programs expect some undocumented hardware modification. @jdersch and I are looking into this.

@tuban
Copy link

tuban commented Apr 15, 2020 via email

@larsbrinkhoff
Copy link
Member Author

By the way, the makers of the "From Bedrooms to Billions" series of video game documentaries are making a new episode about big iron games. I have helped them get some footage of PDP-6/10 ITS games, but MAZE is still on their to do list.

@jh95468
Copy link

jh95468 commented Apr 15, 2020

IIRC, there were several hardware mods to the DM Imlacs. All of them were very simple, and were accomplished by wirewrapping changes on the backplane, using some unused existing logic gates wherever they could be found to make the change.

The one that was done for Maze was motivated by the glitchiness of the display, where lines would occasionally go randomly off the screen. It looked like a loose connection, but everything was tight and the same behavior occurred on different Imlacs.

The problem was a lack of synchronization between the Imlac's two processors. The program (Maze etc.) ran in the main CPU, and shared memory with the display processor. So to change the screen image, the program modified the graphics instructions that the display processor was executing. Depending on where the display processor was executing at the time the main processor changed the display list, glitches could occur.

I can't recall exactly how we fixed that (even though I'm probably the one who designed the hardware mod). IIRC, it had something to do with adding a way for the display processor to raise an interrupt for the main processor, so that the main processor could make a display program change at a 'safe' time. There was probably a flag bit involved somewhere too.

In any case, it was a simple mod, probably just a few additional gates or FFs that were already in the machine somewhere. If you look into the Maze code and find where it changes the Imlac's display code, that's likely the only place where you'll find the hardware mod being used. PDL may remember more - I'm pretty sure he's the one who changed the software to use the mod.

The other two mods are probably not of concern to the emulator since they involved the RS232 interface. I remember doing something to push the RS232 speed as far as it could go and be reliable - that was important for Maze to reduce latency - i.e., the "muzzle velocity" of the bullets. The other mod was done while sitting in the ballroom of the Washington Hilton, setting up the ICCC '72 demonstration of the ARPANET. That had something to do with RS232 control signals (CTS, RTS, etc.) to make the Imlac work with the ARPANET TIP.

Documented? Of course it was documented. Like all software of the day, the "documentation is in the code". In the case of hardware, that meant handwritten changes on the master copy of the Imlac logic diagrams kept in a rack in the machine room. But I suspect those have been lost long ago.

/Jack Haverty
MIT-DM 1970-1977

@larsbrinkhoff
Copy link
Member Author

Thank you @jh95468, that is great information!

The modification we're puzzling over right now is why the range of the argument to DLXA and DLYA (load X/Y accumulator) was extended from 12 to 13 bits, just like the address argument to DJMP and DJMS. X/Y coordinates are just 10 (or possibly 11?) bits.

@jh95468
Copy link

jh95468 commented Apr 15, 2020

Sorry, can't help with that. We didn't do any mods that extensive.

Is it possible that the Imlac corporation made changes, e.g., to add memory? We had some of the first Imlacs, and we were always complaining about memory in everything. Engineers from Imlac used to occasionally come to MIT-DM and just hang out to see what we were doing, and that probably influenced changes or additions to their next production runs. Maybe they made a mod in anticipation of more memory in the future.

Or perhaps MIDAS was changed to permit use of larger addresses, if anyone ever got around to making the hardware changes to do so? Does the code ever set those new bits to other than 0?

I do remember one kind of funny "mod". Lick was very much into office automation, and the first Imlac displays were delivered as landscape mode rather than portrait orientation. Lick really wanted them to look like a standard 8-1/2x11 printed page. So Imlac did a mod whereby the displays became portrait mode.

The funny part of this is that the change didn't really matter to the hardware. The displayable address space was square, not rectangular. So all the rotation accomplished was to move the non-displayable part of the screen from the top/bottom to the sides.

But that may have led to changes, e.g., adding a bit here or there to make more of the screen usable?

I never did any Imlac programming, so I don't know about such mods, but if it involved a hardware mod I'm pretty sure it was not done by DM. PDL or GAT would likely know more.

@larsbrinkhoff
Copy link
Member Author

Some information about what happens when the MAZE game is started on the PDP-10.

  1. MAZE should be started from an Imlac running an appropriate version of SSV (or SST).
  2. The user is asked some questions.
  3. The PDP-10 loads the Imlac code by first sending ^A^A. This makes SSV jump to location 40 where the bootstrap ROM is.
  4. Then the MAZE code is sent.
  5. When done, Imlac MAZE used to jump back to SSV thus being ready to accept more data from the PDP-10. The current (latest) version goes into a loop looking for ^A^A.
  6. Next, PDP-10 loads data for the maze. It sends ^A^A again, then IMLAC; IMLAC BLKLDR, and then the data.
  7. After this, we are back in SSV. The PDP-10 does some more initializations.
  8. And then sends ^A^F to the Imlac. This is SSV-speak for go to 10000, which is where MAZE is loaded.

@larsbrinkhoff
Copy link
Member Author

larsbrinkhoff commented Apr 21, 2020

I single stepped this in DDT (sometimes using comlink to get to the otherwise disconnected TTY), and right after the ^A^F I got this!

maze

@larsbrinkhoff
Copy link
Member Author

The 3D view doesn't work yet.
maze2

@larsbrinkhoff
Copy link
Member Author

After a while, I get this intermittently. @jdersch, help!
maze3

@jdersch
Copy link

jdersch commented Apr 21, 2020 via email

@larsbrinkhoff
Copy link
Member Author

larsbrinkhoff commented Apr 24, 2020

Was going to send this, but Dave posted his message seconds before me. I'll still send it, even though some information is duplicated.

Several MAZE people are inolved. I'm not entirely familiar with the history, but something like this:

  • @hpalmer, @gregt590 and others wrote MAZE at NASA Ames.
  • Greg took the code to MIT, where @dlebling618 wrote the PDP-10 part.
  • Ken Harrenstien is not on GitHub as far as I know, but gets sent emails every now and then.
  • Some previous revivals happened at Oracle and DigiBarn.
  • This issue is about running the MIT version on ITS, using PDP-10 and Imlac emulators.
  • Source code for the game and all tools are available and built fresh, except the Imlac SSV console program for which there is just a binary version.
  • The Maze Watcher and Guncher have not been found. (EDIT: They have been found now.)

@dlebling618
Copy link

I wrote the Guncher. It was a very simple program, given that ITS had no security. It just looked for certain specific bits of code that were at known addresses in MAZE and killed any program containing them. It was mandated to exist by certain powers-that-were, and it was moderately fun to write, but also trivially easy for anyone who wanted to play to kill the daemon that ran it, or to reassemble MAZE with slightly different locations or contents for the code the Guncher was looking for.

A very primitive precursor of anti-virus programs.

@WardCunningham
Copy link

@hpalmer, @gregt590 and others wrote MAZE at NASA Ames.

So was it natively an Imlac program? Or clone for Imlac from somewhere else?

@jdersch
Copy link

jdersch commented Apr 24, 2020 via email

@WardCunningham
Copy link

WardCunningham commented Apr 24, 2020

@jdersch Wow, it could have been. The solver left bright little dots in the middle of each cell. It would animate both the construction and solution of the maze. This might not be obvious if a simulator were too fast.

I would love to be reunited with this source code.

@larsbrinkhoff
Copy link
Member Author

This is Steve Colley's recollections of how he created the 3D maze program: http://www.digibarn.com/history/04-VCF7-MazeWar/stories/colley.html

So yes, it was an Imlac program from the very beginning.

@tuban
Copy link

tuban commented Apr 24, 2020 via email

@tuban
Copy link

tuban commented Apr 24, 2020 via email

@tuban
Copy link

tuban commented Apr 24, 2020 via email

@jdersch
Copy link

jdersch commented Apr 24, 2020 via email

@jdersch
Copy link

jdersch commented Apr 24, 2020 via email

@WardCunningham
Copy link

@jdersch Yes, please. I would love to browse a decompiled version. I'd also like to have a running version so that I can impress my friends (or not).

@tuban
Copy link

tuban commented Apr 25, 2020 via email

@gregt590
Copy link
Contributor

gregt590 commented Apr 26, 2020 via email

@WardCunningham
Copy link

@gregt590 Thank you for this summary.

I wonder if you recall aspects of the initial development which we might now call software engineering? For example, were you generally familiar with the who program when you worked on it or did you find a leveraged place and insert your code there? How did you come to understand what had been done before? Was there psudo-code? Did you write psudo-code or flow charts or state-transition tables? There seem to be some thoughtful comments explaining the approach at a high level. Were those always there? Did they evolve substantially before the program stabilized?

I remember there were many two or three instruction idioms that were used all the time. I went looking for things I might recognize. This sequence caught my eye:

02030	030000		ISZ	WPTR
02031	030000		ISZ	WPTR2
02032	030000		ISZ	CNT
02033	010000		 JMP	PRNT1

This must be exploiting some carry propagation to some end. The browser's search showed the many places that WPTR2 was used and the highlights in the scroll bar offered insight into how references were distributed: once at the top, once at the bottom, and lots in the middle.

I once set out to "preserve" the programming experience for an assembly language program. My experiment in website design included pop-ups for register allocations and common idioms. I'm not sure I could see all that in the program as it exists today but maybe you do and would be interested in such a restoration?

Here, for the interested, is one of my restorations:
http://c2.com/ward/pdp8sim/

@gregt590
Copy link
Contributor

gregt590 commented Apr 26, 2020 via email

@jh95468
Copy link

jh95468 commented Apr 30, 2020

If you're interested in assembly-language "experience", this might be interesting:

https://inwap.com/pdp10/hbaker/hakmem/hacks.html

See items 145 onward. I've wondered for 50 years how some of these "hacks" were discovered (software engineered?).

There was a class of die-hard assembly language programmers that we called "bit-twiddlers". That was a compliment. It meant that they could wring the last bit of memory and cpu power out of the machines of the era by "clever hacks", i.e., programming constructs that were somewhat outlandish but worked.

/Jack Haverty
MIT-DM 1970-1977

@larsbrinkhoff
Copy link
Member Author

I can testify that debugging those clever hacks now is a dual delight/headache.

Happy to report that all outstanding issues with Maze have been solved. (For now.) @jdersch's latest version of the @livingcomputermuseum sImlac emulator does run SSV 22 and MAZE.

@larsbrinkhoff
Copy link
Member Author

Here's a video:
https://youtu.be/jYRFDLYPeTU

@tuban
Copy link

tuban commented Apr 30, 2020 via email

@larsbrinkhoff
Copy link
Member Author

That is @jdersch's PDS-1D emulator:
https://github.com/livingcomputermuseum/sImlac

@jh95468
Copy link

jh95468 commented Apr 30, 2020

Very nice! It sure looks exactly as I remember it.

Just curious - does anyone remember a 3D version of Maze, or see any evidence of such a beast in the artifacts?

I vaguely recall a brainstorming session many decades ago where a bunch of us were trying to solve the problem of certain people having become so proficient with Maze that no one else could survive more than a few seconds with them around.

There were several ideas. One was simply to extend the maze size so it would be harder for one player to dominate the whole Maze world. That evolved into the idea of a 3D Maze. In addition to corridors heading left and right, there could be corridors heading up and down. Going forward when you were facing a wall would cause you to climb up that wall, and the maze would rotate so the wall became the new floor. Similarly going forward at the edge of a "cliff" (corridor heading downward) would rotate you 90 degrees onto that corridor as the new floor.

IIRC, this actually got programmed at least far enough to try it out by walking around a 3D maze, and the conclusion was that it was so confusing that even the experts (KLH.....!) wouldn't be able to master it. It was really difficult to "get your bearings" after a few quick moves in 3D space.

But I can't remember much beyond that, and don't have any memory of ever playing in a 3D multiplayer battle. Maybe that was happening just as I left MIT.

Does anybody else remember anything like this? It might be fun to play such a game...anyone planning to port Maze to IOS/Android, or maybe as a Web app? SpaceMaze?

/Jack Haverty
MIT-DM 1970-1977

@tuban
Copy link

tuban commented Apr 30, 2020 via email

@jdersch
Copy link

jdersch commented Apr 30, 2020 via email

@gregt590
Copy link
Contributor

gregt590 commented Apr 30, 2020 via email

@gregt590
Copy link
Contributor

gregt590 commented Apr 30, 2020 via email

@jh95468
Copy link

jh95468 commented May 1, 2020

Wow, yes, that's probably what I remember. I didn't recall that it was hardware. Must have taken quite a lot of work too.

Six or seven years prior to your project, Ken Pogran and I did a digital project lab (6.711 then) which built a word-processor, with a tty/tape reader and a memory that could store a bunch of pages of text, for display and editting on a 4-line CRT (possibly the same Tektronix you guys used...). Kind of a primitive WYSIWYG editor machine a la Emacs. Lots of fun even though it never worked - the memory was an acoustical delay line (only large memory available back then) and it didn't play well with the noise created by the tty activity. We were the first proejct ever to get an A with a project that didn't work after the TAs and Prof concluded that the acoustical memory should never have been made available. I still have my project report; a few years ago it even went in to court as evidence of prior art for a patent fight.

Your Maze Machine was cheaper than an Imlac but must have been less powerful. I bet it didn't even have a way to burn out an amp in the display.

Maze was very popular; I remember when we brought it to Interop in 1992, the lines to play were always long. Curious that it never made it to the modern gaming world; I bet it would still be popular.

/Jack

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants