Shop OBEX P1 Docs P2 Docs Learn Events
need help with MAX7219 — Parallax Forums

need help with MAX7219

ellizardellizard Posts: 106
edited 2005-04-25 16:15 in BASIC Stamp
HI everybody,
I'm experimenting with the MAX7219 seven segment display driver,
and i am using the MAX7219.bs2 file (that you can find in attachment) for trying, but i cannot resolve to ligth the decimal point.
has anyone suggestion to give me.
Thanks in advance

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-04-24 15:38
    ellizard,
    ·· I can help you with the MAX7219 as I have used it extensively.· Basically to enable the Decimal Point on a given digit, whatever·hex value you are sending to a given digit must be logically ORed with the Decimal Point constant.· For example:
    d7219 = Value
    d7219 = d7219 | DecPnt
    

    ·· The variable d7219 is being assigned whatever is in the variable Value.· Let's say it's $00.· In the next line this is ORed with the value of DecPnt, which earlier was defined as a constant of %10000000.· What this is essentially doing is setting BIT7 of the value being sent to the MAX7219.· If you have any other questions, let me know.

    BTW, this is for the Decode Mode.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com


    Post Edited (Chris Savage (Parallax)) : 4/24/2005 3:44:17 PM GMT
  • ellizardellizard Posts: 106
    edited 2005-04-24 15:51
    I tried to OR the DecPnt Constant to the temp variable ( see MAX7219.bs2 file) wich contains the digit to display but nothing happen, the digit is displayed with the decimal point not lighted.

    during the initialization the decimal point of all the digits ligth on correctly so i know the wiring is done correct.

    WHERE DO I FAIL?
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-04-24 16:00
    ellizard,

    ·· It may be your code.· I don't know where you got the code, but you could try using the code from the StampWorks manual.· It's a free download in PDF format from our website, and contains similar routines to what I am using.· More importantly, it has the constants defined, and shows an example of using the Decimal Point.· The link to it is provided below.

    http://www.parallax.com/detail.asp?product_id=27220

    ·· You can download it from this page.· I have a project in the works which uses the MAX7219 and in fact uses the Decimal Points in a very unconventional way.· However, the code is easy to follow.· When I am finished it will be posted in the Projects forum and you can download it.· Meanwhile try the StampWorks code.· I can answer questions on that code.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • ellizardellizard Posts: 106
    edited 2005-04-24 16:05
    Hi Chris
    thanks for the help that you are giving to me really in real time.
    I'm attaching the MAX7219.bs2 file that i modified for the decimal point.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-04-24 17:03
    ellizard,

    ·· I will look over your code today, but in the meantime, try the other.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • ellizardellizard Posts: 106
    edited 2005-04-24 17:10
    Thanks for the help.

    i'm already having a look to the code you told me, and does not seem to me to have any difference with what i did on my code.

    hope you'll find uot the busillis

    regards
  • ellizardellizard Posts: 106
    edited 2005-04-25 15:25
    HI Chris
    At the end i managed to get the decimal point work,

    I simply defined a nibble for transmitting the number to display, and in that case there was no room for the decimal point information.

    Anyway thanks for you advice

    GREAT SERVICE
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-04-25 16:15
    ellizard,

    ·· Ah yes, that would certainly hinder setting BIT7!· LOL· No BIT7 on a Nibble.· But at least you figured out what you were doing wrong.· That's great!· Take care!

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