How to control an Accopos P3 servo with an external encoder

Hello

I want to get information from an external encoder and use this information to control an Accopos P3 servo motor with both mathematical calculations and encoders. How can I do this and with which commands?

Hi @eem.ferhat ,

actually we have few posts already in the Community for the external encoder, I recommend this one: ACOPOS 2 encoder , in particular the answer from @christoph.hilchenbac and Two encoder control configuration (for all ACOPOS types) posted by @antonio.rapha

Ciao
Valerio

1 Like

Instead of dealing with the servo motors themselves, I prefer to focus on the PLC’s high-speed counters and encoder cables, connecting them to these high-speed counters and controlling them from there.

Hello,

You can use the PLC to generate a Target-Position for you Axis. As a Source for your calculations you can use any Information connected to the PLC.
To send the Calculated Target-Position to the ACOPOS you can use the Functionblock MC_BR_MoveCyclicPosition.
You only have to consider that the Target-Positons should be jumpfree, and matching the dynamic of the servodrive.

Greetings
Michael

1 Like

So, which command can I use to read encoder information from the PLC’s high-speed input?

Hello,

Which IO-Module you will use?
For X20-IO-Modules there is typicaly only an IO-Mapping for the cyclic Data.

Greetings
Michael

1 Like

I use the X20DMF320.

Hello,

If you want to use the ABR-Encoder Input of the Module Pin 1,3,5

You have to set up the configuration of the IO-Module in Automation Studio.

The Documentation for this can be found in section Registers of the IO-Module
X20DMF320 - Counter Configurations

IO-Mapping will then Show a cyclic Datapoint for the Counter Value.

Greetings
Michael

2 Likes

What is latch mode? And why do I choose high or low for the latch level change?

Hi @eem.ferhat ,
I have found this information in the help regarding latch function:

Ciao
Valerio

1 Like


Thanks, but I didn’t quite understand this information. Also, to monitor each of the A, B, and Z phases from the counter inside the DMF320, do we need to use Array? Or will it only show a single channel?

Hello,

The Latch is a functionality to copy the current counter value to a separate Datapoint if a event happens. A typical example would be to latch the Position if the Z (R)- Signal is triggered.

If Z has Positive Edge then copy CounterValue to LatchValue.



The Module will still show Digital Input Values of Input 1,3,5 with “DigitalInputxx” on the IO-Mapping, but due to the refreshrate of the filedbus you will only see values in Fieldbus intervall.
This is why the Counter uses a special electronic couter on the IO-Module to not miss the high frequency counter signals.

There is only one output in INT Format for the ABR Counter Value.

Greetings
Michael

Thank you
Michael Bertsch