mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-06-05 14:17:20 +08:00
QuRT: removed calls to sleep
A stub for hrt_sleep was removed. Will add back when DSPAL supports sleep. Signed-off-by: Mark Charlebois <charlebm@gmail.com>
This commit is contained in:
@@ -285,14 +285,6 @@ void hrt_call_at(struct hrt_call *entry, hrt_abstime calltime, hrt_callout callo
|
|||||||
hrt_call_internal(entry, calltime, 0, callout, arg);
|
hrt_call_internal(entry, calltime, 0, callout, arg);
|
||||||
}
|
}
|
||||||
|
|
||||||
void hrt_sleep(uint32_t seconds)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
void hrt_usleep(uint32_t useconds)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
/*
|
/*
|
||||||
* Convert absolute time to a timespec.
|
* Convert absolute time to a timespec.
|
||||||
|
|||||||
@@ -195,3 +195,8 @@ void px4_show_tasks()
|
|||||||
|
|
||||||
// STUBS
|
// STUBS
|
||||||
|
|
||||||
|
extern "C" {
|
||||||
|
void hrt_sleep(unsigned long)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -40,15 +40,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "hello_example.h"
|
#include "hello_example.h"
|
||||||
#include <drivers/drv_hrt.h>
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
/*
|
|
||||||
* Wrap the sleep call.
|
|
||||||
*/
|
|
||||||
__EXPORT extern void hrt_sleep(uint32_t seconds);
|
|
||||||
|
|
||||||
px4::AppState HelloExample::appState;
|
px4::AppState HelloExample::appState;
|
||||||
|
|
||||||
int HelloExample::main()
|
int HelloExample::main()
|
||||||
@@ -57,7 +51,6 @@ int HelloExample::main()
|
|||||||
|
|
||||||
int i=0;
|
int i=0;
|
||||||
while (!appState.exitRequested() && i<5) {
|
while (!appState.exitRequested() && i<5) {
|
||||||
hrt_sleep(2);
|
|
||||||
|
|
||||||
printf(" Doing work...\n");
|
printf(" Doing work...\n");
|
||||||
++i;
|
++i;
|
||||||
|
|||||||
Reference in New Issue
Block a user