commit c839292b22dae996444d7c97d9bb710b051553e9
parent c5520f341297059b468dc591cb50ba670c09ba75
Author: Paco Esteban <paco@e1e0.net>
Date: Mon, 6 Jul 2020 13:18:20 +0200
force read tag file at start if needed
Diffstat:
1 file changed, 3 insertions(+), 0 deletions(-)
diff --git a/clock.c b/clock.c
@@ -108,6 +108,9 @@ main(int argc, char *argv[])
if (init_pins() == -1)
errx(1, "Unable to setup wiringPi: %s\n", strerror(errno));
+ /* force reading of the tag file on init (if present) */
+ readCount = readInterval;
+
for (;;) {
t = time(NULL);
tm = localtime(&t);