Difference between revisions of "Ipodrom"
(Utilisation) |
|||
(5 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
Ipodrom is the acronym for '''I'''nterface '''po'''ur contrôler un '''dro'''ne sur un '''m'''obile. | <categorytree style="float:right; clear:right; margin-left:1ex; border: 1px solid gray; padding: 0.7ex;" mode=pages>Tools</categorytree> | ||
__TOC__ | |||
Ipodrom is the french acronym for '''''I'''nterface '''po'''ur contrôler un '''dro'''ne sur un '''m'''obile''. | |||
It is the French for UAV control interface on a mobile phone. | It is the French for UAV control interface on a mobile phone. | ||
Line 11: | Line 14: | ||
== On the ground station == | == On the ground station == | ||
The goal of this program is to relay the messages from the airplane (via the server on the ivy bus) to the mobile, and the commands from the phone on ground station's ivy bus. | The goal of this program (called IpodromPC) is to relay the messages from the airplane (via the server on the ivy bus) to the mobile, and the commands from the phone on ground station's ivy bus. | ||
== On the mobile == | == On the mobile == | ||
There is a program developped with Java ME (MicroEdition). | There is a program developped with Java ME (MicroEdition). Ipodrom connects to the Bluetooth relay of the ground station, and displays the main information about the plane and the flight. It is also possible to send commands, such as climb, jump to Standby block, land, and move the waypoints. | ||
= How to get Ipodrom ? = | = How to get Ipodrom ? = | ||
Line 55: | Line 58: | ||
* The source for the ground application (relay on the ground station) is here : http://svn.assembla.com/svn/ipodrom/IpodromPC/ | * The source for the ground application (relay on the ground station) is here : http://svn.assembla.com/svn/ipodrom/IpodromPC/ | ||
== | == Compilation == | ||
'' | |||
The compilation process is described here, not because I think you can't guess it, but you don't create Java ME applications every day ! | |||
=== For Ipodrom === | |||
# Once you've installed the WTK, launch it (the program is here : WTK_folder/bin/ktoolbar). | |||
# Then create a new project, named "Ipodrom", and with Midlet Class Name "main.Ipodrom" | |||
# You can copy the Ipodrom's src and res folder you've downloaded into the project folder : ~/j2mewtk/2.5.2/apps/Ipodrom/ (you may need to restart the application) | |||
# When pressing the "Run" button in the WTK, the simulator should start executing Ipdrom | |||
# To create a archive to send to your mobile, go into the "Project" menu, then "Package/create package". You have a Ipodrom.jar file in the /bin folder of your project folder | |||
See below for compilation options. | |||
=== For IpodromPC === | |||
On the svn server you can find the source code and the required librairies (necessary to use Bluetooth and to connect to the ivy bus), and also a Makefile. Once you've downloaded them, just type ''make'', that will create the runnable java archive (IpodromPC.jar). | |||
= How to use Ipodrom ? = | = How to use Ipodrom ? = | ||
Line 62: | Line 78: | ||
== Finding the maps files == | == Finding the maps files == | ||
Like | Like Paparazzi, Ipodrom can show the plane on a map with aerial pictures. The images are not downloaded automatically from the internet, we use the ones downloaded by Paparazzi (they are located in ''$PAPARAZZI_HOME/var/maps''). | ||
== Compiling the right version == | == Compiling the right version == | ||
(Ipodrom only) | |||
You might use Ipodrom on your mobile in real conditions (the phone connected to the ground station), or you might test it on a simulator (included in the Sun Wireless Toolkit, see above). You must change a little line in the code, depending on your target. | You might use Ipodrom on your mobile in real conditions (i.e. the phone connected to the ground station), or you might test it on a simulator (included in the Sun Wireless Toolkit, see above). You must change a little line in the code, depending on your target. | ||
See in the file Configuration.java (in the package ''main''), you can change the variable isSimulation, from true to false. | See in the file Configuration.java (in the package ''main''), you can change the variable isSimulation, from true to false. | ||
=== The case of the simulation === | === The case of the simulation === | ||
In this case, the images for the map must be included in the *.jar file (in the folder /res/maps). Save them before the packaging, and WTK will include them automatically in the final .jar file. The problem is that the size of the file will increase. | In this case, the images for the map must be included in the *.jar file (in the folder ''/res/maps''). Save them before the packaging, and WTK will include them automatically in the final .jar file. The problem is that the size of the file will increase. | ||
=== The case of a "real test" === | === The case of a "real test" === | ||
In this case, it is not necessary to put the map files in the .jar archive. The program will scan the filesystems you have on your device, and search the images in the /maps folder located at the root a filesystem. So just | In this case, it is not necessary to put the map files in the .jar archive. The program will scan the filesystems you have on your device, and search the images in the /maps folder located at the root of a filesystem. So just copy the Paparazzi /maps folder at the root of your phone memory card. | ||
== Executing the applications == | == Executing the applications == | ||
Line 80: | Line 97: | ||
On the ground station, start Paparazzi, then start Ipodrom for the PC : | On the ground station, start Paparazzi, then start Ipodrom for the PC : | ||
java -jar IpodromPC.jar -ac_id 42 | |||
assuming that 42 is the ID of the plane you're flying. | (assuming that 42 is the ID of the plane you're flying). | ||
If you're using the phone simulator, then add the ''-local'' option on the command line, that will start the program listening on a local connection instead of Bluetooth. | If you're using the phone simulator, then add the ''-local'' option on the command line, that will start the program listening on a local connection instead of Bluetooth. | ||
You can have a better options description with : | You can have a better options description with : | ||
java -jar IpodromPC.jar -h | |||
It is necessary to have the environment variable ''$PAPARAZZI_HOME'' positionned for a correct detection of the flight plan and other informations about the plane. | |||
Now you can start Ipodrom on you mobile phone ! | Now you can start Ipodrom on you mobile phone ! | ||
[[Category:Tools]] [[Category:User_Documentation]] |
Latest revision as of 06:56, 24 January 2013
Ipodrom is the french acronym for Interface pour contrôler un drone sur un mobile. It is the French for UAV control interface on a mobile phone.
This system has been designed and developped by 3 ENAC students. It is based on Paparazzi, and enables the control of a UAV running Paparazzi on a mobile phone connected via Bluetooth to the ground station.
Presentation
The system is entirely based on Java technology. It is divided in 2 programs : one running on the ground station, and the other on the mobile.
On the ground station
The goal of this program (called IpodromPC) is to relay the messages from the airplane (via the server on the ivy bus) to the mobile, and the commands from the phone on ground station's ivy bus.
On the mobile
There is a program developped with Java ME (MicroEdition). Ipodrom connects to the Bluetooth relay of the ground station, and displays the main information about the plane and the flight. It is also possible to send commands, such as climb, jump to Standby block, land, and move the waypoints.
How to get Ipodrom ?
The installation described here is for debian-like systems (typically Ubuntu). Thank you for sharing your experience on others systems!
Requirements
You need to have Paparazzi installed. That won’t be detailed here, I think you can find the instructions by yourself on this site.
The source code is in Java, so you need both Java SE (Standard Edition) for your PC, and Java ME (MicroEdition) for the mobile program. Java SE downloads can be found here : http://java.sun.com/javase/downloads/index.jsp, but it's far more easy to install the corresponding debian packages :
- sun-java6-jre
- sun-java6-jdk
Note: you need both JRE and JDK in order to compile java applications. Be sure you have version 6 (it doesn't work with 5).
JavaME downloads can be found here : http://java.sun.com/javame/downloads/index.jsp
Download and install the Sun Wireless Toolkit (WTK), which enables to manage JavaME projects, compiling and packaging them. The version we used is Sun Java Wireless Toolkit 2.5.2 for CLDC.
You need a Bluetooth peripheral on your computer (and on your mobile device). These are the debian packages that already should be installed:
- libxpm-dev
- libxt-dev
- libx11-dev
- libice-dev
- libsm-dev
- libc6-dev
- libstdc++6-dev
There are specific Bluetooth packages you have to install:
- bluetooth
- bluez
- libbluetooth3
- libbluetooth-dev
The source code
It is available on a subversion server.
- The source for the mobile application (on the phone) is here : http://svn.assembla.com/svn/ipodrom/Ipodrom/
- The source for the ground application (relay on the ground station) is here : http://svn.assembla.com/svn/ipodrom/IpodromPC/
Compilation
The compilation process is described here, not because I think you can't guess it, but you don't create Java ME applications every day !
For Ipodrom
- Once you've installed the WTK, launch it (the program is here : WTK_folder/bin/ktoolbar).
- Then create a new project, named "Ipodrom", and with Midlet Class Name "main.Ipodrom"
- You can copy the Ipodrom's src and res folder you've downloaded into the project folder : ~/j2mewtk/2.5.2/apps/Ipodrom/ (you may need to restart the application)
- When pressing the "Run" button in the WTK, the simulator should start executing Ipdrom
- To create a archive to send to your mobile, go into the "Project" menu, then "Package/create package". You have a Ipodrom.jar file in the /bin folder of your project folder
See below for compilation options.
For IpodromPC
On the svn server you can find the source code and the required librairies (necessary to use Bluetooth and to connect to the ivy bus), and also a Makefile. Once you've downloaded them, just type make, that will create the runnable java archive (IpodromPC.jar).
How to use Ipodrom ?
Finding the maps files
Like Paparazzi, Ipodrom can show the plane on a map with aerial pictures. The images are not downloaded automatically from the internet, we use the ones downloaded by Paparazzi (they are located in $PAPARAZZI_HOME/var/maps).
Compiling the right version
(Ipodrom only)
You might use Ipodrom on your mobile in real conditions (i.e. the phone connected to the ground station), or you might test it on a simulator (included in the Sun Wireless Toolkit, see above). You must change a little line in the code, depending on your target. See in the file Configuration.java (in the package main), you can change the variable isSimulation, from true to false.
The case of the simulation
In this case, the images for the map must be included in the *.jar file (in the folder /res/maps). Save them before the packaging, and WTK will include them automatically in the final .jar file. The problem is that the size of the file will increase.
The case of a "real test"
In this case, it is not necessary to put the map files in the .jar archive. The program will scan the filesystems you have on your device, and search the images in the /maps folder located at the root of a filesystem. So just copy the Paparazzi /maps folder at the root of your phone memory card.
Executing the applications
Once you've created the right version for your mobile, just send the .jar file. The installation procedure depends on your device.
On the ground station, start Paparazzi, then start Ipodrom for the PC :
java -jar IpodromPC.jar -ac_id 42
(assuming that 42 is the ID of the plane you're flying).
If you're using the phone simulator, then add the -local option on the command line, that will start the program listening on a local connection instead of Bluetooth. You can have a better options description with :
java -jar IpodromPC.jar -h
It is necessary to have the environment variable $PAPARAZZI_HOME positionned for a correct detection of the flight plan and other informations about the plane.
Now you can start Ipodrom on you mobile phone !