From a8dc17a6cfe9e678ba37b2cf9073ebfd25841405 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89milie=20Feral?= Date: Wed, 17 Jan 2018 15:21:24 +0100 Subject: [PATCH] [ion] Add TODO on implementations of usleep msleep --- ion/src/device/device.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ion/src/device/device.cpp b/ion/src/device/device.cpp index 20b006599..23daf95f9 100644 --- a/ion/src/device/device.cpp +++ b/ion/src/device/device.cpp @@ -19,6 +19,10 @@ extern "C" { // Public Ion methods +/* TODO: The delay methods 'msleep' and 'usleep' are currently dependent on the + * optimizations chosen by the compiler. To prevent that and to gain in + * precision, we could use the controller cycle counter (Systick). */ + void Ion::msleep(long ms) { for (volatile long i=0; i<8852*ms; i++) { __asm volatile("nop");