How to calculate time in 8051???

Status
Not open for further replies.

nisarg001

Newbie level 6
Joined
Sep 26, 2007
Messages
14
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,353
Hi!
I am making a game that counts the reflection time of the user using 8051 µC

I want to calculate the user's reflection time. It may vary from many miliseconds to few (upto 4) seconds.
Can anyone help me "How to calculate time upto 4sec in c51 keil??"

Thanks for your consideration.
 

Make timer interrupt of an 1ms.

Every entrance in interrupt, increment variable "count" by 1. When count = 4000, 4 seconds elapsed.


Mr.Cube
 

    nisarg001

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…