mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-16 22:53:34 +08:00
POSIX: Fixes for ARMv7 build
uint64_t needs to use PRIu64 in printf. Clang-3.5 found an error is variable types for a compare. Signed-off-by: Mark Charlebois <charlebm@gmail.com>
This commit is contained in:
@@ -211,7 +211,7 @@ Airspeed::ioctl(device::file_t *filp, int cmd, unsigned long arg)
|
||||
bool want_start = (_measure_ticks == 0);
|
||||
|
||||
/* convert hz to tick interval via microseconds */
|
||||
long ticks = USEC2TICK(1000000 / arg);
|
||||
unsigned long ticks = USEC2TICK(1000000 / arg);
|
||||
|
||||
/* check against maximum rate */
|
||||
if (ticks < USEC2TICK(_conversion_interval))
|
||||
|
||||
@@ -42,6 +42,7 @@
|
||||
#include <semaphore.h>
|
||||
#include <time.h>
|
||||
#include <string.h>
|
||||
#include <inttypes.h>
|
||||
#include "hrt_work.h"
|
||||
|
||||
static struct sq_queue_s callout_queue;
|
||||
@@ -301,7 +302,7 @@ hrt_call_internal(struct hrt_call *entry, hrt_abstime deadline, hrt_abstime inte
|
||||
sq_rem(&entry->link, &callout_queue);
|
||||
|
||||
if (interval < HRT_INTERVAL_MIN) {
|
||||
PX4_ERR("hrt_call_internal interval too short: %lu", interval);
|
||||
PX4_ERR("hrt_call_internal interval too short: %" PRIu64, interval);
|
||||
}
|
||||
entry->deadline = deadline;
|
||||
entry->period = interval;
|
||||
|
||||
Reference in New Issue
Block a user