ladrians / pixy2_ros

Basic ROS node to publish image from a pixy2 camera.
1 stars 0 forks source link

Connecting to Pixy2 cam over USB #1

Open erikasnow opened 4 years ago

erikasnow commented 4 years ago

I am connecting Pixy2cam to ROS. Platform is the Nvidia Jetson Nano. I have pixy2 library with libpixyusb2 built. pixy2_ros built with no errors in my catkin workspace. Error message below when running roslaunch pixy2_ros pixy2.launch. rosrun pixy2_ros pixy2_cam also doesn't work.

process[pixy_cam-1]: started with pid [14880] [ INFO] [1570044245.946029508]: Read Parameters [ INFO] [1570044245.947933080]: frame_rate: 5 PixyCam::PixyCam() void PixyCam::run() void PixyCam::checkCamera() runtime_error Can't get firmware version. [pixy_cam-1] process has died [pid 14880, exit code 1, cmd /home/autonodyne-nano/catkin_ws/devel/lib/pixy2_ros/pixy2_cam image_raw:=/camera/rgb/image frame_id:=camera name:=pixy_cam log:=/home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1.log]. log file: /home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1*.log [pixy_cam-1] restarting process process[pixy_cam-1]: started with pid [14889] [ INFO] [1570044246.554363121]: Read Parameters [ INFO] [1570044246.556817327]: frame_rate: 5 PixyCam::PixyCam() void PixyCam::run() void PixyCam::checkCamera() LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 terminate called after throwing an instance of 'std::runtime_error' what(): Unable to connect to device. [pixy_cam-1] process has died [pid 14889, exit code -6, cmd /home/autonodyne-nano/catkin_ws/devel/lib/pixy2_ros/pixy2_cam image_raw:=/camera/rgb/image frame_id:=camera name:=pixy_cam log:=/home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1.log]. log file: /home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1*.log [pixy_cam-1] restarting process process[pixy_cam-1]: started with pid [14905] [ INFO] [1570044250.413405233]: Read Parameters [ INFO] [1570044250.416999143]: frame_rate: 5 PixyCam::PixyCam() void PixyCam::run() void PixyCam::checkCamera() LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 ^C[pixy_cam-1] killing on exit LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 terminate called after throwing an instance of 'std::runtime_error' what(): Unable to connect to device. shutting down processing monitor... ... shutting down processing monitor complete done

leeyunhome commented 2 years ago

I am connecting Pixy2cam to ROS. Platform is the Nvidia Jetson Nano. I have pixy2 library with libpixyusb2 built. pixy2_ros built with no errors in my catkin workspace. Error message below when running roslaunch pixy2_ros pixy2.launch. rosrun pixy2_ros pixy2_cam also doesn't work.

process[pixy_cam-1]: started with pid [14880] [ INFO] [1570044245.946029508]: Read Parameters [ INFO] [1570044245.947933080]: frame_rate: 5 PixyCam::PixyCam() void PixyCam::run() void PixyCam::checkCamera() runtime_error Can't get firmware version. [pixy_cam-1] process has died [pid 14880, exit code 1, cmd /home/autonodyne-nano/catkin_ws/devel/lib/pixy2_ros/pixy2_cam image_raw:=/camera/rgb/image frame_id:=camera name:=pixy_cam log:=/home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1.log]. log file: /home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1*.log [pixy_cam-1] restarting process process[pixy_cam-1]: started with pid [14889] [ INFO] [1570044246.554363121]: Read Parameters [ INFO] [1570044246.556817327]: frame_rate: 5 PixyCam::PixyCam() void PixyCam::run() void PixyCam::checkCamera() LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 terminate called after throwing an instance of 'std::runtime_error' what(): Unable to connect to device. [pixy_cam-1] process has died [pid 14889, exit code -6, cmd /home/autonodyne-nano/catkin_ws/devel/lib/pixy2_ros/pixy2_cam image_raw:=/camera/rgb/image frame_id:=camera name:=pixy_cam log:=/home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1.log]. log file: /home/autonodyne-nano/.ros/log/2022de50-e54a-11e9-9037-00044be5eaad/pixy_cam-1*.log [pixy_cam-1] restarting process process[pixy_cam-1]: started with pid [14905] [ INFO] [1570044250.413405233]: Read Parameters [ INFO] [1570044250.416999143]: frame_rate: 5 PixyCam::PixyCam() void PixyCam::run() void PixyCam::checkCamera() LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 ^C[pixy_cam-1] killing on exit LIBUSB_ERROR_TIMEOUT: libusb_bulk_write -7 terminate called after throwing an instance of 'std::runtime_error' what(): Unable to connect to device. shutting down processing monitor... ... shutting down processing monitor complete done

Hello,

Can you tell me how to resolve this issue?

Thank you.

ladrians commented 2 years ago

@leeyunhome I do not know really. Have you copied the pixy.rules rules? Maybe the first option is to check everything works from the official site and your linux environment. Then I would try again with this ROS node. Hope it helps, regards