same devices with "direct PWM" (idCmd=0, iqCmd controls torque)

Test Servo, Stage X Parker MX80L, Stage Y Parker MX80L, LS Mecapion rotationstage
This commit is contained in:
2016-12-15 16:31:31 +01:00
parent 5b4848f6dc
commit 87168508e6
4 changed files with 212 additions and 61 deletions

View File

@@ -29,13 +29,27 @@ http://www.inmoco.co.uk/Upload/product/1037_DD_Series_Motors_79.pdf
- Max Current 4.38 Arms - Max Current 4.38 Arms
- 32 pole (16 einraster per rev) - 32 pole (16 einraster per rev)
Servo Test Motor QBL Servo Test Motor QBL 4208-41-04-006
-------------------- -----------------------------------
- 8 pole (4 einraster per rev) 8 pole (4 lock position per rev)
24 V rated voltage
1.79 A rated phase current
5.4 A max peak current
4000 rpm rated speed
1.8 ohm line to line resistance
2.6 mH line to line inductance
2Phase Stepper Test Motor Vextra PK244M 2Phase Stepper Test Motor Vextra PK244M
--------------------------------------- ---------------------------------------
- 200 pole (100 einraster per rev) - 200 pole (100 einraster per rev)
************************ ************************
copy configuration after 'save':
scp -r root@SAROP11-CPPM-MOT6871:/opt/ppmac/usrflash /scratch
restore
scp -r /scratch/usrflash.IDE/* root@SAROP11-CPPM-MOT6871:/opt/ppmac/usrflash
$$$
#4$

83
cfg/dirMicrostep.cfg Normal file
View File

@@ -0,0 +1,83 @@
// Here we use 'real encoder with direct microstepping'. Further the axis are scaled
// in this configuration, the PID gives 'speed' to iqCmd this is multiplied with 0.25 (SlipGain) to result in the phasePos
// The torque is constant given as idCmd
// the PID regulates the position by setting speed, if the motor is not at the desired position
// x einraster == -> x-N and x-S poles =2*x poles -> 1 rev = x*2048 ustep=phase_step
// changing the polarity from S-N-S (one pole cycle) are 2048 phase_step. phase_step is also called ustep
//Mot 1: Rotation stage LS Mecapion MDM-DC06DNC0H 32 poles = 1 rev = 16*2048=32768 phase_step
//Enc 1: Rotation stage LS Mecapion 1 rev = 1048576 enc_steps
//Mot 2: Stage X Parker MX80L D11 25mm one pole cycle = 13mm = 2048 phase_step
//Enc 2: Stage X Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step)
//Mot 3: Stage Y Parker MX80L D11 25mm one pole cycle = 13mm = 2048 phase_step
//Enc 3: Stage Y Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step)
//Mot 4: Test Servo: Trinamic QBL 4208 motor 8 poles 1 rev = 4*2048=8192 phase_step
//Enc 4: Test Servo: Incremental encoder mounted with motor 1 1 rev = 2000 enc count (500 inc_ quadrature encoder)
//Enc 5: Test Servo: Trinamic QBL 4208 hall sensor 1 rev = 24 enc count (hall sensor encoder)
//Mot 6: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 phase_step (2 stepper motor)
//Enc 6: Test Stepper: inc_enc 1 rev = 1600 enc_step
//Mot 7: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 phase_step (2 stepper motor)
//Enc 7: Test Stepper: ssi_enc multiturn 1 rev = 4096 enc_step
$$$***
!common()
//rot stage
//---------
//use 360'000 for 360 deg as motor unit
!encoder_sim(enc=1,tbl=9,mot=9,posSf=360000./32768)
!encoder_biss(enc=1,tbl=1,mot=1,numBits=20,posSf=360000./1048576)
!motor(mot=1,dirCur=200,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=8.,numPhase=3,invDir=True,servoSf=32768/360000.)
//#1j:90000 // = moves 90 deg
//Stage X Parker MX80L
//--------------------
//use um as motor unit
!encoder_sim(enc=2,tbl=10,mot=10,posSf=13000./2048)
!encoder_inc(enc=2,tbl=2,mot=2,posSf=13000./650000)
!motor(mot=2,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True,servoSf=2048/13000.)
//#2j:1000 -> moves 1000um
//Stage Y Parker MX80L
//--------------------
//use um as motor unit
!encoder_sim(enc=3,tbl=11,mot=11,posSf=13000./2048)
!encoder_inc(enc=3,tbl=3,mot=3,posSf=13000./650000)
!motor(mot=3,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True,servoSf=2048/13000.)
//#3j:1000 -> moves 1000um
//Test Servo: Trinamic QBL 4208 motor
//-----------------------------------
//use 360 for 360 deg as motor unit
!encoder_sim(enc=4,tbl=12,mot=12,posSf=360./8192)
!encoder_inc(enc=4,tbl=4,mot=4,posSf=360./2000) // incremental encoder
!encoder_inc(enc=5,tbl=13,mot=13,encctrl=15,posSf=360./24) //Hall sensor encoder
!motor(mot=4,dirCur=400,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=8.,numPhase=3,servoSf=8192/360.)
//#4j:360 -> moves 1 rev
//Test Stepper: Vextra PK244M inc_enc
//-----------------------------------
//use 360 for 360 deg as motor unit
!encoder_sim(enc=6,tbl=14,mot=14,posSf=360./204800)
!encoder_inc(enc=6,tbl=6,mot=6,posSf=360./1600)
!motor(mot=6,dirCur=200,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,servoSf=204800/360.)
//#6j:360 -> moves 1 rev
//Test Stepper: Vextra PK244M abs_enc
//-----------------------------------
//use 360 for 360 deg as motor unit -> JogSpeed=2048./204800*360
!encoder_sim(enc=7,tbl=7,mot=7,posSf=360./204800)
!encoder_ssi(enc=7,tbl=15,mot=15,numBits=25,posSf=360./4096)
!motor(mot=7,dirCur=100,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,servoSf=204800/360.,JogSpeed=3.6)
//#7j:360 -> moves 1 rev

View File

@@ -1,23 +1,39 @@
// Here we use 'real encoder with direct PWM'. Further the axis are scaled
// in this configuration, the PID gives 'torque' to iqCmd.
// the phasePos is received from tne encoder on the motor shaft.
// The idCmd is set to 0
// the PID regulates the position by setting torque, if the motor is not at the desired position
// Compared to 'real encoder with direct microstepping', following main elements have to be reconfigured:
// SlipGain=0 (instead 0.25) ,PhasePosSf= calculated value (instead of 0)
// look also at PwmSf,PhaseMode,PhaseCtrl,
// x einraster == -> x-N and x-S poles =2*x poles -> 1 rev = x*2048 ustep=phase_steps // -> PhasePosSf is calculated as follows: (2048*pole_cycle)/(256*enc_step) = 8*pole_cycle/enc_step
//Mot 1: Rotation stage LS Mecapion MDM-DC06DNC0H 32 poles = 1 rev= 16*2048 usteps // e.g. Motor[x].pPhaseEnc -> PowerBrick[.].Chan[.].PhaseCapt.a
// 1 rev = 8192 phase_step = 4 pole_cycle = 512000 PhaseCapt =256*2000 (256=scaling of encTable, 2000=enc_step/rev)
// PhasePosSf 8*4/2000=0.016
// x einraster == -> x-N and x-S poles =2*x poles -> 1 rev = x*2048 ustep=phase_step
// changing the polarity from S-N-S (one pole cycle) are 2048 phase_step. phase_step is also called ustep
//Mot 1: Rotation stage LS Mecapion MDM-DC06DNC0H 32 poles = 1 rev = 16*2048=32768 phase_step
//Enc 1: Rotation stage LS Mecapion 1 rev = 1048576 enc_steps //Enc 1: Rotation stage LS Mecapion 1 rev = 1048576 enc_steps
//Mot 2: Stage X Parker MX80L D11 25mm one pole cycle = 13mm = 2048usteps //Mot 2: Stage X Parker MX80L D11 25mm one pole cycle = 13mm = 2048 phase_step
//Enc 2: Stage X Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step) //Enc 2: Stage X Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step)
//Mot 3: Stage Y Parker MX80L D11 25mm one pole cycle = 13mm = 2048usteps //Mot 3: Stage Y Parker MX80L D11 25mm one pole cycle = 13mm = 2048 phase_step
//Enc 3: Stage Y Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step) //Enc 3: Stage Y Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step)
//Mot 4: Test Servo: Trinamic QBL 4208 motor 8 poles 1 rev = 8*2048 usteps //Mot 4: Test Servo: Trinamic QBL 4208 motor 8 poles 1 rev = 4*2048=8192 phase_step
//Enc 4: Test Servo: Incremental encoder mounted with motor 1 1 rev = 2000 enc count (500 inc_ quadrature encoder) //Enc 4: Test Servo: Incremental encoder mounted with motor 1 1 rev = 2000 enc count (500 inc_ quadrature encoder)
//Enc 5: Test Servo: Trinamic QBL 4208 hall sensor 1 rev = 24 enc count (hall sensor encoder) //Enc 5: Test Servo: Trinamic QBL 4208 hall sensor 1 rev = 24 enc count (hall sensor encoder)
//Mot 6: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 usteps (2 stepper motor) //Mot 6: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 phase_step (2 stepper motor)
//Enc 6: Test Stepper: inc_enc 1 rev = 1600 enc_step //Enc 6: Test Stepper: inc_enc 1 rev = 1600 enc_step
//Mot 7: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 usteps (2 stepper motor) //Mot 7: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 phase_step (2 stepper motor)
//Enc 7: Test Stepper: ssi_enc multiturn 1 rev = 4096 enc_step //Enc 7: Test Stepper: ssi_enc multiturn 1 rev = 4096 enc_step
$$$*** $$$***
@@ -25,52 +41,95 @@ $$$***
//rot stage //rot stage
//--------- //---------
//use 360'000 for 360 deg as motor unit //use 360'000 for 360 deg as motor unit
//1 rev = 16*2048=32768 phase_step = 1048576 enc_steps
//PhasePosSf= 8*el_cycle/enc_step =8*16/1048576=1./8192
//Motor[1].pPhaseEnc=EncTable[1].pEnc=Acc84B[0].Chan[0].SerialEncDataA.a
// -> PhasePosSf is calculated as follows: (2048*pole_cycle)/(256*enc_step) = 8*pole_cycle/enc_step
//PhasePosSf = (2048*pole_cycle)/(SerialEncDataA)=8*16/1048576=1/32
!encoder_sim(enc=1,tbl=9,mot=9,posSf=360000./32768) !encoder_sim(enc=1,tbl=9,mot=9,posSf=360000./32768)
!encoder_biss(enc=1,tbl=1,mot=1,numBits=20,posSf=360000./1048576) !encoder_biss(enc=1,tbl=1,mot=1,numBits=20,posSf=360000./1048576)
!motor(mot=1,dirCur=200,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=8.,numPhase=3,invDir=True,servoSf=32768/360000.) Motor[1].pPhaseEnc=Acc84B[0].Chan[0].SerialEncDataA.a
//#1j:90000 // = moves 90 deg //Motor[1].pAbsPhasePos=Acc84B[0].Chan[0].SerialEncDataA.a
!motor_servo(mot=1,ctrl='ServoCtrl',Kp=0.8,Kvfb=20,Ki=0.001,Kvff=40,Kaff=0,MaxInt=1000)
!motor(mot=1,dirCur=0,contCur=1000,peakCur=2000,timeAtPeak=1,IiGain=1.5,IpfGain=0,IpbGain=3,JogSpeed=360.,numPhase=3,invDir=True,servo=None,PhasePosSf=1./8192,PhaseFindingDac=1000,PhaseFindingTime=50,SlipGain=0,AdvGain=0,PwmSf=10000,FatalFeLimit=3000,WarnFeLimit=1000,InPosBand=10)
//Stage X Parker MX80L //Stage X Parker MX80L
//-------------------- //--------------------
//Motor[2].pPhaseEnc -> PowerBrick[0].Chan[1].PhaseCapt.a
// 1 el_step = 13mm = 2048 phase_step = 166400000 PhaseCapt =256*650000 (256=scaling of encTable)
// -> PhasePosSf=(2048*el_cycle)/(256*enc_step) = 8*el_cycle/enc_step =2048*1/(256*650000)=8*1/650000=1./81250=1.23077e-05
//2048 phase_step =166400000 PhaseCapt -> PhasePosSf = 2048/166400000= 2048./(256*650000)
$$$***
!common()
//use um as motor unit
!encoder_sim(enc=2,tbl=10,mot=10,posSf=13000./2048) !encoder_sim(enc=2,tbl=10,mot=10,posSf=13000./2048)
!encoder_inc(enc=2,tbl=2,mot=2,posSf=13000./650000) !encoder_inc(enc=2,tbl=2,mot=2,posSf=13000./650000)
!motor(mot=2,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True,servoSf=2048/13000.) !motor_servo(mot=2,ctrl='ServoCtrl',Kp=16,Kvfb=800,Ki=0.001,Kvff=1000,Kaff=0,MaxInt=1000)
//#2j:1000 -> moves 1000um !motor(mot=2,dirCur=0,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=10.,numPhase=3,invDir=True,servo=None,PhasePosSf=1./81250,PhaseFindingDac=100,PhaseFindingTime=50,SlipGain=0,AdvGain=0,PwmSf=10000,FatalFeLimit=200,WarnFeLimit=100,InPosBand=2)
//Stage Y Parker MX80L //Stage Y Parker MX80L
//-------------------- //--------------------
//Motor[3].pPhaseEnc -> PowerBrick[0].Chan[1].PhaseCapt.a
// 1 el_step = 13mm = 2048 phase_step = 166400000 PhaseCapt =256*650000 (256=scaling of encTable)
// -> PhasePosSf=(2048*el_cycle)/(256*enc_step) = 8*el_cycle/enc_step =2048*1/(256*650000)=8*1/650000=1./81250=1.23077e-05
//2048 phase_step =166400000 PhaseCapt -> PhasePosSf = 2048/166400000= 2048./(256*650000)
!encoder_sim(enc=3,tbl=11,mot=11,posSf=13000./2048) !encoder_sim(enc=3,tbl=11,mot=11,posSf=13000./2048)
!encoder_inc(enc=3,tbl=3,mot=3,posSf=1.,posSf=13000./650000) !encoder_inc(enc=3,tbl=3,mot=3,posSf=13000./650000)
//!motor(mot=3,dirCur=0,contCur=800,peakCur=2400,timeAtPeak=.5,JogSpeed=32.,numPhase=3) !motor_servo(mot=3,ctrl='ServoCtrl',Kp=10,Kvfb=220,Ki=0.001,Kvff=240,Kaff=0,MaxInt=1000)
!motor(mot=3,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True,servoSf=2048/13000.) !motor(mot=3,dirCur=0,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=10.,numPhase=3,invDir=True,servo=None,PhasePosSf=1./81250,PhaseFindingDac=100,PhaseFindingTime=50,SlipGain=0,AdvGain=0,PwmSf=10000,FatalFeLimit=2000,WarnFeLimit=100,InPosBand=2)
//#3j:1000 -> moves 1000um
//Test Servo: Trinamic QBL 4208 motor //Test Servo: Trinamic QBL 4208 motor
//----------------------------------- //-----------------------------------
//use 360 for 360 deg as motor unit //use 360 for 360 deg as motor unit
//Motor[4].pPhaseEnc -> PowerBrick[0].Chan[3].PhaseCapt.a
// 1 rev = 8192 phase_step = 512000 PhaseCapt =256*2000 (256=scaling of encTable, 2000=enc_step/rev)
// -> PhasePosSf=8192/512000 = 0.016 = (2048*el_cycle)/(256*enc_step) = 8*el_cycle/enc_step
!encoder_sim(enc=4,tbl=12,mot=12,posSf=360./8192) !encoder_sim(enc=4,tbl=12,mot=12,posSf=360./8192)
!encoder_inc(enc=4,tbl=4,mot=4,posSf=360./2000) // incremental encoder !encoder_inc(enc=4,tbl=4,mot=4,posSf=360./2000) // incremental encoder
!encoder_inc(enc=5,tbl=13,mot=13,encctrl=15,posSf=360./24) //Hall sensor encoder !encoder_inc(enc=5,tbl=13,mot=13,encctrl=15,posSf=360./24) //Hall sensor encoder
!motor(mot=4,dirCur=400,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=8.,numPhase=3,servoSf=8192/360.) //!motor_servo(mot=4,ctrl='ServoCtrl',Kp=40,Kvfb=715.17053,Kvff=715.17053,Kaff=63279.855,Ki=5.9003407e-5,MaxInt=1500,MaxPosErr=1333.356) //tweaked parameters from IDE
!motor_servo(mot=4,ctrl='ServoCtrl',Kp=30.8,Kvfb=461.,Kvff=461,Kaff=3522,Ki=0.0e-5,MaxInt=1500,MaxPosErr=1333.356) //tweaked parameters from IDE
!motor(mot=4,dirCur=0,contCur=1790,peakCur=5400,timeAtPeak=.5,JogSpeed=8.,numPhase=3,servo=None,PhasePosSf=0.016,SlipGain=0,PhaseFindingTime=50.0,PhaseFindingDac=90.0)
//Further tweaks to optimize positioning
//Motor[4].Servo.BreakPosErr=4
//Motor[4].Servo.Kbreak=5
//Motor[4].Servo.OutDbOn=.2
//Motor[4].Servo.OutDbOff=.3
//Motor[4].Servo.OutDbOn=0
//Motor[4].Servo.OutDbOff=.3
//#4j:360 -> moves 1 rev //#4j:360 -> moves 1 rev
// 1 rev = 8 poles (4 lock pos) = 4*2048 ustep=phase_step
// 1 rev = 2000 enc count (500 inc_ quadrature encoder)
// 1 rev = 24 enc count (hall sensor encoder)
//Test Stepper: Vextra PK244M inc_enc //Test Stepper: Vextra PK244M inc_enc
//----------------------------------- //-----------------------------------
//use 360 for 360 deg as motor unit //use 360 for 360 deg as motor unit
// Motor[6].pPhaseEnc -> PowerBrick[1].Chan[1].PhaseCapt.a
//3.6deg=2048 phase_step -> 360 deg= 204800 phase_step
// 1 rev = 409600 = PhaseCapt =256*1600 (256=scaling of encTable, 1600=enc_step/rev)
// -> PhasePosSf=204800/409600 = 0.5 = (2048*el_cycle)/(256*enc_step) = 32*el_cycle/enc_step
!encoder_sim(enc=6,tbl=14,mot=14,posSf=360./204800) !encoder_sim(enc=6,tbl=14,mot=14,posSf=360./204800)
!encoder_inc(enc=6,tbl=6,mot=6,posSf=360./1600) !encoder_inc(enc=6,tbl=6,mot=6,posSf=360./1600)
!motor(mot=6,dirCur=200,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,servoSf=204800/360.) !motor_servo(mot=6,ctrl='ServoCtrl',Kp=40,Kvfb=715.17053,Kvff=715.17053,Kaff=63279.855,Ki=5.9003407e-5,MaxInt=1500,MaxPosErr=1333.356)
!motor(mot=6,dirCur=0,contCur=800,peakCur=1000,timeAtPeak=1,numPhase=2,invDir=False,servo=None,PhasePosSf=0.5,SlipGain=0,PhaseFindingTime=50.0,PhaseFindingDac=400.0)
Motor[6].JogSpeed=0.32
Motor[6].FatalFeLimit=90
!!!!! THIS WORKS (but needs slow speed to never get out of sync! if it gets out of sync it runs in the wrong direction until following error)
//Motor[6].PhaseFindingTime=50.0;Motor[6].PhaseFindingDac=400.0 //Four Guess Phasing Search
//#6$
//Motor[6].PhaseFindingTime=260.0;Motor[6].PhaseFindingDac=400.0 //stepper-motor phasing-search
//#6$
//#6j:360 -> moves 1 rev //#6j:360 -> moves 1 rev
// 1 rev = 200 poles = 100 lock pos = 100*2048 ustep=phase_step //the phasing is very critical with stepper motors
// 1 rev = 1600 enc count (400 inc_ quadrature encoder)
//Test Stepper: Vextra PK244M abs_enc //Test Stepper: Vextra PK244M abs_enc
//----------------------------------- //-----------------------------------
@@ -79,7 +138,4 @@ $$$***
!encoder_ssi(enc=7,tbl=15,mot=15,numBits=25,posSf=360./4096) !encoder_ssi(enc=7,tbl=15,mot=15,numBits=25,posSf=360./4096)
!motor(mot=7,dirCur=100,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,servoSf=204800/360.,JogSpeed=3.6) !motor(mot=7,dirCur=100,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,servoSf=204800/360.,JogSpeed=3.6)
//#7j:360 -> moves 1 rev //#7j:360 -> moves 1 rev
// 1 rev = 4096 enc count = 204800 ustep=phase_step = 360 deg

View File

@@ -1,41 +1,44 @@
//Mot 1: Rotation stage LS Mecapion MDM-DC06DNC0H // Here we use 'simulated encoder with direct microstepping'
//Enc 1: Rotation stage LS Mecapion // in this configuration, the PID gives 'speed' to iqCmd this is multiplied with 0.25 (SlipGain) to result in the phasePos
// The torque is constant given as idCmd
// the PID does no regulation, as a real encoder is not used
//Mot 2: Stage X Parker MX80L D11 25mm // x einraster == -> x-N and x-S poles =2*x poles -> 1 rev = x*2048 ustep=phase_step
//Enc 2: Stage X Parker MX80L D11 inc_enc 20nm // changing the polarity from S-N-S (one pole cycle) are 2048 phase_step. phase_step is also called ustep
//Mot 3: Stage Y Parker MX80L D11 25mm //Mot 1: Rotation stage LS Mecapion MDM-DC06DNC0H 32 poles = 1 rev = 16*2048=32768 phase_step
//Enc 3: Stage Y Parker MX80L D11 inc_enc 20nm //Enc 1: Rotation stage LS Mecapion 1 rev = 1048576 enc_steps
//Mot 4: Test Servo: Trinamic QBL 4208 motor //Mot 2: Stage X Parker MX80L D11 25mm one pole cycle = 13mm = 2048 phase_step
//Enc 4: Test Servo: Incremental encoder mounted with motor 1 //Enc 2: Stage X Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step)
//Enc 5: Test Servo: Trinamic QBL 4208 hall sensor
//Mot 6: Test Stepper: Vextra PK244M //Mot 3: Stage Y Parker MX80L D11 25mm one pole cycle = 13mm = 2048 phase_step
//Enc 6: Test Stepper: inc_enc //Enc 3: Stage Y Parker MX80L D11 inc_enc 20nm one pole cycle = 13mm = 650000 enc_step (20nm/enc_step)
//Mot 7: Test Stepper: Vextra PK244M //Mot 4: Test Servo: Trinamic QBL 4208 motor 8 poles 1 rev = 4*2048=8192 phase_step
//Enc 7: Test Stepper: ssi_enc multiturn //Enc 4: Test Servo: Incremental encoder mounted with motor 1 1 rev = 2000 enc count (500 inc_ quadrature encoder)
//Enc 5: Test Servo: Trinamic QBL 4208 hall sensor 1 rev = 24 enc count (hall sensor encoder)
//Mot 6: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 phase_step (2 stepper motor)
//Enc 6: Test Stepper: inc_enc 1 rev = 1600 enc_step
//Mot 7: Test Stepper: Vextra PK244M 200 poles 1 rev = 100*2048 phase_step (2 stepper motor)
//Enc 7: Test Stepper: ssi_enc multiturn 1 rev = 4096 enc_step
$$$*** $$$***
!common() !common()
//rot stage //rot stage
//--------- //---------
!encoder_sim(enc=1,tbl=1,mot=1) !encoder_sim(enc=1,tbl=1,mot=1)
!encoder_biss(enc=1,tbl=9,mot=9,numBits=20,posSf=1.) !encoder_biss(enc=1,tbl=9,mot=9,numBits=20,posSf=1.)
//real limits in closed loop (does not work with simulated encoder)
//!motor(mot=5,dirCur=0,contCur=1460,peakCur=4380,timeAtPeak=.5,JogSpeed=32.,numPhase=3)
!motor(mot=1,dirCur=200,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=8.,numPhase=3,invDir=True) !motor(mot=1,dirCur=200,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=8.,numPhase=3,invDir=True)
//16 einraster -> 16N 16S poles -> 1 rev = 16*2048 //#1j:32768 = 1 rev
//#1j:32768 // = 1 rev = 1048576 enc_steps
//Stage X Parker MX80L //Stage X Parker MX80L
//-------------------- //--------------------
!encoder_sim(enc=2,tbl=2,mot=2) !encoder_sim(enc=2,tbl=2,mot=2)
!encoder_inc(enc=2,tbl=10,mot=10,posSf=1.) !encoder_inc(enc=2,tbl=10,mot=10,posSf=1.)
//!motor(mot=2,dirCur=0,contCur=800,peakCur=2400,timeAtPeak=.5,JogSpeed=32.,numPhase=3)
!motor(mot=2,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True) !motor(mot=2,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True)
//#2j:2048 -> moves one pole cycle= 650000 enc_step =13mm (Electrical Pitch in MX80 doc) //#2j:2048 -> moves one pole cycle= 650000 enc_step =13mm (Electrical Pitch in MX80 doc)
@@ -45,7 +48,6 @@ $$$***
//-------------------- //--------------------
!encoder_sim(enc=3,tbl=3,mot=3) !encoder_sim(enc=3,tbl=3,mot=3)
!encoder_inc(enc=3,tbl=11,mot=11,posSf=1.) !encoder_inc(enc=3,tbl=11,mot=11,posSf=1.)
//!motor(mot=3,dirCur=0,contCur=800,peakCur=2400,timeAtPeak=.5,JogSpeed=32.,numPhase=3)
!motor(mot=3,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True) !motor(mot=3,dirCur=400,contCur=500,peakCur=2400,timeAtPeak=1,IiGain=1,IpfGain=0,IpbGain=2,JogSpeed=1.,numPhase=3,invDir=True)
//#3j:2048 -> moves one pole cycle= 650000 enc_step =13mm (Electrical Pitch in MX80 doc) //#3j:2048 -> moves one pole cycle= 650000 enc_step =13mm (Electrical Pitch in MX80 doc)
@@ -56,14 +58,10 @@ $$$***
!encoder_sim(enc=4,tbl=4,mot=4) !encoder_sim(enc=4,tbl=4,mot=4)
!encoder_inc(enc=4,tbl=12,mot=12,posSf=1.) // incremental encoder !encoder_inc(enc=4,tbl=12,mot=12,posSf=1.) // incremental encoder
!encoder_inc(enc=5,tbl=13,mot=13,encctrl=15) //encctrl=11 Hall sensor encoder !encoder_inc(enc=5,tbl=13,mot=13,encctrl=15) //encctrl=11 Hall sensor encoder
//real limits in closed loop (does not work with simulated encoder)
//!motor(mot=4,dirCur=0,contCur=1790,peakCur=5400,timeAtPeak=.5,JogSpeed=32.,numPhase=3)
!motor(mot=4,dirCur=200,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=32.,numPhase=3) !motor(mot=4,dirCur=200,contCur=500,peakCur=1000,timeAtPeak=.5,JogSpeed=32.,numPhase=3)
//#4j:2048 -> moves one pole cycle= 90deg -> 8 poles
//#4j:8192 -> moves 1 rev //#4j:8192 -> moves 1 rev
// 1 rev = 2000 enc count (500 inc_ quadrature encoder) //#4j:2048 -> moves one pole cycle= 90deg -> 8 poles
// 1 rev = 24 enc count (hall sensor encoder)
//Test Stepper: Vextra PK244M inc_enc //Test Stepper: Vextra PK244M inc_enc
//----------------------------------- //-----------------------------------
@@ -71,8 +69,8 @@ $$$***
!encoder_sim(enc=6,tbl=6,mot=6) !encoder_sim(enc=6,tbl=6,mot=6)
!encoder_inc(enc=6,tbl=14,mot=14) !encoder_inc(enc=6,tbl=14,mot=14)
!motor(mot=6,dirCur=100,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,JogSpeed=2048) !motor(mot=6,dirCur=100,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,JogSpeed=2048)
//#6j:2048 ->moves one pole cycle -> #6j:204800 moves 1 rev //#6j:204800 moves 1 rev
// 1 rev = 1600 enc count (400 inc_ quadrature encoder) //#6j:2048 ->moves one pole cycle
//Test Stepper: Vextra PK244M abs_enc //Test Stepper: Vextra PK244M abs_enc
@@ -80,5 +78,5 @@ $$$***
!encoder_sim(enc=7,tbl=7,mot=7) !encoder_sim(enc=7,tbl=7,mot=7)
!encoder_ssi(enc=7,tbl=15,mot=15,numBits=25) !encoder_ssi(enc=7,tbl=15,mot=15,numBits=25)
!motor(mot=7,dirCur=100,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,JogSpeed=2048) !motor(mot=7,dirCur=100,contCur=400,peakCur=600,timeAtPeak=1,numPhase=2,invDir=False,JogSpeed=2048)
//#7j:2048 ->moves one pole cycle -> #7j:204800 moves 1 rev //#7j:204800 moves 1 rev
// 1 rev = 4096 enc count //#7j:2048 ->moves one pole cycle