This is a simple simulation of a Tello drone using Ursina. The drone can be controlled via tcp calls.
In the repo there is the simulation server along with a client class that can be used to interact with the sim server
The easiest way to get started is using the provided dev container which includes all dependencies and GUI support:
-
Setup the dev container for your platform:
.devcontainer/setup.sh
This will auto-detect your platform (macOS, Linux, Windows, WSL) and generate the appropriate
devcontainer.json. -
Open in VS Code:
- Install the "Dev Containers" extension
- Open Command Palette (Cmd/Ctrl + Shift + P)
- Run "Dev Containers: Reopen in Container"
-
Platform-specific requirements:
- macOS: Install XQuartz (
brew install --cask xquartz) and runxhost +localhost - Linux: X11 forwarding should work out of the box
- Windows: Access GUI via VNC at
http://localhost:5901(password:vncpass)
- macOS: Install XQuartz (
If you prefer to set up the environment manually:
-
Create the virtual environment by running:
python3.12 -m venv venv
-
Activate the virtual environment by running:
source venv/bin/activate -
Install the required packages by running:
pip install --trusted-host pypi.org --trusted-host files.pythonhosted.org -r requirements.txt
-
Export the python path by running:
export PYTHONPATH=$PWD
To run the simulation, run the following command:
python tello_sim/run_sim.pyYou can try running some of the examples to see how the simulation works. The examples are located in the examples folder.
Or use the client class to interact with the simulation server. The client class is located in the tello_sim folder.
-
For a specific python version on macOS, consider using pyenv to manage multiple python versions.
-
Another alternative for macOS users is to use Homebrew to install the desired python version:
brew install python@3.12
-
Conda users can create an environment with the desired python version:
conda create -n tello-sim python=3.12 conda activate tello-sim pip install --trusted-host pypi.org --trusted-host files.pythonhosted.org -r requirements.txt export PYTHONPATH=$PWD
