Discussion in "Project Help" started by    diya    Sep 5, 2007.
Tue Sep 11 2007, 01:07 am
#21

Q1/ why r u using the higher nibble and the lower nibble here
(sometime u set the highr nibble as "high" and some times "low" , same thin with the lower nibble) ?

Light


I am not setting them high or low.. i am masking them..
masking means.. clearing the unwanted bits..
like in above example.. anl a,#0FH
this statement will mask the higher nibble, i.e. making upper four bits as 0. because when you are displaying the upper nibble then you need to mask the lower nibble and when displaying lower nibble the upper nibble has to be masked.

Q2/ the decoded table .... is it going to contain the values of all digits that can be displyed on 7-segment , OR the vaues that is going to be representing the temperature only ?

Light


yes it will contain the value that displays digit on 7-segment..
 Light like this.
Tue Sep 11 2007, 06:18 am
#22

Q2/ the decoded table .... is it going to contain the values of all digits that can be displyed on 7-segment , OR the vaues that is going to be representing the temperature only ?

Light


yes it will contain the value that displays digit on 7-segment..

[/quote1189471324]

woow , that means alooot of values will be decoded , cuz we hav 2 DUAL ! seven-segment
its like from 24.00°C (24.01° , 24.02° , ...) to 100.00°C, that would take 3 or 4 pages :-)

thank u for these answers.

the prevoise program for the 7-segment can be used right ?
if yes lets move to ADC .


[ Edited Tue Sep 11 2007, 06:19 am ]
Tue Sep 11 2007, 02:13 pm
#23
No you just need the values from 0 to 9, as you have to display in multiplexed mode.. so first display first digit and then second digit.. so all you need is decoded table from 0 to 9
Wed Sep 12 2007, 02:33 am
#24
Ajay , today i tryd the simple program that shows (45) on the 7-segment to test my hardware , but it didnt show 45 !
insted , the fan worked !!!!!!!!!!!!!! <--- dont ask me how
and the four 7-segments show ( 8 8 8 8) , all the LED r on.

this is the code that i installed it :

ORG 0000

MOV A,P0
MOV A,66H
SETB P1.0
CLR P1.1
MOV A,P0
MOV A,6DH
SETB P1.1
CLR P1.0

RET

DELAY:
MOV R5,#50H
BACK:
MOV R4,#0FFH
DJNZ R4,$
DJNZ R5,BACK



END
--------------------------------------------------

so where is the mistake ?
Wed Sep 12 2007, 02:50 am
#25
ORG 0000
CLR P0
start:
MOV A,66H
mov P0,a
SETB P1.0
acall DELAY
CLR P1.0

MOV A,6DH
mov P0,a
SETB P1.1
acall DELAY
CLR P1.1
SJMP start

DELAY:
MOV R5,#20H
BACK:
MOV R4,#0FFH
DJNZ R4,$
DJNZ R5,BACK

END

-------
TRY AGAIN!!
Wed Sep 12 2007, 03:17 am
#26
there is 1 error on the 2nd line (CLR P0)
it says : ( segment type mismatch )

??
Wed Sep 12 2007, 03:19 am
#27
oops my mistake..
replace clr P0 with mov P0,#00H
Wed Sep 12 2007, 04:47 am
#28
you mean replace CLR P0 with MOV P0,#00H

??
Wed Sep 12 2007, 04:48 am
#29
oh ok ok , i didnt c the ( mov ) that u wrote

thanks alooot

Get Social

Information

Powered by e107 Forum System

Downloads

Comments

RodneyKnorb
Thu Apr 25 2024, 07:08 pm
Williamjef
Thu Apr 25 2024, 02:08 pm
SamuelSmise
Thu Apr 25 2024, 09:56 am
DustinErele
Thu Apr 25 2024, 08:44 am
ztaletpzca
Wed Apr 24 2024, 11:19 pm
IrardlPex
Wed Apr 24 2024, 08:42 pm
Charlestehed
Wed Apr 24 2024, 05:20 pm
Robertgurse
Wed Apr 24 2024, 02:43 pm