View Single Post
Old 16th Apr 2021, 3:15 am   #1697
ortek_service
Octode
 
ortek_service's Avatar
 
Join Date: May 2018
Location: Northampton, Northamptonshire, UK.
Posts: 1,444
Default Re: Non-working Commodore PET 3016

Quote:
Originally Posted by SiriusHardware View Post
I would have thought that somewhere in that hoard of information Owen found, you would find a user port tester program which will probably need a simple loopback connector to work.

Sending values to the user port will involve setting up PORT A of the 6522 to be all outputs (once) by POKEing an appropriate value to the data direction register for PORT A, (POKE 59459,255)? ...then POKEing the values you want to output to the data register for PORT A. (POKE 59471,value)?

This might make for good bedtime reading, although the example for outputting to the port is more complex than it needs to be.

http://cini.classiccmp.org/pdf/kilob...k%20(0379).pdf

Testing the User Port isn't too much different from the testing that's been done with the 6520 for the IEEE. Except that you have to set the Data Direction Register (59459) first. And you read or write just one (59471) Data Register, that is the same for both directions.

So I think it's easiest to just set all lines as outputs: POKE 59459,255
Set all outputs High: POKE 59471,255
Measure the voltages on connector pins C to L, and check they are all >3.5V
Set all outputs Low: POKE 59471,0
Measure the voltages on connector pins C to L, and check they are all <0.4V

Then type-in & Run the Example 3 program, from that PET User Port Cookbook (I've re-attached an OCR'd version, that still looks OK, but programs haven't OCR'd very well).
Ensure it displays 255 (as all inputs are pulled-high by default, inside 6522 VIA) , then connect connector pins C to L, to ground in-turn, one at a time and you should then see 254, 253, 251, 247, 239, 223, 191 & 127.

There's not really anything to go wrong with the user port, other than the 6522 (which is also used by several other things so has to be mostly-working. Just in case it has some damaged Port A lines, I see that Cricklewood list it at the same £15+VAT as the 6502. However, both are available on the 'bay for around £3(+VAT) each inc. delivery for 1off from China (So a slightly longer weight and probably want to check supplier has sold other OK with good feedback, and been around a while to avoid fakes)
Attached Files
File Type: pdf Pet User Port Cookbook (0379)__OCR'd.pdf (2.65 MB, 45 views)

Last edited by ortek_service; 16th Apr 2021 at 3:26 am.
ortek_service is offline