dot matrix display programming in c

Thread Starter

nikhilsonar29

Joined Sep 26, 2014
68
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
 

ErnieM

Joined Apr 24, 2011
8,377
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?
 

Thread Starter

nikhilsonar29

Joined Sep 26, 2014
68
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
 

Attachments

DickCappels

Joined Aug 21, 2008
10,152
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?
 

Thread Starter

nikhilsonar29

Joined Sep 26, 2014
68
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.
 

DickCappels

Joined Aug 21, 2008
10,152
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... ?
 

Thread Starter

nikhilsonar29

Joined Sep 26, 2014
68
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
 
Top