control pixhawk with rasberry pi and make it fly towards a color

Hi I have a competition in one month. I have the quad but I need to make the quad fly above a field and fly to different orange buckets(unknown position). I have looked at the red balloon project already but need more help. I am using a raspberry pi, pixhawk, and noir camera. I want the drone to fly a set path and then when it sees an orange bucket it centers itself over it for 5 seconds and then continues back onto its set path. How can I control it so that when it sees the orange bucket the raspberry pi tells it to go forwards or right or left until it is centered over it. I am new to this so please link me to anything or explain(video would be really helpful). I have already gotten the camera to identify colors and blobs I just need to figure out how to tell the pixhawk to center itself over the blob. Thanks!

Views: 669

Reply to This

Replies to This Discussion

what would be an example code for simple telling the drone to move 3 feet forward. Also is there some functions like set_target that would attatch an anchor to a red blob and tell the drone to keep moving until it was centered, if so could you pleasae include and example thanks!

Am I missing a part of Randy's code because it looks like they only have the color recognition. I have gotten that using open CV.what I need is code to figure out how to make the drone fly towards the red blob until it is centered above it. If he does include that could you please tell me which github file to download because it seems like there is only code for color recognition. Also could you please explain position vectors? Thank you!
Thank you so much! I am not used to github so I thought what was listed on the first page of the github was all. Is the ball on strategy script the onethat controls the movement (like reading frames so when the blob is in the frame accelerate). Once again thanks!
Ok, so where would I put all these files? Do they go on the raspberry pi. Thanks you have been so much help.
What do you mean by directories?

Hi ! i am doing a project similar to your's !

i am interested to know if you are able to achieve it with raspberry pi with opencv.

Hey sevyon! Unfortunately I ended this project without being able to get it. I believe that the pi 3 is not compatible with the pixhawk. I checked about 2 months ago and the only listed pi companion computer was the pi 2. Perhaps you could try that. For the project we got as far as identifying colors but flying towards it was our problem since we couldn't establish a mavlink connection between the pixhawk and pi 3. We use open cv for the color tracking and I believe there should be several github projects you can use. Best of luck on your project!

Reply to Discussion

RSS

© 2018   Created by Chris Anderson.   Powered by

Badges  |  Report an Issue  |  Terms of Service