• Please review our updated Terms and Rules here

Question: Planetfall rendering issues on Kaypro 1

misterblack

Experienced Member
Joined
Jul 20, 2017
Messages
228
Location
Portland, Oregon, USA
Hey guys! I recently added a Kaypro 1 to my collection -- my first dedicated CP/M machine. (And got it for a reasonable $80 here in Portland.)

I'm having one issue: I wanted to play through Planetfall on it but it's not rendering quite right.

EDIT -- I solved this, scroll down to post #9 for how to do this yourself.

ZJC8mbd.jpg


Makes it pretty unplayable. I'm so unfamiliar with CP/M -- was wondering if there is the equivalent of 'ANSI.SYS' or a setting that needs to be changed to assist in text rendering? I tried a couple other games (From other companies) and they seemed to work fine including the neat space invaders clone that uses the Kaypro extended characters for graphics.

Thanks for any assistance you can give to this CP/M n00b!

Galley of the machine if interested:
https://imgur.com/a/Vecjfe5
 

Attachments

  • ZJC8mbd.jpg
    ZJC8mbd.jpg
    93 KB · Views: 1
Last edited:
It's been my experience that games from this era have embedded code/tables to handle specific terminal types. some used a common data file scheme, but I don't know this game. My guess would be that it requires some modification for the Kaypro 1 terminal codes. I don't know what sort of modification, though. The Kaypro 1 is actually a later model Kaypro (much newer than Kaypro II, for example). Assuming it also uses terminal codes based on the ADM3, that is what it would need to be customized for.

Odd, though, that your case silk-screening says "Kaypro 1" but the FCC label says "Kaypro 2" (perhaps they never changed the FCC label for any models). The back panel arrangement looks like a Kaypro 10 mainboard. And the ROM is v2.01 which is the newer "universal" ROM BIOS.
 
Last edited:
Odd, though, that your case silk-screening says "Kaypro 1" but the FCC label says "Kaypro 2" (perhaps they never changed the FCC label for any models). The back panel arrangement looks like a Kaypro 10 mainboard. And the ROM is v2.01 which is the newer "universal" ROM BIOS.

Good Eye I didnt see that.
 
Odd, though, that your case silk-screening says "Kaypro 1" but the FCC label says "Kaypro 2" (perhaps they never changed the FCC label for any models). The back panel arrangement looks like a Kaypro 10 mainboard. And the ROM is v2.01 which is the newer "universal" ROM BIOS.

Yep -- I think the Kaypro 1 was the last CP/M machine they made (why did they even call it the Kaypro 1?!) and I guess there weren't enough changes to warranty a re-certify from the Kaypro 2 (not the old II.) I learned a lot researching these machines when I picked this one up. It came with just one tatty old floppy disc which did work, but I immediately tossed that and made new discs .. and figured out the ROM situation to find which disc I had to write to boot this thing. I think the 10, 2 and 1 all had the same general motherboard -- this one is missing the realtime clock and hard drive connector, almost like a budget model.
 
Misterblack see my old thread, I hope it can help you as its about all infocom games ported to CP/M: http://www.vcfed.org/forum/showthre...CP-M-computers&highlight=infocom+interpreters

Interesting, thanks. I downloaded that archive of interpreters -- but do you recall which works best on the Kaypro? I suppose I can try them all. Funny looking in my files I already had that archive of interpreters but I didn't know what to do with them. (Now I know -- hex edit the first 8 bytes to the name of the DAT file.)
 
Ok I found this on Google groups:

https://groups.google.com/forum/#!topic/comp.os.cpm/yFfsRiwFzqE

The significant differences between CP/M interpreters (say, the Kaypro
version vs. the Osborne version) consisted largely in a few patch points
toward the front of the .COM file for screen control. Other than that,
they're interchangeable (the Kaypro .COM file should run on the Osborne,
for example, or vice versa). Specifically, a Kaypro .COM file is easily
patched to 52 columns to accomadate an Osborne screen.

The following is a little information I put together about ten years ago
for patching the .COM file (note: the recommended hex values given are
for ADM3A terminals).

Also note that the later Infocom games (generally, those whose .DAT files
are >128kb) will not run under CP/M. The newer format (what Infocom
called "Plus") allowed for larger, more complex games (.DAT files up to
256kb), but CP/M with it's memory constraints couldn't handle them. Keep
in mind that several of the "Plus" format games -- e.g., Leather
Goddesses of Phobos -- were also released in "classic" format, and that
most of the "classic" format games (Zork, Enchanter, etc.) were
re-released in "Plus" format, with additions such as on-line hints. Only
the classic versions of Infocom games can be played under CP/M.

VIDEO CONTROL PATCH POINTS FOR INFOCOM'S GAMES:

Use any CP/M patch utility to modify the .COM file - Zap, Superzap, or
Patch all work equally well.

Starting at location 05h is room for up to 8 characters; this is where
you put the name of the .DAT file of the game you wish to run. For
example, if I insert the string WISHBRIN, then run the .COM file, it
loads Wishbringer; if I change the string to CUTTHROA and run the .COM
file, it runs Cutthroat.

(This is particularly handy under the Z-System. I've set up a series of
aliases which load a generic INFOCOM.COM into memory, POKE in the proper
string for whichever game I want to play, and then run it. Instead of 23
different .COM files on disk, then, I only need one.)

Near the beginning of the CP/M version of each Infocom COM file is room
for four video control code strings, beginning at addresses 0110h, 0131h,
0152h and 0173h with room for up to 20h bytes per string. The first byte
of each string holds the length of the string, followed by the string
itself. All bytes after the indicated end of string are ignored.

0110h : Screen initialization. Used at game startup to prepare screen,
position cursor for first line of output. Suggest including clear screen
code and code for positioning cursor at beginning of last line of screen.
05 1A 1B 3D 37 20

0131H : Screen uninitialization. Used when exiting the game to
de-initialize the screen. Probably not needed unless you want to clear
the screen on exit. 00

0152h : Status line. Used just before printing status line. Suggest
including code for nondestructive home cursor, inverse video. 05 0F 1B 3D
20 20

0173h : Prompt line string. Used just before printing '>' prompt. Suggest
turning off status line video attributes (e.g. inverse video),
positioning cursor at beginning of last line of screen. 05 0E 1B 3D 37
20.

0103h : Screen width in hex. Must be 0C to 85h. Warning: Anything less
than 20h causes funny things to happen to the output. 4F

Hope some of this helps!

-Calvin
cric...@itis.com

This is a good start -- if I can't find the right interpreter I should be able to make this work, would just need to figure out the codes which shouldn't be impossible.

Thanks guys!
 
One more tidbit that might be useful. I just found this for the Kaypro.

Code:
        ESCAPE SEQUENCES, CONTROL CODES, AND PORT COMMANDS

Cursor left                        ^H    ASCII 7 decimal
Cursor right                       ^L         12
Cursor down                        ^J         10
Cursor up                          ^K         11
Erase from cursor to end of screen ^W         23
Erase from cursor to end of line   ^X         24
Clear screen                       ^Z         26
  (also cancels special effects)
Home cursor                        ^^         30

The following are all preceded by ESC, character #27:

Insert line                        E     | contrary to  
Delete line                        R     | manuals 
Inverse video on/off               B0/C0
Reduced intensity on/off           B1/C1
Blinking on/off                    B2/C2
Underlining on/off                 B3/C3
Cursor visible/invisible           B4/C4
Video mode on/off                  B5/C5   
Remember/recover cursor position   B6/C6
Status line preservation on/off    B7/C7
Cursor address                     =, row + 32, col + 32
 
Solved!

Solved!

Thanks guys -- I successfully edited the interpreter to render perfectly on the Kaypro! Here are some pictures and scroll down for the hex codes I used. Took a bit of figuring out just because the I did the bonehead move and put in DEC codes into the hex editor instead of HEX. Ooops!

Pictures look crappy but believe me, this Keypro has a super sharp screen edge to edge. The Macro photography on my phone just makes it look so blurry around the edges.

oPvR7M8.jpg

LBuI6fZ.jpg

inBoLkS.jpg


So the interpreter I had didn't have the codes at the same location as described in the Google post I referenced .. but I was able to figure out the correct locations (By just looking at it.) Here is the information with updated locations for anyone else who wants to do this edit themselves.

Code:
0010h : Screen initialization. Used at game startup to prepare screen, 
position cursor for first line of output. Suggest including clear screen 
code and code for positioning cursor at beginning of last line of screen. 
05 1A 1B 3D 37 20
Kaypro:
02 1A 1E

0031H : Screen uninitialization. Used when exiting the game to 
de-initialize the screen. Probably not needed unless you want to clear 
the screen on exit. 00
04 1B 43 37 1A

0052h : Status line. Used just before printing status line. Suggest 
including code for nondestructive home cursor, inverse video.
05 0F 1B 3D 20 20
Kaypro: 
0A 1B 42 30 1B 43 37 1B 3D 38 20
A
0073h : Prompt line string. Used just before printing '>' prompt. Suggest 
turning off status line video attributes (e.g. inverse video), 
positioning cursor at beginning of last line of screen.
05 0E 1B 3D 37 20
Kaypro:
0B 1B 43 30 1B 42 37 1B 3D 37 20 0D

0107h?? : Screen width in hex. Must be 0C to 85h. Warning: Anything less 
20h causes funny things to happen to the output. 4F
Kaypro:
4F (was 5F)


        ESCAPE SEQUENCES, CONTROL CODES, AND PORT COMMANDS

Cursor left                        ^H    	   8 - 08h
Cursor right                       ^L         12 - 0Ch
Cursor down                        ^J         10 - 0Ah
Cursor up                          ^K         11 - 0Bh
Erase from cursor to end of screen ^W         23 - 17h
Erase from cursor to end of line   ^X         24 - 18h
Clear screen                       ^Z         26 - 1Ah
  (also cancels special effects)
Home cursor                        ^^         30 - 1Eh

The following are all preceded by ESC, character 27 or 1Bh:



Insert line                        E     or   45h
Delete line                        R     or	  52h
Inverse video on/off               B0/C0 B = 42h 0 = 30h 
Reduced intensity on/off           B1/C1 C = 43h
Blinking on/off                    B2/C2
Underlining on/off                 B3/C3
Cursor visible/invisible           B4/C4
Video mode on/off                  B5/C5   
Remember/recover cursor position   B6/C6
Status line preservation on/off    B7/C7 7 = 37h
Cursor address                     = or 3Dh , row [79 is 4Fh] + 32 (20h), col + 32 (20h)
 
Yes, the slow phosphor and tight, interlaced, video make it a very sharp looking screen. When you are spending hours at the machine, it really makes a difference on eye-strain.
 
you know that crossed my mind as well. Everything looks otherwise normal so I just assumed it was ok. But your right, it should be on top.
 
you know that crossed my mind as well. Everything looks otherwise normal so I just assumed it was ok. But your right, it should be on top.

Your terminal codes configuration uses the 25th line of the Kaypro screen, so that is why the status line is on the bottom. That last ESC code in the "status line" sequence is the direct cursor address sequence for line 24 column 0. Normal output goes to lines 0 through 23. I suspect that on terminals which only support 24 lines of text, you would setup that config to use the top line for status as it simplifies the rest.
 
Your terminal codes configuration uses the 25th line of the Kaypro screen, so that is why the status line is on the bottom. That last ESC code in the "status line" sequence is the direct cursor address sequence for line 24 column 0. Normal output goes to lines 0 through 23. I suspect that on terminals which only support 24 lines of text, you would setup that config to use the top line for status as it simplifies the rest.

Yes exactly!! I looked at screenshots from other platforms and it always had it at the top, but since the Kaypro has the 25th line for "status line" that wouldn't otherwise be used, I moved it to the bottom. Might as well get use out of that line. :) I used the status bar preservation code as well although I gotta say scrolling still is a bit funky where you see flashes of the status bar at the top on the far left side of the screen briefly. It must be something with the way the Kaypro handles the buffer. If I had the bar the top, it would just scroll off until it was redrawn. This way it does stay at the bottom even during scrolling.

Anyway, if someone has a place they want me to upload the Kaypro specific interpreter, let me know. VCFED wouldn't let me upload the .COM file, LOL.
 
Back
Top