??? 06/16/09 12:21 Read: times |
#166135 - My Methods Responding to: ???'s previous message |
Dear David & Sandeep,
Normally I use the following method, 1> Use a timer ISR to generate a delay. (for e.g. a timer-0 ISR every 10mS, increase a counter; when counter reaches 100, it is 1 second) This is the method I normally use for most of the delays.(Like key scanning, timeouts for some methods, etc...; which in deed needs different timings) Only thing needed is to calculate TH & TL accurately Another method I once used was 2> I was using DS1307 RTC IC in an application. I configured it to generate 1Hz square wave on its SQW/OUT pin which was connected to /INT1 pin of my MCU (p89lpc936). Every external-1 ISR (edge triggered) is 1 Sec count. Regards, Mahesh |