238 Commits

Author SHA1 Message Date
Beniamino Pozzan
2e83c3a465 Fixed fastrtps version reading in microRTPS generation
Issue addressed: ROS2 is built from source and
no system-wide version of fastrtps is installed

Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2022-09-15 13:36:40 -04:00
Alvin Sun
238fdadfee Add attitude and bodyrate control to RTPS 2022-09-09 22:21:02 +02:00
Agata Barcis
e268e69265 Fixed fastrtps version reading in microRTPS generation for ROS2 built from sources 2022-09-09 15:11:11 +01:00
Hamish Willee
30e2490d5b
Docs are now in user guide and main (#19977)
* Fix links to docs in source to point to docs on main not master

* More docs and scripts that need to point to main
2022-08-01 11:39:39 +10:00
Agata Barcis
d5d88cba5b generate_microRTPS_bridge.py updated to support ROS2 humble
Signed-off-by: Agata Barcis <agata.barcis@tii.ae>
2022-07-29 15:21:05 +02:00
Hamish Willee
e6eed43648
Spelling errors (#19935) 2022-07-27 14:33:16 +10:00
Daniel Agar
d5839e2dd5 optical flow sensor pipeline overhaul
- all sources of optical flow publish sensor_optical_flow
 - sensor_optical_flow is aggregated by the sensors module, aligned with integrated gyro, and published as vehicle_optical_flow

Co-authored-by: alexklimaj <alex@arkelectron.com>
2022-06-20 20:56:56 -04:00
Matthias Grob
8ca28f3796 Separate message for trajectory setpoint 2022-05-12 17:19:48 +02:00
Junwoo Hwang
35613df210 uORB : Don't automatically include message name as default topic name in uORBTopics source files, to handle case where user doesn't use default messgae name for multi topic definition in .msg file 2022-04-13 09:08:51 +02:00
Daniel Mesham
06a9be74fa microdds: add xrce client 2022-03-22 09:01:05 +01:00
Beat Küng
8a2b310b83 topic_listener: avoid code generation, use existing metadata at runtime
This reduces flash size for v5 by ~110KB, the topic listener now only adds
about 1.2KB.
2021-10-20 08:10:05 +02:00
Beat Küng
4c73ac3805 uorb: use single byte for internal types in o_fields metadata
Reduces flash usage by ~9KB.
2021-10-20 08:10:05 +02:00
mcsauder
21163d859e Whitespace cleanup. 2021-10-19 13:29:26 -04:00
Christian Llanes
6423ea50e6 add sensor_combined to urtps_bridge_topics.yaml 2021-08-18 23:52:45 +01:00
Hamish Willee
8aecc64a73 generate uorb - support multiline descriptions 2021-08-16 08:29:44 +02:00
Hamish Willee
51fa834ac6 generate_msg_docs: generate better page title 2021-08-16 08:29:44 +02:00
TSC21
2a368b4db1 uorb_to_ros_urtps_topics: minor cleanup 2021-08-12 08:44:53 +02:00
TSC21
74557c9071 uorb_to_ros_msgs: minor cleanup 2021-08-12 08:44:53 +02:00
TSC21
e83a3a6cf7 microRTPS: update RTPS message list naming from 'ids' to 'msgs' 2021-08-12 08:44:53 +02:00
TSC21
ffa70ac0fd microRTPS: generate_microRTPS_bridge: run fastrtsgen only once for all files
Reducing the generation time to a 4th of the time (!!)
2021-08-12 08:44:53 +02:00
TSC21
a8a56a03a4 microRTPS: rename uorb_to_ros_rtps_ids to uorb_to_ros_urtps_topics and remove the 'id' references on it 2021-08-12 08:44:53 +02:00
TSC21
4609949bbb microRTPS: generate_microRTPS_bridge: only run the generator for the topics that are actually marked to be used 2021-08-12 08:44:53 +02:00
TSC21
695e1fa574 uorb_to_ros_rtps_ids: add an header with a notice regarding the autogneration of the 'px4_ros_com' urtps_bridge_topics.yaml file
Although it can be modified manually, we are going to recommend the developer to generate it from the PX4-Autopilot side instead
2021-08-12 08:44:53 +02:00
TSC21
c478e2985a microRTPS: simplify the attribution of the RTPS IDs by makiing it automatic
1. The RTPS IDs are now automatically assigned to the topics
2. Only the topics that get defined to be sent or received in the urtps_bridge_topics.yaml (renamed, since now it doesn't contain IDs) receive the IDs
3. Any addition or removal on the urtps_bridge_topics.yaml file might update the topic IDs - this will require that the agent and the client ID list has to be in sync. This will further require a robustification of the way we check the IDs and the message definitions when starting the bridge.
2021-08-12 08:44:53 +02:00
TSC21
d31b7feb31 microRTPS: agent: publish timesync status 2021-08-12 08:44:53 +02:00
Beat Küng
86dc35022a generate_msg_docs.py: simplify logic a bit 2021-08-03 07:54:41 +02:00
Hamish Willee
bf59fd84ba Add simple comment parser 2021-08-03 07:54:41 +02:00
Beat Küng
da6275e43a msg: add script structure to generate docs from .msg files 2021-08-03 07:54:41 +02:00
Daniel Agar
93aa6e3f78 ekf2: baro bias publish minor cleanup
- naming consistency (estimator prefix as "namespace")
 - only publish if baro is available and bias is changing as a small logging optimization
 - avoid unnecessary copying (get const reference to status directly)
 - trivial code style fixes
2021-08-02 13:59:38 -04:00
Igor Mišić
af2247bd94
mavlink: use dynamic camera comp id instead of hardcoded value 2021-07-31 12:41:49 -04:00
Dima Ponomarev
d08d0443bc
Add internal combustion engine status uavcan bridge and mavlink EFI_STATUS stream 2021-07-30 22:31:43 -04:00
TSC21
205d4400eb add baro_bias_estimate to RTPS list 2021-07-20 04:56:33 -07:00
Beat Küng
38f3b8d356 mavlink & system: add events interface
- sending protocol
- uorb event message & template methods for argument packing
- libevents submodule to send common events and handle json files
- cmake maintains a list of all (PX4) source files for the current build
  (PX4 modules + libs), which is used to extract event metadata and
  generate a json file
2021-07-07 21:38:09 -04:00
TSC21
4741ec25ce microRTPS: increase base message ID space to 179 2021-06-25 13:05:24 +02:00
TSC21
578e426e9e microRTPS: set trajectory_waypoint to be sent only, as this is outgoing data with vehicle_trajectory_waypoint_desired 2021-06-21 16:36:44 +02:00
David Sidrane
64db89ab20 px_generate_uorb_topic_helper: Use inttypes 2021-06-16 17:07:47 +02:00
Nuno Marques
f9fe0e3746
ROS2/microRTPS: Add support for ROS2 Galactic and ROS2 Rolling (#17664)
microRTPS: generate_microRTPS_bridge: add support for ROS2 versions
* Galactic
* Rolling
2021-05-27 09:32:16 -07:00
Julian Kent
5c5ec1a0ea Receive telemetry_status, send vehicle_trajectory_waypoint_desired 2021-03-31 13:26:00 +02:00
Julian Kent
b5a64f957e Update RTPS messages to match what is needed for PX4/Avoidance 2021-03-31 13:26:00 +02:00
mohamed.moustafa
6914ebef4e added messages required by offboard_control example 2021-03-10 08:42:33 -05:00
Paul Riseborough
4465c4fbf6
ekf2: Publish and log EKF warning and information events (NEW msg estimator_event_flags)
* msg: Add estinator information and warning events message (estimator_event_flags)
 * ekf2: publish information and warning events
 * logger: log estimator_event_flags
 * update ecl submodule to latest

Co-authored-by: Daniel Agar <daniel@agar.ca>
2021-03-07 16:16:48 -05:00
Silvan Fuhrer
0ea8104344
select single system-wide wind estimate message (current best)
- publish wind estimate only from EKF, and wind speeds from airspeed selector to new separate topic (airspeed_wind)
 - rename message wind_estimate to wind
 - publish wind from currently used ekf instance (ekf2selector)

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2021-02-20 13:15:01 -05:00
Julian Kent
a3e0e2e84f Fix RTPS builds 2021-02-17 13:54:34 -05:00
Martina Rivizzigno
48b00ff678 Support for gimbal v2 protocol
- add command to request a message
- add gimbal attitude message

mavlink_receiver handle GIMBAL_MANAGER_SET_ATTITUDE

first implementation of new vmount input MavlinkGimbalV2
- setup class
- decode gimbal_manager_set_attitude in ControlData

add gimbal information message

add gimbal manager information and vehicle command ack

mavlink messages: add stream for GIMBAL_MANAGER_INFORMATION

mavlink_receiver: handle GIMBAL_DEVICE_INFORMATION

remove mavlink cmd handling from vmount input MavlinkGimbalV2

complete gimbal manager:
- send out fake gimbal_device_information for dummy gimbals
- complete ROI handling with nudging

small fixes

fix typos

cleanup
- gimbal device information
- flags lock
- check sanity of string

add support for CMD_DO_GIMBAL_MANAGER_ATTITUDE

stream GimbalDeviceAttitudeStatus for dummy gimbals
- add uROB gimbal_attitude_status
- fill status in vmount output_rc for dummy gimbals not able to send the
status themselves
- stream mavlink GimbalDeviceAttitudeStatus

better handle the request for gimbal infomation request

clean up

bring gimbal information back on vmount init

add new gimbal message to mavlink normal stream

fix publication of gimbal device information

rename gimbal_attitude_status to gimbal_device_attitude_status

stream gimbal_manager_status at 5Hz

mavlink: send information only on request

Sending the information message once on request should now work and we
don't need to keep publishing it.

mavlink: debug output for now

make sure to copy over control data

mavlink: add missing copyright header, pragma once

mavlink: address review comments

mavlink: handle stream not updated

Our answer does not just depend on whether the stream was found but
whether we actually were able to send out an update.

mavlink: remove outdated comment

vmount: add option for yaw stabilization only

The stabilize flag is used for gimbals which do not have an internal IMU
and need the autopilot's attitude in order to do stabilization. These
gimbals are probably quite rare by now but it makes sense to keep the
functionality given it can e.g. be used by simple servo gimbals for
sensors other than highres cameras.

The stabilize flag can also be re-used for gimbals which are capable of
stabilizing pitch and roll but not absolute yaw (e.g. locked to North).
For such gimbals we can now set the param MNT_DO_STAB to 2.

We still support configuring which axes are stabilized by the
MAVLink command DO_MOUNT_CONFIGURE, however, this is generally not
recommended anymore.

vmount: fix incorrect check for bit flag

mavlink_messages: remove debug message

Signed-off-by: Claudio Micheli <claudio@auterion.com>

use device id

remove debug print

gimbal attitude fix mistake

clang tidy fix

split:
- gimbal_attitude -> gimbal_device_set_attitude, gimbal_manager_set_attitude
- gimbal_information -> gimbal_device_informatio, gimbal_manager_information

add gimbal protocol messages to rtps msg ids

support set attitude for gimbal directly speaking mavlink

clean up gimbal urob messages

vmount: address a few small review comments

vmount: split output into v1 and v2 protocol

This way we can continue to support the MAVLink v1 protocol. Also, we
don't send the old vehicle commands when actually using the new v2
protocol.

vmount: config via ctor instead of duplicate param

vmount: use loop to poll all topics

Otherwise we might give up too soon and miss some data, or run too fast
based on commands that have nothing to do with the gimbal.

typhoon_h480: use gimbal v2 protocol, use yaw stab

Let's by default use the v2 protocol with typhoon_h480 and enable yaw
lock mode by stabilizing yaw.
2021-02-17 13:54:34 -05:00
Daniel Agar
a416731656 drivers/heater: add logging and minor improvements
- new heater_status logging message
 - run continously at low rate until configured sensor is found
 - fix px4io fd bugs (fd open/close/ioctl must be same thread)
2021-02-16 15:16:19 -05:00
Gerald
88c68914a9 update uorb_rtps_message_ids.yaml for id: 30
For some usecases like starting video recording on a companion computer or triggering a ROS based (offboard control) mission control execution the status of RC channel is needed in ROS(2). This allows the user to start/stop such functionalities from the RC transmitter.

Therefore InputRc to be changed accordingly.
add 'Set send: true' for id: 30
2021-02-03 08:52:44 -05:00
TSC21
10d94e5981 update uorb_rtps_message_ids.yaml 2021-02-02 13:55:42 +01:00
TSC21
701a585a81 RTPS: add check for IDs on multi-topics/alias messages as well 2021-02-02 13:55:42 +01:00
Matthias Grob
fbd64fbdd8 FlightModeManager: publish takeoff status 2021-01-31 11:37:00 +01:00
Matthias Grob
65884960fa Remove ancient submodules
that were accidentally added back without URL in #16471
2021-01-21 10:46:29 +01:00