From 859d946f4f204b6e6d5aa9d9f64bbffae0f05e50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martynas=20Mickevi=C4=8Dius?= Date: Thu, 1 Jan 1970 01:34:34 -0700 Subject: [PATCH] use usleep --- rpi/platform.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rpi/platform.c b/rpi/platform.c index 213f355..c792f5b 100644 --- a/rpi/platform.c +++ b/rpi/platform.c @@ -1,6 +1,6 @@ #include #include -#include +#include void print(char *str) { @@ -22,7 +22,7 @@ void print_buf(uint8_t *buf, uint8_t n) void delay_ms(int ms) { - nanosleep((struct timespec[]){{0, ms * 1000000}}, NULL); + usleep(ms * 1000); } void enable_spi()