How to use Pop-ups on a Doosan robot

For this tutorial u need:

  • Doosan robot
  • Laptop with DRL studio - Homburger Hub, installed

For creating a Pop up on the teach pendant u can use the command:

tp_popup(string message, int pm_type, int button_type)
Input Name Input Type Description
message string The message to show in the pop_up
pm_type int The message type can only be: DR_PM_MESSAGE, DR_PM_WARNING, DR_PM_ALARM
button_type int The button type can only be 0 (continue or stop button) or 1 (continue button).

For example this is the complete line of code to create an information message pop-up with a button you need to press to continue:

tp_popup('Lookout robot arm starts homing.', pm_type=DR_PM_MESSAGE, button_type=1)

This message will pop up on the teach pendant, after which the robots waits for an input on the teachpendant. In this case button type 1 is only to show a continue button which, when pressed, will continue the code and resume the program.

You can not use the popup function in combination with an if statement as the input. You can use it to give information after an ifstatement. For example we used it to give us a popup message when the camera didn’t detect our workpiece. See this Example:

### function that uses all the other functions to do a compleet solder job ###
def soldeer():
    X_Y_R = get_data_from_cognex('GVC019')
    if (X_Y_R == ['']):
        tp_popup('No mold detected please place mold in the detectable square', pm_type=DR_PM_MESSAGE, button_type=1)
        return 0

For more information we recommand you to look in the Doosan Robotics Programming Manual this manual has all the commands you can use to code the robot.

This was the end of this tutorial, I hope it helped you. Good luck with your project!

If you want to discuss this topic or if you have questions, reply in the comments.

Code Writen by A.Vonk

1 Like