Tello Coding in Drone Blocks

My class is having issues getting DroneBlock code to consistently execute from their chromebook. The program is attached which flies a vertical loop consisting of two semicircles.
One student can run the program successfully only 3 out of 15 times. It’s not the drone, because we took her drone and a student flew it from her chromebook multiple times using the same program and there was no issue. Takeoff is from the floor. We thought the issue could be the 2.4 GHz, so we attached the LED board to the TT, and got the Drone on 5 GHz because that bandwidth is wide open according to our network engineer. The number of times the code was successfully executed did not fundamentally change.

I will try to execute from a smartphone next week. Perhaps that will help.

Let us know what you discover with the mobile version of DroneBlocks, but the commands being sent to the Tello drone should fundamentally be the same. I’ll run your student’s code on my ChromeBook this weekend to see if I can learn anything. Thanks for the info.

It flies correctly in the simulator but not on the smartphone or the Chromebook. How did it fly for you?

Mike, sorry for the delayed reply. I just ran a test in my office. I ran “almost” identical code to yours successfully 5/5 tries. I say almost because I did need to reduce the vertical distance of the loop to make sure I didn’t run into my ceiling. I wonder if you’re up against some lighting or floor reflectivity issues? Have you been able to deduce anything else on your end? I’m sort of stumped here, but let’s pulling on the thread. BTW my test was with Tello Talent and the LED board attached.

Hi Dennis,
Definitely agreed. These issues have stopped my program in its tracks. 1) With the screenshot above, if you selected TT, shouldn’t the menu on the left include both Camera and LED boxes?
My environment does. We are running Droneblocks on a Chromebook( the android version.) 2) Is this your test environment? ( we even placed a hover for 5 seconds after the “fly up” attempting to provide a delay, that did not help) I am running in a room with a tiled floor and overhead LED lighting.
3) How hard would it be to code this program in python?

Sorry about this, Mike. I did not see your block categories and when you mentioned ChromeBook I assumed the Chrome App. I will test the Android DroneBlocks version on my ChromeBook tonight or tomorrow. BTW this is early alpha, but if you are interested in testing I’d love to hear your feedback on Python and the drone simulator:

I’ll follow up with more info when I have it. Thanks for pointing me in the right direction.

Hi Dennis,
Here is our code for flying a sinewave with multiple periods. See how your testing goes with this.

Feel free to modify accordingly. The repeat loop is critical. This code works in the simulator.

I’m still planning to get to your block code but ran out of time today. Regarding your Python question I did write your mission code and tested it in our Tello simulator with Python. Here’s the code:

import asyncio
import time
from DroneBlocksTelloSimulator import SimulatedDrone

async def mission():

    drone = SimulatedDrone('08b5e487-fd90-4f6b-b9ed-e7a1153ddde3')
    await drone.connect()
    await drone.takeoff()

    await drone.fly_up(100, 'cm')

    num_waves = 2
    t = 200
    a = 50

    for i in range(num_waves):
        await drone.fly_curve(t/4, 0, a, t/2, 0, 0, 'cm')
        await drone.fly_curve(t/4, 0, -a, t/2, 0, 0, 'cm')

and here is the result:

Very cool use of variables, loops, and the curve block :+1:

This is great Dennis, thanks! Would you kindly point me to the lesson which I can study to set up the Python environment and its ( simulator - alpha version)? Mike

What environment would are you trying to run Python in? Maybe you could start a new thread so we can talk about it over there and we can continue with the block coding conversation here.

I would be running this on a windows laptop.

How is the droneblocks testing going?

I’m seeing identical behavior to what you describe. I wonder if Tello and Tello Talent (what I tested with) are having problems processing the curve blocks without a delay in between. It’s very strange behavior. Will try to step through our app code to see if I can find anything out.

I was very hopeful that the hover after the fly up would provide a sufficient delay. I did not try inserting delays after every curve block. Perhaps using python would afford greater control over inserting delays.
Also, Would you kindly point me to the appropriate DroneBlocks lesson on Python so I can try generating the Python code you supplied me in a previous post?
Thanks, Mike

I wanted to share (in a new thread) my experience with the curve command today:

Tello Talent Curve Command Inconsistency - Tello Coding - DroneBlocks Drone Coding Discussion Groups & Community

Regarding your Python request we are working on a “Mini Course” that shows how to use ChromeBooks with Python and our Tello Simulator. That should be done later this week or early next. That will help guide you through the code I shared in a previous post, which was a Python mission of your DroneBlocks Sine Wave code. Thanks for all time and feedback you’re investing into DroneBlocks. We greatly appreciate it :slight_smile:

@mikejp we have not been able to roll out the Python mini course yet due to other priorities, but it’s on the roadmap and will get done in the coming weeks. In the meantime would you mind giving this howto a try:

If you have any issues please post a new thread in our community and let’s work through it together. This will help guide us on what needs to be improved before we make this widely available. Thanks so much and Happy New Year.