From 58084685b2b2f8e31598320318a7c34dd0a96955 Mon Sep 17 00:00:00 2001 From: Lorenz Meier Date: Thu, 16 May 2013 09:12:13 +0200 Subject: Hotfix: Changed alarms back to what they originally were designed for: Traps to later see if condition was once violated. Currente status can be read through the status flags --- src/drivers/px4io/px4io.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/drivers/px4io') diff --git a/src/drivers/px4io/px4io.cpp b/src/drivers/px4io/px4io.cpp index a40142792..8b2fae12b 100644 --- a/src/drivers/px4io/px4io.cpp +++ b/src/drivers/px4io/px4io.cpp @@ -1273,6 +1273,9 @@ PX4IO::print_status() ((alarms & PX4IO_P_STATUS_ALARMS_FMU_LOST) ? " FMU_LOST" : ""), ((alarms & PX4IO_P_STATUS_ALARMS_RC_LOST) ? " RC_LOST" : ""), ((alarms & PX4IO_P_STATUS_ALARMS_PWM_ERROR) ? " PWM_ERROR" : "")); + /* now clear alarms */ + io_reg_set(PX4IO_PAGE_STATUS, PX4IO_P_STATUS_ALARMS, 0xFFFF); + printf("vbatt %u ibatt %u vbatt scale %u\n", io_reg_get(PX4IO_PAGE_STATUS, PX4IO_P_STATUS_VBATT), io_reg_get(PX4IO_PAGE_STATUS, PX4IO_P_STATUS_IBATT), -- cgit v1.2.3