[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 580: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 636: sizeof(): Parameter must be an array or an object that implements Countable
Brads Electronic Projects Forum • great race great project for school - Page 2
Page 2 of 2

Re: great race great project for school

Posted: Thu Dec 20, 2012 11:40 am
by brad
My Apologies Mark - I need to look at my own schematic properly next time!

I should have said that you need to send all 0's to the Green Anodes rather than all 1's to the Green Cathodes. You are 100% correct in saying that you can't send all 1's to the green cathodes at the same time :)

Re: great race great project for school

Posted: Thu Dec 20, 2012 2:25 pm
by Mike M
brad wrote:My Apologies Mike - I need to look at my own schematic properly next time!
That's ok. I apologize for asking you to go back five years to talk about one of your early designs (lol).
You are 100% correct in saying that you can't send all 1's to the green cathodes at the same time :)
Good, then we agree. The way you wired the 7442, you're only selecting "1 of 8" outputs instead of "1 of 9" outputs and so one green row is always left enabled when you enable the red row (and I hope you realize why this isn't desirable).
I should have said that you need to send all 0's to the Green Anodes rather than all 1's to the Green Cathodes.
Well, that really doesn't work either, does it? Basically, there's no way to light a red LED and "send all 0's to the Green Anodes" at the same time. But, let's walk through it, just to be sure...

When we want to light one of the red LEDs in our program, we set the PIC RA3 pin to '0'. Checking the schematic, we see this enables the red cathode row at the bottom of the display. But remember that since the 7442 is wired incorrectly, one of the green cathode rows is also enabled. Going back to the schematic, we see that each of the column lines is connected to the anodes of all the red and green LEDs in each column. Now if we put a '1' onto one of those column lines, we're going to light a red LED at that column position in the red row at the bottom of the display, but, this will also light a green LED at that column position in the green row that was left enabled. I can't imagine this is what you intended.

I believe my analysis is correct and my logic sound. What baffles me is how you used a seemingly flawed design in the Great Race project and in the Christmas Card project without seeing visual artifacts or signs of the flaw. On the other hand, I also wonder how many people, besides bman2309, have built the Great Race or Christmas Card project and then experienced symptoms of the flaw? In any event, now that we know about the design flaw, we might consider providing people who experience symptoms of the flaw with an updated schematic and program instead of suggesting that they check their wiring (lol)...

Cheerful regards, Mike

Re: great race great project for school

Posted: Fri Dec 21, 2012 10:46 am
by brad
This is an interesting problem - Now that I have had a good look at the schematic I am a little confused as to how mine worked in the first place. I guess it's one of those rare times where a flaw in your circuit worked for good :)

The easiest fix would to leave the circuit as is but slightly modify the code so that when you want to draw the car on the screen, you make sure that the same row of green cathodes is enabled. This way, you won't get ghosting and will have an orange car.

Re: great race great project for school

Posted: Fri Dec 21, 2012 9:06 pm
by bitfogav
Mike thats some great logic and Im not saying you are wrong but I have built this project and never saw the phantom green + red dot, So just always assumed there wasn't a problem with the circuit. :)

Re: great race great project for school

Posted: Sat Dec 22, 2012 2:29 am
by Mike M
brad wrote:This is an interesting problem - Now that I have had a good look at the schematic I am a little confused as to how mine worked in the first place.
I'm baffled too, Brad. You mentioned on your projects web page that this was your first LED project and since it was from such a long time ago I wondered if you had maybe discovered and fixed the problem early on and simply forgotten to post an updated schematic and program before moving on to bigger and better things. Anyway, the problem didn't affect me because I had to come up with a different design. For one thing, I didn't have a 7442 IC, but more importantly, the 7442 wouldn't have worked because the sample Lumex display I had was the opposite type. Fortunately, the single chip design I came up with will support either "common anode row" or "common cathode row" display types.
The easiest fix would to leave the circuit as is but slightly modify the code so that when you want to draw the car on the screen, you make sure that the same row of green cathodes is enabled. This way, you won't get ghosting and will have an orange car.
Yes Sir, that should work...

Cheerful regards, Mike