loading
 
Vision based PID Control
pranavtrehun007 from United Kingdom  [33 posts]
15 year
1)   I am thinking about making soccer playing robots. The vision system gives me about 5.5 FPS due to the demanding code. I am thinking of implementing a vision based PID to better orient my robot and to move in a precise trajectory.

The robot will have a complex PID loop that would control the motors using encoders. So the robot will be able to orient its direction at the angle specified or move at any speed set in runtime.

Now, i want to have another PID loop with feedback from the camera. The camera will look that robot and tell it how to move and orient. What is the FPS required to have a decent control for such a system (this is not the FPS of the camera but the effective FPS that i'll get after vision processing in RoboRealm).  

2)   Has anyone tried any PID based control loop with the camera? what were your results?

Pranav Trehun
Anonymous 15 year
Pranav,

The required FPS will really depend on the speed and accuracy of your robot. For example, in the path planning tutorial

http://www.roborealm.com/tutorial/Path_Planning/slide010.php

the boe-bot is very accurate and is slow enough such that a fps or 1 fps would be adequate. For other robots that are not capable of moving slowly or accurately (similar to the Lego NXT) you will need a faster fps otherwise the robot will tend to oscillate around a particular value.

So it is a little tricky to answer that question but obviously as fast as possible is always better since slower robots will still function just fine.

Also be sure that you are using an appropriate image size. Bigger may seem better but at a cost of 4x processing time. See if you can just use a 80x60 image and work up from there ... that will keep all processing quite fast. We often over compensate for the image size when you really don't need that much information as accuracy is not very important as long as you can correct many times a second.

STeven.
pranavtrehun007 from United Kingdom  [33 posts] 15 year
the robot will have a max speed of 1 feet per second. and to make matters worse, the area is large and ceiling low, there will be 9 cameras(may be more) to cover it. i plan to merge their images to make one big image in RR. and i'll be using feducials to identify the orientation of the robot as other robots can have any color or shape. i plan to use an existing robot base that is about 14inches by 14 inches.

so basically i have three options:
1) Just make it like its in the tutorials. so it will zig-zag its way to the destination. i have made that on a smaller scale, i have the code and it does a decent job. but i wanted to take it to the next level.

2) make it turn only if the error exceeds a particular threshold. but whenever it turns, it will make a precise turn using the feedback from the encoders. But i am not sure if this would be efficient on a curved trajectory. and would cost an extra $300 for encoders and stuff.

3) implement a full fledged PID with vision feed back. if it can give a good enough FPS. due to the other PID loops with encoders, it should be able to handle anything thats thrown at it. but the FPS can be the cause of the bottleneck.

which one would you recommend? do you think the third option is possible?
Anonymous 15 year
Pranav,

Yes, I think option #3 is possible but might require some tweaking. We will use the forward, stop, reverse movements in lots of our examples as that is easiest to do. But in other demos we use a position factor to scale the motor speed based on the amount of turning required. This works but requires some experimentation to see what that factor is. For example, if the orientation is off by 45 deg versus 90 what should the motor speeds really be for either? If 45 should one wheel remain at full speed but the other be at 50%? Or should the one be 75% and the other 45%? In extreme cases you may also have negative motor values.

So basically it is possible but you will have to experiment to see what scaling equation you use to transform from orientation to wheel power. Obviously this assumes a differential wheel structure ...
chaitanya from India  [1 posts] 15 year
hi
Me planing to move ahead wid da same project this is wat i hav planed

only one overhead camera mounted onto a ceiling hook.it will be focused in such a way to hav a clear picture of the soccer arrena.
ball (yellow in colour),two bots in each team the camera ll' identify the bots from diff teams and send it commands to manuver so as to tackle the ball to  the opponents goal post.

  you could help me understand wat all it requires to start wid.PID controller & how could i be able to process the images.
Anonymous 15 year
chaitanya,

Start with a static image and see if you can segment the colors into each of the different objects that you want to track. Try this and if you get stuck upload an image and the robofile that you are working on such that others can help you progress further.

Also, if you could please type in full sentences without using shorthand that would make it easier for folks to understand what you are requesting and also for your request to come up better in search results.

Thanks,
STeven.

This forum thread has been closed due to inactivity (more than 4 months) or number of replies (more than 50 messages). Please start a New Post and enter a new forum thread with the appropriate title.

 New Post   Forum Index