Multitasking - Linking robot speed to extruder screw speed
I need assistance figuring out how to run this task in the background while another task is running. I know how to read actual robot velocity, I need help figuring out how to read programmed speeddata in order to compare actual velocity against programmed velocity
The basic idea is linking the extruder command to the difference between the actual and commanded robot velocity. This is done so that when the XY motion of the robot motion is accelerating or decelerating, the extruder will also be accelerating instead of running at a constant RPM. This helps significantly on corners.
A quick example: the XY motion is commanded for 10in/s, but is currently at just 5in/s – so currently at 50% of the commanded value. This 50% needs to be mirrored to the extruder. So if the extruder is commanded for 200RPM, it should be set to 100RPM. This calculation and adjustment needs to happen on the PLC in real time.
Any help would be greatly appreciated.
pseudo code attached.