This repository was archived by the owner on Jul 26, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Tutorial: How to run the firefighting app for a single quadcopter
peterdu2 edited this page Aug 31, 2018
·
23 revisions
-
On quadcopter:
- GeographicLib (included in NAVIO image)
-
Position control code (Clone quadcopter folder into your
catkin_ws
directory) -
ROS VRPN client (
apt-get install ros-kinetic-vrpn-client-ros
) -
rosbridge server (
apt-get install ros-kinetic-rosbridge-server
) - MAVROS (included in NAVIO image)
-
On local machine:
- Ground control software (only necessary if developing for the drone)
- ROS (follow this to install ROS if not previously installed)
- Vicon instructions here
- Quadcopter:
- Plug in battery pack. Placement should be made such that the frame can balance on the center of gravity. Refer to frame manual page 24 for more info.
- Power on
- SSH from local machine using Raspberry Pi IP of quadcopter (use IP lookup software)
NOTE: (IF SENDING MANUAL REACHED MESSAGE, MESSAGE NEEDS TO BE "TRUE" (IN ALL CAPS))
- Local machine:
-
Set up StarL application code
- Pull code from newLib (quadcopter branch)
- Edit
newLib/src/main/java/testmain/TestMain.java
as follows:- Set number of robots participating (
numRobots
) to 2. - Create a new
BotInfoSelector
object - Set
apptoRun
toFollowApp
- Change
selectedRobot
to 1.
- Set number of robots participating (
- Edit
newLib/src/main/java/testmain/BotInfoSelector.java
as follows:- Set IP for drone in the
green
robot section.
- Set IP for drone in the
- Run
mvn clean install
- Push changes to repo
- Repeat step 2 but ensure that
selectedRobot
is now 0. - Repeat step 3 but now set IP for UI machine in the
red
robot section. - Run
mvn clean install
-
Run StarL code and UI application
- Make sure computer is connected to the same WiFi network as the VICON computer.
- Launch RosBridge server:
roslaunch rosbridge_server rosbridge_websocket.launch
- Launch VRPN client to receive VICON data:
roslaunch vrpn_client_ros sample.launch server:=IP
(SetIP
to that of VICON computer. Note:IP
is typically 192.168.1.2) - Clear the following files (in
/newLib
):tasks.txt
anderase.txt
- In newLib/UI_files, run
vrpn_wrapper.py
, then rungui_simply.py
- In newlib, start StarL app with
./run.sh
-
Set up StarL application code
- Quadcopter (via SSH):
- Copy pulled code from Decawave repo to catkin workspace and shell script to home directory
cp -r Decawave/ROS/cyphyhouse/quadcopter ~/catkin_ws/src
cp Decawave/ROS/cyphyhouse/quadcopter/dronesetup.bash ~
- Make the code into the ROS node, work out any library dependencies
cd ~/catkin_ws
source devel/setup.bash
catkin_make
- Change to home directory and edit
dronesetup.bash
line 7 to IP of VICON computer (usually 192.168.1.2)- should look like
roslaunch vrpn_client_ros sample.launch server:=192.168.1.2 &
if using that IP
- should look like
- Run
dronesetup.bash
- Copy pulled code from Decawave repo to catkin workspace and shell script to home directory