andyshrimpton
New Member
I have spent most of the day getting no where fast.
I have a DS1307 RTC clock set up and running thanks help from Westaust55
It pulses an LED once per second, i also have an LCD showing me the time and date, clocking nicely
In my current project i am using the pause command to wait a second, this is not accurate as i have many "if" statements that makes a countdown timer and depending where it jumps out of the "if" staements effect the time accuratacy when timing more than a few minutes
Instead of using a pause 1000 command, can a use the output on the flashing LED (one per second). So if the LED is HIGH the programme with continue, as all of my "if" statement take less than i would say 0.3 of a second to complete, the code should complete all of the "if" staement and then wait for the LED to go high, meaning a second has passed for it to continue.
Thanks
Andy
I have a DS1307 RTC clock set up and running thanks help from Westaust55
It pulses an LED once per second, i also have an LCD showing me the time and date, clocking nicely
In my current project i am using the pause command to wait a second, this is not accurate as i have many "if" statements that makes a countdown timer and depending where it jumps out of the "if" staements effect the time accuratacy when timing more than a few minutes
Instead of using a pause 1000 command, can a use the output on the flashing LED (one per second). So if the LED is HIGH the programme with continue, as all of my "if" statement take less than i would say 0.3 of a second to complete, the code should complete all of the "if" staement and then wait for the LED to go high, meaning a second has passed for it to continue.
Thanks
Andy