aboutsummaryrefslogtreecommitdiff
path: root/src/modules/uavcan/uavcan_main.hpp
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2014-11-20 09:37:02 +1100
committerAndrew Tridgell <tridge@samba.org>2014-11-26 08:32:46 +1100
commitb830137ec8492dc583b61689b7d56a1b359a5c5b (patch)
tree97f775057ad69b8bcc276d070dbc0ba9796ed7d1 /src/modules/uavcan/uavcan_main.hpp
parentf6b0a3e07f27f34af6e6d209aec761374611e968 (diff)
downloadpx4-firmware-b830137ec8492dc583b61689b7d56a1b359a5c5b.tar.gz
px4-firmware-b830137ec8492dc583b61689b7d56a1b359a5c5b.tar.bz2
px4-firmware-b830137ec8492dc583b61689b7d56a1b359a5c5b.zip
uavcan: added support for actuator_direct ORB topic
this watches the actuator_direct topic and uses it to allow for direct output of actuator values, bypassing the mixer
Diffstat (limited to 'src/modules/uavcan/uavcan_main.hpp')
-rw-r--r--src/modules/uavcan/uavcan_main.hpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/modules/uavcan/uavcan_main.hpp b/src/modules/uavcan/uavcan_main.hpp
index b791663d4..d7eb16764 100644
--- a/src/modules/uavcan/uavcan_main.hpp
+++ b/src/modules/uavcan/uavcan_main.hpp
@@ -42,6 +42,7 @@
#include <uORB/topics/actuator_outputs.h>
#include <uORB/topics/actuator_armed.h>
#include <uORB/topics/test_motor.h>
+#include <uORB/topics/actuator_direct.h>
#include "actuators/esc.hpp"
#include "sensors/sensor_bridge.hpp"
@@ -128,6 +129,10 @@ private:
pollfd _poll_fds[NUM_ACTUATOR_CONTROL_GROUPS_UAVCAN + 1] = {}; ///< +1 for /dev/uavcan/busevent
unsigned _poll_fds_num = 0;
+ int _actuator_direct_sub = -1; ///< uORB subscription of the actuator_direct topic
+ uint8_t _actuator_direct_poll_fd_num;
+ actuator_direct_s _actuator_direct;
+
// index into _poll_fds for each _control_subs handle
uint8_t _poll_ids[NUM_ACTUATOR_CONTROL_GROUPS_UAVCAN];
};