View previous topic :: View next topic |
Author |
Message |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Thu Aug 12, 2010 5:35 pm |
|
|
Can you post a photo of your board for this project ? |
|
|
StingzLD
Joined: 18 Jul 2010 Posts: 42 Location: Richmond, VA
|
|
Posted: Fri Aug 13, 2010 9:40 am |
|
|
Okay, the image is pretty big; so here is the link to it: http://img530.imageshack.us/i/max7221setup.jpg/
The chip on the left is the PIC16F684 (with programmer connected), and the right is the MAX7221. For ease of seeing the different LED colors instead of the Bi-Polar, I swapped it out for two regular LEDs with the wiring of them being unchanged. And I have a bunch of different things on this breadboard all at once, so don't worry about the other wiring you see. |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19553
|
|
Posted: Fri Aug 13, 2010 10:06 am |
|
|
Add a small decoupling capacitor right by the PIC.
Decoupling at the supply, is _not_ adequate for boards like this.
Can't see the ground connection to PIN4 on the chip. Presumably under the blue wire?.
Double check your Iset calculations. Looks like you have 270R. If so, you will probably have destroyed the LED's. The current is set to about 100* the value set by the Iset resistor. You want no more than 25mA on the LEDs, so about 0.25mA on the resistor About 1.2K _minimum_.....
Best Wishes |
|
|
StingzLD
Joined: 18 Jul 2010 Posts: 42 Location: Richmond, VA
|
|
Posted: Fri Aug 13, 2010 10:45 am |
|
|
Thanks for the capacitor tip. I'm not sure if it will smooth power out or not since my programmer (which is seconding as my power supply while trying to get it to work) has all that built in, but it doesn't hurt to have more than needed! And as for the Iset resistor, it is a 220 ohm resistor that so far has not killed the LEDs. But just to be on the safe side, I swapped it out for the 1.2k ohm you suggested.
[Side note: I never went to school for any of this, so figuring out calculations is not my strong point. So thanks for the pointer!) |
|
|
StingzLD
Joined: 18 Jul 2010 Posts: 42 Location: Richmond, VA
|
|
Posted: Fri Aug 13, 2010 11:03 am |
|
|
I finally got it to work correctly!!!! I have no clue why the difference in the resistor made such a huge impact, but it worked! I thought that it would have worked no matter what, except it would just be extremely dim if it was too high or blow if it was too low. But thanks for all of your help everyone! Hopefully this will be the end of this thread, and I will not encounter more problems as I add more LEDs. Thanks again! |
|
|
StingzLD
Joined: 18 Jul 2010 Posts: 42 Location: Richmond, VA
|
|
Posted: Sat Aug 14, 2010 8:33 am |
|
|
UPDATE:
This is solely FYI. Since getting the MAX7221 to work and playing around with it, I decided that I would take that chip out and try the MAX7219 for sh1ts and giggles. Well, apparently whatever has been going wrong during this whole thread has been because the MAX7219 doesn't like my chip. Just be certain I slapped the MAX7221 back in and voila! Worked like a charm. I do find it very curious though that the MAX7219 does perform the lighting of the single LED... but only very sporadically with an immense amount of time in between flashes.
So the lesson to be learned from this experiment is if your chip doesn't have any special features in regards to communication (like my PIC16F684), use the MAX7221! |
|
|
|