I am working on a project and need to stop an electrically powered vehicle autonomously. I have experience building remote control cars and can build whatever is needed for the project, however I do not know anything about programing a robot, or the materials needed to build the components i need to stop the robot at a certain distance. I am currently considering 2 methods of stopping the car, the first is to measure the cars velocity and calculate the time needed to reach a certain distance and program that time into a timer which will shut off my drive motor. The second would be to count the revolutions of the wheel and use its circumference to calculate how many revolutions are needed to stop at a certain distance.

Last edited by JohnWatson on Fri Nov 22, 2013 11:37 am, edited 2 times in total.

Removed two links from comment.

Mon Nov 18, 2013 2:36 am

rcahoon

Site Admin

Joined: Tue Oct 09, 2012 10:34 amPosts: 192

Re: anything about programing a robot

Hi tindra,Your first method will work to certain degree, but will probably have pretty low accuracy because your vehicle's velocity is not going to be perfectly maintained.

Your second method is the standard approach. Usually people use sensors called rotary encoders to measure wheel rotations. These sensors produce a defined number of electrical pulses per revolution, and so you can count the number of pulses (either using a programmable microcontroller or you could build your own simple counter circuit) to determine how far the vehicle has gone. If you don't need much resolution, you can build your own cheap encoder by attaching an encoder wheel pattern to your wheel, then using an optical reflectance sensor to detect the transitions from black to white to black as the wheel goes around. Here's a page on using ROBOTC with an Arduino and encoders to do measured movement.

If you don't have to travel very far (maybe 100 meters or less), another - very low-tech - option would be to attach one end of string to a spool on your wheel axle, and the other end to the lever of a knife switch. As your vehicle travels, it will wind up the string; when it has wound up all the string, it will pull the knife switch, disconnecting the electricity from your motor.

Also, do you need the vehicle to stop very precisely or approximately is fine? How heavy is the vehicle? How fast are you planning to travel? If your vehicle is heavy and travelling fast, the vehicle may not be able to stop on the dime when you reach your "target position". Understanding your requirement is crucial in determining what the best way to implement the solution is.

Who is online

Users browsing this forum: No registered users and 1 guest

You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forumYou cannot post attachments in this forum