mirror of
https://github.com/okalachev/flix.git
synced 2026-01-09 12:36:49 +00:00
Updates to main readme. Add much more info to usage article. Move simulator building to simulation's readme. Improve assembly article. Many fixes. Updates in diagrams.
3.5 KiB
3.5 KiB
Troubleshooting
The sketch doesn't compile
Do the following:
- Check ESP32 core is installed. Check if the version matches the one used in the tutorial.
- Check libraries. Install all the required libraries from the tutorial. Make sure there are no MPU9250 or other peripherals libraries that may conflict with the ones used in the tutorial.
- Check the chosen board. The correct board to choose in Arduino IDE for ESP32 Mini is WEMOS D1 MINI ESP32.
The drone doesn't fly
Do the following:
- Check the battery voltage. Use a multimeter to measure the battery voltage. It should be in range of 3.7-4.2 V.
- Check if there are some startup errors. Connect the ESP32 to the computer and check the Serial Monitor output. Use the Reset button to make sure you see the whole ESP32 output.
- Check the baudrate is correct. If you see garbage characters in the Serial Monitor, make sure the baudrate is set to 115200.
- Make sure correct IMU model is chosen. If using ICM-20948/MPU-6050 board, change
MPU9250toICM20948/MPU6050in theimu.inofile. - Check if the CLI is working. Perform
helpcommand in Serial Monitor. You should see the list of available commands. You can also access the CLI using QGroundControl (Vehicle Setup ⇒ Analyze Tools ⇒ MAVLink Console). - Configure QGroundControl correctly before connecting to the drone if you use it to control the drone. Go to the settings and enable Virtual Joystick. Auto-Center Throttle setting should be disabled.
- If QGroundControl doesn't connect, you might need to disable the firewall and/or VPN on your computer.
- Check the IMU is working. Perform
imucommand and check its output:- The
statusfield should beOK. - The
ratefield should be about 1000 (Hz). - The
accelandgyrofields should change as you move the drone.
- The
- Calibrate the accelerometer. if is wasn't done before. Type
cacommand in Serial Monitor and follow the instructions. - Check the attitude estimation. Connect to the drone using QGroundControl. Rotate the drone in different orientations and check if the attitude estimation shown in QGroundControl is correct.
- Check the IMU orientation is set correctly. If the attitude estimation is rotated, make sure
rotateIMUfunction is defined correctly inimu.inofile. - Check the motors type. Motors with exact 3.7V voltage are needed, not ranged working voltage (3.7V — 6V).
- Check the motors. Perform the following commands using Serial Monitor:
mfr— should rotate front right motor (counter-clockwise).mfl— should rotate front left motor (clockwise).mrl— should rotate rear left motor (counter-clockwise).mrr— should rotate rear right motor (clockwise).
- Check the propeller directions are correct. Make sure your propeller types (A or B) are installed as on the picture:

- Check the remote control. Using
rccommand, check the control values reflect your sticks movement. All the controls should change between -1 and 1, and throttle between 0 and 1. - If using SBUS receiver, calibrate the RC. Type
crcommand in Serial Monitor and follow the instructions. - Check the IMU output using QGroundControl. Connect to the drone using QGroundControl on your computer. Go to the Analyze tab, MAVLINK Inspector. Plot the data from the
SCALED_IMUmessage. The gyroscope and accelerometer data should change according to the drone movement.