aboutsummaryrefslogtreecommitdiff
path: root/src/tasks.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/tasks.c')
-rw-r--r--src/tasks.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/tasks.c b/src/tasks.c
new file mode 100644
index 0000000..1d94eaa
--- /dev/null
+++ b/src/tasks.c
@@ -0,0 +1,17 @@
+#include "../tasks.h"
+
+#ifdef CONFIG_IOE_TASKS
+
+#else /* CONFIG_IOE_TASKS */
+
+int8_t taskDelayTillT(int8_t *condition, uint8_t timeout_10us) {
+ while(*condition == 0) {
+ if (timeout_10us == 0)
+ return 1;
+ timeout_10us--;
+ _delay_us(10);
+ }
+ return 0;
+}
+
+#endif /* CONFIG_IOE_TASKS */