RobotStudio event

How to continuously display numeric data (real time)

Hi all,
1. I would like to display real time position (angle) for example axis 1 of robot as shown in image below.
    But i could not get the real time data. The joint angle (Bar graph) will only update once robot stop movement, Does anybody try this before and have a solution?
2. I could not find a way to display data in a rectangle box instead of using a bar display. Does anybody know?

Comments

  • Micky
    Micky ✭✭✭
    Hello yu1988,

    1. The required values must be provided via RAPID in a persistent data declaration because variables do not generate any data changed event.
    2. You can use the control "tpsLabel" to show the value. If you want to have a reactangle around the label you can change the BorderStyle from "None" to "FixedSingle".

    Best regards
    Micky
  • Hi Mifky,

    Sorry yo let u misunderstand. I can display the current angle position by using PERM. My problem is that, the data will not update continuously while the robot is moving. The data will only updated after robot has stopped.
    For example, I need the value display 90.0, 90.1, 90.2,.......while robot is moving.
  • Micky
    Micky ✭✭✭
    Hello yu1988,

    I think you should create another task that is responsible for reading the angle of the robot in a WHILE loop over and over again and writing it into the persistent.
    Please use a short wait time (about 0.05 - 0.1 s) between the reads to relieve the CPU.

    Best regards
    Micky
  • Hi Micky,

    As my poor understanding about RAPID programming, the source code is running by step.(rolling down). The instruction will stop at line for example MOVEL, how can it go through WHILE loop? Can you give me an example of programming?
  • It's hard to understand what kind of problem you have without seeing the code block with that persistent variable.

    Does your robot support option "Multitasking"? If yes, you can create another task, and write a while loop there. This task and your current task will run in parallel.
    To create new task you go here in FlexPendant: Control Panel -> Configuration -> Topics -> Controller -> Task. Or in RobotStudio: Controller tab -> Configuration Editor -> Controller -> Task, then right-click New Task.
  • Thank Dmitry, I wiil give it a try.