Applications - Technology insights

Connection to Pixhawk autopilots Teraranger Tower Evo

TeraRanger Tower Evo connection to Pixhawk Autopilots with embedded Firmware Builds
Tower Evo Pixhawk 2 Final 1

Table of contents

1 Introduction

2 Compatibility table

3 Wiring Connection to Pixhawk

3.1 TeraRanger Evo wiring connection – Pixhawk 2.1

3.2 TeraRanger Evo wiring connection – Pixhawk 1

4 Mounting on a drone

5 Onboard firmware setup instructions

5.1 Arducopter – QGroundControl

5.2 Update parameters

6 Further reading

1 Introduction

The purpose of this document is to give instructions on how to connect a TeraRanger Tower Evo LiDAR system to a Pixhawk board using an UART interface and how to setup ArduPilot firmware to enable TeraRanger Tower Evo use.

2 Compatibility table

TeraRanger Tower Evo works with Ardupilot (APM) software. Compatibility with ArduCopter has been tested from V3.6 onwards. Other versions of Ardupilot for planes, rover, etc… could work but it has not been tested in our facilities.
Teraranger Tower Evo Pixhawk Compatibility

3 Wiring Connection to Pixhawk

3.1 TOWER EVO WIRING CONNECTION - PIXHAWK 2.1

To connect the TeraRanger Tower Evo system to Pixhawk please make sure you have the following items:

1. DF13 (6 pin) to open-ended cable
2. TeraRanger Tower Evo
3. Pixhawk 2.1

Please use the open-ended cable and make your connection as described in the pinout table below. It is suggested to connect the UART cable to GPS2 port on Pixhawk 2.1 (serial 4). In case you need to connect to a different serial port (Telemetry 1/2, GPS 1 or Debug) please consult the Pixhawk 2 datasheet on the pinout of the desired port.
Tower Pixhawk 2 Cable

Pixhawk UART connector reference: JST-GH 6pin.

This figure illustrates wiring connections from TeraRanger Tower Evo to Pixhawk 2.1. Red wire in the image represents Pin 1.
Pix 2

Wiring connection to Pixhawk 2.1
Tower Evo Pixhawk 2 Final 1

3.2 TeraRanger Evo wiring connection – Pixhawk 1

To connect a TeraRanger Tower Evo (TR-TW-EVO) system to Pixhawk please make sure you have the following items:

1. DF13 6P to open-ended cable (or Pixhawk telemetry cable)
2. TeraRanger Tower Evo
3. Pixhawk 1
Tower Pixhawk Cable

Please use the open-ended cable and make your connection as described in the pinout table on the right. It is suggested to connect the UART cable to SERIAL 4/5 port on Pixhawk 1.

Pixhawk serial connector ref: DF13 6pins.

Pix 1

This figure illustrates wiring connections from TeraRanger Tower Evo to Pixhawk 1. Red wire in the image represents Pin 1.

Tower Evo Pixhawk Cable Fixed

4 Mounting on a drone

The default orientation for the TeraRanger Tower Evo is with the sensor numbered 1 pointing forward. All the consecutive sensor numbers are in a clockwise order. Sensor number 1 is always indicated with a blue sticker.

Mounting orientation for TeraRanger Tower Evo on a drone:
Tower Evo Orientation

5 Setup the onboard firmware steps to follow:

5.1 ARDUCOPTER – QGROUNDCONTROL

Go to the Firmware tab on QGroundControl (reconnect autopilot in order to flash a new firmware). Select ArduPilot Flight Stack. In the dropdown menu select MultiRotor – APM:Copter.
Arducopter Setup

5.2 UPDATE PARAMETERS

In the ground control station software of your choice (Mission Planner, QGroundControl, APM Planner 2) set the following parameters in the parameter list.

Teraranger Tower Evo Arducopter Compatibility

The following section describes the steps for setting parameters on QGroundControl software.

STEP 1

Go to Settings -> Parameters and select “Serial” option. Make sure that “SERIAL4_PROTOCOL is set to “921600” and SERIAL4_BUAD is set to “Lidar360”.

Serial Ports For Tower Evo

STEP 2

Back in Parameters select the “PRX” option, click on “Advanced settings”, “Manual entry” and set the type of proximity sensor connected to, “6”. Click “Save”.

Prx Parameters For Tower Evo

In the above settings it is assumed that the Tower Evo is connected to SERIAL 4 port. In case you are using a different port on your autopilot board please make sure that you refer to the corresponding settings (e.g. SERIAL 5 settings).

STEP 3

After setting the parameters, please reboot the autopilot (unplug and plug the USB cable).

STEP 4

To verify that the TeraRanger Tower Evo is functional on your ground control station, go to “Widgets” (top task bar) and select “Analyze”. The message plotter will now open.

From the list on the left hand side select “M1:DISTANCE_SENSOR.current_distance” to visualize the distance values received from the TeraRanger Tower Evo, which is an indicator that the system is operating normally.

Distance Readings Pixhawk Tower Evo Set Up

STEP 4 (ALTERNATIVE)

Another option to visualize distance values from the TeraRanger Tower Evo is to use Mission Planner’s proximity viewer. Navigate to Mission Planner Flight Data screen, press Ctrl-F and select the “Proximity” option.
Mission Planner Distance Measurements Check Tower Evo

6. Further reading

For more information about object avoidance please consult the following link: