Flight Computer Code
Welcome to the FawnRescue Drone project! This repository houses the codebase for a drone designed to execute specialized missions autonomously with a focus on wildlife rescue operations. Our software is developed in Kotlin for the drone's primary operations and Python for the camera server, ensuring a robust system capable of navigating and performing tasks with high efficiency and reliability.
-
Clone the Repository
git clone https://github.com/FawnRescue/drone.git -
Set Up Secrets
Create a
secrets.propertiesfile in the root directory based on the template provided insecrets.properties.example.
Before diving into the drone's operation, ensure your development environment is ready:
-
Development Toolchain: Follow the PX4 Development Guide to set up your development environment.
-
MAVSDK Server: Download and set executable permissions:
wget https://github.com/mavlink/MAVSDK/releases/download/v2.4.1/mavsdk_server_musl_x86_64 chmod +x mavsdk_server_musl_x86_64 ./mavsdk_server_musl_x86_64
To simulate the drone's flight:
-
Open a new console and navigate to the PX4-Autopilot directory:
cd PX4-Autopilot make px4_sitl gz_x500 -
Run the code in this repository.
(Instructions to be added)
- Install OpenCV:
apt install python-opencv - Install SeekCamera Drivers: (Link to installation guide)
-
Install MAVLink Router: Visit MAVLink Router for installation instructions.
-
Adjust Executable Paths in service files.
-
Deploy Services: Copy and enable custom services:
cp services/* /etc/systemd/system systemctl enable <service-name>
-
Restart the Drone to apply changes.
Authentication with our app is handled via a dedicated Bluetooth repository. This is crucial for ensuring that the drone is operated securely and only by authorized users.
The core of our project, the Flight Computer Software, manages a wide array of tasks from command execution, telemetry data processing, to handling connectivity issues. It is built with resilience and security in mind.
- Authentication Workflow: Initiates with a BLE server for secure app communication, involving OTP exchange for backend verification.
- Flight Controller Handler: Integrates with MAVSDK Java for flight control and telemetry monitoring.
- Supabase Handler: Manages data exchange with Supabase for real-time telemetry and command processing.
- Reconnection Workflow: Ensures the drone remains operational through dynamic connectivity conditions by actively monitoring and attempting reconnections.
