README.md 2.97 KB
Newer Older
Philippe Gaussier's avatar
Philippe Gaussier committed
1
2
3
[![Awesome Badges](https://img.shields.io/badge/Laboratory-Etis-purple.svg)](https://www-etis.ensea.fr)
[![Awesome Badges](https://img.shields.io/badge/Team-Neurocyber-red.svg)](https://www-etis.ensea.fr)
[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](sylvain.colomer.pro@gmail.com)
GitLab's avatar
GitLab committed
4

Philippe Gaussier's avatar
Philippe Gaussier committed
5
# Pixhawk service  #
GitLab's avatar
GitLab committed
6

Philippe Gaussier's avatar
Philippe Gaussier committed
7
## Introduction ##
GitLab's avatar
GitLab committed
8

Philippe Gaussier's avatar
Philippe Gaussier committed
9
The pixhawk service program is a simple application that allow use to communicate thourgh Mavlink to a pixhawk flying controler. It use Blc channels, a lib to use shared memory make by friendly collegue, Arnaud Blanchard (See blaar lib).
Philippe Gaussier's avatar
Philippe Gaussier committed
10

GitLab's avatar
GitLab committed
11

Philippe Gaussier's avatar
Philippe Gaussier committed
12
## Project Structure ##
GitLab's avatar
GitLab committed
13

Philippe Gaussier's avatar
Philippe Gaussier committed
14
15
16
17
18
The project word in real time with multiple thread : 
* Serial port thread in reading and writing 
* IHM thread
* Joystick thread
* Main thread
GitLab's avatar
GitLab committed
19

Philippe Gaussier's avatar
Philippe Gaussier committed
20
### Language ###
GitLab's avatar
GitLab committed
21

Philippe Gaussier's avatar
Philippe Gaussier committed
22
C++
GitLab's avatar
GitLab committed
23

Philippe Gaussier's avatar
Philippe Gaussier committed
24
### Dependencies ###
GitLab's avatar
GitLab committed
25

Philippe Gaussier's avatar
Philippe Gaussier committed
26
27
28
29
30
31
This project use :
* https://promethe.u-cergy.fr/blaar/blaar -> important
* xboxdrv
* librapidxml-dev 1.13-1
* libncurses5-dev
* libsdl2-ttf-dev
GitLab's avatar
GitLab committed
32

Philippe Gaussier's avatar
Philippe Gaussier committed
33
34
 ```
 git clone https://git.cyu.fr/blaar/blc.git
35
36
 cd blc
 mkdir blc_build && cd blc_build  && cmake ..
Philippe Gaussier's avatar
Philippe Gaussier committed
37
38
39
 make
 sudo make install
 ```
Philippe Gaussier's avatar
Philippe Gaussier committed
40

Philippe Gaussier's avatar
Philippe Gaussier committed
41
42
43
44
45
46
47
48
49
50
### Organisation ###
The project is organized in different specific folders : 
* bin : application exe folder
* build: cmake folder 
* data : explicit
* include : all header of the application
* lib : all lib use in the project like Mavlink v2.0
* log : classic
* src : all the source file of the project
* test : unit test use by the system
GitLab's avatar
GitLab committed
51

Philippe Gaussier's avatar
Philippe Gaussier committed
52
## How to ? ##
GitLab's avatar
GitLab committed
53

Philippe Gaussier's avatar
Philippe Gaussier committed
54
#  see blc_channels
GitLab's avatar
GitLab committed
55

Philippe Gaussier's avatar
Philippe Gaussier committed
56
57
58
cd $HOME/blaar
./run.sh gnuplot/o_gnuplot /pixhawk.control.arm
./run.sh gnuplot/o_gnuplot /pixhawk.control.motors -m-1000 -M1000
GitLab's avatar
GitLab committed
59

Philippe Gaussier's avatar
Philippe Gaussier committed
60
### Resolve serial port problem ?
GitLab's avatar
GitLab committed
61

Philippe Gaussier's avatar
Philippe Gaussier committed
62
http://tvaira.free.fr/bts-sn/activites/preparation-ccf-e52/activite-port-serie-usb.html
GitLab's avatar
GitLab committed
63

Philippe Gaussier's avatar
Philippe Gaussier committed
64
### Compilate the project ###
GitLab's avatar
GitLab committed
65
66


Philippe Gaussier's avatar
Philippe Gaussier committed
67
68
69
70
71
72
73
Don't lose your time with greedy IDE :P. Use Cmake in the build folder.
 
 ```
 mkdir build
 cd build
 cmake ..
 make
GitLab's avatar
GitLab committed
74

Philippe Gaussier's avatar
Philippe Gaussier committed
75
76
77
78
79
80
 ```
 
 ### Execute tests ###
 
No unitary test support was made but the system was prepared. It's only a simple option on cmake.

Philippe Gaussier's avatar
Philippe Gaussier committed
81
82
83
84
85
86
87
88
89
90
91
92
93
 ### Use ###

To launch promethe with a script to control the drone via joystick and check feedback signals.
 ```
 promethe droneRemote.script droneRemote.res droneRemote.config
 ```

 launch in another window testDrone (source code in test):

  ```
 testDrone /dev/ttyUSB0
 ```

Philippe Gaussier's avatar
Philippe Gaussier committed
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
## Other ##
Some links are interresting to consult to contributre to this program.

* https://www.google.com/search?client=ubuntu&channel=fs&q=mavlink+mode+guided&ie=utf-8&oe=utf-8
* https://gitter.im/dronekit/dronekit-python/archives/2017/06/04
* ardupilot.org/copter/docs/common-mavlink-mission-command-messages-mav_cmd.html -> tone
* https://dev.px4.io/en/qgc/video_streaming.html 
* https://dev.px4.io/en/advanced/parameter_reference.html -> pixhawk flight stack
* https://msgpack.org/ -> format
* https://capnproto.org/ -> format
* https://docs.qgroundcontrol.com/en/SetupView/Joystick.html JOYSTICK

### Wiki ###


### Author ###
Sylvain Colomer into the Laboratory Etis, University of Cergy-Pontoise
Don't hesitate to contact me trough gitLab !
GitLab's avatar
GitLab committed
112