Go to Post Keep reading. - Billfred [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 08-02-2010, 23:12
Lumit Lumit is offline
Registered User
FRC #2521
 
Join Date: Jan 2010
Location: Oregon
Posts: 26
Lumit is an unknown quantity at this point
Joystick-Servo control

So we want to have the servos on the camera mount controlled by a joystick.
our camera mount: http://andymark.biz/am-0568.html

I have a feeling the issue is our number range conversion.

As I understand it, the joystick axes output a value of -127 to 127.
And the servos can use 0 to 1 (with set position) or 0 to 180 (with set angle).

So I added 127 to the joystick input, then divided it by 255, then fed that value into the set position VI. When powered up, it locks itself facing straight upwards, and wont respond to the joystick.

Am I missing something? It feels mathematically solid yet it isn't working!

thanks
Reply With Quote
  #2   Spotlight this post!  
Unread 08-02-2010, 23:21
Mark McLeod's Avatar
Mark McLeod Mark McLeod is offline
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Joystick-Servo control

If you use Joystick Get, the joystick value is -1 to 1.
Use that with Servo Set Position.
Just feed it directly for your first test without any mathematical manipulation.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Labview Servo Control Issue EricWilliams Programming 5 22-01-2010 14:24
Camera servo control off of the Joystick axes m3rc1l3ss NI LabVIEW 5 13-03-2009 20:00
1 Joystick Control penguain Programming 9 01-02-2008 10:02
Servo Control? mattg101 Technical Discussion 2 20-01-2007 13:12
Direct control of a Servo or Speed Controller Schmitty! National Instruments LabVIEW and Data Acquisition 3 06-03-2006 13:53


All times are GMT -5. The time now is 22:34.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi