© 2013
SPiiPlus Training Class
MC4U Trainer Setup
1
© 2013
Presentation Contents
• Introduction
• EtherCAT Configurator walkthrough
• System Configuration Wizard walkthrough
• System Information Viewer
• Complete setup of a single axis on an ACS drive
2
© 2013
Introduction• This presentation is a step-by-step setup of the MC4Unt trainer unit.
It is meant to give a flavor of what a real system setup is like.
• Setup in the presentation was done using SPiiPlus MMI Application Studio 2.10 software. The latest version can be found at acsmotioncontrol.com
• There are three main setup tasks for the trainer unit:1. EtherCAT network configuration2. System configuration3. Axis setup and tuning
• The trainer unit has three axes. This presentation covers setup of one axis, the other two are up to you!
3
© 2013
MC4U Trainer Contents
4
Controller Card SPiiPlus NT-LT-8; 8 axis EtherCAT network master
Power Supply PSM3U-320V-8kW
Drive DDM3U-4-320-3/6A; 4 axis PWM Drive
Motors Axis 1: 3ph BLDC w/ incremental quad encoderAxis 3: 3ph BLDC w/ SINCOS encoderAxis 4: Open-loop stepper
1 43
© 2013
Establish Communication with Controller
• Connect an Ethernet cable between the PC and the MC4U (J6-ETH1)
• Open the MMI, and User Mode Driver (if not already running)
• Set ‘Controller IP Address’ to 10.0.0.100 and make sure your PC is on the same network, then click ‘Connect’
• When connection is established, the workspace window shows a green LED next to the connected controller’s serial number
5
© 2013
Add Components to Workspace
• Right-click on the controller in the workspace window and select ‘Add Component’ to add the following:o Setup Adjuster Wizardo Setup System Configuration Wizardo Setup EtherCAT Configuratoro Utilities System Information Viewero Utilities Communication Terminalo Application Development Program Manager
6
© 2013
EtherCAT Configurator
• Double click ‘EtherCAT Configurator’ componentin the workspace tree to open
• Select ‘Scan System’ and the connectedEtherCAT network will be displayed
• Click ‘Generate Configuration’to save to flash
• Wait for controller to reboot
• Close EtherCAT Configurator
7
© 2013
System Configuration
• Double click ‘System Configuration Wizard’in the workspace tree to open
• Select ‘Change System Configuration’radio button, click next
• Leave application details blank, click next
• Click ‘Approve All’ at bottom ofscreen, click next
• When prompted to save configuration to controller’s flash, select yes, and OK to reboot
• Click next to skip COC and Print Reports. Click ‘Finish’ to close System Configuration Wizard
8
© 2013
System Information Viewer• Double click ‘System Information Viewer’
in the workspace tree to open
• Any relevant information about a system can be found using the System Information Viewer, as well as save/load system information
9
© 2013
System Information Viewer• For instance, to view which IO are available: look under System
Configuration Network Units Unit 0 Inputs/Outputs Assignment
• Looking at the pane to the right, there are 8 digital I/O, and 4 analog I/O
10
© 2013
Adjuster Wizard
• Double click ‘Adjuster Wizard’ in theworkspace tree to open
• Specify you are working with Axis 3
• Select ‘Setup New System or Controller’option
• Click next to get to ‘Initialization’
• Leave user information blank, click next to get to ‘Axis Structure’
11
© 2013
Adjuster Wizard: Axis Structure
• Specify axis structure as ‘Single Motor’
• Specify motor-load topology as ‘Rotary Motor and Rotary Load – Direct Drive’
• Set feedback topology as ‘Single, on motor’
• Apply user units to motor
• Select ‘Degrees’ as rotary units
• Press ‘Next’ button
12
© 2013
Adjuster Wizard: Motor
• Press the ‘+’ button to add a new motor
• Enter the following motor data:
• Click next
13
Motor Type 3-phase DC Brushless/AC Servo
Nominal Current 4.4 Amps (peak of sine)
Peak Current 8.48 Amps (peak of sine)
Maximum Velocity 7000 RPM
Number of Poles 6
Back EMF Constant 39 V/kRPM
Phase Connection Star / Wye Phase
Phase Resistance 3.42 Ohm
© 2013
Adjuster Wizard: Drive
14
• Press the ‘+’ button to add a drive
• The ACS drive will automatically be recognized except supply input voltage and/or frequency
• Specify the input voltage as 110V
• Specify frequency as 60Hz
• Click next
© 2013
Adjuster Wizard: Motor Feedback
• Press the ‘+’ button to add a new motor feedback
• Select the motor feedback type as ‘Incremental Quadrature Encoder’
• Specify the resolution as 2048 lines per revolution
• Set the external multiplier to 1
• Click next
15
© 2013
Adjuster Wizard: Calculate Parameters
• Click ‘Calculate Parameters’
• A list of all calculatedparameters differentfrom current values isshown
• Click ‘Apply Changes’to update all parametersto the newly calculatedvalues
• Click next
16
© 2013
Adjuster Wizard: Safety and Protection
17
!!! I
mpo
rtan
t Saf
ety
Info
!!!
• Skip to ‘Current Limits’ by clicking onit in the task pane
• The adjuster sets current limits toprevent damage to the motor based oninfo entered in ‘Components’. It is importantto verify it is correct
• Click next to get to ‘Position Errors’
• Position error parameters are set automatically too, but these may need to be relaxed temporarily for tuning purposes
© 2013
Adjuster Wizard: Verification
• Skip to ‘Switches’ under the ‘Verification’heading by clicking on it in the task pane
• Verify upper and lower limit switchfunctionality and inverse logic if necessary
• Click next to get to ‘Stop, Alarm and Brake’
• Verify Hardware Emergency Stop functionalityand inverse logic if necessary
• Click next
18
!!! I
mpo
rtan
t Saf
ety
Info
!!!
© 2013
Adjuster Wizard: Axis Setup and Tuning
• The Axis Setup and Tuning process iscovered in detail in the ‘SPiiPlus TimeDomain Tuning’ presentation, but in generalinvolves:
1. Current loop tuning
2. Motor commutation
3. Velocity loop tuning
4. Position loop tuning
19
© 2013
Adjuster Wizard: Axis Setup and Tuning• ACS utilizes a cascaded control loop structure, ideal for motion
control applications:o Current loopo Velocity loopo Position loop
• The position loop generates a command to the velocity loop
• The velocity loop generates a command to the current loop
20
© 2013
Adjuster Wizard: Axis Setup and Tuning• Tuning rules of thumb:
• For current and velocity loops:o Begin by setting proportional and integrator gains low (usually 10 is fine
for both)o Start by doubling proportional gain until response is noisy, then reduce
by halfo Keep proportional gain fixed and begin doubling integrator gain until
roughly 10-15% overshoot is observed
• For position loop:o Start low (usually 10) and begin doubling until position error is
minimized.o Make sure position error while moving at constant velocity is not noisy.
21
© 2013
Adjuster Wizard: Current Loop Tuning
• Set both SLIKP and SLIKI = 10 (start out low)
• Default current level is 10% with 4ms pulse width. These values are fine, do not change.
• Click ‘Scope Autoset’ and ‘Run’
• Double SLIKP until high frequency effects (noise) or overshoot are present, then reduce by half.o Typical values: 50 – 500
• Changing SLIKI should not require returning the change SLIKP
• Double SLIKI until overshoot is excessive, then reduce by half. Overshoot should be roughly 10-15%o Typical values: 1000 – 10,000
22
© 2013
Adjuster Wizard: Current Loop Tuning
23
SLIKP = 25, SLIKI = 10Not responsive enough
SLIKP = 100, SLIKI = 10Too aggressive (excessive
overshoot)
SLIKP = 75, SLIKI = 10Okay
SLIKP = 75, SLIKI = 1000Not responsive enough
SLIKP = 75, SLIKI = 15000Too aggressive (excessive
overshoot)
SLIKP = 75, SLIKI = 12000Well tuned
© 2013
Adjuster Wizard: Commutation
• Commutation is the process of keeping current vector perpendicular to motor magnetic field vector.
• Handled automatically in brush DC motors, and not necessary in steppers operating in micro-stepping mode.
• At controller startup the magnetic field orientation of a BLDC motor is not known and needs to be found. The adjuster has a facility for finding it and setting the commutation angle.
• Once found, the commutation angle is kept track of using motor feedback (encoder)
24
© 2013
Adjuster Wizard: Commutation• Adjuster based commutation only needs to be done once during
initial axis setup.
• Once axis is properly setup and tuned, ACSPL+ COMMUT command can be used instead.
• COMMUT command pings motor three times and finds commutation angle with very little physical motion.
• If motor is equipped with hall sensors, commutation angle is based on first hall state transition, and COMMUT command is not necessary.
25
© 2013
Adjuster Wizard: Commutation• In the commutation dialog, click
the ‘default’ button to tailor the commutation process for this particular axis
• Click ‘Start Commutation’
• On top of finding the commutation angle, a number of magnetic pitches will be measured and checked against encoder feedback to verify settings
• On successful commutation, click next twice to skip to ‘Position and Velocity Loops’
26
© 2013
Adjuster Wizard: Position and Velocity Loops
• Select ‘Velocity Loop’
• Click ‘Motion Manager Autoset’, and ‘ScopeAutoset’
• The only variables you need to be concerned with in velocity loop tuning are Proportional Gain (SLVKP), and Integrator Gain (SLVKI)
• Start SLVKP, SLVKI lowand use a similar tuningapproach as in current loop
• In Motion Manager, click ‘EnableMotor’ and ‘Start Motion’
27
© 2013
SLVKP = 100, SLVKI = 10Not responsive enough
SLVKP = 2300, SLVKI = 10Too aggressive (noisy)
SLVKP = 400, SLVKI = 10Okay
SLVKP = 400, SLIKI = 200Not responsive enough
SLVKP = 400, SLVKI = 2000Too aggressive (excessive overshoot)
SLVKP = 400, SLVKI = 700Just right
Adjuster Wizard: Position and Velocity Loops
28
© 2013
• Select ‘Position Loop’
• Click ‘Motion Manager Autoset’ and ‘ScopeAutoset’
• Enter the following settings in the MotionManager:
• Click ‘Enable Motor’ then ‘Start Motion’
Adjuster Wizard: Position and Velocity Loops
29
© 2013
Adjuster Wizard: Position and Velocity Loops
• The only variable you need to be concerned with in position loop tuning is Proportional Gain (SLPKP)
• Start SLPKP low and doubleuntil position error is minimizedwhile making sure it is notnoisy at constant velocity.
30
© 2013
SLPKP = 1Not responsive enough
SLPKP = 500Too aggressive (noisy)
SLPKP = 100Position error minimized
Adjuster Wizard: Position and Velocity Loops
31
© 2013
Adjuster Wizard: Save to Flash
Once all previous steps are complete the system is now setup and tuned. Save to flash so it will be available on controller startup.
32