mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-23 06:53:34 +08:00
Replacing usleep with px4_usleep
This is a step towards isolating time from the system.
This commit is contained in:
@@ -340,7 +340,7 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
while (sim_delay) {
|
||||
usleep(100);
|
||||
px4_usleep(100);
|
||||
}
|
||||
|
||||
PX4_DEBUG("Called px4_poll timeout = %d", timeout);
|
||||
|
||||
@@ -234,7 +234,7 @@ int CDevExample::do_poll(int fd, int timeout, int iterations, int delayms_after_
|
||||
}
|
||||
|
||||
if (delayms_after_poll) {
|
||||
usleep(delayms_after_poll * 1000);
|
||||
px4_usleep(delayms_after_poll * 1000);
|
||||
}
|
||||
|
||||
loop_count++;
|
||||
|
||||
Reference in New Issue
Block a user