RE: Position control Servo System -by LV

Needed HELP..
In the first stage, I have a problem on writing Lv program in the data acquisition
part of my project and also do not know how to control analog signal using
PC set-point.
With Thanks!!
http://www.zfree.co.nz

A good place to start with questions like this is by going trough the example programs that ship with LV, or are available on NI's web site. Find something that is close to what you need and then tweak it to make it exactly what you need.
Mike...
Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion
"... after all, He's not a tame lion..."
Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps

Similar Messages

  • Position Control of compumotor linear servo table and GV-U6E with PCI-7344

    I'm referring PCI-7344 (not 7334).
    I have the GV-U6E which is a drive only and does not possess control functionality. the drive only version does not store or use programs. So, serial commands can not be sent through COM port by LabVIEW even though A few basic commands can be emulated.
    I am trying to do position control as I mentioned. For example, the motor should move A point to B point exactly with a certain speed. The points must be aboulte position.
    I would like you to see the reference comment that I have been contacting with in your website forum.
    http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=135&HOID=506500000008000000DD490000&USEARCHCONTEXT_CATEGORY_0=_14_&USEARCHCONTEXT_CATEGORY_S=0&UCATEGORY_0=_14_&UCATEGORY_S=0
    Regard,
    Jin Ho Lee
    ----- Original Message -----
    From:
    To:
    Sent: Thursday, September 26, 2002 5:00 PM
    Subject: Re: (Reference#1549-QYW196) "Position Control of linear servo table and GV-U6E with PCI-7344
    >
    > Note: Your reference number is included in the Subject field of this
    > message. It is very important that you do not remove or modify this
    > reference number, or your message may be returned to you.
    >
    >
    > JinHo. Compumotor is a very popular brand, and I know of several customers
    > who integrate our 7334 with Computmotor drives. However, when you say that
    > the MAX configuration doesn't fit in the compumotor drive settings, are you
    > referring to the specs from the 7344? It looks like the 7344 and the
    > Compumotor will work well together through a UMI break out box. If you're
    > referring to specific commands that the Compumotor receives, I'd have to
    > know more about the protocol. If the Compumotor needs serial commands,
    > then you can send them through the computer's COM port from LabVIEW.
    > Please let me know exactly what kind of configurations you're trying to
    > set. The 7344 can be completely configured in MAX and LabVIEW.
    >
    >
    > Best Regards
    >
    > Kyle Voosen
    > Applications Engineer
    > National Instruments
    > http://www.ni.com/support
    >
    > ------------------------------------------------------------------------------
    >
    > Problem Description :
    > "Position Control of compumotor 406LXR linear servo table and GV-U6E(motor
    > drive) with PCI-7344"
    >
    > "Since I had the answers referring:
    > http://exchange.ni.com/servlet/ ProcessRequest?RHIVEID=101&RPAGEID=135&
    > HOID=506500000008000000DD490000& USEARCHCONTEXT_CATEGORY_0=_14_&
    > USEARCHCONTEXT_CATEGORY_S=0& UCATEGORY_0=_14_&UCATEGORY_S=0
    >
    > Wiring step was done well. However, I still have a problem that MAX
    > configuration doesn't fit in compumotor drive settings. Therefore, the
    > setup is shown below, and I want to know how I can set up PCI-7344
    > configuration in MAX or LabVIEW VI.
    >
    >
    > -----------------------------------------------------
    >
    > Uploaded from device address 0
    >
    > Gemini GV Servo Drive Setup
    >
    >
    >
    > Motor Setup
    > DMTR 1703
    > Motor ID (406-x-LXR-M-x-D13-x-x-x-x-E5-x-x-x)
    > DMTIC 2.48
    > Continuous Current (Amps-RMS)
    > DMTICD 0.00
    > Continuous Current Derating (% derating at rated speed)
    > DMTKE 17.6
    > Motor Ke (Volts (0-to-peak)/krpm)
    > DMTRES 10.10
    > Motor Winding Resistance (Ohm)
    > DMTJ 119.300
    > Motor Rotor Inertia (kg*m*m*10e-6)
    > DPOLE 1
    > Number of Motor Pole Pairs
    > DMTW 40.5
    > Motor Rated Speed (rev/sec)
    > DMTIP 7.40
    > Peak Current (Amps-RMS)
    > DMTLMN 3.4
    > Minimum Motor Inductance (mH)
    > DMTLMX 3.4
    > Maximum Motor Inductance (mH)
    > DMTD 0.000000
    > Motor Damping (Nm/rad/sec)
    > DMTRWC 0.23
    > Motor Thermal Resistance (degrees Celsius/Watt)
    > DMTTCM 20.0
    > Motor Thermal Time Constant (minutes)
    > DMTTCW 0.33
    > Motor Winding Time Constant (minutes)
    > DMTAMB 40.00
    > Motor Ambient Temperature (degrees Celsius)
    > DMTMAX 90.00
    > Maximum Motor Winding Temperature (degrees Celsius)
    > DHALL 1
    > Disable Hall Sensor Checking
    > DMTLQS 0
    > Set Q Axis Inductance Saturation
    > DMTLDS 0
    > Set D Axis Inductance Saturation
    > DTHERM 0
    > Disable motor thermal switch input
    >
    >
    >
    > Drive Setup
    > DMODE 2
    > Drive Control Mode
    > DRES 8400
    > Drive Resolution (counts/rev)
    > DPWM 16
    > Drive PWM Frequency (kHz)
    > SFB 1
    > Encoder Feedback
    > ERES 8400
    > Encoder Resolution (counts/rev)
    > ORES 8400
    > Encoder Output Resolution (counts/rev)
    > DMEPIT 42.00
    > Electrical Pitch (mm)
    > SHALL 0
    > Invert Hall Sensors
    > DMTLIM 1.5
    > Torque Limit (Nm)
    > DMTSCL 1.5
    > Torque Scaling (Nm)
    > DMVLIM 119.000000
    > Velocity Limit (rev/sec)
    > DMVSCL 119.000000
    > Velocity Scaling (rev/sec)
    >
    >
    >
    > Load Setup
    > LJRAT 0.0
    > Load-to-Rotor Inertia Ratio
    > LDAMP 0.0000
    > Load Damping (Nm/rad/sec)
    >
    >
    >
    > Fault Setup
    > FLTSTP 1
    > Fault on Startup Indexer Pulses Enable
    > FLTDSB 1
    > Fault on Drive Disable Enable
    > SMPER 8400
    > Maximum Allowable Position Error (counts)
    > SMVER 0.000000
    > Maximum Allowable Velocity Error (rev/sec)
    > DIFOLD 0
    > Current Foldback Enable
    >
    >
    >
    > Digital Input Setup
    > INLVL 11000000
    > Input Active Level
    > INDEB 50
    > Input Debounce Time (milliseconds)
    > INUFD 0
    > Input User Fault Delay Time (milliseconds)
    > LH 0
    > Hardware EOT Limits Enable
    >
    >
    >
    > Digital Output Setup
    > OUTBD 0
    > Output Brake Delay Time (milliseconds)
    > OUTLVL 0100000
    > Output Active Level
    >
    >
    >
    > Analog Monitor Setup
    > DMONAV 0
    > Analog Monitor A Variable
    > DMONAS 100
    > Analog Monitor A Scaling (% of full scale output)
    > DMONBV 0
    > Analog Monitor B Variable
    > DMONBS 100
    > Analog Monitor B Scaling (% of full scale ouput)
    >
    >
    >
    > Servo Tuning
    > DIBW 1500
    > Current Loop Bandwidth (Hz)
    > DVBW 100
    > Velocity Loop Bandwidth (Hz)
    > DPBW 40.00
    > Position Loop Bandwidth (Hz)
    > SGPSIG 1.000
    > Velocity/Position Bandwidth Ratio
    > SGIRAT 1.000
    > Current Damping Ratio
    > SGVRAT 1.000
    > Velocity Damping Ratio
    > SGPRAT 1.000
    > Position Damping Ratio
    > DNOTAF 0
    > Notch Filter A Frequency (Hz)
    > DNOTAQ 1.0
    > Notch Filter A Quality Factor
    > DNOTAD 0.0000
    > Notch Filter A Depth
    > DNOTBF 0
    > Notch Filter B Frequency (Hz)
    > DNOTBQ 1.0
    > Notch Filter B Quality Factor
    > DNOTBD 0.0000
    > Notch Filter B Depth
    > DNOTLG 0
    > Notch Lag Filter Break Frequency (Hz)
    > DNOTLD 0
    > Notch Lead Filter Break Frequency (Hz)
    > SGINTE 1
    > Integrator Option
    > SGVF 0
    > Velocity Feedforward Gain (%)
    > SGAF 0
    > Acceleration Feedforward Gain (%)
    > -----------------------------------------------------
    >
    >
    > Regards,
    > JinHo"
    > NI Software :
    > LabVIEW version 6.0
    > NI Hardware :
    > Motion Control device PCI-7344
    > Driver Version :
    > no
    > OS :
    > Windows 2000
    > CPU :
    > Pentium
    > RAM :
    > 128
    > Vendor :
    > DELL
    > Customer Information :
    > Jin Ho Lee
    > North Carolina State Univ.
    > US
    > [email protected]
    > Ph: (
    > 919
    > )
    > 512-9929
    >
    >

    Yes, we used an NI PXI-7344 motion control card with an NI UMI-7764 box connected to a Gemini GV-U12E servo drive. (which is a drive only.)
    We did positional control in absolute position mode.
    I can send you an AutoCAD schematic detailing how to connect the UMI-7764 to the Gemini GV servo drive.
    In regard to the Rs232 interface to the GV servo drive,
    the GV drive only model is "configurable" not "programmable". You can create unique GV configuration files with Compumotor's Motion planner then download the configuration via Rs232 using LabVIEW as desired. Or, using LabVIEW via Rs232 you can change individual GV drive parameters on demand,
    or use the GV's two analog outputs back to LabVIEW's analog inputs to measure commanded motor current or torque, etc.etc.etc

  • Stepper motor positioning control system

    hello
    Iam building positioning control system using a stepper motor, and I need to know what are some position sensors available to feedback the position of the stepper motor.. Also I need to know how can use a C code in the labview...For example, if I have an algorithm developed in C; How can I use that code in the labview..
    Thanks
    Shaham

    Shaham,
    Below is a link to several encoders that NI provides specifically for stepper motors.
    Quadrature Encoder:
    http://sine.ni.com/nips/cds/view/p/lang/en/nid/205321
    As far as the C code is concerned, this can be accomplished in two different ways, provided that the code is first placed in a dll file.  
    First, you can import the dll into a project library, by selecting Tools»Import»Shared Library.  This option is good for code that will be used often, as it creates wrapper VIs for each function that can be reused.
    Secondly, a "Call Library Function" node can be used to call a C function from a dll.  This procedure is shown in the following tutorial, and is useful when code only needs to be called a few times.
    http://decibel.ni.com/content/docs/DOC-9069
    I hope this helps!
    Drew
    Drew T.
    NIC AE Specialist

  • LIFA+servo position control

    HI all, I have installed the Labview Interface for Arduino.
    I just need VI s for the position control of servo motor
    I have few questions regarding this
    1) what is closed loop position control , can i do that with servo motor ( I am using RC servo -VS-2)
    2)can i control my servo without using Arduino code , directly from m Labview
    3)How to implement PID controller for position control of Servo
    Thanx

    If you want to control servo directly from LabVIEW, you need NI Daq card.
    Your starting point should be from this link : http://zone.ni.com/devzone/cda/tut/p/id/3367
    CLA 2014
    CCVID 2014

  • NI 9505 Closed Loop Position Control Example

    Hello, I have a cRIO 9073 with a NI 9505 module that I'd like to use for simple position control of a unit along a lead screw.
    I don't have the softmotion module, and am trying to write a program bassed off of the "Position Control (closed loop) - NI 9505" example to control the position the small motor attached to the lead screw (Faulhaber 2342S024CR with a 512 count/rev encoder that we had laying around)
    I've reviewed the manual PID tuning example, and have not had much luck getting the response that I'd like when making large position moves simply by adjusting Kp,Ki,Kd gains of the position loop, as the overshoot remains too high for this application when making large moves.  The system is also oscillating about the set point, and doesn't ever seem to dampen out unless I change things other parameters on the fly such as the current limit, or current loop parameters (osciallations get worse as current limit is increased).
    Can someone advise me if the components of this example are up to this task?  Or on the interactions between the current limit, current loop parameters, and position loop parameters from this example, and which parameters would have the most impact on achieving desirable system performance?
    Is there a VI available that can autotune such a motor?

    Hello - there are many reasons why a closed loop controller can oscillate - from correct settings of controller (kp,ki,kd) to making sure signals act in the appropriate direction to deadband/friction in the actuator to badly sized signals/actuators.
    Firstly, have a look at the signal your controller is outputing (ideally in LabVIEW so you can graph it). Does it oscillate - perhaps as a sawtooth, a sinewave or simply switching between maximum and minmum values. I presume the electrical motor driving the screw which is driven from some AO signal from the cRIO (could also be a PWM signal driving the motor).
    I expect (from what you say about current limit) the control signal will be oscillating by switching between maximum and minimum (e.g. +10V to -10V) or oscillating like a sinewave. What values of kp, ki, kd are you using ? If kd is non-zero, set it to zero (you only need worry about this if you want to get maximum performance). Is ki non-zero ? Try setting it to zero - any better ? If you are still getting big oscillations in your control signal, keep reducing kp (e.g. half each time?) until oscillations disappear (as you reduce kp, control signal *should* get smaller - maybe not straight way though).
    If this does not make oscillations go away, then it may be that you have a sign wrong in your loop - i.e. a positive control signal makes lead screw move in opposite direction controller expects. This should be a fundamental thing sorted out when setting up the loop - you could do an open test to check which way +ve voltage moves lead screw. If you find it moves in opposite direction - you can either re-wire, or put a "-1" gain on controller output.
    If there is any more subtle oscillations / obersvations, then try to show some plots of the lead screw motion and control signal, as that always helps when trying to diagnose what is going wrong.
    Good luck.
    Consultant Control Engineer
    www-isc-ltd.com

  • Stepper position control with myRIO

    Hello, 
    I am developing a position control system to move a linear stage back and forth using a stepper motor (file 1).  The stage will ultimately need to follow the motion path set out in a function that I have defined (file 2).  
    I have been able to get the motor to move using a Big Easy Driver from Sparkfun (file 3), sending it a PWM signal from one myRIO pin, and setting another pin on the myRIO to high or low in order to establish the direction.  From what I understand, each low-to-high transition in the PWM signal causes the motor to take one step (or microstep).  Therefore the PWM frequency is equal to steps/second, the motor speed.  Using timed loops along with this information, I am able to control how many rotations the motor performs at a constant speed.  
    However, I would like to be able to count steps, so that I can give the motor a position (number of steps to take from some defined "home") and it will go there, and vary speed accordingly to get there and ultimately follow my function.  I will apparently need to implement some sort of PID control eventually, in order to accomplish this task.  Right now I would just like to know how I can keep track of the position of my motor and control it that way. 
    I greatly would greatly appreciate any advice on how to implement this process. 
    Best, 
    E
    Attachments:
    Stepper_PK244-02AA.pdf ‏764 KB
    PositionFunction.png ‏133 KB
    BigEasyDriver_A4988.pdf ‏383 KB

    Hi E,
    How are you implementing PWM with the myRIO? Are you just using the myRIO express VI or are you writing your own code?
    Also, just as a heads up, the Academic Hardawre Products page is a little more specific to the myRIO and is monitored by NI Developers who work with that device. If you post this question there, you may get a better response.
    Ryan K.

  • Can you control servo valves without the PID toolkit?

    I need to be able to control servo valves using labview, but I don't have the PID toolkit. Is there an alternate way to control servo valves without the toolkit? Any help would be greatly appreciated.
    Thanks

    Well first thing is to get a basic understanding of what a PID controller is doing. There is some discussion about PID on the NI web site, and a search of the net will also provide much information. What you are controlling with your valves will determine the complexity of your control solution and whether learning just the basics of control theory and PID in particular or whether you need to know more. It really isn't wasted effort, any success in implementing a PID control system, regardless of purchased toolkit or "roll it yourself" will need you to understand that basics. Even if you had picked up someone elses project that was complete except for "tuning" the system you would find that getting the system to run the way you need it to requires some knowledge and frequently a lot of patience. Good luck and keep asking questions.
    P.m.
    Putnam
    Certified LabVIEW Developer
    Senior Test Engineer
    Currently using LV 6.1-LabVIEW 2012, RT8.5
    LabVIEW Champion

  • Cambridge Technology servo system

    IWe have a Cambridge Technology servo system (603X) to control a scanning microscope mirrors. Currently, we use an old ISA card to drive the controller and collect the photodiode signal, and we want to replace the card with NI daq card. I tried to get some info from Cambridge Technology, but had little luck. Did anyone have more luck?

    erezg,
        We have had many customers put together systems that do very similar things.  We do have very fast and accurate DAQ cards, but we also have a series of cards that are made for Motion (for more information: http://www.ni.com/motion/) and have ports for Digital I/O.  That site is probably your best resource for getting more information.  If you tell me a little more about your application - I know you have servo motors and are reading a diode signal, how many motors?  what kind of resolution would you need? etc. - I'd be glad to recommend a few cards.  Let me know if you have any questions, or would like any formal quotes sent to you concerning our cards.  Thank you!
    -Allison S.
    Applications Engineer, NIC
    -Allison S.
    Calibration Services
    Product Support Engineer

  • Servo System

    Sir,
          I am working with my company to design a servo system for cnc milling machines.From last 6 months i am unable to understand from where to start.Kindly help me for my project.
                                                      ​                              Adnan Sikandar

    Hi Adnan,
    The Developer Zone section on our website is a great source
    for documentation regarding product information in the form of tutorials and
    example programs.  There is a direct link
    from our homepage at http://www.ni.com.  On our DevZone page, I found two documents
    that should provide some guidance in building your motor drive by just typing
    in the keywords “motor control selection”.  The first two links that populate the search
    are attached below.  
    Motion Control Selection Guide: 
    http://zone.ni.com/devzone/cda/tut/p/id/3655
    Build Your Own Motion Control: 
    http://zone.ni.com/devzone/cda/tut/p/id/3054
    Please let us know if you need any clarification or further
    information that we can provide. 
    Regards,
    Vu D
    Applications Engineer

  • PID position control : guide me

    Dear member
    I want to built a PID position control 
    i read the DC position through potentiometer with -128 to 127 [full 360 degree]
    so the input to the pid is voltage range between -128 to 127
    the input of dc motor is PWM and the motor rotate direction
    so the PID output will be PWM 
    what about direction bit ??? What will be it circuit
    also how to control the speed in same system ?? is thire another PID?? 
    best regards
    hi ?Q>
    Solved!
    Go to Solution.

    nathand wrote:
    mangood wrote:
    what about control the position and the speed at same time ???
    That's a complicated problem. A quick internet search turned up this paper which describes some possible approaches:
    http://www.idt.mdh.se/kurser/ct3340/ht09/ADMINISTRATION/IRCSE09-submissions/ircse09_submission_22.pd...
    okkkkkk
    terrific paper
    hi ?Q>

  • I am looking to control a 4-way hydraulic solenoid valve. Do I need a PID control toolset, or can i control the system through my 16E4 daq card and scxi chasis

    I am looking to control a 4-way hydraulic solenoid valve. Do I need a PID control toolset, or can i control the system through my 16E4 daq card and scxi chasis

    I think you're asking 2 different questions.
    The PID control toolset is for using PID loops for control; it's just software.
    The DAQ card and scxi chassis are hardware. If you have the appropriate signal conditioning cards in your chassis to control/monitor your solenoid valve, then you can run a PID loop.
    I believe the simple answer is: the PID control toolset is the best way to do control, but there are simple PID VI's (even on this website) that you can download and use for simple control.
    Mark

  • How do I handle a count overflow while running "end's" rotation drive in position control?

    Hi everyone!
    We run a direct drive in position control mode and normally do oscillating movements i.e. +-10°. The Signal we get is a TTL with 120 counts/°. And with those counts we do our control.
    But now we want to run the motor permanent one direction for some days (or 4 ever :-). That means that we get sooner or later a overflow on the count variable. So I think we have a problem when the setpoint is on Overflow -32767 and the Position is 32767. ( I know that I can increase the Integer Value but that does not solve it at the end :-)
    How can I handle that?
    Is there any programmatic approach?
    Thanks for Help!

    Hi Petric,
    I do see the math but that does not help when I have more then one overflow, right?
    Well, you have to make sure you NEVER miss such an overflow event. It would be a big problem if you would detect just every second overflow…
    I got a big issue when the setpoint is jumping due to overflow! I have to handle that primarly.
    Have your control loop work with arbitrary units.
    Convert your measurement signal to arbitrary unit with handling overflows in this step.
    Convert your control output to output signal handling overflows as well…

  • NI pci 6251 position control

    Hi
    Im new to this forum and new to Labview and NI pci 6251 as well ;(
    I'm using NI-PCI-6251 (DC Motor ) with Labview to control the position of a DC motor  we developed the program that reads the encoder and display the position of the DC motor shaft
    but the problem is that the counter 0 (cnt0) always increases whether the disc rotating clockwise or anticlockwise??!! and when the desired position is reached the controller does nothing to stop the motor ?
    i don't know what is the problem or why its happening.

    Hi,
    I am also doing something similar.
    The problem is the motor is the DC motor from Quanser. (DCMCT).
    I know the encoder channel of the motor is ctr0 and when I test from "Measurement and Automation Explorer" (Labview>>Tools) I can only read the PFI8 channel.
    The motor read 4096 pulses per revolution and no reading is available from PFI10. As per Quanser the motor should be about to do position control. I have seen lab tutorials for position control in internet.
     I tested both the vi is mentioned above. The "Example" vi reads the motor position in terms of pulses. But when I rotate the motor in the other direction the count increment not decrement.
    Also the quadratureencoderMseries vi did not read the angle position when I set the channel values.
    I have attached the parameters that I set.
    Can any one please check..
    Thanks.
    Attachments:
    encoder issue.JPG ‏357 KB

  • Analog Fedback for position control

    Hi all,
    Its been a long time since I have written into this discussion forum. I have a question. Till now I have been using encoder as a feedback device for position control in PCI 7342 motion controller. Now I want to know about position control using the analog input channel. I cant figure out how the controller understands the equation between input voltage and position.
                                                               Say X Volts = How many mm of movement?
    With the encoder f/b the motion controller knows the encoder pulse per revolution and it keeps counting the feedback and generates motion accordingly. How is it done with analog feedback. My application involves an LVDT which give proportional analog feedback with respect to the displacement. Please help me oiut on this. Also is position compare and breakpoint feature relevant to this particular problem?

    Hi Giridhar,
    it's good to see you back in the forums.
    I have posted a document to another thread that contains a detailed description of the analog feedback feature.
    I hope that helps,
    Jochen Klier
    National Instruments Germany

  • Position Control - HR or Finance?

    It is believed that HR should manages the org structure and control the increases/decreases in positions.  Since Finance is managing the Budgets how do the increases, decreases or movement of positions monitored and reflected in the financial budgets?  Does Finance approve the changes to the number of position? or does Finance get a report to monitor the budget of positions?  If yes, which would be the best report so that Finance can get the information they need to monitor position budgets?  
    I just like to know how other international organizations manage their org structure and position control and the Finance department's involvement in controlling the budgets.  If available kindly send me links to documents or white papers on the subject.
    Thanks for your help.

    as you said
    HR shd manage the Organisational structure
    and Finance Budgets right
    The finance people can know Cost incurred for all the employees
    based on the PERSONAL NUMBERs and the results will posted to fico and u will get thru Cost Center  and that is assigned to GL account
    here the Personal number is assigned to the Position and cost Center is assigned to Position or Personal Number
    so when u hire an employee he shd occupy certain postion and that position shd assigned to Cost Center
    and Cost Center will gives the details of the Balances and Expenses Right
    >here there might be a question wht in case for Vaccant Positions as there are not used these position will not come into the PICture unless they are assigned to the person
    so the control shd be with in the HR as some times the Person may move form one orgunit to another orgunit at that time
    the cost center will get differs right ???  and the first person who gets intimation towards tranfer of the employees is the HR

Maybe you are looking for