0
$\begingroup$

Rosanswers logo

Hello,

I am trying to home 3 drives in a specific order. Here akosodry asked the same question: Link to another question So what I did was specify the nodes as a list:

nodes: #The order here is important because it defines the homing order. welp it does not
  - name: joint_z
    id: 4 #node id
    dcf_overlay:
      "3202": "77"          #Motor configuration
      "6099sub1": "40000"  #Homing speed when searching for switch
      "6099sub2": "5000"    #Homing speed when searching for zero
      "3240sub1": "7"       
      "6098": "14"          #Homing method,
      "6081": "50000"       #profile velocity
      "3700": "1"           #Reaction to following error
    pos_to_device: "rint(pos*1000)" # rad -> mdeg
    pos_from_device: "obj6064/1000" # actual position [mdeg] -> rad
    vel_to_device: "rint(vel*1000)" # rad/s -> mdeg/s
    vel_from_device: "obj606C/1000" # actual velocity [mdeg/s] -> rad/s
    eff_to_device: "rint(eff)" # just round to integer
    eff_from_device: "0" # unset

  - name: joint_y
    id: 3 # node id
    dcf_overlay:
      "6099sub1": "40000"    #Homing speed when searching for switch
      "6099sub2": "5000"    #Homing speed when searching for zero
      "3240sub1": "7"       
      "6098": "10"          #Homing method
      "6081": "50000"       #profile velocity
      "3700": "1"           #Reaction to following error
      "6065": "4294967295"  #Following error surveillance deactivated
    pos_to_device: "rint(-pos*1000)" # rad -> mdeg
    pos_from_device: "-obj6064/1000" # actual position [mdeg] -> rad
    vel_to_device: "rint(-vel*1000)" # rad/s -> mdeg/s
    vel_from_device: "-obj606C/1000" # actual velocity [mdeg/s] -> rad/s
    eff_to_device: "rint(eff)" # just round to integer
    eff_from_device: "0" # unset   

joint_z should be homed before joint_y, but no matter in which order I put them, joint_y always gets homed first. What am I doing wrong or is there a different solution?


Originally posted by TLZ on ROS Answers with karma: 3 on 2021-07-07

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

What am I doing wrong

Nothing!

Even with the list-style, the node will be sorted by name.

I just discovered this issues recently. Please try https://github.com/ros-industrial/ros_canopen/pull/438

is there a different solution?

If you want to use the release version:

You can name the node alphabetically, but set different joint names:

nodes:
  - name: motor_1
    joint: joint_z
    id: 4 #node id

Originally posted by Mathias Lüdtke with karma: 1596 on 2021-07-08

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by TLZ on 2021-10-21:
Sorry for the super late reply. Thank you for the fast commit. It now works as expected.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.