Skip to content

Commit 8436873

Browse files
committed
Major documentation update, the new drone version files released
1 parent 0397b3a commit 8436873

19 files changed

+439
-38
lines changed

README.md

Lines changed: 108 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,17 @@
1-
# flix
1+
# Flix
22

3-
**flix** (*flight + X*) — making an open source ESP32-based quadcopter from scratch.
3+
**Flix** (*flight + X*) — making an open source ESP32-based quadcopter from scratch.
44

5-
<img src="docs/img/flix.jpg" width=500 alt="Flix quadcopter">
5+
<table>
6+
<tr>
7+
<td align=center><strong>Version 1</strong> (3D-printed frame)</td>
8+
<td align=center><strong>Version 0</strong></td>
9+
</tr>
10+
<tr>
11+
<td><img src="docs/img/flix1.jpg" width=500 alt="Flix quadcopter"></td>
12+
<td><img src="docs/img/flix.jpg" width=500 alt="Flix quadcopter"></td>
13+
</tr>
14+
</table>
615

716
## Features
817

@@ -15,55 +24,123 @@
1524
* MAVLink support.
1625
* Control using mobile phone (with QGroundControl app).
1726
* ESCs with reverse mode support.
18-
* *Textbook and videos for students on writing a flight controller\*.*
19-
* *Completely 3D-printed frame*.*
20-
* *Position control and autonomous flights using external camera\**.
27+
* Completely 3D-printed frame.
28+
* *Textbook and videos for students on writing a flight controller¹.*
29+
* *Position control and autonomous flights using external camera¹*.
2130
* [Building and running instructions](docs/build.md).
2231

23-
*\* — planned.*
32+
*¹ — planned.*
2433

2534
## It actually flies
2635

36+
See detailed demo video (for version 0): https://youtu.be/8GzzIQ3C6DQ.
37+
2738
<a href="https://youtu.be/8GzzIQ3C6DQ"><img width=500 src="https://i3.ytimg.com/vi/8GzzIQ3C6DQ/maxresdefault.jpg"></a>
2839

29-
See YouTube demo video: https://youtu.be/8GzzIQ3C6DQ.
40+
Version 1 test flight: https://t.me/opensourcequadcopter/42.
41+
42+
<a href="https://t.me/opensourcequadcopter/42"><img width=500 src="docs/img/flight-video.jpg"></a>
3043

3144
## Simulation
3245

33-
Simulation in Gazebo using a plugin that runs original Arduino code is implemented:
46+
The simulator is implemented using Gazebo and runs the original Arduino code:
3447

3548
<img src="docs/img/simulator.png" width=500 alt="Flix simulator">
3649

37-
## Schematics
50+
See [instructions on running the simulation](docs/build.md).
51+
52+
## Components (version 1)
53+
54+
|Type|Part|Image|Quantity|
55+
|-|-|:-:|:-:|
56+
|Microcontroller board|ESP32 Mini|<img src="docs/img/esp32.jpg" width=100>|1|
57+
|IMU and barometer² board|GY-91 (or other MPU-9250 board)|<img src="docs/img/gy-91.jpg" width=100>|1|
58+
|Motor|8520 3.7V brushed motor (**shaft 0.8mm!**)|<img src="docs/img/motor.jpeg" width=100>|4|
59+
|Propeller|Hubsan 55 mm|<img src="docs/img/prop.jpg" width=100>|4|
60+
|MOSFET (transistor)|100N03A or [compatible](https://t.me/opensourcequadcopter/33)|<img src="docs/img/100n03a.jpg" width=100>|4|
61+
|Pull-down resistor|10 kΩ|<img src="docs/img/resistor10k.jpg" width=100>|4|
62+
|3.7V Li-Po battery|LW 952540 (or any compatible by the size)|<img src="docs/img/battery.jpg" width=100>|1|
63+
|Li-Po Battery charger|Any|<img src="docs/img/charger.jpg" width=100>|1|
64+
|Screws for IMU board mounting|M3x5|<img src="docs/img/screw-m3.jpg" width=100>|2|
65+
|Screws for frame assembly|M1.4x5|<img src="docs/img/screw-m1.4.jpg" height=30 align=center>|4|
66+
|Frame bottom part|3D printed: [`flix-frame.stl`](docs/assets/flix-frame.stl)|<img src="docs/img/frame1.jpg" width=100>|1|
67+
|Frame top part|3D printed: [`esp32-holder.stl`](docs/assets/esp32-holder.stl)|<img src="docs/img/esp32-holder.jpg" width=100>|1|
68+
|Washer for IMU board mounting|3D printed: [`washer-m3.stl`](docs/assets/washer-m3.stl)|<img src="docs/img/washer-m3.jpg" width=100>|1|
69+
|*RC transmitter (optional)*|*KINGKONG TINY X8 or other³*|<img src="docs/img/tx.jpg" width=100>|1|
70+
|*RC receiver (optional)*|*DF500 or other³*|<img src="docs/img/rx.jpg" width=100>|1|
71+
|Wires|28 AWG recommended|<img src="docs/img/wire-28awg.jpg" width=100>||
72+
|Tape, double-sided tape||||
73+
74+
*² — barometer is not used for now.*
75+
76+
*³ — you may use any transmitter-receiver pair with SBUS interface.*
77+
78+
Tools required for assembly:
79+
80+
* 3D printer.
81+
* Soldering iron.
82+
* Solder wire (with flux).
83+
* Screwdrivers.
84+
* Multimeter.
85+
86+
Feel free to modify the design and or code, and create your own improved versions of Flix! Send your results to the [official Telegram chat](https://t.me/opensourcequadcopterchat), or directly to the author ([E-mail](mailto:[email protected]), [Telegram](https://t.me/okalachev)).
87+
88+
## Schematics (version 1)
89+
90+
### Simplified connection diagram
3891

39-
<img src="docs/img/schematics.svg" width=800 alt="Flix schematics">
92+
<img src="docs/img/schematics1.svg" width=800 alt="Flix version 1 schematics">
4093

41-
You can also check a user contributed [variant of complete circuit diagram](https://miro.com/app/board/uXjVN-dTjoo=/) of the drone.
94+
Motor connection scheme:
4295

43-
*\* — SBUS inverter is not needed as ESP32 supports [software pin inversion](https://github.com/bolderflight/sbus#inverted-serial).*
96+
<img src="docs/img/mosfet-connection.png" height=400 alt="MOSFET connection scheme">
4497

45-
## Components (version 0)
98+
Complete diagram is Work-in-Progress.
4699

47-
|Component|Type|Image|Quantity|
48-
|-|-|-|-|
49-
|ESP32 Mini|Microcontroller board|<img src="docs/img/esp32.jpg" width=100>|1|
50-
|GY-91|IMU+LDO+barometer board|<img src="docs/img/gy-91.jpg" width=100>|1|
51-
|K100|Quadcopter frame|<img src="docs/img/frame.jpg" width=100>|1|
52-
|8520 3.7V brushed motor (**shaft 0.8mm!**)|Motor|<img src="docs/img/motor.jpeg" width=100>|4|
53-
|Hubsan 55 mm| Propeller|<img src="docs/img/prop.jpg" width=100>|4|
54-
|2.7A 1S Dual Way Micro Brush ESC|Motor ESC|<img src="docs/img/esc.jpg" width=100>|4|
55-
|KINGKONG TINY X8|RC transmitter|<img src="docs/img/tx.jpg" width=100>|1|
56-
|DF500 (SBUS)|RC receiver|<img src="docs/img/rx.jpg" width=100>|1|
57-
||~~SBUS inverter~~*|<img src="docs/img/inv.jpg" width=100>|~~1~~|
58-
|3.7 Li-Po 850 MaH 60C|Battery|||
59-
||Battery charger|<img src="docs/img/charger.jpg" width=100>|1|
60-
||Wires, connectors, tape, ...|||
61-
||3D-printed frame parts|||
100+
### Notes
62101

63-
*\* — not needed as ESP32 supports [software pin inversion](https://github.com/bolderflight/sbus#inverted-serial).*
102+
* Power ESP32 Mini with Li-Po battery using VCC (+) and GND (-) pins.
103+
* Connect the GY-91 board to the ESP32 Mini using VSPI , power it using 3.3V and GND pins:
104+
105+
|GY-91 pin|ESP32 pin|
106+
|-|-|
107+
|GND|GND|
108+
|3.3V|3.3V|
109+
|SCK|SVP (GPIO18)|
110+
|MOSI|GPIO23|
111+
|MISO|GPIO19|
112+
|NCS|GPIO5|
113+
114+
* Solder pull-down resistors to the MOSFETs.
115+
* Connect the motors to the ESP32 Mini using MOSFETs, by following scheme:
116+
117+
|Motor|Position|Direction|Wires|GPIO|
118+
|-|-|-|-|-|
119+
|Motor 0|Rear left|Counter-clockwise|Black & White|GPIO12|
120+
|Motor 1|Rear right|Clockwise|Blue & Red|GPIO13|
121+
|Motor 2|Front right|Counter-clockwise|Black & White|GPIO14|
122+
|Motor 3|Front left|Clockwise|Blue & Red|GPIO15|
123+
124+
Counter-clockwise motors have black and white wires and clockwise motors have blue and red wires.
125+
126+
* Optionally connect the RC receiver to the ESP32's UART2:
127+
128+
|Receiver pin|ESP32 pin|
129+
|-|-|
130+
|GND|GND|
131+
|VIN|VC (or 3.3V depending on the receiver)|
132+
|Signal|GPIO4 ⁴|
133+
134+
*⁴ – UART2 RX pin was [changed](https://docs.espressif.com/projects/arduino-esp32/en/latest/migration_guides/2.x_to_3.0.html#id14) to GPIO4 in Arduino ESP32 core 3.0.*
135+
136+
## Version 0
137+
138+
See the information on the obsolete version 0 in the [corresponding article](docs/version0.md).
64139

65140
## Materials
66141

67-
Subscribe to Telegram-channel on developing the drone and the flight controller (in Russian): https://t.me/opensourcequadcopter.
142+
Subscribe to the Telegram channel on developing the drone and the flight controller (in Russian): https://t.me/opensourcequadcopter.
143+
144+
Join the official Telegram chat: https://t.me/opensourcequadcopterchat.
68145

69146
Detailed article on Habr.com about the development of the drone (in Russian): https://habr.com/ru/articles/814127/.

docs/assets/esp32-holder.stl

123 KB
Binary file not shown.

docs/assets/flix-frame.stl

510 KB
Binary file not shown.

docs/assets/washer-m3.stl

78.8 KB
Binary file not shown.

docs/build.md

Lines changed: 45 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,26 @@ cd flix
7878
make simulator
7979
```
8080

81-
### Flight
81+
### Setup and flight
8282

83-
Use USB remote control or [QGroundControl mobile app](https://docs.qgroundcontrol.com/master/en/qgc-user-guide/getting_started/download_and_install.html#android) (with *Virtual Joystick* setting enabled) to control the drone. *Auto-Center Throttle* setting **should be disabled**.
83+
#### Control with smartphone
84+
85+
1. Install [QGroundControl mobile app](https://docs.qgroundcontrol.com/master/en/qgc-user-guide/getting_started/download_and_install.html#android) on your smartphone.
86+
2. Connect your smartphone to the same Wi-Fi network as the machine running the simulator.
87+
3. If you're using a virtual machine, make sure that its network is set to the **bridged** mode with Wi-Fi adapter selected.
88+
4. Run the simulation.
89+
5. Open QGroundControl app. It should connect and begin showing the virtual drone's telemetry automatically.
90+
6. Go to the settings and enable *Virtual Joystick*. *Auto-Center Throttle* setting **should be disabled**.
91+
7. Use the virtual joystick to fly the drone!
92+
93+
#### Control with USB remote control
94+
95+
1. Connect your USB remote control to the machine running the simulator.
96+
2. Run the simulation.
97+
3. Calibrate the RC using `cr` command in the command line interface and stop the simulation.
98+
4. Copy the calibration results to the source code (`gazebo/joystick.h`).
99+
5. Run the simulation again.
100+
6. Use the USB remote control to fly the drone!
84101

85102
## Firmware
86103

@@ -119,12 +136,33 @@ Use USB remote control or [QGroundControl mobile app](https://docs.qgroundcontro
119136

120137
See other available Make commands in the [Makefile](../Makefile).
121138

122-
### Firmware code structure
139+
### Setup and flight
123140

124-
See [firmware overview](firmware.md) for more details.
141+
Before flight you need to calibrate the accelerometer:
142+
143+
1. Open Serial Monitor in Arduino IDE (use use `make monitor` command in the command line).
144+
2. Type `ca` command there.
145+
3. Copy calibration results to the source code (`flix/imu.ino`).
146+
147+
#### Control with smartphone
125148

126-
## Setup
149+
1. Install [QGroundControl mobile app](https://docs.qgroundcontrol.com/master/en/qgc-user-guide/getting_started/download_and_install.html#android) on your smartphone.
150+
2. Power the drone using the battery.
151+
3. Connect your smartphone to the appeared `flix` Wi-Fi network.
152+
4. Open QGroundControl app. It should connect and begin showing the drone's telemetry automatically.
153+
5. Go to the settings and enable *Virtual Joystick*. *Auto-Center Throttle* setting **should be disabled**.
154+
6. Use the virtual joystick to fly the drone!
127155

128-
Before flight in simulation and on the real drone, you need to calibrate your remote control. Use drone's command line interface (`make monitor` on the real drone) and type `cr` command. Copy calibration results to the source code (`flix/rc.ino` and/or `gazebo/joystick.h`).
156+
#### Control with remote control
129157

130-
On the real drone, you also need to calibrate the accelerometer and the gyroscope. Use `ca` and `cg` commands for that. Copy calibration results to the source code (`flix/imu.ino`).
158+
Before flight using remote control, you need to calibrate it:
159+
160+
1. Open Serial Monitor in Arduino IDE (use use `make monitor` command in the command line).
161+
2. Type `cr` command there.
162+
3. Copy calibration results to the source code (`flix/rc.ino`).
163+
164+
Then you can use your remote control to fly the drone!
165+
166+
### Firmware code structure
167+
168+
See [firmware overview](firmware.md) for more details.

docs/img/100n03a.jpg

26.7 KB
Loading

docs/img/battery.jpg

31.8 KB
Loading

docs/img/esp32-holder.jpg

9.3 KB
Loading

docs/img/flight-video.jpg

79.2 KB
Loading

docs/img/flix1.jpg

88.8 KB
Loading

docs/img/frame1.jpg

10.9 KB
Loading

docs/img/mosfet-connection.png

38 KB
Loading

docs/img/resistor10k.jpg

12.3 KB
Loading

0 commit comments

Comments
 (0)