From a196e73842259152595d524b150a611076ca91d0 Mon Sep 17 00:00:00 2001 From: Lorenz Meier Date: Tue, 5 Feb 2013 18:11:59 +0100 Subject: Fixed arm ok flag typo --- apps/drivers/px4io/px4io.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'apps/drivers/px4io/px4io.cpp') diff --git a/apps/drivers/px4io/px4io.cpp b/apps/drivers/px4io/px4io.cpp index f948fec2c..2a0d72c31 100644 --- a/apps/drivers/px4io/px4io.cpp +++ b/apps/drivers/px4io/px4io.cpp @@ -541,9 +541,9 @@ PX4IO::io_set_arming_state() clear |= PX4IO_P_SETUP_ARMING_VECTOR_FLIGHT_OK; } if (vstatus.flag_external_manual_override_ok) { - set |= PX4IO_P_SETUP_ARMING_MANUAL_OVERRIDE; + set |= PX4IO_P_FEAT_ARMING_MANUAL_OVERRIDE_OK; } else { - clear |= PX4IO_P_SETUP_ARMING_MANUAL_OVERRIDE; + clear |= PX4IO_P_FEAT_ARMING_MANUAL_OVERRIDE_OK; } return io_reg_modify(PX4IO_PAGE_SETUP, PX4IO_P_SETUP_ARMING, clear, set); @@ -1214,6 +1214,10 @@ monitor(void) int px4io_main(int argc, char *argv[]) { + /* check for sufficient number of arguments */ + if (argc < 2) + goto out; + if (!strcmp(argv[1], "start")) { if (g_dev != nullptr) @@ -1330,5 +1334,6 @@ px4io_main(int argc, char *argv[]) if (!strcmp(argv[1], "monitor")) monitor(); + out: errx(1, "need a command, try 'start', 'stop', 'status', 'test', 'monitor' or 'update'"); } -- cgit v1.2.3