Skip to content

Latest commit

 

History

History
205 lines (120 loc) · 7.68 KB

README.md

File metadata and controls

205 lines (120 loc) · 7.68 KB

BOREALIS SPECIFIC MAVROS SETUP

Migrating From existing Borealis drone

change the DRONE_NAME variable in bashrc to a new drone id

Change hostname

sudo nano /etc/hostname , delete and change to a new name sudo nano /etc/hosts , replace all existing computer name with new one sudo reboot

Rebuild workspaces

You might need to catkin clean and catkin build the workspaces again

New Borealis Setup

Installation

Follow inital mavros installation and change branch to pull changes

Initalise this fork from master branch

1. run through normal ros and mavros setup

2. git remote set-url origin https://github.com/Kian-Wee/mavros.git

3. git branch borealis

4. git checkout borealis

5. git pull origin borealis

If any prior changes were made, drop the changes first with, git stash, git stash drop stash@{0}. Enter name and email if prompted.

More instructions(on git) available at [Github & Syntax & Bash](Github & Syntax & Bash/Github Updating Instructions)

Vehicle and position setup

Run the setup file to initalise aliases and udev rules . ~/catkin_ws/src/mavros/borealis_setup/setup.bash

PX4 Params configuration

EKF2_HGT_Mode -> Vision

EKF2_RNG_AID -> Enabled

EKF_2_AID_MASK -> Vision position fusion, Vision yaw fusion (uncheck everything else, value should be 24)

SYS_ID -> same as tgt_id on mavros

MC_YAWRATE_MAX -> 80 deg/s(prevent localisation drift)

MC_YAWRAUTO_MAX -> 4 deg/s(prevent localisation drift)

Frame specific parameters (set to whatever specific to the airframe)

PWM_MAIN_MIN -> 950 (esc calibration often does not give the proper min value)

MPC_THR_HOVER -> 32

MC_ROLLRATE, MC_PITCHRATE, MC_YAWRATE -> ensure pid tuning is done

Developer blogpost on params

QGC Setup

Do remember to change the MAV_SYS_ID on different vehicles, subsequently, change the gcs url port in the mavros launch file The first drone using port 14555 and the subsequent starting from 14556(or any port your prefer), Remember to add the port in QGC when monitoring

Other reference

To run the ouster, ensure the ethernet link is set to link-local only under ipv4 settings

Scripts

basic_position - send positions and generate trajectories

pos_265 - node to provide vision position for mavros, supports posestamped and odometry types (pos_265_old shows all output)

follow+odom+velocity - follows and republishes odom and velocity, counts error per lap

Old Scripts

follow - basic follow script to follow a topic

follow+ - saves additional datapoints

follow+odom - uses odometry instead of posestamped and implements a lapcounter(for use with basic_position)

Multi-Drone Setup

Run sudo ntpdate -s time.nist.gov on all devices

Debugging Position Control

Aside from checking the coordinate frame, check that the uorb topics are being published to by typing listener [topic].

/vehicle_visual_odometry should show the position estimate and

/vehicle_local_position should show the postition estimate post fusion and should not be using dead reckoning.

MAVROS

GitHub release (latest by date) Gitter CI

MAVLink extendable communication node for ROS.

  • Since 2014-08-11 this repository contains several packages.
  • Since 2014-11-02 hydro support separated from master to hydro-devel branch.
  • Since 2015-03-04 all packages also dual licensed under terms of BSD license.
  • Since 2015-08-10 all messages moved to mavros_msgs package
  • Since 2016-02-05 (v0.17) frame conversion changed again
  • Since 2016-06-22 (pre v0.18) Indigo and Jade separated from master to indigo-devel branch.
  • Since 2016-06-23 (0.18.0) support MAVLink 2.0 without signing.
  • Since 2017-08-23 (0.20.0) GeographicLib and it's datasets are required. Used to convert AMSL (FCU) and WGS84 (ROS) altitudes.
  • Since 2018-05-11 (0.25.0) support building master for Indigo and Jade stopped. Mainly because update of console-bridge package.
  • Since 2018-05-14 (0.25.1) support for Indigo returned. We use compatibility layer for console-bridge.
  • Since 2019-01-03 (0.28.0) support for Indigo by master not guaranteed. Consider update to more recent distro.
  • 2020-01-01 version 1.0.0 released, please see #1369 for reasons and its purpose.
  • 2021-05-28 version 2.0.0 released, it's the first alpha release for ROS2.

Instructions on launching the files for navigation for the Shadow Drone:

  • cd into workspace

  • RUN source devel/setup.bash

  • RUN sudo chmod 666 /dev/ttyPixhawk to enable serial read from Pixhawk 2.1 FCU

  • RUN roslaunch mavros shadow.launch to establish connection with Pixhawk 2.1 FCU

  • RUN rosrun mavros shadow.final (trajectory within the room) for navigation, takeoff in stabilise mode and switch to Offboard

OR

  • RUN rosrun mavros shadow.corner (fly forward along the corner of the room and then back but with greater altitude) for navigation, takeoff in stabilise mode and switch to Offboard

Scripts can be found under src/mavros/mavros/scripts

ADVISED TO RUN ON PYTHON 2.7.12

mavros package

It is the main package, please see its README. Here you may read installation instructions.

mavros_extras package

This package contains some extra nodes and plugins for mavros, please see its README.

libmavconn package

This package contain mavconn library, see its README. LibMAVConn may be used outside of ROS environment.

test_mavros package

This package contain hand-tests and manual page for APM and PX4 SITL. Please see README first!

mavros_msgs package

This package contains messages and services used in MAVROS.

Support forums and chats

Please ask your questions not related to bugs/feature or requests on:

We'd like to keep the project bug tracker as free as possible, so please contact via the above methods. You can also PM us via Gitter and the PX4 Slack.

CI Statuses

  • ROS Melodic: Build Status
  • ROS Noetic: Build Status