mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-18 06:23:34 +08:00
platforms: use define for lockstep scheduler
Instead of using the define __PX4_POSIX_SITL it makes more sense to have a define just to determine if the lockstep scheduler should be used.
This commit is contained in:
@@ -65,7 +65,7 @@
|
||||
*/
|
||||
#define system_exit exit
|
||||
|
||||
#if defined(__PX4_POSIX_SITL)
|
||||
#if defined(ENABLE_LOCKSTEP_SCHEDULER)
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
@@ -99,7 +99,7 @@
|
||||
#include <unistd.h>
|
||||
#include <time.h>
|
||||
|
||||
#else // defined(__PX4_POSIX_SITL)
|
||||
#else // defined(ENABLE_LOCKSTEP_SCHEDULER)
|
||||
|
||||
#define system_usleep usleep
|
||||
#define system_sleep sleep
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
#define clockid_t int
|
||||
#endif
|
||||
|
||||
#if defined(__PX4_POSIX_SITL) || defined(__PX4_QURT)
|
||||
#if defined(ENABLE_LOCKSTEP_SCHEDULER) || defined(__PX4_QURT)
|
||||
|
||||
__BEGIN_DECLS
|
||||
__EXPORT int px4_clock_gettime(clockid_t clk_id, struct timespec *tp);
|
||||
|
||||
Reference in New Issue
Block a user