Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Boot Issue: Configuration Download Failed #324

Open
jclinton830 opened this issue Oct 1, 2024 · 1 comment
Open

Boot Issue: Configuration Download Failed #324

jclinton830 opened this issue Oct 1, 2024 · 1 comment
Labels
question Further information is requested

Comments

@jclinton830
Copy link

Describe the bug
I am currently writing a driver for the roboteq motor controller. When I run the driver with the hardware I get the following error. There are two problems.

  1. There is an error which suggests that there was a boot issue in downloading the configuration.
  2. The Lely software reckons the pdo mapping for entry 2000 with sub index 1 is not possible. Even though above that in the lod it shows that entry 2000 with sub id of 1 was mapped correctly as per the bus.yaml.

See below for the log file

Why is it saying that there is a boot issue but then it also says the device booted and is ready for use?
Also why would it say that the PDO mapping is not possible when the same PDO mapping works with the canopen_system example?

See below the extract of the entry 2000 from the eds file.

[2000]
ParameterName=Cmd_CANGO Set Motor Command
SubNumber=4
ObjectType=0x8

[2000sub0]
ParameterName=Number of entries
ObjectType=0x7
DataType=0x0005
LowLimit=
HighLimit=
AccessType=ro
DefaultValue=0x03
PDOMapping=0
ObjFlags=0x0

[2000sub1]
ParameterName=Channel 1
ObjectType=0x7
DataType=0x0004
LowLimit=
HighLimit=
AccessType=wo
DefaultValue=
PDOMapping=1
ObjFlags=0x0

[2000sub2]
ParameterName=Channel 2
ObjectType=0x7
DataType=0x0004
LowLimit=
HighLimit=
AccessType=wo
DefaultValue=
PDOMapping=1
ObjFlags=0x0

[2000sub3]
ParameterName=Channel 3
ObjectType=0x7
DataType=0x0004
LowLimit=
HighLimit=
AccessType=wo
DefaultValue=
PDOMapping=1
ObjFlags=0x0

Logs

ros2 launch roboteq_driver roboteq.launch.py 
[INFO] [launch]: All log files can be found below /home/jerome/.ros/log/2024-10-01-15-18-57-289551-jjustin-3471590
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [launch.user]: /home/jerome/gh_ws/install/roboteq_driver/share/roboteq_driver/config/bus_roboteq/bus.yml
[INFO] [launch.user]: /home/jerome/gh_ws/install/roboteq_driver/share/roboteq_driver/config/bus_roboteq/master.dcf
[INFO] [launch.user]: /home/jerome/gh_ws/install/roboteq_driver/share/roboteq_driver/config/bus_roboteq/drive.bin
[INFO] [launch.user]: can0
[INFO] [device_container_node-1]: process started with pid [3471605]
[device_container_node-1] [INFO] [1727759937.402709191] [device_container_node]: Starting Device Container with:
[device_container_node-1] [INFO] [1727759937.402840561] [device_container_node]:         master_config /home/jerome/gh_ws/install/roboteq_driver/share/roboteq_driver/config/bus_roboteq/master.dcf
[device_container_node-1] [INFO] [1727759937.402854517] [device_container_node]:         bus_config /home/jerome/gh_ws/install/roboteq_driver/share/roboteq_driver/config/bus_roboteq/bus.yml
[device_container_node-1] [INFO] [1727759937.402864075] [device_container_node]:         can_interface_name can0
[device_container_node-1] [INFO] [1727759937.403852702] [device_container_node]: Loading Master Configuration.
[device_container_node-1] [INFO] [1727759937.404469948] [device_container_node]: Load Library: /home/jerome/gh_ws/install/canopen_master_driver/lib/libmaster_driver.so
[device_container_node-1] [INFO] [1727759937.407253397] [device_container_node]: Found class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::MasterDriver>
[device_container_node-1] [INFO] [1727759937.407303710] [device_container_node]: Instantiate class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::MasterDriver>
[device_container_node-1] [INFO] [1727759937.410334837] [master]: NodeCanopenBasicMaster
[device_container_node-1] [INFO] [1727759937.410432478] [device_container_node]: Load master component.
[device_container_node-1] [INFO] [1727759937.410494360] [device_container_node]: Added /master to executor
[device_container_node-1] [INFO] [1727759937.423491115] [device_container_node]: Loading Driver Configuration.
[device_container_node-1] [INFO] [1727759937.423633923] [device_container_node]: Found device drive with driver ros2_canopen::RoboteqDriver
[device_container_node-1] [INFO] [1727759937.424088332] [device_container_node]: Load Library: /home/jerome/gh_ws/install/roboteq_driver/lib/libroboteq_driver.so
[device_container_node-1] [INFO] [1727759937.428824181] [device_container_node]: Found class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::RoboteqDriver>
[device_container_node-1] [INFO] [1727759937.428861749] [device_container_node]: Instantiate class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::RoboteqDriver>
[device_container_node-1] [INFO] [1727759937.431484584] [device_container_node]: Load driver component.
[device_container_node-1] [INFO] [1727759937.431574909] [device_container_node]: Added /drive to executor
[device_container_node-1] [INFO] [1727759937.443275162] [drive]: eds file /home/jerome/gh_ws/install/roboteq_driver/share/roboteq_driver/config/bus_roboteq/roboteq_motor_controllers_v80.eds
[device_container_node-1] [INFO] [1727759937.443317549] [drive]: bin file /home/jerome/gh_ws/install/roboteq_driver/share/roboteq_driver/config/bus_roboteq/drive.bin
[device_container_node-1] Found rpdo mapped object: index=2000 subindex=1
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=a
[device_container_node-1] Found rpdo mapped object: index=200e subindex=0
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=c
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=d
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=e
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=f
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=10
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=11
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=12
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=13
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=14
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=15
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=16
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=17
[device_container_node-1] Found rpdo mapped object: index=2005 subindex=18
[device_container_node-1] Found tpdo mapped object: index=2100 subindex=1
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=2
[device_container_node-1] Found tpdo mapped object: index=210b subindex=1
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=4
[device_container_node-1] Found tpdo mapped object: index=210a subindex=1
[device_container_node-1] Found tpdo mapped object: index=2122 subindex=1
[device_container_node-1] Found tpdo mapped object: index=2111 subindex=0
[device_container_node-1] Found tpdo mapped object: index=2112 subindex=0
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=19
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=1a
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=1b
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=1c
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=1d
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=1e
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=1f
[device_container_node-1] Found tpdo mapped object: index=2106 subindex=20
[device_container_node-1] [WARN] [1727759937.451346661] [drive]: Wait for device to boot.
[device_container_node-1] [ERROR] [1727759937.461930232] [drive]: Boot Issue: Configuration download failed.
[device_container_node-1] [INFO] [1727759937.462004699] [drive]: Driver booted and ready.
[device_container_node-1] [INFO] [1727759937.462012511] [drive]: diag enabled.
[device_container_node-1] [INFO] [1727759937.462184499] [roboteq_driver]: Initialised
[device_container_node-1] [INFO] [1727759937.462409959] [drive]: Starting with polling mode.
[device_container_node-1] [INFO] [1727759937.462596320] [drive]: Starting with diagnostics enabled.
[device_container_node-1] terminate called after throwing an instance of 'lely::canopen::SdoError'
[device_container_node-1]   what():  TpdoWrite:1C:2000:01: Object cannot be mapped to the PDO (06040041): Object cannot be mapped to the PDO
[ERROR] [device_container_node-1]: process has died [pid 3471605, exit code -6, cmd '/home/jerome/gh_ws/install/canopen_core/lib/canopen_core/device_container_node --ros-args -r __node:=device_container_node -r __ns:=/ --params-file /tmp/launch_params__bvyukq9 --params-file /tmp/launch_params_59xni90e --params-file /tmp/launch_params_wfdtaqpt --params-file /tmp/launch_params_km7cm5no'].

Setup:

  • Device: Linux computer, Roboteq motor controller mbl1660A
  • OS: Ubuntu 22.04
  • ROS-Distro: Humble
  • Branch/Commit:

Additional context
Here is my bus.yaml

options:
  dcf_path: "@BUS_CONFIG_PATH@"

master:
  node_id: 1
  package: "canopen_master_driver"
  driver: "ros2_canopen::MasterDriver"
  baudrate: 1000 
  sync_period: 20000

drive:
  node_id: 28
  dcf: "roboteq_motor_controllers_v80.eds"
  package: "roboteq_driver"
  driver: "ros2_canopen::RoboteqDriver"
  polling: true
  period: 50 # in milliseconds
  diagnostics:
    enable: true
    period: 1000
  reset_communication: true
  tpdo:
    1:
      enabled: true
      cob_id: auto
      mapping:
        - { index: 0x2100, sub_index: 1 } # read motor amps
    2:
      enabled: true
      cob_id: auto
      mapping:
        - { index: 0x210B, sub_index: 1 } # read relative BL motor speed
    3:
      enabled: true
      cob_id: auto
      mapping:
        - { index: 0x210A, sub_index: 1 } # read motor speed in RPM
        - { index: 0x2122, sub_index: 1 } # read motor status flags
    4:
      enabled: true
      cob_id: auto
      mapping:
        - { index: 0x2111, sub_index: 0 } # read status flags
        - { index: 0x2112, sub_index: 0 } # read fault flags
  rpdo: 
    1:
      enabled: true
      cob_id: auto
      mapping:
        - { index: 0x2000, sub_index: 1 } # set motor command
    2:
      enabled: true
      cob_id: auto
      mapping:
        - { index: 0x200E, sub_index: 0 } # Motor stop in all modes
    3:
      enabled: true
    4: 
      enabled: true
@jclinton830 jclinton830 added the question Further information is requested label Oct 1, 2024
@mrmitchadams
Copy link

In the online examples, the auto parameter of cob_id is in quotes: cob_id: "auto". However, I've found that for the tpdos, I had to get rid of that line altogether to avoid that error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants