aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--demos/AVR/NIL-ARDUINOMEGA/main.c2
-rw-r--r--demos/AVR/NIL-ARDUINOMEGA/nilconf.h7
2 files changed, 6 insertions, 3 deletions
diff --git a/demos/AVR/NIL-ARDUINOMEGA/main.c b/demos/AVR/NIL-ARDUINOMEGA/main.c
index ef2751b14..5d07cee85 100644
--- a/demos/AVR/NIL-ARDUINOMEGA/main.c
+++ b/demos/AVR/NIL-ARDUINOMEGA/main.c
@@ -27,7 +27,7 @@ THD_FUNCTION(Thread1, arg) {
while (true) {
palTogglePad(IOPORT2, PORTB_LED1);
- chThdSleepMilliseconds(1000);
+ chThdSleepMilliseconds(500);
}
}
diff --git a/demos/AVR/NIL-ARDUINOMEGA/nilconf.h b/demos/AVR/NIL-ARDUINOMEGA/nilconf.h
index a7ab0039f..c2dbbc932 100644
--- a/demos/AVR/NIL-ARDUINOMEGA/nilconf.h
+++ b/demos/AVR/NIL-ARDUINOMEGA/nilconf.h
@@ -62,8 +62,11 @@
* @note This value together with the @p NIL_CFG_ST_RESOLUTION
* option defines the maximum amount of time allowed for
* timeouts.
+ * @note Currently the Timer is configured with a prescaler of
+ * 1024. Arduinos running at 16MHz will have a frequency
+ * of 16MHz/1024. This will provide a resolution of ~64uS.
*/
-#define NIL_CFG_ST_FREQUENCY 1000
+#define NIL_CFG_ST_FREQUENCY 15624
/**
* @brief Time delta constant for the tick-less mode.
@@ -73,7 +76,7 @@
* The value one is not valid, timeouts are rounded up to
* this value.
*/
-#define NIL_CFG_ST_TIMEDELTA 0
+#define NIL_CFG_ST_TIMEDELTA 2
/** @} */