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

Display mensage on screen based on the running program

#1
Dear All,
I made a simulation with 7 robots, step by step.

I would like to display a message on the screen according to the program being executed.

Example:
When program RB01 is running - "Robot 1 picking up part"
When program RB02 is running - "Welding part"

Is there any API or Python script to do this?
#2
You can create a custom Add-in that allows you to update the status of your simulation and display the a custom message based on the program that is being executed anytime.

You can find some sample Python code below that will help you retrieve the relevant information:
Code:
RDK = Robolink()
while True:
  # iterate over all programs:
  for prog in RDK.ItemList(ITEM_TYPE_PROGRAM):
    if prog.Busy(): # check if the program is running
      robot = prog.getLink(ITEM_TYPE_ROBOT)
      print("Program %s for robot %s is running" % (prog.Name(), robot.Name())
      break
    time.sleep(1)
  




Users browsing this thread:
1 Guest(s)