jeguzzi / robomaster_ros

ROS2 for DJI Robomaster EP and S1
https://jeguzzi.github.io/robomaster_ros
MIT License
49 stars 10 forks source link

Cannot interact with robomaster #4

Closed UserName-wang closed 10 months ago

UserName-wang commented 10 months ago

after running the command: _ros2 launch robomaster_ros ep.launch name:=RM0 serialnumber:=159CG9T1050FCM but no node found by command in other terminator: ros2 node list nor rqt... Can someone help me please? ROS2 version: humble

log information: ros2 launch robomaster_ros ep.launch name:=RM0 serial_number:=159CG9T1050FCM [INFO] [launch]: All log files can be found below /home/orin/.ros/log/2023-09-02-22-50-04-007892-ubuntu-293672 [INFO] [launch]: Default logging verbosity is set to INFO [INFO] [robomaster_driver-1]: process started with pid [293686] [INFO] [robot_state_publisher-2]: process started with pid [293688] [INFO] [joint_state_publisher-3]: process started with pid [293690] [robomaster_driver-1] [INFO] [1693666207.453671432] [RM0.robomaster]: Waiting for a robot [robomaster_driver-1] [INFO] [1693666207.508756968] [RM0.robomaster]: Found a robot [robomaster_driver-1] [INFO] [1693666207.509638120] [RM0.robomaster]: Try to connect via sta to robot with sn 159CG9T1050FCM

[robomaster_driver-1] [INFO] [1693666208.200431272] [RM0.robomaster]: [Arm] left servo: index 0, direction 1, value 1024, angle 0.073304 [robomaster_driver-1] [INFO] [1693666208.203435208] [RM0.robomaster]: [Arm] right servo: index 1, direction -1, value 1024, angle -0.274016 [robomaster_driver-1] [INFO] [1693666208.245256616] [RM0.robomaster]: [Arm] Callback group <rclpy.callback_groups.MutuallyExclusiveCallbackGroup object at 0xffff3fdcedf0> [robomaster_driver-1] [INFO] [1693666208.309605704] [RM0.robomaster]: [Camera] Start video stream with resolution 360p [robomaster_driver-1] [INFO] [1693666208.464369832] [RM0.robomaster]: topic cmd_vel will control chassis twist [robomaster_driver-1] [INFO] [1693666208.828274056] [RM0.robomaster]: Enabled modules: Arm, Battery, Camera, Chassis, Gripper, LED, Speaker

jeguzzi commented 10 months ago

The posted log does not contain anything anomalous: the robomaster driver node appears to have launched correctly and that it connected to the robot.

ros2 node list should at least print

/RM0/joint_state_publisher
/RM0/robomaster
/RM0/robot_state_publisher

I don't think that your issue is specific to robomaster_ros. Try running a cli publisher ros2 topic pub ... and check if you can connect from the other shell. I also suggest to debug your ROS runtime using the usual tools, like ros2 doctor. You could also try to run ros2 node list --no-daemon -a. Maybe the two shells use different daemons or connect to different network interfaces.

UserName-wang commented 10 months ago

My problem caused by the battery issue(I modified it so that I can power supply from a power supply adapter without a battery.). I can control the robomaster now , if I plug in the power adapter and the battery at same time.

UserName-wang commented 10 months ago

The posted log does not contain anything anomalous: the robomaster driver node appears to have launched correctly and that it connected to the robot.

ros2 node list should at least print

/RM0/joint_state_publisher
/RM0/robomaster
/RM0/robot_state_publisher

I don't think that your issue is specific to robomaster_ros. Try running a cli publisher ros2 topic pub ... and check if you can connect from the other shell. I also suggest to debug your ROS runtime using the usual tools, like ros2 doctor. You could also try to run ros2 node list --no-daemon -a. Maybe the two shells use different daemons or connect to different network interfaces.

yes, you are right! this issue caused by my power supply adapter. thank you for your kindly reply!