Netherlands
Asked — Edited

Autonomous Parrot Ar 2 Drone Navigation

Hey everybody!

First of all, I am amazed by how good your software works! I've been searching for software to use in a project for my university and ARC is by far the most promising software i've found.

So I have a few questions that i'd hoped you guys could help me with. For a project on my university me and a few fellow students want to use a drone to help people navigate within the school. To do this we are using a Parrot AR 2 drone, together with (hopefully) ARC. We have played with ARC for a bit to try and understand how the software really works. This went well until the point that we have to make the drone fly autonomously, why autonomously you might think? We want the drone to be able to fly to a given location within the school, by itself, without any user interaction whatshowever AND without crashing or being a hazard to people. This is where we run into trouble. We got the drone to perform a script, but for it to fly autonomously we need the drone to recognize 'danger' being people (automatic ascending) and close proximity to walls (automatic centering in hallways). Do you guys think this is possible to do with ARC, and if so, can you give us a push in the right direction?

Besides this; is it possible to combine different functionality of ARC? For example, let the drone perform a script, while using the camera to make sure it doesn't hit anything, give a led signal when the destination has been reached and then fly back to the starting point?

Im very curious what you guys think about this and if somebody is willing to help us out a bit :D

Lets end this post with another (small) question!: After I connect to the drone in ARC, and let it take off using my keyboard and then land again, the drone won't respond to any scripts I send to it, it will only listen to my keyboard and I have to reset the connection for it to execute scripts again, is there a way to fix this, so to make the drone respond to everything I tell it to do?

Sorry for the long post!


ARC Pro

Upgrade to ARC Pro

Join the ARC Pro community and gain access to a wealth of resources and support, ensuring your robot's success.

#9  

Have you done any type of programming at all before?... I absolutely mean no offence but I think you need to back up a little and understand a few things first... The "goto" statement in code allows the programmer to jump from one area of the code to another... Without some detailed coding, it doesn't mean for a physical robot to go from one place to another.... You can use many goto statements as you want, but that would get seriously confusing after a while.... Using multiple scripts would work a lot better than many goto statements... I think you need to start right from the basics before tackling some fancy programming/math to accomplish what you want to do.....

To put this in perspective... I consider myself a decent ARC programmer, however what you want to do is even probably beyond me (unless DJ rolls out his indoor nav system). There are a couple of guys on here that have the programming skills to do this, however... What I am trying to say is you have set quite a challenge for yourself indeed... and I seriously applaud your enthusiasm and determination....

Below is a simple example of how to use the "goto" statement in a script


$x=0
:top

if($x=10)
$x=0
else
$x++ #add 1 to x
endif
sleep(1000)
goto(top)

Netherlands
#10  

No offense taken at all, I'm just trying to find a way for me and my team to make this work, even if it just works 'a bit'. I have done some programming before, Java and Python, but I'm not good at it (at all). Thanks for the clarification, I didn't understand that the goto() was used for the code itself. This does enable me to re-use code in a decent-ish way, with the correct use of if/elif statements i reckon. Anyways, I will look into it some more tomorrow and I'll update this thread with any progress, or obstacles:)

#11  

If you work on this enough, I have no doubt you will be able to accomplish this... If you haven't already done so, download a copy of ARC and start playing with it.... A large portion of the software can be used without having an actual ezb controller... Also, in the menu there are examples on how to do things... like control usage, scripts etc... Basically that is how I learned how to use ARC.... You can always ask on here if you need help with a particular example or piece of code...:)

Netherlands
#12  

I have indeed installed ARC and used various functions to check how they worked with the drone. It works great, but the downside is that because the drone is flying indoors, it causes a lot of air displacement, making it unstable.

I'll keep trying and if i run into things or if I succeed, I'll post back here

Netherlands
#13  

So a little update for anybody interested. We have proven to be unable to accomplish anything that has been discussed on this thread tired

To not let our heads get down, we wanted to try to use two functions of ARC to work together to maybe accomplish our task in some way.

We wanted to use the nice color identifying feature in ARC to let the drone follow a stripe of coloured something (paper or something), while following a script invoked by a user.

Is it possible to use EZ script to not let the drone fly for an X amount of seconds, but rather an X amount of metres, while paying attention to the coloured stripe on the floor?

If i need to start a new thread for this let me know, I'm curious to your answers.

Greetings :D

#14  

Moving a specific distance vs a specific amount of time is the same issue you are trying to solve earlier in the thread. Based on the sensors built into the AR-Drone, there is no way to accurately determine your position relative to anything except height above ground, so there is no way to know when you have reached a particular distance. Solve one, and you have solved the other.

If instead of just a stripe, you had some other object (glyph, shape, etc) intersecting the stripe, so the camera could see that it has approached or passed the object might be a way to do it. More programming than I want to try to wrap my head around, but would at least be something to give you positional awareness.

Alan

Netherlands
#15  

@thetechguru You make a valid point, Multiple colours could allow us to make the drone recognize when it's in front of a location. For example a green stripe that it follows in general, and Red one in front of a location, so we can let it decide when the right location has been reached using while and if statements?

Also, is it possible to combine the camerafeed with the EZ-Script functions, I cannot find this in the Script documentation.

As a last question, is it possible to declare your own variables and use these to count (and increase the count) of objects it sees with the camera with EZ-script?

#16  

Simple answers since I am on my phone.. Yes and yes.

More later

Alan