


>>>>>>>>  TEST5099


----------------------------------------------
TARGET
----------------------------------------------

This is code to go into ROM U33 on an IBM 5150 (IBM PC) motherboard.
The IBM 5150 has special ROM requirements. See http://www.minuszerodegrees.net/5150/motherboard/5150_u33.htm


----------------------------------------------
REQUIRED
----------------------------------------------

1. Either a logic probe, or a multimeter (and the knowledge of how to use it to measure DC voltage).

2. A way of putting the BIN file into a suitable ROM/EPROM/EEPROM.
   The IBM 5150 has special ROM requirements. See http://www.minuszerodegrees.net/5150/motherboard/5150_u33.htm


----------------------------------------------
BIN FILES
----------------------------------------------

Per http://www.minuszerodegrees.net/5150/motherboard/5150_u33.htm, if a suitable adapter is used, 16 KB and 32 KB sized ROM/EPROM's can be used on the IBM 5150 motherboard.
Because of that, included here are 16 KB and 32 KB versions of TEST5099_8KB_SIZED.BIN, being TEST5099_16KB_SIZED.BIN and TEST5099_32KB_SIZED.BIN

TEST5099_8KB_SIZED.BIN is for an MCM68766 EPROM, or a 2564 EPROM (2564, not 2764).
TEST5099_16KB_SIZED.BIN is for a 27C128 EPROM (in a suitable adapter).
TEST5099_32KB_SIZED.BIN is for a 27C256 EPROM (in a suitable adapter) or W27E257 EEPROM (in a suitable adapter).

Again, see http://www.minuszerodegrees.net/5150/motherboard/5150_u33.htm


----------------------------------------------
WHAT DOES THE CODE DO ?
----------------------------------------------

It answers the following two questions:

1. Is the POST (power-on self test) in the 27OCT82 BIOS ROM starting and getting as far as the BASE 16KB RAM test ?
2. If the answer to question 1 is yes, is that test passing or failing ?


----------------------------------------------
WHAT YOU SHOULD OBSERVE
----------------------------------------------

If the BASE 16KB RAM test has executed and passed, then a few seconds after power-on, you will:
1. Hear 2 short beeps from the speaker.
2. Then observe that the PB3 (pin 21) on the 8255 chip is toggling (see 'toggling' section below) every two seconds; and
3. Then expect to see (and hear) the relay changing state every two seconds. The 'TEST5099_video_relay.mp4' video shows that.

If the BASE 16KB RAM test has executed and FAILED, then a few seconds after power-on, you will:
1. Hear a series of 8 beeps from the speaker - see the 'error beeps' section below.
2. Then observe that the PB2 (pin 20) on the 8255 chip is toggling (see 'toggling' section below) every two seconds.

If neither 8255 PB3 (pin 21) nor PB2 (pin 20) is toggling, it means that the POST did not get as far as the BASE 16K RAM test.


----------------------------------------------
ERROR BEEPS
----------------------------------------------
If the BASE 16KB RAM test has executed and FAILED, then a few seconds after power-on, you will hear a series of 8 beeps from the speaker.

Some beeps are short, some are long. Short corresponds to a 0. Long corresponds to a 1.

The eight beeps (eight 0's and 1's) make up a byte. The order of beeps is bit 7 to bit 0 (MSB to LSB).
For example, if you hear short-long-short-short-short-short-short-short, that is 01000000 binary, or 40 hex.

00 hex (00000000) = Failure of parity bit
01 hex (00000001) = Failure of bit 0
02 hex (00000010) = Failure of bit 1
04 hex (00000100) = Failure of bit 2
08 hex (00001000) = Failure of bit 3
10 hex (00010000) = Failure of bit 4
20 hex (00100000) = Failure of bit 5
40 hex (01000000) = Failure of bit 6
80 hex (10000000) = Failure of bit 7

Anything else indicates multiple bits. For example, 28 hex (00101000) indicates bits 5 and 3.

See the following link for a diagram showing the layout of RAM chips in bank 0 on the IBM 5150 motherboard:
https://minuszerodegrees.net/5150_5160/ram/5150_5160_motherboard_ram_layout.jpg


----------------------------------------------
TOGGLING
----------------------------------------------

'Toggling' can be observed by monitoring the PB2/PB3 pins via a logic probe, or via a multimeter (in 'DC voltage' mode).

If using a multimeter (instead of a logic probe):
- Put meter into 'DC voltage' mode.
- Put the negative probe on pin 7 of the 8255 (or on any ground).
- Put the positive probe on pin 20 of the 8255.

The 'TEST5099_video_multimeter.mp4' video shows what is seen if a multimeter (in 'DC voltage' mode) is used.


----------------------------------------------
HOW THIS 'TEST5099' CODE WAS CREATED BY ME
----------------------------------------------

Step 1: I obtained the BIN file for the 27OCT82 BIOS ROM.

Step 2: I then located the section that does the BASE 16KB RAM test. I found that by referring to the BIOS source listing in the final technical reference for the IBM 5150.

Step 3: I modified the BASE 16KB RAM test code.

Step 4: I altered the final byte to restore an 8-bit checksum of 00. At this point, I had the file TEST5099_8K.BIN

Step 5: Doubled TEST5099_8K.BIN to create TEST5099_16K.BIN

Step 6: Doubled TEST5099_16K.BIN to create TEST5099_32K.BIN  (for use in 27C256 or W27E257)


----------------------------------------------
HOW THIS 'TEST5099' CODE WAS TESTED BY ME
----------------------------------------------

Step 1: Known good IBM 5150 motherboard of type 64KB-256KB.
Step 2: U33 BIOS ROM swapped out for a suitable EPROM containing TEST5099_32K.BIN
Step 3: Powered on motherboard.
Step 4: After a few seconds, heard 2 short beeps from the speaker.
Step 5: Then, observed PB3 (pin 21) on the 8255 chip toggling, and the relay clicking every two seconds. (Endless)
Step 6: Observed PB2 (pin 20) on the 8255 chip NOT toggling.
Step 7: Powered off motherboard.
Step 8: Simulated RAM failure by grounding pin 2 of the bit 6 RAM chip (4164 class) in RAM bank 0.
Step 9: Powered on motherboard.
Step 10: After a few seconds, from the speaker, heard the bit error pattern of short-long-short-short-short-short-short-short (01000000).
Step 11: Then, observed PB2 (pin 20) on the 8255 chip toggling. (Endless)
Step 12: Observed PB3 (pin 21) on the 8255 chip NOT toggling.












