Hi - unsure if you have continued with this since posted last year
This is the command file - cmnd-01 - from the One-Off Coder tutorial on Swarm Programming
I haven't had a connection yet so am analysing the code
It seems to handle the commands listed in the SDK V2.0 plus the following
9.3. Commands
Command
&
Description | Method | Result |
'//'
comment | _handle_comment
(command) | Print
[COMMENT] (command) |
'scan' | _handle_scan
(command) | |
'>'
gte | _handle_gte
(command) | |
'battery_check' | _handle_battery_check
(command) | |
'delay' | _handle_delay
(command) | |
'correct_ip' | _handle_correct_ip
(command) | |
'=' | _handle_equal
(command) | |
'sync' | _handle_sync
(command) | |
I'm currently testing to connect at least one
Tello EDU
Results so far... (running on WIndows 10)
Command
python planned-flight.py -f cmds-01.txt
Debug prints
>>>>>>
fpath: cmds-01.txt
Commands: ['scan 1\n', 'battery_check 20\n', 'correct_ip\n', '1=0TQZJA9ED01UZY\n', '1>takeoff\n', 'sync 1\n', '1>land']
Swarm commands: ['scan 1\n', 'battery_check 20\n', 'correct_ip\n', '1=0TQZJA9ED01UZY\n', '1>takeoff\n', 'sync 1\n', '1>land']
cmds-01.txt
Swarm Manager <
tello.TelloManager object at 0x0000014D8DB9CD30>
8889
[]
[]
20.0
{}
{}
[]
[]
{'0TQZJA9ED01UZY': '192.168.3.101', '0TQZJ1EED01AHY': '192.168.3.103'}
{0: '0TQZJA9ED01UZY', 1: '0TQZJ1EED01AHY'}
{'192.168.3.101': 0, '192.168.3.103': 1}
socket: AddressFamily.AF_INET
[DEBUG-find_avaliable_tello] possible_ips: []
>>> Output from code
[SEARCHING], Searching for 1 from 0 possible IP addresses
>>> more debug print
[DEBUG-find_avaliable_tello] self.tello_ip_list: []
>>> Output from code
[SEARCHING], Trying to find Tellos, number of tries = 1
[SEARCHING], Trying to find Tellos, number of tries = 2
[SEARCHING], Trying to find Tellos, number of tries = 3
[SEARCHING], Trying to find Tellos, number of tries = 4
[SEARCHING], Trying to find Tellos, number of tries = 5
[SEARCHING], Trying to find Tellos, number of tries = 6
[SEARCHING], Trying to find Tellos, number of tries = 7
[SEARCHING], Trying to find Tellos, number of tries = 8
[SEARCHING], Trying to find Tellos, number of tries = 9
[SEARCHING], Trying to find Tellos, number of tries = 10
>>> Finally I kill it as it is not finding the
Tello drones [^C]
[QUIT_ALL], KeyboardInterrupt. Sending land to all drones
[LOG] Saved log files to ./log/2022-07-04_16-56-46.txt
SO you did get a connection - although the wrong drone
Did it respond to the command list
ie did it takeoff and then land
regards