Dear Community User! We have started the migration process.
This community is now in READ ONLY mode.
Read more: Important information on the platform change.

cancel
Showing results for 
Search instead for 
Did you mean: 
SOLVED

Sequential Motion Progrogramming

Sequential Motion Progrogramming

bclapperton
New Contributor

We have a customer currently using a Delta-Tau motion controller. I am looking for a way to re-use their motion programs with minimal effort. The motion programs for this are written in a text based language similar to IEC1131 Stuctured text. However, when a motion command is executed, the program stops and waits for the motion to be finished before going on to the next instructions. For example....

   INC          // Set relative mode.
   dwell 50  // dwell time
   X(-200) U(-200)   // Relative move in X and U
   dwell 100   // dwell time

Does CtrlX have a way of doing this?

Does our Blockly App operate in this way? I don't think my customer will want to code in Blockly. However, does our Blockly App talk to an API written in another language eg. Python C++ or even IEC? Or can we call blockly blocks from one of these text based languages?

 

 

 

 

 

3 REPLIES 3

maxielse
Member

For applications like that you can use our python app, which got initially released with the 20.07 release. The Blockly app uses this python app. The official name is rexroth-python.

For your use case you could command something like that in python:

MotionLib.kinCmdMoveLinAbs("Robot", (100.0, -200.0, 400.0) )
time.sleep(0.50)
MotionLib.kinCmdJogIncr("Robot", (0.5,0.5), 5.0)
time.sleep(1.00)

Or you could even write a function in python which checks for the state of the command and just waits till its done or reached its point of destination.

Thanks Maxeilse,

I need to get hold of the Python App for the virtual control. I see there is another post from someone trying to find this.

Just to clarify....

Do the python commands just post a motion command to the buffer then return? Or do they hold up execution until the move is done? I'm happy to wrap them in a function that waits until the motion is done. However, please confirm that the processor task handling system is ok with this. Does the Python runtime execute in a Freewheeling or low priority task?


Do the python commands just post a motion command to the buffer then return? Or do they hold up execution until the move is done?

The python commands just post a motion command to the buffer. If you need a functionality to make sure the command got executed, you must do it by your own. The simple solution is to let the python interpreter sleep like in the example above. The better solution is to save the command ID when posting the command and then poll for the command state DONE. (and obviously sleep between the polling cycles)


However, please confirm that the processor task handling system is ok with this.

It is no problem to poll the state of the command like every 10ms.


Does the Python runtime execute in a Freewheeling or low priority task?

Python runs in its own process.

Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist