Shop OBEX P1 Docs P2 Docs Learn Events
trying to run MM5480 LED driver... giving up — Parallax Forums

trying to run MM5480 LED driver... giving up

pixlopixlo Posts: 6
edited 2006-07-05 05:18 in BASIC Stamp
this is my last ditch effort to ask for help on this problem.

i know very little about electronics and hoped that by following the amps and volts on the datasheet for the ins and outs on the MM5480 3.5 digit display driver, I could get it running by sending a 36bit shiftout, but i cant and I've been banging on it for three days straight.

HAS ANYONE WORKED WITH THESE DRIVERS BEFORE?

they are based on the MM5450/MM5451, I think, but they dont have an enable.

if you have and you would like to help, please respond. I have the feeling I'm not hooking it up right. i am a programmer, but not with picbasic.

i mean, whats the deal? do i need to hook capacitors up to the data and clock in or something? ive built the circuit on the brightness control like it said in the datasheet. I get the feeling the datasheet is not what i should be looking at for how to hook this up.

argh

i hate this.

-nick

Post Edited (pixlo) : 7/2/2006 8:31:21 PM GMT

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-07-03 06:20
    Nick,

    ·· On the contrary...The datasheet is definately needed for the connection.· Of course you have to know how to handle the BASIC Stamp side connections as well.· 3 days isn't much for people on this forum.· Not everyone checks in that often so you could be giving up prematurely.

    ·· On the other hand I think my fellow Tech Support Staff would agree I have quite a considerable collection of parts covering many areas of electronics, and yet I have never heard of these drivers, nor do I have any.· The electronics shops that are local do not seem to stock it or I would try to help you.

    ·· I guess what I am saying is hang in there.· Also, maybe you should take a break from this for a few days and start fresh after your head is cleared.· That works for me.· Sometimes if I can't get something working I take a break for a while and just hit it from a different angle.· Sometimes that's all that's needed.· I hope this helps.· Take care.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • pixlopixlo Posts: 6
    edited 2006-07-03 20:10
    i looked at the data out pin and the clock pin with a scope during a looped shiftout and saw something interesting...

    SHIFTOUT 14, 15, MSBFIRST [noparse][[/noparse]%1111111111111111\16, %1111111111111111\16, %1111\4]

    puts big, like byte-sized spaces where each comma is. so the above looks like so on the scope:

    scope.gif

    (data top, clock bottom)

    but the clock ticks for each 16bit string sent by shiftout- it doesnt tick in the spaces between the data sends.

    I dont know how this would effect the MM5480's data and clock ins.

    The MM5480 doesnt use an enable or load pin as far as I can tell. This is weird because it is based on the MM5450/51. One of these, the 50 or 51 HAS an enable in and one does not. the one that doesnt expects a high start bit and then 35 bits. It latches when it gets a high bit on the 35th bit.

    I found an interesting site where a few guys were using MM5450s to build a cockpit simulator:

    www.viperpit.org/forum/viewtopic.php?t=38&highlight=&sid=f0547ea6df1c2c7a7a41fa20ddf374f8

    they post the following wiring diagram:

    circuit.jpg

    I thought this diagram strange as the datasheet specs a max power supply current of 7mA. I see no resistors or voltage regulators on the above wiring diagram. I've hooked resistors and an LM317 voltage regulator to a 9V battery for the brightness control (max V 4.3V, max I .75mA) I tried hooking my MM5480 up to a bare 5V and 6V regulated supply and probably destroyed it doing this, but I didnt smell any magic smoke, so I hope for the best. I have another one as a backup. I've also hooked up a pot and .001uF cap to the pot as listed in the MM5480 datasheet (see MM5480N datasheet). But I dont know if it works unless I have good data running to it.

    So... I cant help but think I have it hooked up right. I'll post a photo and diagram later tonight so you all can see it.

    I really think the problem is with my code, simply:

    DO
    SHIFTOUT 14, 15, MSBFIRST [noparse][[/noparse]%1111111111111111\16, %1111111111111111\16, %1111\4]
    LOOP
    END

    I have three LEDs hooked up to the driver, pins 12, 11 and 10.

    I've put together a quick diagram. The values on the resistors aren't definite, I've done some quick calculations to get what I think i needed. for example, the power needs to be 7mA, I remember my multimeter tellimg me it was something like 136mA so I added resistors until I got it just below 7mA. I've put a 1k resistor here because 7V (approx what i get when i meter the power) 7V/.007 = 1000.

    Im getting better at this, but still a newbie by a long shot.

    The resistors on the LM317 are again what fits into the formula on the datasheet: Vout = 1.25 * ( 1 + R2 / R1). I want 4V as the brightness control takes between 3 and 4.3V.

    I cant remember what the pot's resistance is. It's the pot that ships with the HomeWork board.

    MM5480_shiftout.gif

    Oh, and my LEDs on the schematic above are backwards.

    Thanks so much. I'm sticking with it. It's just so frustrating getting into something new sometimes.

    -nick

    Post Edited (pixlo) : 7/3/2006 9:09:36 PM GMT
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-07-03 20:51
    Nick,

    ·· One thing you could do to get the bits there with no difference in timing would be to write a loop to "bit-bang" the data out to the device.· That will at least help you figure out if that is what's causing the problem.· Just an idea.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • pixlopixlo Posts: 6
    edited 2006-07-05 05:13
    SUCCESS!

    after a ton of time googling, I got things working.

    First big mistake: I assumed the anodes of the LEDs connected to the output pins and the cathodes to ground. WRONG. Once I turned my LEDs around, everything lit up, but flickered quite a bit which I thought had to do with my code, but it didn't.

    I had two batteries hooked up to the circuit and I'm sure it was causing all kinds of trouble on the driver chip. I hope I didnt fry my microcontroller- dont think I did tho, as after hooking Vss and Vdd from the stamp breadboard to the MM5480, everything worked EXACTLY how it's supposed to.

    I am using the MM5480 to close triac switches through optoisolators to turn on and off segments of electroluminescent wire. With this wire I am making giant (4'x2') 16 segment displays (five of them).

    If I finish it I will certainly post photos, code and schematics.

    The code I am using: (this lights up the first and third LED)

    ' {$STAMP BS2}
    ' {$PBASIC 2.5}
    OUTPUT 4
    OUTPUT 5
    LOW 4
    LOW 5
    DO
    SHIFTOUT 4, 5, 1, [noparse][[/noparse]%1010100000000000\16,%0000000000000000\16, %0000\4]
    LOOP
    END

    ·
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-07-05 05:18
    pixlo,

    ·· See, you take a break, clear your head, and find your answer.· Sometimes stuff is obvious, and sometimes it's not.· At least you learned something from it.· Take care.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
Sign In or Register to comment.