VOGONS


First post, by goostaw

User metadata
Rank Newbie
Rank
Newbie

Hi. I have a problem with the game "Below the root".

Works on all dos computers I have except IBM 5155. The game hangs right after the control selection screen (keyboard, joystick)
I checked both versions - pc booter and DOS.
My IBM has 256kB Ram, but I also checked with an additional RAM card (640 in total). Same.
what is going on? what would somebody check on their Ibm?
I will be grateful for your help.

Reply 1 of 12, by kdr

User metadata
Rank Member
Rank
Member

My first thought was that the game might be compiled to use 80286 instructions, but then I looked up the game and saw it was from 1984. 😀

Have you been able to run your copy of the game on any other 8088 machines? I've had a couple of programs hang or otherwise exhibit weird behaviour and the root cause (heh) was actually some bits getting flipped during the download/transfer/write to floppy process.

But the 5155 uses exactly the same system board as the 5160. It's as 100% IBM PC compatible as one can get. So that's why I think there must be something else wrong. Do any other games or programs not work on the 5155? I'd recommend running a comprehensive test (try Check-It 2.1 or 3.0) just to rule out any hardware glitches or bad memory.

I have a 5155 that I am going to get out of storage again soonish, can definitely give the game a try to confirm whether it does or doesn't work.

Reply 2 of 12, by VileR

User metadata
Rank l33t
Rank
l33t
kdr wrote on 2020-10-15, 22:35:

My first thought was that the game might be compiled to use 80286 instructions, but then I looked up the game and saw it was from 1984. 😀

A game from 1984 can come from the internet in a form that was 'deprotected' much later. I've seen enough cases where a game was written for the 8088, but comes with a crack/loader that uses 386 code, or depends on AT BIOS calls. 🤦

On the other hand, the OP says he tried at least two versions, so that may not be the case. Still possible, just less likely.
All I know is that BTR runs fine on my 5160, which like you said, is pretty much identical to the 5155.

@goostaw: is your 5155 'stock'? does it have the original BIOS (which revision)? Any extra cards you might have in there?
Is BTR the only thing that hangs/misbehaves on it?

[ WEB ] - [ BLOG ] - [ TUBE ] - [ CODE ]

Reply 3 of 12, by leileilol

User metadata
Rank l33t++
Rank
l33t++
VileR wrote on 2020-10-16, 00:32:
kdr wrote on 2020-10-15, 22:35:

My first thought was that the game might be compiled to use 80286 instructions, but then I looked up the game and saw it was from 1984. 😀

A game from 1984 can come from the internet in a form that was 'deprotected' much later.

I've seen a deprotected/loader'd version from far earlier (1986) that's definitely nothing to do with the commonly recirculated 1998 "abandonware" one, and it's buried in time.

apsosig.png
long live PCem

Reply 4 of 12, by goostaw

User metadata
Rank Newbie
Rank
Newbie

Thanks for the answers.

kdr wrote on 2020-10-15, 22:35:

Have you been able to run your copy of the game on any other 8088 machines? I've had a couple of programs hang or otherwise exhibit weird behaviour and the root cause (heh) was actually some bits getting flipped during the download/transfer/write to floppy process.

But the 5155 uses exactly the same system board as the 5160. It's as 100% IBM PC compatible as one can get. So that's why I think there must be something else wrong. Do any other games or programs not work on the 5155? I'd recommend running a comprehensive test (try Check-It 2.1 or 3.0) just to rule out any hardware glitches or bad memory.

I have a 5155 that I am going to get out of storage again soonish, can definitely give the game a try to confirm whether it does or doesn't work.

1. Yes. I have tried different copies and yes, the concrete copy works on Bondwell b200 Laptop. (80C88)
2. I ran the check-it. No hardware problems seen. I don't remember a program that wouldn't run on my 5155 but ran on another computer.
3. Yes. Please check the game on your 5155. I bet it won't work. 😀

VileR wrote on 2020-10-16, 00:32:

@goostaw: is your 5155 'stock'? does it have the original BIOS (which revision)? Any extra cards you might have in there?
Is BTR the only thing that hangs/misbehaves on it?

1. Yes. Stock.
2. Original Bios rev. 11/08/82

3. I also tested in the simplest configuration - only with fdd controller and cga card (both stock).
4. Yes . BTR is only one.

On another forum, one of the users confirmed the problem with the game and 5155. Interestingly, the game works on 5160 (the same mainboard)
'Probably a bug in the "determine what this machine is" code, which reads the Model ID byte in ROM.'

It makes sense, but afaik id. byte is in FFFFE
FE is there:
FE = XT or Portable PC

The conclusion is that either the game assumes there is an FB (xt with 640kB mainboard) in there, or more likely something else.
This is a lead. I'll try to check it out.

Attachments

Reply 5 of 12, by kdr

User metadata
Rank Member
Rank
Member
goostaw wrote on 2020-10-16, 09:26:
On another forum, one of the users confirmed the problem with the game and 5155. Interestingly, the game works on 5160 (the same […]
Show full quote

On another forum, one of the users confirmed the problem with the game and 5155. Interestingly, the game works on 5160 (the same mainboard)
'Probably a bug in the "determine what this machine is" code, which reads the Model ID byte in ROM.'

It makes sense, but afaik id. byte is in FFFFE
FE is there:
FE = XT or Portable PC

The conclusion is that either the game assumes there is an FB (xt with 640kB mainboard) in there, or more likely something else.
This is a lead. I'll try to check it out.

Yes, I saw that Trixter has confirmed that it works on a 5160 but not on a 5155. Fascinating! I was certain that they were identical, but it seems not?

Thanks for posting about this game, what an interesting thing to discover.... will definitely be trying it on my 5155 in the near future...

Reply 6 of 12, by kdr

User metadata
Rank Member
Rank
Member

Well, I couldn't resist, so I've unpacked the 5155 and found a copy of the game. It's the one with a tiny LOADER.COM, not the booter. (Which I wasn't able to find.)

The results: running PC DOS 2.10, the LOADER.COM did nothing and just returned me to the DOS prompt. Running MS-DOS 3.30, the LOADER.COM worked and was able to load the game. Upon startup, it displayed the 'select control' screen but then *immediately* displayed the main menu screen [skipping the intro, it would seem] without any keys being pressed. And once on the menu screen, it wouldn't accept any key input. It didn't freeze the machine, though: eventually the keyboard buffer filled up and I started getting beeps (from the BIOS) with any additional keypresses.

IIMG_20201016_235739.jpg
Filename
IIMG_20201016_235739.jpg
File size
222.63 KiB
Views
962 views
File license
CC-BY-4.0

It sounds like this might be slightly different to what you experienced?

I can confirm that my generic turbo XT clone system was able to run the game as expected from the same floppy.

My 5155 also has the 11/08/82 BIOS, but it's not the original CPU. At some point in the distant past, the machine had its original 8088 CPU removed and replaced with a 286 accelerator card. So in the process of restoring the 5155 to "stock" configuration I have installed an AMD P8088-1. I've got the original CGA and floppy adapters installed as well as an AST SixPackPlus to bring it up to 640K RAM.

IIMG_20201017_000138.jpg
Filename
IIMG_20201017_000138.jpg
File size
109.71 KiB
Views
962 views
File license
CC-BY-4.0

Reply 8 of 12, by VileR

User metadata
Rank l33t
Rank
l33t

Hm. My first thought before my previous post was the Model ID byte, but I looked it up and found that it's identical to the 5160 (as expected).
And indeed the only branch is on the value of FDh (PCjr), so that can't be it.

OTOH, I just remembered that Trixter had long ago mentioned a certain keyboard-related problem with the 5155 that didn't show up on 5160s, so I'll ping him about that one. If those freezes you guys are describing are due to the keyboard buffer filling up w/beeps (i.e. unhandled keystrokes), it MAY be related somehow... very weird!

Edit: Okay, resolved on VCF - and yep, it's the keyboard, more precisely the lack of a keyboard controller in the 5155. So even if I was beaten to the punch, at least my hunch was validated 😎

[ WEB ] - [ BLOG ] - [ TUBE ] - [ CODE ]

Reply 9 of 12, by kdr

User metadata
Rank Member
Rank
Member

I was able to play Below the Root on my 5155 tonight:

IMG_20201018_001005.jpg
Filename
IMG_20201018_001005.jpg
File size
1007.41 KiB
Views
875 views
File comment
Enjoying the intro in all its amber glory
File license
CC-BY-4.0
IMG_20201018_001044.jpg
Filename
IMG_20201018_001044.jpg
File size
618.69 KiB
Views
875 views
File comment
Playing the game on a teensy tiny CRT
File license
CC-BY-4.0

This has been quite a mystery, because several people reported that this game worked just fine on an IBM model 5160. Which we know uses the exact same motherboard and BIOS as the 5155 portable. And aside from the 5155 having a built-in 9" amber monochrome CRT, the two systems are identical.... or are they?

They're not! The 5155 has a different keyboard! My epiphany was to try plugging in my regular XT keyboard into the 5155. And sure enough, that did the trick, and the game worked perfectly.

Reply 10 of 12, by goostaw

User metadata
Rank Newbie
Rank
Newbie

Thanks for the tests. A big step forward. 😀
It is a pity that I do not have such a keyboard.

From what you wrote on another forum, only the original 5160 keyboard works with the game and if I understand correctly, it does not work with the generic XT keyboard.

So my guess is that the 5155 keyboard connected to the pc xt clone will not cause problems with the game?

Reply 11 of 12, by dosenfisch

User metadata
Rank Newbie
Rank
Newbie

The issue is not only the keyboard. My 5155 uses an IBM XT mainboard (newer version with 640KB of ram onboard) because the original one went bad ~10 years ago and I wanted more ram anyway. Long story short, the game runs without any issues, even with the original 5155 keyboard. I'm using MS-DOS 5.00, a NEC V20 CPU and a CF card as mass storage (via the XT-IDE card from monotech).

Reply 12 of 12, by goostaw

User metadata
Rank Newbie
Rank
Newbie

I came back to the topic after a long time.

I managed to sell 5155 and after some time I bought two more following the spirit of nostalgia.
Imagine my surprise when both of my ibm portables started BTR without any problem.
I was happy and did not pursue the topic.

I was even more surprised when after some time it turned out that the game freezes again.
This bothered me so I loaded (loader.com) the DOS version of BTR into debug and traced what the program was doing.

First, it loads 3 files into memory, sets int63h (i/o calls redirect?) and transfers control to belowroot.exe.
And that's where EVIL happens.
The program calls int 11h ( bios config ) and TESTs the presence of game port. If it finds it, it skips several instructions that clear several bytes in memory.

In my case, the bit indicating the presence of the game port was ON although the game port was not physically present.

Of course, I thought about what I had changed in the configuration since the game was working. Well - I took out the game port card. (I don't have a joystick yet)

So I put the game port into the computer. And here I was surprised for the third time. It turned out that the bios says that there is no game port (zeroed bit).

I fired up the btr and it worked. Conclusion (wrong as it later turned out) - This bit works inversely ( 0 - game port present. )

After exiting the game surprise #4: The bit is on again.
I launched the game - it works.
At this point, I was numb!

Conclusion 1 : If there is NO game port on your computer and for some reason the game port bit is ON then the game crashes.
Conclusion 2 : If there IS a game port on your computer, it doesn't matter if the bit is on or off. Game works ( with keyboard )

I thought I'd check.
The jump instruction in the absence of a game port BYPASS a piece of code. So it is enough to replace two 751B bytes (1B jump) into two NOPs. - the game starts (with the keyboard) and seems to work without a problem.

Quick solution:
1. open 'btroot.exe' in hex editor.
2. search for '751B' ( first occurrence )
3. replace with '9090'
4. save the file.

I wrote a simple patch for 5155 if you wish.
Put it in the directory with btroot.exe and run it.

 
.model tiny
.code
org 100h
start: jmp begin

fname db 'btroot.exe', 0
newval db 90h,90h
handle dw ?
errcode db ?
errmsg db 'error 0x','$'
sucmsg db 'File sucessfully patched!','$'

begin: mov ax,3D02h ; open file
lea dx,fname
int 21h
jc errors
mov handle,ax

mov ax,4200h ; move pointer
mov bx,handle
mov cx,0h
mov dx,20DAh
int 21h
jc errors

mov ah, 40h
mov bx,handle
mov cx,02h
lea dx,newval
int 21h
jc errors

mov ah,3Eh ; close file
mov bx,handle
int 21h
jc errors

mov ah,09h
lea dx,sucmsg
int 21h

fine: ret ; 0 to IP from stack ( int 20 )

print_byte_hex proc near
push cx
push dx
mov dh,dl ; copy byte
mov cx,4
shr dl,cl ; first digit
call print_digit
xchg dl,dh
and dl,0Fh ; second one
call print_digit
pop dx
pop cx
ret
print_byte_hex endp
print_digit proc near
cmp dl,0Ah
Show last 21 lines
	jae	letter
or dl,30h
jmp print
letter: add dl,'A' - 0Ah
print: mov ah,02h
int 21h
ret
print_digit endp

errors: mov errcode,al
mov ah,09h
lea dx,errmsg
int 21h
mov dl,errcode
call print_byte_hex
jmp fine

end start


The solution is dirty and I still don't know why Bios once claims that there is a game port and the second time that it does not exist, although the fact is that it does not exist.

Maybe someone can educate me on this topic.

I think it might have something to do with the keyboard. If there is no gameport and the game hangs then
after a soft reset, the keyboard "goes crazy" (the screen prints several characters after one press)

Attachments

  • Filename
    55patch.zip
    File size
    1.83 KiB
    Downloads
    39 downloads
    File license
    Public domain