6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sat Nov 23, 2024 6:24 pm

All times are UTC




Post new topic Reply to topic  [ 50 posts ]  Go to page 1, 2, 3, 4  Next
Author Message
PostPosted: Sun Jan 10, 2021 12:30 pm 
Offline

Joined: Sun Jan 03, 2021 7:22 pm
Posts: 13
Hey, everyone :D

I built Ben Eater's 6502 breadboard computer, but something strange is happening:
When I try to turn the computer on it just turns on the LCD backlight and I need to plug it in and out a lot of times so it can show the text on the screen.

Can this problem be fixed?

Best regards,
Krum


Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 10, 2021 12:55 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10986
Location: England
My best guess would be that the reset signal isn't doing what it needs to. Is there a reset button?

Power-on reset, done properly, is a bit more complicated that one might guess. But a reset button is simpler than that.

Other things might be the cause: the clock might not start up, for example. Or maybe the LCD needs some warm-up time and the software isn't giving it that time. (By warm-up, I mean it needs some time to build up an internal voltage.)


Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 10, 2021 1:25 pm 
Offline

Joined: Sun Jan 03, 2021 7:22 pm
Posts: 13
The LCD is fine I have used it before in other projects, but I have noticed that the reset switch doesn't work. I have checked the schematics and it seems like everything is OK.

I've attached how I wired the reset switch.


Attachments:
File comment: A simple schematic.
schematic.png
schematic.png [ 9.22 KiB | Viewed 1944 times ]
Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 10, 2021 1:42 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10986
Location: England
We might have to wait for some people with more experience. The problem is that mechanical switches are very indecisive: they bounce lots of times before settling. So the 6502 will see a whole series of reset pulses. What's important is that the final contact just before it lets go is long enough to work.

Do you have good power supply, and a bypass capacitor next to every chip?


Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 10, 2021 1:54 pm 
Offline

Joined: Sun Jan 03, 2021 7:22 pm
Posts: 13
Yes, I have bypass caps on every power line and I have a 2amp/ 5v power supply


Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 10, 2021 2:27 pm 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3367
Location: Ontario, Canada
We need some photos of your project, please. :) This is important -- can be very helpful. And tell us about the CPU you're using -- was it purchased new from a reputable dealer, or is its origin somewhat doubtful?

Also, do you have a voltmeter or DMM available? (What about other gadgets, such as a 'scope or logic probe?) I suggest you use the meter to measure between Gnd and pin 40 (Reset). Please verify that the voltage is normally 5V, and that it goes to 0 when you hold the button down.

Krsultov wrote:
When I try to turn the computer on it just turns on the LCD backlight and I need to plug it in and out a lot of times so it can show the text on the screen.
Uhhh... to be clear, what is it you're plugging in and out? The LCD? The power cord for your PSU? Something else, perhaps?

Edit: is that resistor in your diagram really 220 ohm -- not 2200 ohm, perhaps?

-- Jeff

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 10, 2021 2:34 pm 
Offline
User avatar

Joined: Sat Dec 01, 2018 1:53 pm
Posts: 730
Location: Tokyo, Japan
BigEd wrote:
We might have to wait for some people with more experience. The problem is that mechanical switches are very indecisive: they bounce lots of times before settling.

Right. It might be worth having a look at Garth Wilson's Reset Circuits page for some ideas on improvements you could make to the reset circuit. You probably don't have a DS1813 handy in your parts box, but you may have a 74xx14 or something else with a Schmitt trigger input. Even just a cap and resistor might help clean up the reset signal enough. I notice that Ben Eater's schematic uses a 1k resistor and 0.1 μF cap.

_________________
Curt J. Sampson - github.com/0cjs


Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 9:46 am 
Offline

Joined: Sun Jan 03, 2021 7:22 pm
Posts: 13
Unfortunately I don't have any other parts that I can use. The capacitor on the reset switch doesn't work, I tried it.

I also attached some pictures of my project:


Attachments:
1610358024475.jpg
1610358024475.jpg [ 2.86 MiB | Viewed 1897 times ]
1610358024454.jpg
1610358024454.jpg [ 2.62 MiB | Viewed 1897 times ]
1610358024484.jpg
1610358024484.jpg [ 2.78 MiB | Viewed 1897 times ]
1610358024465.jpg
1610358024465.jpg [ 3.11 MiB | Viewed 1897 times ]
1610358024444.jpg
1610358024444.jpg [ 2.84 MiB | Viewed 1897 times ]
Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 9:49 am 
Offline

Joined: Sun Jan 03, 2021 7:22 pm
Posts: 13
Dr Jefyll wrote:
We need some photos of your project, please. :) This is important -- can be very helpful. And tell us about the CPU you're using -- was it purchased new from a reputable dealer, or is its origin somewhat doubtful?

Also, do you have a voltmeter or DMM available? (What about other gadgets, such as a 'scope or logic probe?) I suggest you use the meter to measure between Gnd and pin 40 (Reset). Please verify that the voltage is normally 5V, and that it goes to 0 when you hold the button down.

Krsultov wrote:
When I try to turn the computer on it just turns on the LCD backlight and I need to plug it in and out a lot of times so it can show the text on the screen.
Uhhh... to be clear, what is it you're plugging in and out? The LCD? The power cord for your PSU? Something else, perhaps?

Edit: is that resistor in your diagram really 220 ohm -- not 2200 ohm, perhaps?

-- Jeff


The CPU is compleately new from Mouser electronics. The resistor is 1k I have typed 220 ohm by mistake. I have a voltmeter, checked the voltage - everything looks OK. I have to plug in/out the power plug.


Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 9:54 am 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10986
Location: England
Thanks for the photos!

When you say the capacitor didn't work, do you mean it didn't fix the problem?

So, you need to power-cycle the whole machine - reset isn't enough. Is never enough, or is usually not enough?

Have you any way to tell if it's just the LCD display which isn't coming up - can you read off activity on SYNC for example, or on address lines or data lines?


Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 10:01 am 
Offline

Joined: Sun Jan 03, 2021 7:22 pm
Posts: 13
BigEd wrote:
Thanks for the photos!

When you say the capacitor didn't work, do you mean it didn't fix the problem?

So, you need to power-cycle the whole machine - reset isn't enough. Is never enough, or is usually not enough?

Have you any way to tell if it's just the LCD display which isn't coming up - can you read off activity on SYNC for example, or on address lines or data lines?


Is never enough, or is usually not enough? - never enough

Have you any way to tell if it's just the LCD display which isn't coming up - can you read off activity on SYNC for example, or on address lines or data lines? I've tried blinking some LEDs, but no luck.


Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 10:29 am 
Online
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8546
Location: Southern California
Some manufacturers' 65c02's had a Schmitt-trigger Reset input, allowing a slowly-rising signal from a capacitor to ground. I don't see anything in WDC's datasheet about it though. This however is a problem with solderless breadboards that I cannot emphasize enough, about the inductance of the connections and the fact also that they can act not only as transmitting antennas but also receiving antennas. A computer that controlled a product we sold for 13 years had a capacitor going to a 74HC00 (non-Schmitt-trigger) input, whose output went to an R65C02's reset input. Noise getting into the reset line from the clock signal was enough to keep it from working until we put another capacitor from the reset pin to ground. Even then, this arrangement was not good enough (I know it looks like it's not connected on the left end; but it was):
Attachment:
LeadsTooLong1.jpg
LeadsTooLong1.jpg [ 41.73 KiB | Viewed 1891 times ]

but this one worked and never gave us any trouble:
Attachment:
ShortLeads1.jpg
ShortLeads1.jpg [ 44.1 KiB | Viewed 1891 times ]

Note the difference in lead length. Yes, that little bit made all the difference between not working, and never having any problem. I could have laid out the board again to fix it, but the cost of first article was too high back then, particularly for multilayer boards.

I don't know/remember whether the Rockwell part had a Schmitt-trigger reset input. If it did, the size of the hysteresis was too small. If it did not, the gain of the CMOS input was high enough that a slowish-rising reset signal was ok as long as it was not noisy.

If you go by what's in the 6502 primer, you won't have any trouble.

_________________
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?


Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 10:36 am 
Offline

Joined: Sun Jan 03, 2021 7:22 pm
Posts: 13
But, Why does this problem occur? I built the computer exactly how Ben did. He didn't have this problem.

He didn't have any capacitors, any different parts etc.

Is there an easy way to fix the problem without adding any parts? Just rewire something?


Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 1:46 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10986
Location: England
It's usually a question of diagnosis. Quite often we might find, by careful review and inspection, that some wire is in the wrong place, or not quite making contact.

It's also possible, but less likely, that some component is defective - more likely, it is not quite connected, perhaps because of tarnish, or dirt.

What diagnostic equipment do you have? Multimeter? With frequency readout? Logic probe?

With patience and guidance you can learn a lot with just an LED and a logic gate or two - but while it's possible there is a quick fix, it might take some diligence.

It's a bit like software: rarely does a newly written program have no bugs. Learning to debug is an essential part of learning to program. It's like that with hardware too - unless you're lucky!

Edit: we should all have high confidence that this can be fixed, provided you stick with it!


Top
 Profile  
Reply with quote  
PostPosted: Mon Jan 11, 2021 3:46 pm 
Offline
User avatar

Joined: Mon May 12, 2014 6:18 pm
Posts: 365
What are the other chips you have in the circuit? If any of them require 5v, you might want to check the voltage at the power pin of each chip and the LCD individually. Depending on the breadboard and wires you're using, it could be dropping significant voltage, though it looks like you're using the breadboards that Ben Eater recommends


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 50 posts ]  Go to page 1, 2, 3, 4  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 47 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: