Home Programming

Discussion

Left ArrowBack to discussions page
AkoesslerAkoessler Posts: 1 Recruit
Hello,

My goal is to use force control along a specific trajectory defined. To this end I mounted an FT300 sensor on the robot. Using structures given by the URCap ("force control" and "multipoint trajectory") for preliminary experiments, the desired behaviour can be reached.
On to the next step : the trajectory is in reality time-varying and defined through vision of certain features. It should allow to set the waypoints inside the "multipoint trajectory".
The problem that I am faced with is that I cannot access the values of the WPs in the program. In particular, I'd like to use URScript and socket communication to modify WPs dynamically, but it seems that WP values are not hardcoded in the generated script file. Instead, something called node_rpc_server is used.

Here is a bit of code to highlight what I am talking about. See how WP value is hardcoded in the movej() command while no WP value shows during force control with the URCap.
while (True):<br>    $ 1 "Programme de robot"<br>    $ 2 "DéplacementA"<br>    $ 3 "PointPassage_4"<br>    movej(get_inverse_kin(p[.292251391283, -.030978746220, .095004651879, 1.336814379754, -2.821429512594, .034661380497], qnear=[2.6624062061309814, -1.622237507496969, 2.6584012508392334, -2.6132529417621058, -1.601675812398092, 0.2029333859682083]), a=1.3962634015954636, v=1.0471975511965976)<br>    $ 5 "Boucle"<br>    while (True):<br>      # begin: URCap Program Node<br>      #   Source: Robotiq_Force_Copilot, 1.9.2, Robotiq Inc.<br>      #   Type: Contrôle de la force<br>      $ 7 "Contrôle de la force"<br>      #ft mode node start<br>      rq_ft_sensor_disconnected_check()<br>      node_rpc_server.movejdefinewaypoint(1, get_actual_joint_positions(), 1.0, 1.0)<br>      node_rpc_server.setparentid(1, 3)<br>      initialise_execution_node()<br>      node_execution_thread = run keep_node_executor_alive_thread()<br>      active_and_reset_node(3)<br>      execute_node(1)<br>      #ft mode node children start<br>      # begin: URCap Program Node<br>      #   Source: Robotiq_Force_Copilot, 1.9.2, Robotiq Inc.<br>      #   Type: Trajectoire multipoint<br>      $ 8 "Trajectoire multipoint"<br>      #robotiq move node start<br>      rq_ft_sensor_disconnected_check()<br>      path_answer = node_rpc_server.rqmovesplantrajectory(4)<br>      verify_path_answer(path_answer)<br>      q0 = node_rpc_server.rqmovesgetfirstpoint(4)<br>      node_rpc_server.setparentid(1,3)<br>      node_rpc_server.movejdefinewaypoint(1, q0, 1.0, 0.4)<br>      execute_node(1)<br>      #robotiq move node children start<br>      # begin: URCap Program Node<br>      #   Source: Robotiq_Force_Copilot, 1.9.2, Robotiq Inc.<br>      #   Type: Point de cheminement (WP)<br>      $ 9 "DéplacementA vers point         "<br>      execute_node(5)<br>      # end: URCap Program Node<br>      # begin: URCap Program Node<br>      #   Source: Robotiq_Force_Copilot, 1.9.2, Robotiq Inc.<br>      #   Type: Point de cheminement (WP)<br>      $ 10 "Ligne vers le WP 2         "<br>      execute_node(6)<br>      # end: URCap Program Node<br>      #robotiq move node children finished<br>      #robotiq move node finished<br>      # end: URCap Program Node<br>      #ft mode node children finished<br>      kill node_execution_thread<br>      sleep(0.05)<br>      #ft mode node finished<br>      # end: URCap Program Node<br>    end<br>  end

My question is to know if WP values during force control can by reached and even modified by communicating with node_rpc_server or by any other means.
I hope this questions is not redundant, a quick research on this website yielded nothing.

Greetings

A. Koessler

Best Answer

Comments

  • PE_GermainPE_Germain Vacuum Beta tester Posts: 13 Handy
    Hello everyone,

    Regarding the current need of Mr. Koessler. This is not possible for now to make variable waypoint in a multipoint. When the program start, the robot pre-calculate the trajectory of the path. That makes impossible the use of variable waypoint in this case. 
    Pierre-Étienne Germain
    Integration Coach
    [email protected]
    (+1) 418-380-2788 ext. 269
  • manishmanish Posts: 2 Recruit
    edited November 2019
    Hello everyone,

    Regarding the current need of Mr. Koessler. This is not possible for now to make variable waypoint in a multipoint. When the program start, the robot pre-calculate the trajectory of the path. That makes impossible the use of variable waypoint in this case. 
    @PE_Germain

    Thanks for following up on inquiries like this - it makes these forum posts quite valuable.

    Do you have any clues on how to get around this limitation? I can think of hardcoding a series of paths and then using conditional logic to pick the "closest" one. 
  • SatazSataz Posts: 5 Apprentice
    Hi, may I check if there is any work around to change the waypoints at the start of the program without using teach pendant? Or is it possible to create our own rpc xml function and let the force control to call that function to get the waypoints pose dynamically at the beginning of the program?
Sign In or Register to comment.
Left ArrowBack to discussions page