View unanswered posts | View active topics It is currently Mon Jul 28, 2014 4:20 am






Reply to topic  [ 4 posts ] 
Motor Scaling 
Author Message
Rookie

Joined: Tue Feb 19, 2013 8:28 pm
Posts: 2
Post Motor Scaling
I have 2 DC Motors controlling an arm,but they are too powerful, how do I decrease the amount of power they use without having to focus on how much I move the analog stick?

Thank You!!~

_________________
Do you even Robotics? #LegitServoSwag #ThomasAlexFarisSetoShirleyDerickCarlMiguelEmelyEricaKaitlynnTiceEvanMitchellMannyAvery


Tue Feb 19, 2013 8:36 pm
Profile
Moderator
Moderator
User avatar

Joined: Wed Mar 05, 2008 8:14 am
Posts: 3164
Location: Rotterdam, The Netherlands
Post Re: Motor Scaling
You could clip or scale the values. Clipping is the easiest. I have a function in my Driver Suite called clip:
Code:
#define min2(a, b) (a < b ? a : b)
#define max2(a, b) (a > b ? a : b)
#define clip(a, b, c) min2(c, max2(b, a))

To find out how to scale values, I would say: "Use the Omniscient Google."

= Xander

_________________
| Professional Conduit of Reasonableness
| (Title bestowed upon on the 8th day of November, 2013)
| My Blog: I'd Rather Be Building Robots
| ROBOTC 3rd Party Driver Suite: [Project Page]


Wed Feb 20, 2013 12:53 am
Profile WWW
Guru
User avatar

Joined: Sun Nov 15, 2009 5:46 am
Posts: 1347
Post Re: Motor Scaling
Alternative, you can just scale down the motor power. For example,
Code:
motor[motorA] = joystick.joy1_y1/3;


Thu Feb 21, 2013 1:46 am
Profile
Rookie

Joined: Tue Feb 19, 2013 8:28 pm
Posts: 2
Post Re: Motor Scaling
MHTS wrote:
Alternative, you can just scale down the motor power. For example,
Code:
motor[motorA] = joystick.joy1_y1/3;

That doesn't seem to effect the speed of the robot. But, I will try clipping.

_________________
Do you even Robotics? #LegitServoSwag #ThomasAlexFarisSetoShirleyDerickCarlMiguelEmelyEricaKaitlynnTiceEvanMitchellMannyAvery


Fri Mar 01, 2013 5:55 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 4 posts ] 

Who is online

Users browsing this forum: No registered users and 2 guests


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

Search for:
Jump to:  



Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.