Dronekit setup, simulation and visualization on Mission Planner

preview_player
Показать описание
Setup a Virtual Machine (VM) and set the internet connection as "Bridged". Open a terminal and install dronekit, dronekit-sitl and mavproxy using pip

********************************
NOTE: THIS SETUP IS OBSOLETE. IN ORDER TO INSTALL DRONEKIT DOWNLOAD THE REPOSITORY AND INSTALL FROM SOURCE:

dronekit--sitl is obsolete

*******************************

pip install mavproxy
pip install dronekit
pip install dronekit-sitl

Start the simulator with
dronekit-sitl copter

Share the connection with the localhost and external UDP (as your phone for example)

On windows, open Mission Planner (or in your phone open Tower) and connect the UDP port 14550

In Linux, write your script and connect the vehicle to "udp:127.0.0.1:14550"

Enjoy

*** SHOP NOW at my store and help sustaining the channel:

Рекомендации по теме
Комментарии
Автор

Bro, I got an error while executing this code
Showing error: autopilot:ARMING MOTORS

antonypaul
Автор

In 8 minutes from install to functional. THANK YOU for this amazing tutorial that gets to the point very quickly.

asnaeb
Автор

well i cant believe why this amazing channel has soo less subs and views do all youtube users just watch shit instead learning something

prabhakargupta
Автор

"mavproxy.py --master tcp:127.0.0.1:5760 --out udp:127.0.0.1:14551 --out udp:(ip address):14550" when i write this command in cmd (windows), open mavproxy.py in my ide and then not execute. pls help ? how i execute this command

faikvural
Автор

If you're getting an error in Mission Planner that says "Only one usage of each socket address is normally permitted" it's either due to your Virtual Box not having a bridged connection or in my case Windows private network firewall was blocking the connection from guest (VM) to host, hope this helps someone!

SuperKing
Автор

Gracias Tiziano! I will follow your straightforward and easy-to-understand video! One quick question, have you tried MAVSDK, and if so, what do you think about it?

sanperez
Автор

OMG thank im so glad I found this it was so straitforward and to the point you saved my life THANKS

brockm
Автор

Thank you for your work! Please make an up-to-date step-by-step video with Dronekit setup,
simulation and visualization on Mission Planner for ubuntu 20.04.
I am particularly interested in which packages need to be installed and configured.
With best wishes.

tarasdvoretskij
Автор

Hey Tiziano Fiorenzani!
 I'm unable to open it, I'm getting the below mentioned in my terminal.
 Thank you!

# mavproxy.py --master tcp:127.0.0.1:5760 --out udp:127.0.0.1:14551 --out udp:10.55.222.120:14550
WARNING: You should uninstall ModemManager as it conflicts with APM and Pixhawk
Connect tcp:127.0.0.1:5760 source_system=255
Log Directory:
Telemetry log: mav.tlog
MAV> Waiting for heartbeat from tcp:127.0.0.1:5760
Exception in thread main_loop:
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
self.run()
File "/usr/lib/python2.7/threading.py", line 754, in run
self.__target(*self.__args, **self.__kwargs)
File "/usr/local/bin/mavproxy.py", line 811, in main_loop

TypeError: wait_heartbeat() got an unexpected keyword argument 'timeout'

MAV>

abhinavreddyk
Автор

Hi Tiziano! Thank you I followed the procedure and when i run the script of control with arrow keys i end up with this error "ERROR:autopilot:DISARMING MOTORS"

malakzitouni
Автор

Also at first Ubuntu 16.04 was saying dronekit-sitl command was not recognized but I ended up rebooting my VM and it worked all of a sudden

SuperKing
Автор

Insightful, But I think, You need to specify groundspeed in the simple_goto function to move the drone

pasinduranasinghe
Автор

brother all is work but "vehicle.mode= VehicleMode()""
-mode not work return same mode! what cai I do??

ais_robotic
Автор

Hi, Mr. Tiziano! I am pretty into your videos. Currently I always have a question like:" Arming motors..." again over again. Never stop. I believe it is because the vehicle is not armable yet. so my question is how to exactly make the vehicle armable? I am using Dronekit-python, Intel onboard, and Pixhawk4 (Ardupilot). Looking forward your response!

guohaoye
Автор

I am having a problem where my drone won't take off. Basically, I get an error like this
APM: ARMING MOTORS
APM: Initialising APM...
ARMED
Arming checks disabled
APM: DISARMING MOTORS
DISARMED
The simulated drone tries to take off but can't go over 0.1. Mr.
Tiziano Fiorenzani, do you know what might be the problem?

visionpoudel
Автор

when i run the code the simulation and the program is not running simultaneously. The python program is running but its not showing in mission planner until the program is finished running. Please help me out. i have a deadline

chaitanya
Автор

Hi Tiziano, i able to use your script on a real drone using --connect 0.0.0.0:14550. If i want to connect to another real drone... can i issue another --connect 0.0.0.0:14560?

Thanks in advance

scratchsatriani
Автор

Sir are you connect hardware when you are Programming drone or doing simulation

electronicseverywhere
Автор

Thank you sir for your content.
Sir I need a help.
Sir I'm very confused and stuck in the software solution, that is I cannot able to figure out which softwares you're using in this video and how can I use the same softwares in Windows 10.

Please give me a software solution for Windows 10, i.e. for this codings which softwares I can use in Windows 10.

grabitgo
Автор

hi tiziano,
i need ur help..
when i enter this command "dronekit-sitl copter --home=35.9835973, -95.8742309, 0, 180"
i get an error like this
os: linux, apm: copter, release: stable
SITL already Downloaded and Extracted.
Ready to boot.
Traceback (most recent call last):
File "/usr/local/bin/dronekit-sitl", line 11, in <module>
sys.exit(main())
File "/home/pi/.local/lib/python2.7/site-packages/dronekit_sitl/__init__.py", line 591, in main
sitl.launch(args, verbose=True)
File "/home/pi/.local/lib/python2.7/site-packages/dronekit_sitl/__init__.py", line 251, in launch
caps =
File "/home/pi/.local/lib/python2.7/site-packages/dronekit_sitl/__init__.py", line 160, in __init__
process = subprocess.Popen([path, '--help'], stdout=subprocess.PIPE)
File "/usr/lib/python2.7/subprocess.py", line 390, in __init__
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1024, in _execute_child
raise child_exception
OSError: [Errno 8] Exec format error"

I'm using at putty in windows and i have been searching on internet... i don't get an answer. Maybe u can help me..
thanks.

nb: sry for bad english, i'm student from indonesia.

fendadwiariefianto