Trying to pinpoint a problem with serial circuit
Trying to pinpoint a problem with serial circuit
I have pretty much finished transferring my homebrew computer from bread to protoboard, however I seem to be having a problem with the serial circuit. It's a 6551 chip, with a MAX232 to convert voltages. It seems the circuit works when I press down on the crystal, while resetting. Thought it could be a wiring problem so I resoldered the crystal wires. Now it doesn't work at all! I used garth's 22pf cap idea at pin 6 to ground idea to clean the signal btw (which worked before). Voltages at both ends seem good, so any ideas what I causing it?
- BigDumbDinosaur
- Posts: 9426
- Joined: 28 May 2009
- Location: Midwestern USA (JB Pritzker’s dystopia)
- Contact:
Re: Trying to pinpoint a problem with serial circuit
ioncannon wrote:
I have pretty much finished transferring my homebrew computer from bread to protoboard, however I seem to be having a problem with the serial circuit. It's a 6551 chip, with a MAX232 to convert voltages. It seems the circuit works when I press down on the crystal, while resetting. Thought it could be a wiring problem so I resoldered the crystal wires. Now it doesn't work at all! I used garth's 22pf cap idea at pin 6 to ground idea to clean the signal btw (which worked before). Voltages at both ends seem good, so any ideas what I causing it?
First determine if the crystal is oscillating. If you have a 'scope you should be able to detect a clean and symmetric waveform at the crystal. A logic probe can also help if a 'scope isn't handy. If you see nothing, suspect the crystal. Clock crystals are high volume commodity parts and a 2-3 percent failure rate per lot is not unheard of. Also, you may need to bond the crystal's case to ground to get a stable oscillation.
If the crystal is oscillating and the signal is present at pins 6 and 7 (PDIP package) of the 6551, verify that you have a Ø2 clock present at pin 27 of the 6551. Also, tie DCD (pin 16) low for testing (and leave low if you aren't going to connect a modem).
The 6551's chip selects should be active as soon as a valid address is placed on A0-A15 by the MPU. When Ø2 goes high D0-D7 will become valid and you should be able to read or write the chip. Interfacing the 6551 with the 65C02 is very straightforward (a little less so with the 65C816).
x86? We ain't got no x86. We don't NEED no stinking x86!
Well it seemed to have been a mixture of broken crystal and not grounded crystal. I think the reason it worked when I touched it was my finger was grounding the case. Thanks for the info, didn't realize they had to be grounded. I don't know how it worked before, probably a stray ground wire grounding it or something. Anyway, soldered a ground wire to the new crystal and I am getting output. It's coming in as the wrong characters (I am using my old Win3.1 computer as a terminal, so maybe that is why) but the amount that comes in is correct so the cpu/ram/rom/6551 side of things should be correct. Probably the Terminal program isn't set correctly.
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Then I wonder if there's something else wrong with the crystal and grounding the case just got oscillation started but at the wrong frequency. Do you have a 'scope or frequency counter? I have never grounded the case of the crystal (it usually came with a gray heat-shrink plastic insulating label over it anyway) and have never had any problem. I put the crystal from pin 6 to pin 7, and a 22pF capacitor from 6 (the input) to ground.
- BigDumbDinosaur
- Posts: 9426
- Joined: 28 May 2009
- Location: Midwestern USA (JB Pritzker’s dystopia)
- Contact:
GARTHWILSON wrote:
Then I wonder if there's something else wrong with the crystal and grounding the case just got oscillation started but at the wrong frequency. Do you have a 'scope or frequency counter? I have never grounded the case of the crystal (it usually came with a gray heat-shrink plastic insulating label over it anyway) and have never had any problem. I put the crystal from pin 6 to pin 7, and a 22pF capacitor from 6 (the input) to ground.
I have, on occasion, run into crystals that weren't stable if the case wasn't grounded. I suspect in this particular case (no pun intended) that there may be other issues. What type of capacitor did you use for that 22pf part?
x86? We ain't got no x86. We don't NEED no stinking x86!
I went through all this when I tried to build a UK101 clone. The clock just would not tick, even though it is exactly the same as the original machine. Have you a circuit diagram of just the clock circuit?
Here's a link to the one that worked:
viewtopic.php?t=1795&postdays=0&postorder=asc&start=120
That's part of a long long thread that describes the build and all the problems I encountered (and eventually overcame with the help of the community). On my machine, the clock circuit runs at 8Mhz which is then divided down three times by a 74LS93 to yield 1Mhz for the CPU.
Actually there is a lot of good advice on that thread. In the end the frequency counting multimeter was the winner, because I couldn't quite afford an oscilloscope, as well as a logic probe and NOP generator.
Regards
JonB
Here's a link to the one that worked:
viewtopic.php?t=1795&postdays=0&postorder=asc&start=120
That's part of a long long thread that describes the build and all the problems I encountered (and eventually overcame with the help of the community). On my machine, the clock circuit runs at 8Mhz which is then divided down three times by a 74LS93 to yield 1Mhz for the CPU.
Actually there is a lot of good advice on that thread. In the end the frequency counting multimeter was the winner, because I couldn't quite afford an oscilloscope, as well as a logic probe and NOP generator.
Regards
JonB
- BigDumbDinosaur
- Posts: 9426
- Joined: 28 May 2009
- Location: Midwestern USA (JB Pritzker’s dystopia)
- Contact:
Tick, Tock, Fix My Clock
jonb wrote:
I went through all this when I tried to build a UK101 clone. The clock just would not tick, even though it is exactly the same as the original machine. Have you a circuit diagram of just the clock circuit?
Here's a link to the one that worked:
viewtopic.php?t=1795&postdays=0&postorder=asc&start=120
That's part of a long long thread that describes the build and all the problems I encountered (and eventually overcame with the help of the community). On my machine, the clock circuit runs at 8Mhz which is then divided down three times by a 74LS93 to yield 1Mhz for the CPU.
Actually there is a lot of good advice on that thread. In the end the frequency counting multimeter was the winner, because I couldn't quite afford an oscilloscope, as well as a logic probe and NOP generator.
Regards
JonB
Here's a link to the one that worked:
viewtopic.php?t=1795&postdays=0&postorder=asc&start=120
That's part of a long long thread that describes the build and all the problems I encountered (and eventually overcame with the help of the community). On my machine, the clock circuit runs at 8Mhz which is then divided down three times by a 74LS93 to yield 1Mhz for the CPU.
Actually there is a lot of good advice on that thread. In the end the frequency counting multimeter was the winner, because I couldn't quite afford an oscilloscope, as well as a logic probe and NOP generator.
Regards
JonB
x86? We ain't got no x86. We don't NEED no stinking x86!