Delta Tau Forums

Full Version: ECAT Beckhoff EL7031 stepper drive - unstable Amp-Enable on open/closed loop cmd
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi everybody!

Testing an EL7031, a stepper drive terminal, everything works so far until I added that ECAT-drive to PPMAC-motor #8, concerning Motor[8].AmpEna:
Entering "#8j/" or "#8out0" will enable the drive and power the motor just for the length of Motor[8].EcatAmpFaultLimit. Meanwhile Motor[8].AmpEna does not go to 1 a single time - and so at the end causes an amp-fault-indication at the status for motor #8.
By hand I can enable the drive steadily by writing to ECAT[0].IO[2].Data=1 as long until I reset it back to 0. I can move the motor forth and back by writing to another register (drive is in Pos-Mode). No deal.
I tried everything around Motor[8].pAmpEnable, AmpEnableBit... no chance.

Apparently it runs on MDP 703:
https://download.beckhoff.com/download/d...70x1en.pdf

Does anybody has an idea about that issue?
Probably this is a terminal never been tested with PPMAC - nevertheless, since this is the only missing link, does anybody know a way to fix this so I can implement that ECAT-drive entirely as a PPMAC-motor
Quote:Entering "#8j/" or "#8out0" will enable the drive and power the motor just for the length of Motor[8].EcatAmpFaultLimit. Meanwhile Motor[8].AmpEna does not go to 1 a single time - and so at the end causes an amp-fault-indication at the status for motor #8.
This typically indicates that there is a fault on the drive side. I would at least check the device for errors.

Quote:By hand I can enable the drive steadily by writing to ECAT[0].IO[4].Data=1 as long until I reset it back to 0. I can move the motor forth and back by writing to another register (drive is in Pos-Mode). No deal.
And this makes it hard to view the issue as only a drive problem. It sounds like the process where the drive tells PMAC it has enabled and cleared faults isn't happening before the timeout.
Does it look like Motor[8].pAmpFault is set to the status word?
I realized my post might be confusing so I attached a screenshot. Is the Amp Fault Input set to the status word for the correct drive like in the picture?
Hi Eric!
There is no way to integrate the ECAT-drive EL7031 using motor topology.
See thread: http://forums.deltatau.com/showthread.php?tid=3056

I did a plot where you can see, Motor8].AmpEna remains 0 all the time.
The same for ECAT[0].IO[4101].Data whereto Motor[8].pAmpFault is pointing to.

Here the most important settings for motor #8:
Motor[8].pDac=ECAT[0].IO[5].Data.a
Motor[8].AmpEnableBit=0
Motor[8].pAmpEnable=ECAT[0].IO[2].Data.a
Motor[8].AmpFaultBit=0
Motor[8].pAmpFault=ECAT[0].IO[4101].Data.a
Motor[8].EcatAmpFaultLimit=$500

Here PDO-Mapping ECATconfig.cfg:
ECAT[0].IO[4098].BitLength=1
ECAT[0].IO[4098].Index=24592
ECAT[0].IO[4098].SubIndex=1
ECAT[0].IO[4098].Input=1
ECAT[0].IO[4098].Offset=6
ECAT[0].IO[4098].BitPosition=0
ECAT[0].IO[4098].Slave=2
ECAT[0].IO[4099].BitLength=1
ECAT[0].IO[4099].Index=24592
ECAT[0].IO[4099].SubIndex=2
ECAT[0].IO[4099].Input=1
ECAT[0].IO[4099].Offset=6
ECAT[0].IO[4099].BitPosition=1
ECAT[0].IO[4099].Slave=2
ECAT[0].IO[4100].BitLength=1
ECAT[0].IO[4100].Index=24592
ECAT[0].IO[4100].SubIndex=3
ECAT[0].IO[4100].Input=1
ECAT[0].IO[4100].Offset=6
ECAT[0].IO[4100].BitPosition=2
ECAT[0].IO[4100].Slave=2
ECAT[0].IO[4101].BitLength=1
ECAT[0].IO[4101].Index=24592
ECAT[0].IO[4101].SubIndex=4
ECAT[0].IO[4101].Input=1
ECAT[0].IO[4101].Offset=6
ECAT[0].IO[4101].BitPosition=3
ECAT[0].IO[4101].Slave=2
ECAT[0].IO[4102].BitLength=1
ECAT[0].IO[4102].Index=24592
ECAT[0].IO[4102].SubIndex=5
ECAT[0].IO[4102].Input=1
ECAT[0].IO[4102].Offset=6
ECAT[0].IO[4102].BitPosition=4
ECAT[0].IO[4102].Slave=2
ECAT[0].IO[4103].BitLength=1
ECAT[0].IO[4103].Index=24592
ECAT[0].IO[4103].SubIndex=6
ECAT[0].IO[4103].Input=1
ECAT[0].IO[4103].Offset=6
ECAT[0].IO[4103].BitPosition=5
ECAT[0].IO[4103].Slave=2
ECAT[0].IO[4104].BitLength=1
ECAT[0].IO[4104].Index=24592
ECAT[0].IO[4104].SubIndex=7
ECAT[0].IO[4104].Input=1
ECAT[0].IO[4104].Offset=6
ECAT[0].IO[4104].BitPosition=6
ECAT[0].IO[4104].Slave=2
ECAT[0].IO[4105].BitLength=1
ECAT[0].IO[4105].Index=24592
ECAT[0].IO[4105].SubIndex=12
ECAT[0].IO[4105].Input=1
ECAT[0].IO[4105].Offset=7
ECAT[0].IO[4105].BitPosition=3
ECAT[0].IO[4105].Slave=2
ECAT[0].IO[4106].BitLength=1
ECAT[0].IO[4106].Index=24592
ECAT[0].IO[4106].SubIndex=13
ECAT[0].IO[4106].Input=1
ECAT[0].IO[4106].Offset=7
ECAT[0].IO[4106].BitPosition=4
ECAT[0].IO[4106].Slave=2
ECAT[0].IO[4107].BitLength=1
ECAT[0].IO[4107].Index=24592
ECAT[0].IO[4107].SubIndex=14
ECAT[0].IO[4107].Input=1
ECAT[0].IO[4107].Offset=7
ECAT[0].IO[4107].BitPosition=5
ECAT[0].IO[4107].Slave=2
ECAT[0].IO[4108].BitLength=1
ECAT[0].IO[4108].Index=24592
ECAT[0].IO[4108].SubIndex=16
ECAT[0].IO[4108].Input=1
ECAT[0].IO[4108].Offset=7
ECAT[0].IO[4108].BitPosition=7
ECAT[0].IO[4108].Slave=2
ECAT[0].IO[4109].BitLength=32
ECAT[0].IO[4109].Index=24592
ECAT[0].IO[4109].SubIndex=21
ECAT[0].IO[4109].Input=1
ECAT[0].IO[4109].Offset=8
ECAT[0].IO[4109].BitPosition=0
ECAT[0].IO[4109].Slave=2
ECAT[0].IO[2].BitLength=1
ECAT[0].IO[2].Index=28688
ECAT[0].IO[2].SubIndex=1
ECAT[0].IO[2].Input=0
ECAT[0].IO[2].Offset=6
ECAT[0].IO[2].BitPosition=0
ECAT[0].IO[2].Slave=2
ECAT[0].IO[3].BitLength=1
ECAT[0].IO[3].Index=28688
ECAT[0].IO[3].SubIndex=2
ECAT[0].IO[3].Input=0
ECAT[0].IO[3].Offset=6
ECAT[0].IO[3].BitPosition=1
ECAT[0].IO[3].Slave=2
ECAT[0].IO[4].BitLength=1
ECAT[0].IO[4].Index=28688
ECAT[0].IO[4].SubIndex=3
ECAT[0].IO[4].Input=0
ECAT[0].IO[4].Offset=6
ECAT[0].IO[4].BitPosition=2
ECAT[0].IO[4].Slave=2
ECAT[0].IO[5].BitLength=16
ECAT[0].IO[5].Index=28688
ECAT[0].IO[5].SubIndex=33
ECAT[0].IO[5].Input=0
ECAT[0].IO[5].Offset=8
ECAT[0].IO[5].BitPosition=0
ECAT[0].IO[5].Slave=2


With Motor[8].EcatAmpFaultLimit=$500 (@4kHz RTI it is 320 ms) the plot looks like as follows:
ECAT[0].IO[2].Data which is bitlenght 1 in the pdo-mapping goes 14 - 7 - 15 - 14 - at the end is set during 640 ms to 1 but then reset again.
The drive itself also gets enable for about that time (640 ms).
Manual setup of Acontis EtherCAT motors may be a bit complicated simply because it is unfamiliar. If you want to go down this route, I would suggest setting up another EtherCAT motor and taking a full configuration to compare the motor parts against. If you don't have another ecat drive I can do this with a 1S and email the results.

Quote:Motor[8].AmpEnableBit=0
Motor[8].AmpFaultBit=0
You might try setting these bit numbers. I believe they are both ignored once PMAC sees the address is in an ethercat range, but the IDE does set them.

I believe there may be something else you can do to the drive to get it to show up as a servo drive.
Quote:Manual setup of Acontis EtherCAT motors may be a bit complicated...
I did setup EL7211 manually - and it runs! I "copied" it from a 1S-drive.
But in all cases, if both, Motor[x].AmpEnableBit and Motor[x].AmpFaultBit are not set right, it would not run - in contratiction to the manual...
Quote:I believe there may be something else you can do to the drive to get it to show up as a servo drive.
Well, let me know Eric!!

At last, I guess, the MDP703, which this EL7031 runs on, causes the problems (it has not MDP742 nor DS402). Therein I only get the status bitwise - check out the pic with the pdo-mapping above.
Quote:I did setup EL7211 manually - and it runs! I "copied" it from a 1S-drive.
But in all cases, if both, Motor[x].AmpEnableBit and Motor[x].AmpFaultBit are not set right, it would not run - in contratiction to the manual...
These were 0 when you posted settings. Has changing them improved the drive's behavior.

Quote:Well, let me know Eric!!
I was referring to the other thread. I'm not familiar with switching the EL7031 between appearing as IO and drive, so I was letting Alex handle it.
http://forums.deltatau.com/showthread.php?tid=3073
On the EL7211 and 1S-drive those 2 bits (AmpFault, AmpEna) are important to set them right.
On the EL7031 I have to set them to 0 since related PDOs are bit-wide.But still, the Amp-Enable Motor[8].AmpEna does not come up at all!!
Quote:On the EL7031 I have to set them to 0 since related PDOs are bit-wide.
That sounds like a problem. The EtherCAT standard has AmpFaultBit as bit 3, which the firmware should automatically use when an EtherCAT address is chosen for Motor[x].pAmpFault. This most likely means your ECAT device still needs to be set up as a drive.

Is your AmpEnable PDO only a single bit?
Yes, AmpEnable PDO is a single bit in 0x7010:01 (all pdo-mappings are shown in the pic above)

You did not tell me yet how to set up the drive so it shows up as servo drive in the motor topology view
The fact that it isn't showing up as a drive is most likely related to the fact that we can't properly read form the device with the ecattypedsdo command--for now, I'd say let's focus on that issue. The IDE needs to use that command to determine what slaves are present and potential drives.
Hi Alex!
After changing phase/servo/RTI from 32/16/4 to 8/2/2 ecattypedsdo() work fine.

So back to the drive-enable-fail - which still is present.
I set Motor[8].EcatAmpFaultLimit=$1000
Then on a "#8j/" the motor produces torque after about 2s for about 2s. Motor[8].AmpEna never get set.
Can you offer some quick fix for this and how long will it take - day/week/month/year/ever?!
I apparently misread--because there were some mentions to the EL7211 here, I assumed this thread was referring to the same slave device as the other thread and did not notice at first that it is (primarily) about the EL7031.

For DS402, the process of enabling the drive is a state machine that sets a register to specific values, then waits for the drive to signal via its status register that it is in the correct state. As such, we set the register specified by Motor[x].pAmpEnable equal to a specific value, then wait for the register specified by Motor[x].pAmpFault to go to a specific corresponding value. Seeing as your drive does not follow DS402 and will only accept one bit to enable, this won't work.

Because the slave does not support DS402, our firmware doesn't really support it as a drive. It may be possible to use it anyways, but most likely, you will need to point pAmpEnable to a scratch register such as Sys.Idata[10], then manually copy that into 0x7010:01--this will trick our firmware into simply toggling a bit true/false, rather than going through the state machine required to enable an EtherCAT slave.


Putting all this together, this most likely means your settings will look something like:

Motor[1].pDac = <Target Register>
Motor[1].pAmpEnable = Sys.Idata[10].a
Motor[1].AmpEnabl0eBit = 0 //Assuming you want to toggle Bit 0 of the EtherCAT register to enable
Motor[1].pAmpFault = <Fault Bit over EtherCAT>
Motor[1].AmpFaultBit = 0 //Assuming Bit0 of the EtherCAT register will toggle when you encounter a fault
Motor[1].pEnc = EncTable[1].a
EncTable[1].pEnc = <Feedback Register over ECAT>

OPEN PLC AmpEnableCopyPLC
<Amp Enable over EtherCAT> = Sys.Idata[10]
CLOSE

ENABLE PLC AmpEnableCopyPLC


That PLC would need to stay running at all times so that you can properly enable/disable the slave. There are other ways to do it, too (a user servo routine would be synchronous to the EtherCAT clock, for instance), but that would be a simpler way.

Again, I can't promise that this *will* work--officially, this drive does not use a protocol that we support. However, this would probably be what I would try myself.
Hey, Alex, great, this is all it needed. Now the stepper runs as PPMAC motor #8 as usually known!
Thank you for your troubles!!