Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

AT89S52 through C Program with 7segment

Status
Not open for further replies.

gakko

Newbie level 6
Joined
Jun 6, 2013
Messages
14
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,363
Hello everyone
I want to know that how to write a C program into AT90S52 and
it make 7-segment become the number adder
EG. with 5ms 0->1 after 5ms 1 -> 2
thanks
 

7-segment is just an output device.
You may connect a keypad with the controller to get the input from some device.

Correct me if I am wrong in intercepting your problem..
 

well...
I want to write a C program into AT89S52
and then
AT89S52 contral 7segment to display the number ( auto add one by sequence
 

5 ms is too fast. If you use single 7 segment to display value from 0 to 9 then in 50 ms all the digits will be displayed once. You cant see the digits changing. Use at least 500 ms delay. If more than one 7 segment display is used to display numbers then you need to multiplex the displays by driving one display at a time. What do you want to display, integer value or floating point value? What type of display are you using? CC or CA?
 

Attachments

  • 80517Seg.rar
    33 KB · Views: 40
Last edited:

thanks
but my counter have 4digital
I don't know how to curry in when 9 -> 10
also
please teach me how to do a good delay time

- - - Updated - - -

I want to display integer value
my type is CA
 

You should be using a function to display the integer on the seven segment.
So always display four digits, whether it be less than 4 digits. Add a 0 in front.
When you write your function in this way, it becomes easier..
 

Its difficult for me to understand how to curry when 9 become 10
Can you write a example program code to shows that how to curry in( when one digital to two digital , two digital to three digital and three digital to four digital
please write more easy
 

Try this Code.

92131d1370582381-7seg.png
 

Attachments

  • 80517Seg_1.rar
    68 KB · Views: 41
  • 7Seg.png
    7Seg.png
    22.5 KB · Views: 67

what is digital[] in use in this program?
also
we use P3 to contal the digital's display dp?
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top