Oleg Kalachev
5bf2e06c5a
Use natural order of ino files includes in simulation
...
In Arduino, ino files are included in alphabetical order.
Cleanup unused function declarations in simulation, add missing.
Rename flu to frd function to match the code style.
2025-02-28 19:06:58 +03:00
Oleg Kalachev
d60628e14d
Support MAVLink console
...
Implement receiving and sending SERIAL_CONTROL message
Use global defined print function instead of Serial.printf
2025-02-18 10:33:01 +03:00
Oleg Kalachev
149c62568f
Refactor CLI submodule
...
Move command parsing to doCommand
Parse command with splitString instead of stringToken
Trim commands
Move cliTestMotor to the bottom
Rename parseInput to handleInput, which is more clear
Move motor test function to motors.ino
2025-02-17 15:51:58 +03:00
Oleg Kalachev
641e711e67
Minor fix in joystick support for simulation
...
Don't use channels variable as it breaks code isolation
2025-02-15 03:29:09 +03:00
Oleg Kalachev
15fbe34d19
Add failsafe to prevent arming without prior zero throttle
2025-01-24 16:23:59 +03:00
Zatupitel
7d2d54a94d
Fix working on ESP32-S3 ( #8 )
...
Disable brown-out detector in a more correct way: clear only enable bit instead of clearing the whole register.
---------
Co-authored-by: Oleg Kalachev <okalachev@gmail.com>
2025-01-24 14:35:44 +03:00
Oleg Kalachev
6028b8a617
Catch port bind error in simulation
2025-01-17 17:38:47 +03:00
Oleg Kalachev
70f5186c1b
Use double for storing time instead of float
...
Float precision may be not enough after some time of operating
2025-01-12 19:58:36 +03:00
Oleg Kalachev
ac54c954aa
Cleanup
2025-01-11 04:31:53 +03:00
Oleg Kalachev
9e4a2c5ffc
Move controlsTime variable to rc.ino
2025-01-11 00:28:31 +03:00
Oleg Kalachev
821e6b105e
Make channels definition to rc.ino
...
It's also planned to parametrize them later
2025-01-10 09:37:48 +03:00
Oleg Kalachev
698cc3d9b8
Global variables cleanups
...
Remove unused PID objects for cli
Move loopRate to time.ino
2025-01-10 07:10:30 +03:00
Oleg Kalachev
85172cdcc8
Make util module header instead of .ino-file
2025-01-10 06:51:14 +03:00
Oleg Kalachev
c8109af04f
Make ONE_G definition const and move to utils.ino
2025-01-09 11:24:40 +03:00
Oleg Kalachev
404ceed851
Make motor indexes definition const int and move them to motors.ino
...
Remove motor indexes definitions from flix.ino
Add motors.ino to simulation code and implement required mocks
2025-01-09 11:14:18 +03:00
Oleg Kalachev
43be27c43d
Fix joystick work in simulation
...
Logic was broken as joystickGet never got called
2024-12-27 15:34:33 +03:00
Oleg Kalachev
8d7a4595f5
Rename flushParameters to more clear syncParameters
2024-12-26 01:14:26 +03:00
Oleg Kalachev
2efae82177
Minor fixes
2024-12-25 01:41:45 +03:00
Oleg Kalachev
ae349fb73c
Implement parameters subsystem
...
* Unified parameters storage.
* Store parameters in flash on the hardware.
* Store parameters in text file in simulation.
* Work with parameters in command line.
* Support parameters in MAVLink for working with parameters in QGC.
2024-12-23 13:00:02 +03:00
Oleg Kalachev
28f6cfff60
Fix SBUS simulation logic
...
Don't consider zero values from not connected joystick
2024-12-23 04:04:00 +03:00
Oleg Kalachev
7533a9cbfa
Move ONE_G definition to flix.ino
2024-12-23 02:37:03 +03:00
Oleg Kalachev
3cc3014ca0
Improve logic of passing channels data in simulated SBUS
...
Return the data the same way as on the real drone without touching channels global vairable
2024-12-23 02:04:22 +03:00
Oleg Kalachev
f54da5bf42
Add CLI command for rebooting the drone
2024-12-20 20:59:59 +03:00
Oleg Kalachev
ea141f851f
Use 'loop rate' term instead of misleading 'loop frequency'
2024-12-04 07:00:00 +03:00
Oleg Kalachev
b015c15a7e
Remove non-working fullmot command
2024-11-24 00:10:37 +03:00
Oleg Kalachev
ec832d4e37
Implement RC fail-safe
2024-11-04 11:51:17 +03:00
Oleg Kalachev
2fdad7bdb6
Remove LED horizontality signalization
...
It's better to control the attitude estimation using QGC
2024-11-03 17:41:13 +03:00
Oleg Kalachev
c5c889679b
Fix simulation build
2024-10-31 19:27:27 +03:00
Oleg Kalachev
378db51de9
Get rid of simulator build warnings
2024-10-24 03:50:03 +03:00
Oleg Kalachev
ba5ac30136
Adjust the default camera position in the simulator
2024-10-24 03:48:31 +03:00
Oleg Kalachev
13341602f0
Fix Gazebo stl model orientation
2024-10-23 14:30:25 +03:00
Oleg Kalachev
0397b3a736
Move the visual part of the gazebo model to the bottom of the file
2024-10-23 09:42:17 +03:00
Oleg Kalachev
c41c96a96d
Update visual of the Gazebo model to the new version
...
Use STL instead of DAE, make props separated visuals
2024-10-23 09:41:16 +03:00
Oleg Kalachev
a94687bd56
Keep the t variable monotonic in the simulation
...
Otherwise it causes stopping sending MAVLink and other bugs
2024-10-23 09:36:54 +03:00
Oleg Kalachev
abcc9b96de
Use FLU as the main coordinate system instead of FRD
...
Corresponding to the IMU orientation in the new version
2024-10-23 09:30:49 +03:00
Oleg Kalachev
f46460e53d
Make RC_CHANNELS=16 corresponding the number of SBUS channels
2024-10-23 09:28:09 +03:00
Oleg Kalachev
23f3295439
Remove ESC support and add MOSFET support in motors code
...
The new version uses MOSFETs
2024-10-23 09:27:54 +03:00
Oleg Kalachev
b0b6eb9a97
Minor code cleanups and clarifications
2024-10-23 09:25:39 +03:00
Oleg Kalachev
e993dde355
Update ESP32 Arduino Core to v3.0.3
2024-07-25 02:45:59 +03:00
Oleg Kalachev
627233f862
Minor updates
2024-07-25 02:44:47 +03:00
Oleg Kalachev
1119c77cca
Remove unneeded abs for motors thrust in simulation
2024-05-24 14:47:26 +03:00
Oleg Kalachev
ad6bc02643
Minor fixes and changes
2024-05-21 10:49:57 +03:00
Oleg Kalachev
41a9a95747
Transfer gyro low pass filter to estimate.ino
...
Separate raw gyro data and filtered rates to different variables
2024-04-20 14:52:01 +03:00
Oleg Kalachev
fff7262d1b
Minor fix for SBUS dummy for simulator
2024-03-23 09:20:08 +03:00
Oleg Kalachev
646fa46f6b
Use FlixPeriph library for SBUS
2024-03-17 02:29:37 +03:00
Oleg Kalachev
e0db3bee38
Read mode stick using axis read in simulation
2024-02-16 01:13:32 +03:00
Oleg Kalachev
bf803cf345
Display MAVLink remote port in simulator
2024-02-10 14:12:09 +03:00
Oleg Kalachev
ba6e63b50b
Correctly set output parameters of simulated SBUS::read, minor name fix
2024-02-06 21:02:20 +03:00
Oleg Kalachev
f718af7f0e
Support MAVLink usage in simulation
2024-01-31 12:10:18 +03:00
Oleg Kalachev
4850b95029
Add a readme to gazebo directory
2024-01-31 12:07:37 +03:00