RobotStudio event

To modify current position [WebWare SDK]

Options
Hi,

I would like to know if I can modify (and how I can do it ) the robot position using webware SDK software.

Thanks

Comments

  • RussD
    Options
    Use the helper method S4ProgramVariableRead method to load the current value of the PERS data you want to access into a matching S4XXXX object, make the desired changes, and then use S4ProgramVariableWrite to send the data back to the robot. The controller must be in auto for this to work.
    Russell Drown
  • Thanks for your response, but which is PERS data that contains current position of robot?

    object.S4ProgramVariableRead(vname As String, progNo As Integer, value As Object) As Integer

    vname?? -->  what is name I have to put here?

     

  • PerSvensson
    Options

    vname is the variable name. So you can't use inline robtargets, you need to declare the robtargets to be able to modify them.

    Also be aware of that the program execution in a robot controller usally is ahead of the motion of the robot. So modifying robtargets may give unpredicted results.

    Per Svensson
    Robotics and Vision Specialist
    Consat Engineering