• Please review our updated Terms and Rules here

CBM (PET) 2001-8-BS

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
3,024
Location
Australia
I just received my first CBM computer. Pictures attached.

It appears to be basically working (no pun intended). I managed to run a short BASIC program.

I have yet to figure out so many things about it. For example:

How can I tell what version of BASIC it is running; 4. something or 3. something ?

What motherboard version it has, and the purpose of the 3 empty IC sockets there ?

Also the connector J4 memory expansion, it looks like with the upward facing pins it could have a card plugged onto it that resides inside the computer?

The good news is that it got shipped all the way from the UK to me in Australia without any significant damage, I was expecting the neck to be broken off the CRT, but I was lucky this time.

In any case, any advice on how to check & verify it would help.

Is there a memory test program where I can check the RAM, it seems hard to believe that all the RAM IC's are ok, but I guess they might be.

( I have ordered an SD2PET)
 

Attachments

  • CBM1.jpg
    CBM1.jpg
    354.3 KB · Views: 30
  • CBM2.jpg
    CBM2.jpg
    375.5 KB · Views: 29
  • CBM3.jpg
    CBM3.jpg
    450.7 KB · Views: 31

daver2

Veteran Member
Joined
Jun 19, 2012
Messages
8,698
Location
UK - Worcester
Welcome to the PET owners' club Hugo.

Glad it all arrived in one piece and we don't have another repair on our hands!

>>> How can I tell what version of BASIC it is running; 4. something or 3. something ?

This is the upgraded version of BASIC (so V2 or V3). The different versions of BASIC had different sign-on messages. This version fixes a number of bugs with the original - and the IEEE488 port actually works! It also adds a little machine code monitor called TIM. See here for more details http://www.icpug.org.uk/national/archives/020227ar.htm. If you can identify the part numbers on the ROMS that will tell us the version of BASIC that you actually have.

For a bit of fun try the command WAIT 6502,1

>>> What motherboard version it has, and the purpose of the 3 empty IC sockets there ?

Look for the magic part number on it and refer to the Zimmers website for the schematic, layout, ROM images etc. I am guessing this is your machine http://www.zimmers.net/anonftp/pub/cbm/schematics/computers/pet/2001N/index.html.

The empty sockets are for ROM expansion. If you decide to upgrade the version of BASIC to V4, one of these will be used. The other sockets can be used for plug-in application code (such as an enhanced debug monitor, word processor dongle etc.). BASIC enhancements were also added here (for example, graphics routines, AUTONUMBER etc.). Some disk controllers plugged into the USER port or the MEMORY EXPANSION port - so required BASIC ROM extensions to operate. The firmware plugs into these sockets. I developed some robot control software to fit in one of these on an 8032 whilst at university.

>>> Also the connector J4 memory expansion, it looks like with the upward facing pins it could have a card plugged onto it that resides inside the computer?

The general case was an external box and two ribbon cables between the external box and the PET. This was the case with my robot interface.

>>> In any case, any advice on how to check & verify it would help.
>>> Is there a memory test program where I can check the RAM, it seems hard to believe that all the RAM IC's are ok, but I guess they might be.

If you download a copy of my PETTESTER code you can burn it into a 2K EPROM (2716) and replace the EDIT ROM at address $Exxx. This will test a number of functions (e.g. VDU, page 0 and 1 RAM, ROM checksums etc.) and then thrash the DRAM to death with a MARCH-C memory test.

I can provide a link to my PETTESTER code if you can't find it on the Commodore forum when I get back from work (i.e. walk downstairs)!

Dave
 
Last edited:

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
3,024
Location
Australia
Hi Dave,

Thanks, That Zimmers link looks right to me.

There is a hand written number on the board, B5654649, but the B could be a "13" and the second 5 in the sequence could be a 3.

I looked at the ROM numbers:

901465-03 (UD9)
901447-24 (UD8)
901465-02 (UD7) Writing very difficult to read
901465-01 (UD6) Writing very difficult to read

I assume the other 4 digits on them are the date codes.
 

daver2

Veteran Member
Joined
Jun 19, 2012
Messages
8,698
Location
UK - Worcester
Hi Hugo.

The hand written number will be the serial number (or something like that). The board assembly number will be either on the silk screen or part of the copper etch (or both).

The firmware is here: http://www.zimmers.net/anonftp/pub/cbm/firmware/computers/pet/index.html.

Three of the ROMs appear to be classed as BASIC 2. But the fourth (UD8 EDIT ROM) appears to be BASIC 3. The upgrade ‘may’ have been the EDIT ROM only?

Dave
 

dave_m

Veteran Member
Joined
Feb 2, 2009
Messages
3,577
Location
Southern California, USA
BASIC 2 ROM set for 40 columns normal keyboard and no CRTC. Lucky you have the 2332/6332 ROMs which you can replace with 2532 EPROMs if needed, and 2114 RAMs which are easy to replace and all on sockets.

And it appears to work. Later you may want to get a RAM/ROM board to plug into the CPU socket and expand the RAM to 32K, and to run BASIC 4 if wanted. But you will have lots of fun as it is.
 

Eudimorphodon

Veteran Member
Joined
May 9, 2011
Messages
5,310
Location
Upper Triassic
2114 RAMs which are easy to replace and all on sockets.

This is a dynamic board with 32K, so it's all 4116s.

I'm going to guess that's not the original motherboard; my spider-senses tell me, based on its "3008" designation, that it shipped with a 4108-equipped board with holes drilled in it (as discussed in the other thread) and with the 4108s soldered down, and when it was upgraded the board was swapped to a new one. (possibly a fully-socket service part? All my PETs have the factory RAM soldered down.) But since there *are* sockets it's also possible it's the original board but Commodore had laid off the drilling thing by the time it was made, which allowed someone to add the sockets themselves. I guess a peek at the bottom to see if they look wave-soldered might settle that.
 

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
3,024
Location
Australia
All the RAMs are the 4116's, luckily I have some in my stock. It is interesting , looking at the RAM sockets, they look to me like factory soldering. But, close inspection shows that there were two tracks that appear to be not present on the board, linking some of the RAM's pins, and these were bypassed with two link wires on the surface, that pass under the sockets, between two sockets where the extra row of RAM is, but it has been so well done that it looks factory to me. There is no evidence of any drill holes. I will check the bottom of the board to see if it looks like those RAM sockets were added later, or not.

Why is the EDIT ROM (UD8) called the "EDIT" ROM ?

Also, I noticed the jumper system, of those horrible kind of jumpers where they get cut, or not. Some have been cut, then re-soldered. Is there any reason why those cannot be DIP switches, or are there some possible switch settings that could cause damage ?

Another observation. One of the screws for the rear VDU panel was missing. I found that the size/thread is 2BA. Very close to 5mm metric, but a fraction smaller in diameter. This would be a very uncommon thread & size in the USA, but very common in the UK. These sorts of screws with the same heads are available as spare parts for Triumph bikes/cars:

 
Last edited:

Eudimorphodon

Veteran Member
Joined
May 9, 2011
Messages
5,310
Location
Upper Triassic
If those "pettester" binaries are the original version I wrote a decade ago they're not what you want for testing your apparently fully functional (or close enough to it, at least) machine. They're only useful for helping suss out why a truly lifeless PET can't get past a "garbage screen. (Basically I had a goofy idea for writing a ROM program that could tell me a little bit more than a NOP generator, which works because the PET is such an incredibly simple machine. The ROM will work as long as the main address decoder chip and the wiring between the CPU and the first ROM socket is complete, and the code gives you visual indications about whether the CPU can write to video RAM, if the character generator works, if there are stuck bits in VRAM, and it does an extremely crude memory test of the first 1K of RAM, crucial because the zero page and stack live there.) If you're getting to the BASIC prompt you're well past their ability to tell you anything.
 

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
3,024
Location
Australia
If those "pettester" binaries are the original version I wrote a decade ago they're not what you want for testing your apparently fully functional (or close enough to it, at least) machine. If you're getting to the BASIC prompt you're well past their ability to tell you anything.

What would be the easiest way to check the entire 4116 RAM array ?

(In my Sol-20 for example to check the motherboard Ram, I wrote an assembly language program, to check the character gen IC & video memory and the small on board Ram. But I don't know how I would do that in BASIC yet. And for checking the added Ram on the S-100 cards I used the MEMTEST program).

So PETTESTER2KV04.zip is Dave R's (Daver2) version and there are a total three versions of Pet Tester programs ?
 
Last edited:

daver2

Veteran Member
Joined
Jun 19, 2012
Messages
8,698
Location
UK - Worcester
>>> Is that exclamation mark normal or an abnormal character ?

Normal. Legend has it this Easter Egg was added by Bill Gates himself after an argument with Jack Tramiel (the founder of Commodore). But...

Yes, there are multiple versions.

The original pettester was originally written by Eudi to check out pages 0 and 1 RAM. This worked with a non-CRTC.

Dave_m modified it to initialise the CRTC so it would work with both a CRTC and non-CRTC PET.

I then took that as an idea and went mad with the tests... My firmware should work on anything apart from a 40 column CRTC PET - where a modification to the CRTC initialisation table is required. The source code and documentation is available on my Google Drive (which I completely forget to post for you yesterday. Sorry about that - I will do it today for you.

There are a couple of ROM/RAM boards that can replace the PET components that also contain a NOP generator and my various test programs (mine amongst them).

Dave
 

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
3,024
Location
Australia
My PET developed its first fault, the main filter cap, 23,000uF 15V capacitor had dropped in capacity so the ripple voltages appeared in the video. I had a 18,000uF 16V cap on hand with the same screw terminals. The original was made in 1979. It might re-form, but I am not much of a capacitor re-former, I have come to regard electrolytics over the years as "disposable" items, any sign of a defect I prefer to replace them.

A while back on another thread there was talk of the 4 state machine in the PET, and Dave (daver2) said it was a "Bear" to fix. This got me interested, so I examined the one in my pet. And I can see why this could be the case. (see attached diagram). In essence it is simply a two bit counter with a non standard counting sequence where the count is msb,lsb ; 0,0---0,1---1,1---1,0 then back to 0,0. Rather than counting the usual 0,0---0,1---1,0----1,1 sequence.

However, I realized that , being a divide by 4 counter, it couldn't possibly produce the duty cycle of the /vertical drive pulse, only 1.28 mS wide, it would have to have a pause in the clocking signal to attain the 16.7mS period.

It is the clock pulses here that are interesting and "tricky" in a number of ways:

The first thing is they come in a group of 4 pulses and they are incredibly narrow, only about 100nS wide & difficult to see on the scope. The counters are clocked on the falling edge. I was able to view them on a scope with a delay timebase and just with my 2465B. Then there is the timing registration, in that that when the counters are initialized after power up, they are cleared to condition 00 by /INIT, which means that the first clock pulse, which then sets the counter to condition 0,1, must be the 3rd pulse in the sequence of the 4 pulses !

The above circuit therefore could get out of step, it obviously could happen with a fault elsewhere altering the clock pulse start sequence, or it could happen say after the unit was powered, with say a momentary short of any of the counter terminals disrupting the sequence while testing with probes. At least now this is documented, if it is malfunctioning, the correct timing of the groups of 4 pulses with respect to the /Vertical Drive pulse and Video ON pulse can be checked. If this was not working, I think I would have found it very difficult to fix without knowing what those clock pulses were supposed to look like and the difficulty of visualizing them on the scope.

In the meantime my SD2PET arrived. Can anybody point me to a source of some BASIC programs I could get onto an SD card to try it out ?
 

Attachments

  • CBM4STATE.jpg
    CBM4STATE.jpg
    191 KB · Views: 9

daver2

Veteran Member
Joined
Jun 19, 2012
Messages
8,698
Location
UK - Worcester
Hi Hugo,

I was in the same camp as you with regard to electrolytic capacitors - until I priced up replacing them all in my DEC PDP-11/45 power supply units. HOW MUCH! Nope, reformatting those bad boys at that price! I have managed to save most of them - with the exception of one of the units. They were bulging and leaking, so I will have to replace those (at a much lighter load on my wallet).

It's great to have you onboard with your vast hardware knowledge looking at the PET. I have been meaning to code up some of the PET logic in LOGISIM so that we can simulate what should happen - but that hasn't happened as of yet.

That's one of the circuits you have identified. The other one is G3/F4 and F2 on schematic 7 of 9. That is the major state machine that looks relatively simple - but a nightmare to fault find on.

I'll hunt out some PET software URLs for you in the meantime. EDIT: Start here: http://www.6502.org/users/andre/petindex/sw.html#archives.

If you checkout the SuperPET link from there (not that you can run the software without the 6809 add-on board) you will find some of my previous work to remove the 6702 dongle protection from the software. I then worked out how to make the software work by 'guessing' (with the help of a genetic algorithm) what the 6702 silicon actually contained to return the 'correct answers' to fool the software/firmware. A number of us then worked on a collaborative project to disassemble the silicon itself. We made a physical model of the silicon and interfaced that to the VICE emulator - which worked. and then I deduced the actual schematic from the that by persuading Excel to identify transistor, resistor and protection diode configurations within the silicon and then spit out a netlist. I then hand-drew the schematics... That was a really interesting project.

There is a much better write up here: http://mikenaberezny.com/hardware/superpet/waterloo-languages/ along with a 6702 chip simulation you can run... I see the link is now broken - but the ZIP file is still there to download and play with (if it still works in a modern browser that is).

I think everything is still on my Google Drive - which reminds me, I still haven't provided you with a link to my PETTESTER code and documentation have I?!

Dave
 
Last edited:

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
3,024
Location
Australia
My PETTESTER code (source, HEX, BIN and documentation) can be found at: https://drive.google.com/drive/folders/1fyLbr1kcG98a2FDOMo1H5pj9lIdJpHcx?usp=sharing.

My MOS6702 project (if you are interested) can be found at: https://drive.google.com/drive/folders/16rN27IjVkuGUETSxi41oe8mdSVLv_SWJ?usp=sharing.

Dave
That is great, what a wonderful 16 page manual. I like that as I have a lot of trouble trying to figure our how to use use something for the first time if the user instructions are not in front of me. And thanks for all the other information.

For example, I received the SD2PET, there was no SD card with it and no instructions, but I later found a user guide on the net. Then I realized I should have bought a formatted SD card with some software on it called a "download pack" that contains a DOS Wedge. So I'm working on making that card. I might have to get an external USB reader as the SD card reader slot, which has never been used on my HP computer, has some corrosion.

I'm "guessing" that when working the SD2PET will simulate the Disk drive in a manner where it would need to be opened with something like OPEN 1,8,15 and then initialized with PRINT#1,"I" but I am not certain.

While I was waiting for the PET to arrive, I started looking at the VDU circuitry and built and tested some circuitry. The idea of it is that it gifts the VDU with scan oscillators that run independently of the computer, and as it is in TV sets, these are synchronized to incoming signals, but if the incoming signals are noise or way off frequency, the oscillators simply just unlock and run close to normal frequency. This is why TV's are not damaged by abnormal syncs, even if that is just total snow or noise. Attached is just a provisional circuit I have tested. The idea is the circuitry just drops in with two wires where a resistor & diode is removed from the board.
 

Attachments

  • PETVDUSAVER.jpg
    PETVDUSAVER.jpg
    264 KB · Views: 6

daver2

Veteran Member
Joined
Jun 19, 2012
Messages
8,698
Location
UK - Worcester
Hugo,

You shouldn’t need the wedge. We all know about wedges now don’t we with your AIM-65!

The only commands you should need are:

LOAD “$”,8
LIST

The above lists the disk catalogue.

LOAD “filename”,8
SAVE “filename”,8
VERIFY “filename”,8

Unit 8 is generically assigned to the first disk drive.

I think you can start with a blank FAT16 card. But not 100% sure on this one.

Dave
 

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
3,024
Location
Australia
Thanks Dave.

I formatted the card on sdcard.org, using their utility. It gave no choice about the format options and it formatted the card as FAT32.

I got sent this link, which when it is extracted contains 6 folders and inside those many other folders with programs and various utilities that I am not certain of the significance of. In there is also the user manual for the SD2PET :


Daft question perhaps, being unfamiliar with the system, is the computer expecting to see only d64 (or d80 ?)style files, or disk images, on the SD card and should I only load d64 images to the card, or will it run just individual .BAS or .prg files files from the card if I load them there? Many of the files, some look like games, do not appear to have a specific file extension and I don't know if they are disk images or not.

For example, I loaded the game Aliens!.prg onto the SD card. On the computer when I type LOAD "Aliens!",8 it comes up with
SEARCHING FOR ALIENS!
LOADING

and just sits there unable to find or load it, it seems.

Am I doing something wrong (likely), or could there be another problem ?
 
Last edited:

daver2

Veteran Member
Joined
Jun 19, 2012
Messages
8,698
Location
UK - Worcester
It’s too late in the UK to think at the moment... I’ll have a look tomorrow.

I would perform a listing of the disk as the first thing rather than attempting to load anything... That’s the LOAD “$”,8 command followed by a LIST.

Dave
 
Top