Go to Post using CD to answer my question is not the way to get the "ALL-BINDING FIRST ANSWER." - rees2001 [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 14-02-2013, 22:08
akash992391 akash992391 is offline
Registered User
AKA: Akash
FRC #4684
Team Role: Programmer
 
Join Date: Nov 2012
Rookie Year: 2013
Location: yonkers
Posts: 76
akash992391 is on a distinguished road
programmed DC motor in degree..

hii
is there any way to programmed DC motor in certain degree control through joystick in LabVIEW
  #2   Spotlight this post!  
Unread 14-02-2013, 22:22
EricH's Avatar
EricH EricH is offline
New year, new team
FRC #1197 (Torbots)
Team Role: Engineer
 
Join Date: Jan 2005
Rookie Year: 2003
Location: SoCal
Posts: 19,825
EricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond reputeEricH has a reputation beyond repute
Re: programmed DC motor in degree..

There is and there isn't. What sensor(s) do you have on the motor you want to move through a certain number of degrees? (And, what is that motor?)

If you don't have any sensors on the motor, you might be able to use time to stop the motor at a given point. However, that can be inaccurate; the window motors are about the only ones I'd trust to do that, and even then only with a hard stop of some kind.

With a sensor, it's a lot easier: run the motor through the angle, read the sensor, and make sure that you can get the same value for the same angle. Then increment/decrement the value to get to where you really need to be. (Note: I'm a mechanical with no knowledge of Labview, so I can't help with the actual programming.)

If you have a servo, then it's even easier, but that isn't the question that was asked.
__________________
Past teams:
2003-2007: FRC0330 BeachBots
2008: FRC1135 Shmoebotics
2012: FRC4046 Schroedinger's Dragons

"Rockets are tricky..."--Elon Musk

  #3   Spotlight this post!  
Unread 14-02-2013, 22:29
akash992391 akash992391 is offline
Registered User
AKA: Akash
FRC #4684
Team Role: Programmer
 
Join Date: Nov 2012
Rookie Year: 2013
Location: yonkers
Posts: 76
akash992391 is on a distinguished road
Re: programmed DC motor in degree..

i have servo but how u programmed that i tried everything but doesn't work on servo can u help me please how to programmed servo i have all electical is good connected but the big problem is progrmming idk please help us....thanx
  #4   Spotlight this post!  
Unread 15-02-2013, 00:52
fb39ca4 fb39ca4 is offline
Registered User
FRC #1899
 
Join Date: Jan 2012
Location: Bellevue, WA
Posts: 195
fb39ca4 is a name known to allfb39ca4 is a name known to allfb39ca4 is a name known to allfb39ca4 is a name known to allfb39ca4 is a name known to allfb39ca4 is a name known to all
Re: programmed DC motor in degree..

On servos, the shaft angle directly corresponds to the value you output on the Digital Sidecar. You would set the PWM output it is connected to to a value between 0.0 and 1.0, and the shaft would move proportional to that.
  #5   Spotlight this post!  
Unread 15-02-2013, 12:17
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: programmed DC motor in degree..

Quote:
Originally Posted by akash992391 View Post
i have servo but how u programmed that i tried everything but doesn't work on servo can u help me please how to programmed servo i have all electical is good connected but the big problem is progrmming idk please help us....thanx
A servo is programmed much like a motor. Instead of setting its relative power from -1 to +1, you set a desired angle from 0 to 180-ish.

But before we go too far down the road of providing you with helpful software, can you convince us that you have the servo correctly wired? Tell us exactly where you have it plugged in, and which colored wires go to what pins, and anything else associated with the electrical connections.
  #6   Spotlight this post!  
Unread 15-02-2013, 21:16
akash992391 akash992391 is offline
Registered User
AKA: Akash
FRC #4684
Team Role: Programmer
 
Join Date: Nov 2012
Rookie Year: 2013
Location: yonkers
Posts: 76
akash992391 is on a distinguished road
Re: programmed DC motor in degree..

i connected servo arm to pwm cable to digital sidecar..and i put jumpers too
Attached Files
File Type: zip IMG_2772.zip (2.01 MB, 14 views)

Last edited by akash992391 : 15-02-2013 at 21:52.
  #7   Spotlight this post!  
Unread 16-02-2013, 01:09
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: programmed DC motor in degree..

I'm going to assume you meant to show us that there's a servo power jumper installed next to PWM 5 on your Digital Sidecar. I don't quite know how to interpret "i connected servo arm to pwm cable", but I'll pretend that it means you plugged the servo connector into a PWM extension cable. The colors of the wires are probably close enough that you wouldn't have plugged it in with the wrong orientation, but it's something you should check.

What exactly do you want the servo to do, and when do you want the servo to do it? Specifically, which joystick controls do you want to cause the servo to move? Pretend it's working precisely as you want, and tell us what we'd see happen if we watched you controlling it. If you can describe what you are trying to make the robot do, we can step you through how to program the robot to do it.
  #8   Spotlight this post!  
Unread 16-02-2013, 09:32
akash992391 akash992391 is offline
Registered User
AKA: Akash
FRC #4684
Team Role: Programmer
 
Join Date: Nov 2012
Rookie Year: 2013
Location: yonkers
Posts: 76
akash992391 is on a distinguished road
Re: programmed DC motor in degree..

OK so i want servo to move 0 to 180 in one button .when i press joystick button
(Triger) i want servo move 0 to 180 and come back to 0 position.
  #9   Spotlight this post!  
Unread 17-02-2013, 00:25
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: programmed DC motor in degree..

I'm not getting a clear idea of how you want the servo to act. Here are two possible interpretations of what you said:
  1. The servo begins at 0. Each time you press the joystick trigger, it moves from 0 to 180 and then back to 0, regardless of how long the trigger is held.
  2. While the joystick trigger is not being pressed, the servo is at 0. While the trigger is being pressed, the servo is at 180.

If #1 is what you want, keep in mind that the servo takes some time to move from 0 to 180, so you have to plan for a delay before it returns from 180 to 0. While the programming is straightforward, it involves some things that you will probably find unfamiliar.

If #2 is what you want, the programming is very easy.

Or did you want the servo action to be something else? Remember that computers are not very clever, and you have to be extremely precise in how you describe what you want them to do.
Closed Thread


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


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

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