CODESYS - the IEC 61131-3 automation software

Welcome to the official CODESYS Forum by 3S-Smart Software Solutions GmbH | A member of the CODESYS Group
Deutsche Version English version russian version 
It is currently Mon Feb 17, 2020 11:08 am

All times are UTC+01:00

Post new topic  Reply to topic  [ 2 posts ] 
Author Message
PostPosted: Wed Apr 18, 2018 8:39 am 

Joined: Sat Apr 07, 2018 7:29 pm
Posts: 1
Hi Folks,

I'm facing a problem where I have a given axis, it can be driven only in Cyclic Synchronous Position mode. I want it to follow a setpoint position, these setpoints are coming from an external system, their calculation and the communication time isn't deterministic, so once it comes, lets say in 10ms once 12ms, 8ms, 20ms, and so on...

The cycle time is 2ms between the PLC and the servo controller, if I use MC_FollowPosition FB, the servo controller drops me errors with over acceleration and velocity because it tries to carry out the (eg. 12ms) movement in 2ms. My first idea was to do interpolation between two samples, but I'm afraid that with linear interpolation in certain situations the acceleration will be still too high, I will need smoothing between the samples.

My other idea is to make a PID controller inside the PLC, and use MC_FollowVelocity, but because the cycle time with the controller can only be 2ms at the lowest, I'm afraid that in high speeds and accelerations (the system needs to be very responsive) the system becomes unstable and start to oscillate and get inaccurate in high demanding situations.

Do someone have experiences with this kind of controlling, or am I missing some applicable FBs to carry this out? Any ideas are appreciated!

PostPosted: Sat Apr 21, 2018 6:19 am 
Frequent User
Frequent User

Joined: Wed May 04, 2016 6:00 pm
Posts: 288

Try with smc_movecontinuousabsolute. Everytime you recives a new position, you can call it.

It goes to a prdefined position and arrives with a predetermined velocity.

But it seems not easy to use because you need to know the velocity at new point, and it seems that you dont know it.

Good luck

Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 2 posts ] 

All times are UTC+01:00

Who is online

Users browsing this forum: No registered users and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited