HAL_SITL: added support for HAL_Semaphore type

This commit is contained in:
Andrew Tridgell 2018-08-07 16:39:42 +10:00
parent fe93113240
commit 5d3b17db6b
2 changed files with 6 additions and 4 deletions

View File

@ -1,9 +1,10 @@
#pragma once
#include <AP_HAL/AP_HAL_Boards.h>
#if CONFIG_HAL_BOARD == HAL_BOARD_SITL
#include "AP_HAL_SITL.h"
#include <stdint.h>
#include <AP_HAL/AP_HAL_Macros.h>
#include <AP_HAL/Semaphores.h>
#include "AP_HAL_SITL_Namespace.h"
#include <pthread.h>
class HALSITL::Semaphore : public AP_HAL::Semaphore {
@ -17,5 +18,5 @@ public:
private:
pthread_mutex_t _lock;
};
#endif // CONFIG_HAL_BOARD

View File

@ -2,6 +2,7 @@
#include <AP_HAL/AP_HAL.h>
#include "AP_HAL_SITL_Namespace.h"
#include "AP_HAL_SITL.h"
#include "Semaphores.h"
class HALSITL::Util : public AP_HAL::Util {