diff --git a/tests/driver_dht/Makefile b/tests/driver_dht/Makefile index 4e8bc9cd6..0d1ad55b3 100644 --- a/tests/driver_dht/Makefile +++ b/tests/driver_dht/Makefile @@ -9,6 +9,7 @@ ifneq (,$(filter stm32f4discovery,$(BOARD))) endif USEMODULE += dht +USEMODULE += xtimer ifneq (,$(DHT_TYPE)) CFLAGS += -DDHT_TYPE=$(DHT_TYPE) diff --git a/tests/driver_dht/main.c b/tests/driver_dht/main.c index 12e886ebf..1cf8f45ca 100644 --- a/tests/driver_dht/main.c +++ b/tests/driver_dht/main.c @@ -29,8 +29,7 @@ #include -#include "hwtimer.h" -#include "timex.h" +#include "xtimer.h" #include "dht.h" @@ -59,7 +58,7 @@ int main(void) dht_parse(&dev, &data, &hum, &temp); printf("raw relative humidity: %i\nraw temperature: %i C\n", data.humidity, data.temperature); printf("relative humidity: %i\ntemperature: %i C\n", (int) hum, (int) temp); - hwtimer_wait(HWTIMER_TICKS(2000 * MS_IN_USEC)); + xtimer_usleep(2000 * MS_IN_USEC); } return 0;