Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

ROBODK Line Follow API in Python: Measure Line length

#1
Is there any functionality to get the total length of a curve, or the distance traveled on the curve? For context I'm working on an Automated Fiber Placement project, and it is important to know the total distance traveled before beginning the path for cutting of the tows.
#2
I moved your thread to the API section.
#3
You can useUpdateon a program to retrieve useful program information, including travelled distance and estimated time. More information here:

So you can do something like:

Code:
from robolink import *
RDK = Robolink()
program = RDK.ItemUserPick('Select a program to get estimated travel distance', ITEM_TYPE_PROGRAM)
if not program.Valid():
quit() # the user cancelled the selection

[n_instructions, program_time, program_distance, valid_ratio, readable_msg] = program.Update()
RDK.ShowMessage('Estimated travel distance is %.1f mm' % program_distance)
#4
Thanks, I think this will work




Users browsing this thread:
1 Guest(s)