LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using stepper motor as a shutter !!!

Highlighted

Greetings everyone, I have a stepper motor to which a filter wheel is attached. I am using an NI USB to connect labview to the stepper motor, My job is to make this filter wheel as a shutter so that I gets ON and OFF and I could gather radiation from a black body cavity.

I have attached a VI. Can you guys give me a hint of how would i do that ?. 

0 Kudos
Message 1 of 10
(503 Views)
Highlighted

Hi Pukhtun,

 


@Pukhtun_Yum wrote:

My job is to make this filter wheel as a shutter so that I gets ON and OFF and I could gather radiation from a black body cavity. Can you guys give me a hint of how would i do that ?. 


Hint:

Read the manual ofr your stepper motor (driver) and send the required signals to have the motor step forward/backwards as needed!

Best regards,
GerdW

using LV2011SP1 + LV2017 (+LV2020 sometimes) on Win10+cRIO
0 Kudos
Message 2 of 10
(493 Views)
Highlighted

Hello, I did that already. I can rotate the motor clockwise and anticlockwise but what i want is to use the motor as a shutter so that it goes clockwise (ON) and anticlockwise (OFF) 

0 Kudos
Message 3 of 10
(487 Views)
Highlighted

Hi Pukhtun,

 


@Pukhtun_Yum wrote:

I can rotate the motor clockwise and anticlockwise but what i want is to use the motor as a shutter so that it goes clockwise (ON) and anticlockwise (OFF) 


So you know how to spin the motor (anti) clockwise - and now you want to know how to spin the motor (anti) clockwise?

 

Btw what about creating a state machine-like code?

Best regards,
GerdW

using LV2011SP1 + LV2017 (+LV2020 sometimes) on Win10+cRIO
0 Kudos
Message 4 of 10
(457 Views)
Highlighted

Sorry for complicating things. It takes 132 number of iterations for a motor to move from OFF position to ON position and vice versa. What I want is to turn the motor very quickly from ON to OFF and from OFF to ON. How can i skip these iterations so that the filter wheel jumps to the desired locatioon instantly ?

0 Kudos
Message 5 of 10
(453 Views)
Highlighted

@Pukhtun_Yum wrote:

Sorry for complicating things. It takes 132 number of iterations for a motor to move from OFF position to ON position and vice versa. What I want is to turn the motor very quickly from ON to OFF and from OFF to ON. How can i skip these iterations so that the filter wheel jumps to the desired locatioon instantly ?


A stepper motor moves in steps, right?  So it's just doing what it's supposed to be doing.  In fact, if you were able to move in such a quick and jarring manner, it might destroy the motor and/or the mechanical components.  If anything, I would think a solenoid would be a better choice.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 6 of 10
(450 Views)
Highlighted

@Pukhtun_Yum wrote:

Sorry for complicating things. It takes 132 number of iterations for a motor to move from OFF position to ON position and vice versa. What I want is to turn the motor very quickly from ON to OFF and from OFF to ON. How can i skip these iterations so that the filter wheel jumps to the desired locatioon instantly ?


Does your stepper motor have an encoder?

0 Kudos
Message 7 of 10
(396 Views)
Highlighted

Yes, it has.

0 Kudos
Message 8 of 10
(362 Views)
Highlighted

Would be pretty easy then. Note where the encoder starts before you start your spin and when you want to go back, subtract where it is at from where you started.

0 Kudos
Message 9 of 10
(343 Views)
Highlighted

@billko wrote:

@Pukhtun_Yum wrote:

Sorry for complicating things. It takes 132 number of iterations for a motor to move from OFF position to ON position and vice versa. What I want is to turn the motor very quickly from ON to OFF and from OFF to ON. How can i skip these iterations so that the filter wheel jumps to the desired locatioon instantly ?


A stepper motor moves in steps, right?  So it's just doing what it's supposed to be doing.  In fact, if you were able to move in such a quick and jarring manner, it might destroy the motor and/or the mechanical components.  If anything, I would think a solenoid would be a better choice.


Hi, @Pukhtun_Yum,

If you want to jump to a desired location instantly, @billko is right. By design, a stepper motor can only rotate one step at a time.

 

If you really only have two states you need (ON and OFF), you should consider a solenoid.

 

If you have to use a motor (solenoid isn't allowed?), you could try a DC motor with good feedback (like an encoder) and control. It can go much quicker than a stepper motor, but it can become really complicated if you aren't familiar with the required hardware and programming to control it.

 

If you must use a stepper motor, you'll just need to optimize its operation.

Some ways to go faster include

  • using full-steps (instead of half- or quarter-steps - maybe you're already using full-steps, I don't know)
  • increasing the step rate (how often you step), up to the physical limitations to what a stepper motor can do. The rate may also be voltage dependent.

Also, I found some additional ideas at this URL:

  1. Use a higher voltage. This lets the current ramp up faster every time you step and allows for a higher average current at high step rates.
  2. Set the current limit to the maximum allowed by your stepper motor. ...[If you're using a stepper-motor driver, it may limit you]...
  3. Ramp the stepper speed up slowly. You can get the stepper motor to a much higher speed if you gradually increase your speed over time rather than trying to start at the maximum speed from rest.
  4. Decrease the external load on the stepper. The more torque your stepper motor needs to deliver, the lower it’s maximum step speed will be.

 

Hope something helps.

-joeorbob

 

Message 10 of 10
(314 Views)