Closed y2d2 closed 1 year ago
There seem to be more fishy things going on around this hokuyo_ust.
Not sure if I have to create a different bug report, but when I launch the simulation ros2 launch clearpath_gz simulation.launch.py
I get multiple errors that are related to this:
root@husky:/# ros2 launch clearpath_gz simulation.launch.py
...
[generate_description-3] ImportError: cannot import name 'HokuyoUST10' from 'clearpath_config.sensors.types.lidars_2d' (/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/types/lidars_2d.py)
...
[generate_launch-4] ImportError: cannot import name 'HokuyoUST10' from 'clearpath_config.sensors.types.lidars_2d' (/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/types/lidars_2d.py)
...
There are other errors in the output, however, I am not sure if they follow because of the initial errors.
Maybe I need to build the packages from source instead of installing them?
full Output:
root@husky:/# ros2 launch clearpath_gz simulation.launch.py
[INFO] [launch]: All log files can be found below /root/.ros/log/2023-08-22-10-50-11-385905-husky-147
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [ruby $(which ign) gazebo-1]: process started with pid [148]
[INFO] [parameter_bridge-2]: process started with pid [150]
[INFO] [generate_description-3]: process started with pid [153]
[generate_description-3] Traceback (most recent call last):
[generate_description-3] File "/opt/ros/humble/lib/clearpath_generator_common/generate_description", line 36, in <module>
[generate_description-3] from clearpath_generator_common.description.generator import DescriptionGenerator
[generate_description-3] File "/opt/ros/humble/local/lib/python3.10/dist-packages/clearpath_generator_common/description/generator.py", line 41, in <module>
[generate_description-3] from clearpath_generator_common.description.sensors import SensorDescription
[generate_description-3] File "/opt/ros/humble/local/lib/python3.10/dist-packages/clearpath_generator_common/description/sensors.py", line 34, in <module>
[generate_description-3] from clearpath_config.sensors.types.lidars_2d import BaseLidar2D, HokuyoUST10, SickLMS1XX
[generate_description-3] ImportError: cannot import name 'HokuyoUST10' from 'clearpath_config.sensors.types.lidars_2d' (/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/types/lidars_2d.py)
[ERROR] [generate_description-3]: process has died [pid 153, exit code 1, cmd '/opt/ros/humble/lib/clearpath_generator_common/generate_description -s /root/clearpath/ --ros-args -r __node:=generate_description'].
[INFO] [generate_launch-4]: process started with pid [158]
[generate_launch-4] Traceback (most recent call last):
[generate_launch-4] File "/opt/ros/humble/lib/clearpath_generator_gz/generate_launch", line 36, in <module>
[generate_launch-4] from clearpath_generator_gz.launch.generator import GzLaunchGenerator
[generate_launch-4] File "/opt/ros/humble/local/lib/python3.10/dist-packages/clearpath_generator_gz/launch/generator.py", line 41, in <module>
[generate_launch-4] from clearpath_generator_gz.launch.sensors import SensorLaunch
[generate_launch-4] File "/opt/ros/humble/local/lib/python3.10/dist-packages/clearpath_generator_gz/launch/sensors.py", line 34, in <module>
[generate_launch-4] from clearpath_config.sensors.types.lidars_2d import BaseLidar2D, HokuyoUST10, SickLMS1XX
[generate_launch-4] ImportError: cannot import name 'HokuyoUST10' from 'clearpath_config.sensors.types.lidars_2d' (/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/types/lidars_2d.py)
[ERROR] [generate_launch-4]: process has died [pid 158, exit code 1, cmd '/opt/ros/humble/lib/clearpath_generator_gz/generate_launch -s /root/clearpath/ --ros-args -r __node:=generate_launch'].
[INFO] [generate_param-5]: process started with pid [169]
[generate_param-5] Generated config: /root/clearpath/platform/config/control.yaml
[generate_param-5] Generated config: /root/clearpath/platform/config/imu_filter.yaml
[generate_param-5] Traceback (most recent call last):
[generate_param-5] File "/opt/ros/humble/lib/clearpath_generator_gz/generate_param", line 46, in <module>
[generate_param-5] main()
[generate_param-5] File "/opt/ros/humble/lib/clearpath_generator_gz/generate_param", line 42, in main
[generate_param-5] gpg.generate()
[generate_param-5] File "/opt/ros/humble/local/lib/python3.10/dist-packages/clearpath_generator_common/param/generator.py", line 64, in generate
[generate_param-5] self.generate_platform()
[generate_param-5] File "/opt/ros/humble/local/lib/python3.10/dist-packages/clearpath_generator_gz/param/generator.py", line 49, in generate_platform
[generate_param-5] platform_param.generate_parameters(use_sim_time=True)
[generate_param-5] File "/opt/ros/humble/local/lib/python3.10/dist-packages/clearpath_generator_common/param/platform.py", line 140, in generate_parameters
[generate_param-5] imus = self.clearpath_config.sensors.get_all_imu()
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/clearpath_config.py", line 187, in sensors
[generate_param-5] self._sensors.config[self.SENSORS])
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/common/types/config.py", line 87, in config
[generate_param-5] self.getter(prop)()
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/sensors.py", line 303, in camera
[generate_param-5] value=self._camera.to_dict()
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/sensors.py", line 219, in to_dict
[generate_param-5] d.append(accessory.to_dict())
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/types/sensor.py", line 97, in to_dict
[generate_param-5] d['ros_parameters'] = self.get_ros_parameters()
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/types/sensor.py", line 214, in get_ros_parameters
[generate_param-5] return self.ros_parameters
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/sensors/types/sensor.py", line 198, in ros_parameters
[generate_param-5] d[node_name] = flatten_dict(d[node_name])
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/common/utils/dictionary.py", line 43, in flatten_dict
[generate_param-5] return dict(_flatten_dict_gen(d, parent_key, dlim))
[generate_param-5] File "/opt/ros/humble/lib/python3.10/site-packages/clearpath_config/common/utils/dictionary.py", line 34, in _flatten_dict_gen
[generate_param-5] for k, v in d.items():
[generate_param-5] AttributeError: 'str' object has no attribute 'items'
[ERROR] [generate_param-5]: process has died [pid 169, exit code 1, cmd '/opt/ros/humble/lib/clearpath_generator_gz/generate_param -s /root/clearpath/ --ros-args -r __node:=generate_launch'].
[ERROR] [launch]: Caught exception in launch (see debug for traceback): [Errno 2] No such file or directory: '/root/clearpath/platform/launch/platform-service.launch.py'
[INFO] [parameter_bridge-2]: sending signal 'SIGINT' to process[parameter_bridge-2]
[INFO] [ruby $(which ign) gazebo-1]: sending signal 'SIGINT' to process[ruby $(which ign) gazebo-1]
[parameter_bridge-2] [INFO] [1692701411.780103267] [rclcpp]: signal_handler(signum=2)
[parameter_bridge-2] terminate called after throwing an instance of 'rclcpp::exceptions::RCLError'
[parameter_bridge-2] what(): Couldn't initialize rcl timer handle: the given context is not valid, either rcl_init() was not called or rcl_shutdown() was called., at ./src/rcl/guard_condition.c:67
[ERROR] [parameter_bridge-2]: process has died [pid 150, exit code -6, cmd '/opt/ros/humble/lib/ros_gz_bridge/parameter_bridge /clock@rosgraph_msgs/msg/Clock[ignition.msgs.Clock --ros-args -r __node:=clock_bridge'].
[ruby $(which ign) gazebo-1] QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] qrc:/qml/StyleDialog.qml:112:3: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onFoo(<arguments>) { ... }
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] qrc:/qml/StyleDialog.qml:105:3: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onFoo(<arguments>) { ... }
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] qrc:/qml/StyleDialog.qml:98:3: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onFoo(<arguments>) { ... }
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] qrc:qml/Main.qml:102:3: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onFoo(<arguments>) { ... }
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] qrc:/qml/PluginMenu.qml:27:3: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onFoo(<arguments>) { ... }
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] file::/Gazebo/GazeboDrawer.qml:241:3: QML Connections: Implicitly defined onFoo properties in Connections are deprecated. Use this syntax instead: function onFoo(<arguments>) { ... }
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] file::/Gazebo/GazeboDrawer.qml:147:3: QML Dialog: Binding loop detected for property "implicitHeight"
[ruby $(which ign) gazebo-1] [GUI] [Wrn] [Application.cc:797] [QT] file::/Gazebo/GazeboDrawer.qml:147:3: QML Dialog: Binding loop detected for property "implicitHeight"
[ERROR] [ruby $(which ign) gazebo-1]: process[ruby $(which ign) gazebo-1] failed to terminate '5' seconds after receiving 'SIGINT', escalating to 'SIGTERM'
[INFO] [ruby $(which ign) gazebo-1]: sending signal 'SIGTERM' to process[ruby $(which ign) gazebo-1]
[ERROR] [ruby $(which ign) gazebo-1]: process has died [pid 148, exit code -15, cmd 'ruby $(which ign) gazebo warehouse.sdf -v 4 --gui-config /opt/ros/humble/share/clearpath_gz/config/gui.config --force-version 6'].
So i see that this has been updated, but has not yet been pushed to the install repos?: https://github.com/clearpathrobotics/clearpath_config/blob/main/clearpath_config/sensors/sensors.py So I will try to build all clearpath packages form source.
Running the simulation from source did solve the HokuyoUST10
issue it did not help however to make the simulation work see https://github.com/clearpathrobotics/clearpath_simulator/issues/14
@y2d2 Thank you for your interest in the clearpath repos. You have jumped aboard early on and astutely have noticed that there are still some issues being worked out. There are patches coming through for a number of packages based on a round of testing that I am just finishing up. See this PR and all of the ones linked: https://github.com/clearpathrobotics/clearpath_common/pull/31
If you are in a rush you can start running the simulation using the indicated branches. If not, these changes are coming soon after a bit more testing, first to main and then will be pushed out to debian.
The documentation website was also recently updated so I would encourage you to revisit that. If you are wanting to try running your Husky using the ROS 2 Humble packages, please see the upgrade instructions here: https://docs.clearpathrobotics.com/docs/ros/installation/upgrading (includes how to create your robot.yaml from your existing envars set on the Husky). However, you do need to be aware that not all sensors are supported yet so please see the list here: https://docs.clearpathrobotics.com/docs/ros/#supported-sensors .
Hi @hilary-luo, Thanks for the information. Indeed I was expecting the husky I have to be shipped with ROS2 Humble since it seemed like this was now the preferred version, given the warnings for the ROS1 Noetic documentation. However, it arrived with ROS1 and worked, more or less out of the box except for the /scan topic having been remapped to front/scan. I am now doubting what to do. Should I upgrade to humble I believe the sensors I have are supported in ROS2 per your link. However, I am wondering whether I would not hit a lot of the "children's diseases". What would you recommend? Thanks y2d2
Hi @hilary-luo , when the fix will be released as debian package? Thanks
@y2d2 I can understand the confusion. While we are moving towards ROS 2 Humble as the preferred version, there is some delay between the software being ready and the systems being sold with it. The notice on the website is more to say that we have shifted most development efforts to ROS 2. The decision of whether or not to migrate is really up to your discretion. Noetic is and will continue to be fully supported for the foreseeable future (officially EOL in 2025). That is to say if your system is working in Noetic then you may want to wait until the Clearpath ROS 2 packages are more mature before migrating. However, if there are reasons that you may benefit from working in ROS2, the packages should be stable enough to migrate now and we will do our best to help you address any issues with the packages as they are discovered.
@Cavalletta98 these changes should now be available through the debian packages.
@hilary-luo Thanks A lot for the info! Then I will keep it at ROS1 for now.
Cheers and thanks!
Ho @hilary-luo still not released the Debian package. I'm still gettin the same errore for Hokuyo laser
@Cavalletta98 do you have the Clearpath package server added? It updates faster then the OSRFs. Here is for clearpath_common
: https://packages.clearpathrobotics.com/stable/ubuntu/pool/main/r/ros-humble-clearpath-common/ and here is how to setup: http://wiki.ros.org/ClearpathRobotics/Packages
Also, make sure that you have updated the robot.yaml you are using to match the latest changes https://docs.clearpathrobotics.com/docs/ros/config/yaml. In particular, the naming of the hokuyo lidar in the robot.yaml file should not contain the 10
. Breaking changes like this are not going to be standard moving forward, but were part of initial development.
If you update the packages without updating the robot.yaml then it will not work.
@tonybaltovski @hilary-luo Done. Now i'm able to see the Hokuyo laser model but not able to see the laser scan in Rviz. I explored the topic and something different from 0 is present. I attach my robot.yaml file. If could help, i attached also the screen of Rviz
@Cavalletta98 Can you please open your own github issue to pursue troubleshooting this? Feel free to assign it to me.
I am able to simulate the robot with your provided robot.yaml file without any problems, including the lidar. In the new issue that you open can you please specify the versions of the packages that you are running and clarify whether you are simulating the robot or running a physical robot? (If you are running a physical robot then please specify the versions of packages that you are running on both the robot and your pc).
Please provide the following information:
Real hardware or simulation: Not applicable
Issue When following https://docs.clearpathrobotics.com/docs/ros/installation/remote_pc/
source /etc/clearpath/setup.bash
throws following error:The robot.yaml was copied from: https://docs.clearpathrobotics.com/docs/ros/config/yaml/ where the model of the 2d lidar has not been adapted to
hokuyo_ust
and still showshokuyo_ust10
By changing this value in the robot.yaml file the issue was solved. Not sure if used the wrong resource or maybe if the site is lagging behind the update of the repo.
additional question I have a real husky which has been prepared at clearpath with GPS etc. I suppose I should have a custom robot.yaml file for my robot, where can I find it? Can i find it on the husky ?
Cheers,