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.

digital counter using 8051

Status
Not open for further replies.

burassu

Junior Member level 1
Joined
Jul 2, 2011
Messages
16
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,391
Hi I am doing an up down digital counter , the counter should count from 0 to 30 . I know how to increment and decrement. but the problem is I have to increment/ decrement the units alone than the tens and then display them on an lcd. How can I do It pls ???
 

Hi I am doing an up down digital counter , the counter should count from 0 to 30 . I know how to increment and decrement. but the problem is I have to increment/ decrement the units alone than the tens and then display them on an lcd. How can I do It pls ???

First you have to draw a flowchart (see attached example) of what you have to do, including all conditions such as what happens when you decrease a number and the unit count is 0, or when you increase a number and the unit count is 9 ..
To count units use, for example, register R2, to count tens use R3.

Once you have a flowchart translating it to the 8051 code is not a major problem.

:wink:
IanP
 

Attachments

  • an35-flowchart-example.jpg
    an35-flowchart-example.jpg
    43.6 KB · Views: 58
Last edited:

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top