1
0
forked from fsfw/fsfw

various changes, stopwatch

Semaphore: Some bugfixes, some constructors added
Stopwatch: First implementation, can measure in ms(double) and
ms(normal)
This commit is contained in:
2020-04-08 18:08:14 +02:00
parent 30ed08005f
commit e0e1e64a09
13 changed files with 247 additions and 45 deletions

View File

@ -3,8 +3,11 @@
#include <stdlib.h>
#include "Timekeeper.h"
extern "C" {
#include <FreeRTOS.h>
#include <task.h>
}
//TODO sanitize input?
//TODO much of this code can be reused for tick-only systems
@ -56,7 +59,6 @@ ReturnValue_t Clock::getUptime(timeval* uptime) {
timeval Clock::getUptime() {
TickType_t ticksSinceStart = xTaskGetTickCount();
return Timekeeper::ticksToTimeval(ticksSinceStart);
}