@@ -80,32 +80,32 @@ Building from source
80
80
2) Prepare the ROS2 driver build: Make sure you have your ROS2
81
81
environment sourced:
82
82
83
- ::
83
+ ::
84
84
85
- source /opt/ros/<my_ros_distro>/setup.bash
85
+ source /opt/ros/<my_ros_distro>/setup.bash
86
86
87
- Create a workspace (``~/ws ``), clone this repo:
87
+ Create a workspace (``~/ws ``), clone this repo:
88
88
89
- ::
89
+ ::
90
90
91
- mkdir -p ~/ws/src
92
- cd ~/ws/src
93
- git clone --branch humble-devel https://github.com/ros-drivers/flir_camera_driver
94
- cd ..
91
+ mkdir -p ~/ws/src
92
+ cd ~/ws/src
93
+ git clone --branch humble-devel https://github.com/ros-drivers/flir_camera_driver
94
+ cd ..
95
95
96
- To automatically install all packages that the ``flir_camera_driver ``
97
- packages depends upon, run this at the top of your workspace:
96
+ To automatically install all packages that the ``flir_camera_driver ``
97
+ packages depends upon, run this at the top of your workspace:
98
98
99
- ::
99
+ ::
100
100
101
- rosdep install --from-paths src --ignore-src
101
+ rosdep install --from-paths src --ignore-src
102
102
103
103
3) Build the driver and source the workspace:
104
104
105
- ::
105
+ ::
106
106
107
- colcon build --symlink-install --cmake-args -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
108
- . install/setup.bash
107
+ colcon build --symlink-install --cmake-args -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
108
+ . install/setup.bash
109
109
110
110
How to use
111
111
==========
@@ -122,7 +122,7 @@ Published:
122
122
Subscribed:
123
123
124
124
- ``~/control ``: (only when ``enable_external_control `` is set to True)
125
- for external control exposure time and gain.
125
+ for external control exposure time and gain.
126
126
127
127
Parameters
128
128
----------
@@ -287,9 +287,13 @@ subnet mask of 255.255.0.0).
287
287
To check if the MTU settings are working correctly on the host you
288
288
can ping with large packet size from a different host on the same
289
289
network (must also have a MTU of 9000):
290
- ```
291
- ping <host_ip_address> -c 2 -M do -s 8972
292
- ```
290
+
291
+ ::
292
+
293
+ ping <host_ip_address> -c 2 -M do -s 8972
294
+
295
+ Note that this will *not * work if you ping the camera: you will find
296
+ a MTU size of 1500, even if both camera and host NIC have correct MTU setting.
293
297
Beware that some network cards have `bugs that mess up the MTU when
294
298
running ptp4l <https://www.reddit.com/r/networking/comments/1ebvj5y/linux_ptp_and_jumbo_frames_for_gige_vision/> `__.
295
299
@@ -356,7 +360,7 @@ Once the camera gets PTP packets it will eventually accept the host's PHC as mas
356
360
357
361
Note that once a camera has been up and running for a while it can be very reluctant to accept PTP message from a master and switch from listener (``LIS ``) to Slave (``SLV ``) mode. Power cycle the camera (disconnect the GigE/POE cable) to fix this. Best practice is to have the master clock running already before starting the camera.
358
362
359
- **Monitor the offset for a while! **. If the system clock of the host that is running the driver is not disciplined by the master PHC then the offset will keep drifting. Make sure that something keeps the system clock synchronized with the PHC.
363
+ **Monitor the offset for a while! ** If the system clock of the host that is running the driver is not disciplined by the master PHC then the offset will keep drifting. Make sure that something keeps the system clock synchronized with the PHC.
360
364
361
365
362
366
@@ -375,7 +379,7 @@ comes with the Spinnaker SDK. Once you know what property you want to
375
379
expose as a ROS parameter, you add a mapping entry to the yaml
376
380
configuration file, e.g.:
377
381
378
- .. code ::
382
+ ::
379
383
380
384
- name: image_width
381
385
type: int
@@ -391,7 +395,7 @@ integers because their values are restricted to a set of strings. Any
391
395
other strings will be rejected by the Spinnaker API. Please document the
392
396
valid enum strings in the configuration file, e.g.:
393
397
394
- .. code ::
398
+ ::
395
399
396
400
- name: line1_linemode # valid values: "Input", "Output"
397
401
type: enum
@@ -435,7 +439,7 @@ Troubleshooting/Common Issues
435
439
436
440
2) Driver doesn't publish images and/or warns about incomplete images for GigE cameras
437
441
438
- .. code ::
442
+ ::
439
443
440
444
rate [Hz] in 39.76 out 0.00 drop 0% INCOMPLETE 100%
441
445
@@ -458,11 +462,11 @@ Troubleshooting/Common Issues
458
462
459
463
6) GigE camera cannot be initialized:
460
464
461
- .. code ::
465
+ ::
462
466
463
- [19074765]: found camera with serial number: 19074765
464
- [Spinnaker Wrapper]: Could not initialize camera on any interface!
465
- [Spinnaker Wrapper]: failed attempt on interface: GEV Interface 1
467
+ [19074765]: found camera with serial number: 19074765
468
+ [Spinnaker Wrapper]: Could not initialize camera on any interface!
469
+ [Spinnaker Wrapper]: failed attempt on interface: GEV Interface 1
466
470
467
471
Either the IP address of your camera is out-of-network (switch it to
468
472
DHCP using SpinView) or another application (SpinView?) is
@@ -476,56 +480,58 @@ your machine.
476
480
477
481
1) Somewhere in your ``.bashrc `` file, set the following env variable:
478
482
479
- .. code ::
483
+ ::
480
484
481
485
export SPINNAKER_GENTL64_CTI=/opt/ros/${ROS_DISTRO}/lib/spinnaker-gentl/Spinnaker_GenTL.cti
482
486
483
487
2) Add the “flirimaging” group and make yourself a member of it
484
488
485
- .. code ::
489
+ ::
486
490
487
491
sudo addgroup flirimaging
488
492
sudo usermod -a -G flirimaging ${USER}
489
493
490
494
3) Bump the usbfs memory limits
491
495
492
- The following was taken from
493
- `here <https://www.flir.com/support-center/iis/machine-vision/application-note/using-linux-with-usb-3.1/ >`__.
494
- Edit the file ``/etc/default/grub `` and change the line default to:
495
-
496
- ::
496
+ The following was taken from
497
+ `here <https://www.flir.com/support-center/iis/machine-vision/application-note/using-linux-with-usb-3.1/ >`__.
498
+ Edit the file ``/etc/default/grub `` and change the line default to:
497
499
498
- GRUB_CMDLINE_LINUX_DEFAULT="quiet splash usbcore.usbfs_memory_mb=1000"
500
+ ::
499
501
500
- Then
502
+ GRUB_CMDLINE_LINUX_DEFAULT="quiet splash usbcore.usbfs_memory_mb=1000"
501
503
502
- ::
504
+ Then
503
505
504
- sudo update-grub
506
+ ::
505
507
506
- If your system does not have ``/etc/default/grub ``, create the file
507
- ``/etc/rc.local ``, and change its permissions to ‘executable’. Then
508
- write the following text to it:
508
+ sudo update-grub
509
509
510
- ::
510
+ If your system does not have ``/etc/default/grub ``, create the file
511
+ ``/etc/rc.local ``, and change its permissions to ‘executable’. Then
512
+ write the following text to it:
511
513
512
- #!/bin/sh -e
513
- sh -c 'echo 1000 > /sys/module/usbcore/parameters/usbfs_memory_mb'
514
+ ::
514
515
515
- exit 0
516
+ #!/bin/sh -e
517
+ sh -c 'echo 1000 > /sys/module/usbcore/parameters/usbfs_memory_mb'
518
+ exit 0
516
519
517
520
4) Setup udev rules
518
521
519
- .. code ::
522
+ ::
520
523
521
- echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="1e10", GROUP="flirimaging"' | sudo tee -a /etc/udev/rules.d/40-flir-spinnaker.rules
522
- echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="1724", GROUP="flirimaging"' | sudo tee -a /etc/udev/rules.d/40-flir-spinnaker.rules
523
- sudo service udev restart
524
- sudo udevadm trigger
524
+ echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="1e10", GROUP="flirimaging"' | sudo tee -a /etc/udev/rules.d/40-flir-spinnaker.rules
525
+ echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="1724", GROUP="flirimaging"' | sudo tee -a /etc/udev/rules.d/40-flir-spinnaker.rules
526
+ sudo service udev restart
527
+ sudo udevadm trigger
525
528
526
529
5) Logout and log back in (or better, reboot)
527
530
528
- ``sudo reboot ``
531
+ ::
532
+
533
+ sudo reboot
534
+
529
535
530
536
531
537
How to contribute
@@ -542,7 +548,7 @@ some basic lint tests:
542
548
543
549
::
544
550
545
- colcon test --packages-select spinnaker_camera_driver && colcon test-result --verbose
551
+ colcon test --packages-select spinnaker_camera_driver && colcon test-result --verbose
546
552
547
553
548
554
License
0 commit comments