I'm new into this and i want to control 2 Tello EDUs in swarm. I tried couple of things that worked for one not in swarm but crashed in swarm (i think I did something in bad way) and I can't figure out Video Stream in swarm. I would be thankful for help with it.
I am using DJITelloPy library from GitHub. Controlling for one drone I did from this YouTube tutorial. I also tried control in example of DJITelloPy but also doesn't work.
from djitellopy import TelloSwarm
import cv2
swarm = TelloSwarm.fromIps([
"10.0.0.125",
"10.0.0.126"
])
swarm.connect()
for tello in swarm:
print(tello.get_battery())
swarm.streamon()
while True:
img = {}
for tello in swarm:
img[i] = tello.get_frame_read().frame
for i in img:
img[i] = cv2.resize(img[i], (360, 240))
cv2.imshow("Image", img[i])
cv2.waitKey(1)
This should just connect to them on the network (by their IPs) and run Image capture. I don't think it is the right way. Can someone help me? I'm running out of ideas.