go_away

Author Topic: Smoother turning program for the $50 robot  (Read 731 times)

0 Members and 1 Guest are viewing this topic.

Offline Selenaut-14Topic starter

  • Full Member
  • ***
  • Posts: 60
  • Helpful? 0
  • Making the $125 robot...
Smoother turning program for the $50 robot
« on: July 06, 2010, 09:10:21 AM »
Okay, this may sound pretty darn stupid, but I haven't even seen the
normal code (broken leg, no access to a computer). So if you post the original code in a quote I can make a code where it takes the intensity of light in each of the photoresistors and continually converts this to a speed for the corresponding servo, required the servo can vary in speed. The trick is to find the max speed of your motor, a practical threshold for concentration of light, and making a good old fashioned graph that passes right through(0,0). You then find the slope and apply.

EDIT: okay. So the graph's x axis should be concentration of light, and the y axis should be motor/servo speed. X will always be %0-%100. Y will be 0-max rpm. The end algorithm should be n times (max rpm / 100), where n is the numerical form of the percentage of light times 100; in other words, if 25% light was getting through on the photoresistor, and your motor's max rpm was 500, the rpm output would be 125. I guess it would just be max rpm times light intensity.
« Last Edit: July 06, 2010, 02:50:38 PM by Selenaut-14 »
The answer is always yes if it is never no.
--------------
SKILLS:

Building- great
Coding/programming- good
circuitry- pitiful

 

Related Topics

  Subject / Started by Replies Last post
6 Replies
3466 Views
Last post April 25, 2008, 06:58:30 PM
by videorov
6 Replies
1370 Views
Last post January 31, 2009, 10:28:15 PM
by Vince
1 Replies
780 Views
Last post August 21, 2010, 01:19:50 AM
by thinkpix
3 Replies
855 Views
Last post May 19, 2011, 12:01:16 PM
by VegaObscura


Get Your Ad Here

data_list