dot matrix display programming in c

Discussion in 'Programmer's Corner' started by nikhilsonar29, May 25, 2015.

  1. nikhilsonar29

    Thread Starter Member

    Sep 26, 2014
    68
    1
    good morning ,
    I have just started working on simple dot matrix display programming in micro controller in PIC or/and 8051
    -My application is related to elevator ,where these dot matrix display will be use for indication of floor level and other purpose like STOP ,OVERLOAD
    -i have seven segment o/p from main controller of elevator,so by using this 7 seg o/p how can i display corresponding floor level like 1,2,3,4.....on dot matrix display
    i tired writing program in kiel uvision compiler,
    i am refering online code for dot matrix display ,and i know the basic concept of displaying character on dot matrix display, but i can not manage to get my desire o/p(i.e when.........a=b=1 then dot matrix display should show "1" on display ,if a=b=d=e=g=1 then dot matrix display should show "2" on dot matrix display ...and so on...i think interrupt method should be employed for this purpose )
    so plz i need help for this purpose ,any one can help for the code in either c or in assembly ,plz help.

    Thanks and Regards
    Nikhil
     
  2. takao21203

    Distinguished Member

    Apr 28, 2012
    3,577
    463
    Huh!
     
    absf likes this.
  3. shteii01

    AAC Fanatic!

    Feb 19, 2010
    3,392
    497
    So you are turning on and off individual led to form a letter/number?
     
  4. nikhilsonar29

    Thread Starter Member

    Sep 26, 2014
    68
    1
    yes that is right@shteii
     
  5. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,389
    1,605
    A dot matrix display is not a 7-segment display. What is the specifics of this display you are actually using? How are you connecting this display to your controller?
     
  6. RRITESH KAKKAR

    Senior Member

    Jun 29, 2010
    2,831
    89
    Hello nikhil,
    I can teach you that in PIC but you have to pay for it!
     
  7. kubeek

    AAC Fanatic!

    Sep 20, 2005
    4,670
    804
    Really? How much do you ask for your exquisite services?
     
    R!f@@ likes this.
  8. RRITESH KAKKAR

    Senior Member

    Jun 29, 2010
    2,831
    89
    Hello,
    I will takes 100 Dollars...
     
  9. R!f@@

    AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    Like 100 buck for an hour.
     
  10. R!f@@

    AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    That is cheap. You dunno if OP will sell that or not.
    You need to charge like a 10,000 USD.
     
  11. nikhilsonar29

    Thread Starter Member

    Sep 26, 2014
    68
    1
    i can not afford...sir
    rather i have written code in 8051 ..just to show character on dot matrix
    this code is in assembly lang
    now only problem is that how do i select particular character for corresponding number
    i have attached block dig of my application ,so can get exact requirement of mine.

    ''''''//////....


    LS74_154 EQU P1
    UDN2981 EQU P2
    SWICH EQU P3

    ORG 00H

    MOV P3,0FFH
    MOV A ,SWICH
    MOV P3,A




    JNB P3.6,FLOOR1 ///jump to floor1 if P3.6 is '0'.....


    FLOOR : MOV DPTR,# MYDATA1
    MOV R0,#0H
    REV1: CLR A
    MOV LS74_154,R0
    MOVC A,@A+DPTR
    JZ FLOOR
    MOV UDN2981,A
    INC DPTR
    INC R0
    ACALL DELAY

    SJMP REV1


    //..................4

    FLOOR1 : MOV DPTR,# MYDATA2
    MOV R0,#0H
    REV: CLR A
    MOV LS74_154,R0
    MOVC A,@A+DPTR
    JZ FLOOR1
    MOV UDN2981,A
    INC DPTR
    INC R0
    ACALL DELAY
    SJMP REV

    //.............0




    DELAY:
    MOV R6,#10
    DL1:
    MOV R7,#249
    DJNZ R7,$
    DJNZ R6,DL1
    RET

    MYDATA1: DB 18H,14H,12H,7FH,10H,0H //....4

    MYDATA2: DB 3EH,41H,41H,41H,3EH,0H //....0



    END
     
  12. RRITESH KAKKAR

    Senior Member

    Jun 29, 2010
    2,831
    89
    Ok, it your wish.
     
  13. R!f@@

    AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    Did you come here to make money ?

    Or to help ?

    Make that clear to us.
     
  14. DickCappels

    Moderator

    Aug 21, 2008
    2,654
    632
    This thread is drifting away from the original purpose.
    @nikhilsonar29 I am not accustomed to reading PIC assembly code. Let me ask you a question: Are you trying to turn on a sequence of dots to create a character?
     
  15. shteii01

    AAC Fanatic!

    Feb 19, 2010
    3,392
    497
    That's intel 8051 assembly code.
     
  16. DickCappels

    Moderator

    Aug 21, 2008
    2,654
    632
    I should have recognized it from 35 years ago :).

    Are you trying to turn on a pattern of LEDs to form characters?
     
  17. nikhilsonar29

    Thread Starter Member

    Sep 26, 2014
    68
    1
    yes sir ,
    due to the persistence of vision,when we are sending pattern to the row of dot matrix display and simultaneously making pins of columns high one by one,the corresponding character will be display.
     
  18. DickCappels

    Moderator

    Aug 21, 2008
    2,654
    632
    Take it a piece at a time. Does your 7 segment decoder routine work? (Did not see it).

    Another question: How does your dot matrix controller know when a number has changed? Or, does it constantly go through a loop of reading the 7 segment, outputting the dot pattern, then read the 7 segment, outputting the dot pattern... ?
     
  19. eric080

    New Member

    May 28, 2015
    2
    0
    It's pretty cool , I mean I was learn a lot from your topic. THX
     
  20. nikhilsonar29

    Thread Starter Member

    Sep 26, 2014
    68
    1
    exactly sir,
    this is where i am having trouble of identifying the seven segment in 8051 uc
    actually the main controller is for elevator controller which will generate the code for seven seg display related to lift floor location
    so currently we are using seven seg display on each floor and giving that o/p from main controller to each floor
    and human can understand the lift location ..so changing of that seven seg is depending upon the floor location
    but with seven seg we are not satisfied with its brightness ...
    but in dot matrix we are getting very good brightness ..and also for modernization in electronics ...i have the task to generate that corrsponding char on dot matrix with the seven seg pattern
     
Loading...