Closed dariodenardi closed 1 year ago
I have not tested on that combination of Ubuntu/spinnaker but last time I tested on Ubuntu 18.04 with that stereo_synced.launch.py file, it definitely worked. Here are a couple of debugging steps:
I did a lot of tests and I have tried with another pc with the same configuration (ubuntu 22.04, spinnaker 2.6.0.157 ...).
I answer by points:
1) No, it doesn't work. The problem is this parameter:
'trigger_mode': 'On',
if I change "on" to "off" script works. but what does disabling this feature mean? Is wired hardware sync disabled?
2) I don't see anything strange:
Dec 18 16:09:39 dario-Modern-14-B11MOL kernel: [ 2460.729497] usb 4-2: USB disconnect, device number 8
Dec 18 16:09:41 dario-Modern-14-B11MOL kernel: [ 2462.082975] usb 4-1: USB disconnect, device number 7
Dec 18 16:09:49 dario-Modern-14-B11MOL kernel: [ 2470.204039] usb 4-1: new SuperSpeed USB device number 9 using xhci_hcd
Dec 18 16:09:49 dario-Modern-14-B11MOL kernel: [ 2470.227510] usb 4-1: New USB device found, idVendor=1e10, idProduct=4000, bcdDevice= 0.00
Dec 18 16:09:49 dario-Modern-14-B11MOL kernel: [ 2470.227516] usb 4-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Dec 18 16:09:49 dario-Modern-14-B11MOL kernel: [ 2470.227519] usb 4-1: Product: Blackfly S BFS-U3-32S4C
Dec 18 16:09:49 dario-Modern-14-B11MOL kernel: [ 2470.227521] usb 4-1: Manufacturer: FLIR
Dec 18 16:09:49 dario-Modern-14-B11MOL kernel: [ 2470.227522] usb 4-1: SerialNumber: 01429F11
Dec 18 16:09:49 dario-Modern-14-B11MOL mtp-probe: checking bus 4, device 9: "/sys/devices/pci0000:00/0000:00:14.0/usb4/4-1"
Dec 18 16:09:49 dario-Modern-14-B11MOL mtp-probe: bus: 4, device: 9 was not an MTP device
Dec 18 16:09:49 dario-Modern-14-B11MOL mtp-probe: checking bus 4, device 9: "/sys/devices/pci0000:00/0000:00:14.0/usb4/4-1"
Dec 18 16:09:49 dario-Modern-14-B11MOL mtp-probe: bus: 4, device: 9 was not an MTP device
Dec 18 16:09:50 dario-Modern-14-B11MOL kernel: [ 2471.352343] usb 4-2: new SuperSpeed USB device number 10 using xhci_hcd
Dec 18 16:09:50 dario-Modern-14-B11MOL kernel: [ 2471.374927] usb 4-2: New USB device found, idVendor=1e10, idProduct=4000, bcdDevice= 0.00
Dec 18 16:09:50 dario-Modern-14-B11MOL kernel: [ 2471.374934] usb 4-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Dec 18 16:09:50 dario-Modern-14-B11MOL kernel: [ 2471.374936] usb 4-2: Product: Blackfly S BFS-U3-32S4C
Dec 18 16:09:50 dario-Modern-14-B11MOL kernel: [ 2471.374938] usb 4-2: Manufacturer: FLIR
Dec 18 16:09:50 dario-Modern-14-B11MOL kernel: [ 2471.374939] usb 4-2: SerialNumber: 01429F12
Dec 18 16:09:50 dario-Modern-14-B11MOL mtp-probe: checking bus 4, device 10: "/sys/devices/pci0000:00/0000:00:14.0/usb4/4-2"
Dec 18 16:09:50 dario-Modern-14-B11MOL mtp-probe: bus: 4, device: 10 was not an MTP device
Dec 18 16:09:50 dario-Modern-14-B11MOL mtp-probe: checking bus 4, device 10: "/sys/devices/pci0000:00/0000:00:14.0/usb4/4-2"
Dec 18 16:09:50 dario-Modern-14-B11MOL mtp-probe: bus: 4, device: 10 was not an MTP device
Dec 18 16:09:52 dario-Modern-14-B11MOL dbus-daemon[1798]: [session uid=1000 pid=1798] Activating service name='org.gnome.gedit' requested by ':1.224' (uid=1000 pid=7830 comm="/usr/bin/nautilus --gapplication-service " label="unconfined")
Dec 18 16:09:52 dario-Modern-14-B11MOL dbus-daemon[1798]: [session uid=1000 pid=1798] Successfully activated service 'org.gnome.gedit'
Dec 18 16:09:52 dario-Modern-14-B11MOL gnome-shell[2005]: meta_window_set_stack_position_no_sync: assertion 'window->stack_position >= 0' failed
3) If I use the parameters of blackfly_s.launch.py
, stereo_synced.launch.py
works
what do you suggest me?
If you switch "trigger_mode" to off then the camera is free running, i.e. it will produce frames without a trigger signal (hardware sync). I just checked and saw that you edited your original post. You originally claimed that it worked with hardware sync if you ran as separate notes, but then edited that claim away. That's a big difference. I only got your original post via email, not the edit. So is it then working with hardware sync if you run as individual nodes? My feeling is that your hardware sync signal is not working, and that's why you get frames from the stereo node when you switch trigger_mode to "off". So next use SpinView to configure the camera for hardware sync (trigger mode on), just for a single node. Does the camera produce frames when the hardware sync is connected? Does it stop producing frames when disconnected? Then you know your hardware sync is working. Next, bring up two cameras in SpinView, and try to get them working with your hardware sync signal. Again make 100% sure that your hardware sync signal is really working by disconnecting it to make sure the sync signal is working. And BTW, the stereo_synced.launch.py assumes you have an external trigger signal. Is that what you have? Or are you trying to run one as master (produces the signal) and one as slave (receives the signal). Then you need a different setup (and also must have the correct cable/pull up resistor).
I seem to understand that trigger connection is different than master-slave connection.
On the flir site I can only find a schematic. Can you confirm that I need to recreate these connections here?
So do you want master-slave (nowadays called primary-secondary) or do you have an external trigger source (like e.g. an IMU)?
For primary-secondary setup for 2 Blackfly_S cameras, create a sync cable following the link you posted. Here is the relevant diagram:
yes, I want create a primary-secondary setup. I've already created the connections.
reading the link I think that I must change params. Also I create two different camera_params
, one for primary camera and one for secondary camera, right?
'debug': False,
'compute_brightness': True,
'dump_node_map': False,
'gain_auto': 'Off',
'gain': 0,
'exposure_auto': 'Off',
'exposure_time': 9000,
'line2_selector': 'Line2',
'line2_v33enable': False,
'line3_selector': 'Line3',
'line3_linemode': 'Input',
'trigger_selector': 'FrameStart',
'trigger_mode': 'On',
'trigger_source': 'Line3',
'trigger_delay': 9,
'trigger_overlap': 'ReadOut',
'chunk_mode_active': True,
'chunk_selector_frame_id': 'FrameID',
'chunk_enable_frame_id': True,
'chunk_selector_exposure_time': 'ExposureTime',
'chunk_enable_exposure_time': True,
'chunk_selector_gain': 'Gain',
'chunk_enable_gain': True,
'chunk_selector_timestamp': 'Timestamp',
'chunk_enable_timestamp': True,
}```
Correct. Primary and secondary need different parameters. On the primary you need to enable the 3.3V power output as well (above line2_v33enable needs to be set to 'True'). First use SpinView to get the hardware triggering to work. Once that works, adopt the same settings in the ROS driver.
Thank you. My problem was the terminology. In documentation, the word "trigger" is used in general and I thought there was only one type of trigger.
I change the params in this way:
camera_params1 = {
'debug': False,
'compute_brightness': True,
'dump_node_map': False,
'gain_auto': 'Off',
'gain': 0,
'exposure_auto': 'Off',
'exposure_time': 9000,
'line1_selector': 'Line1',
'line1_linemode': 'Output',
'line2_selector': 'Line2',
'line2_v33enable': True,
'trigger_mode': 'Off',
'chunk_mode_active': True,
'chunk_selector_frame_id': 'FrameID',
'chunk_enable_frame_id': True,
'chunk_selector_exposure_time': 'ExposureTime',
'chunk_enable_exposure_time': True,
'chunk_selector_gain': 'Gain',
'chunk_enable_gain': True,
'chunk_selector_timestamp': 'Timestamp',
'chunk_enable_timestamp': True,
}
camera_params2 = {
'debug': False,
'compute_brightness': True,
'dump_node_map': False,
'gain_auto': 'Off',
'gain': 0,
'exposure_auto': 'Off',
'exposure_time': 9000,
'trigger_selector': 'FrameStart',
'trigger_mode': 'On',
'trigger_source': 'Line3',
'trigger_delay': 9,
'trigger_overlap': 'ReadOut',
'chunk_mode_active': True,
'chunk_selector_frame_id': 'FrameID',
'chunk_enable_frame_id': True,
'chunk_selector_exposure_time': 'ExposureTime',
'chunk_enable_exposure_time': True,
'chunk_selector_gain': 'Gain',
'chunk_enable_gain': True,
'chunk_selector_timestamp': 'Timestamp',
'chunk_enable_timestamp': True,
}
outputs line up:
Closing this issue as it seems to be resolved.
Hi,
First thank you for this repo. It's very helpful! I have a problem with camera synchronization. My setup is: Ubuntu 22.04, spinnaker 2.6.0.157 and ROS2 Humble. Also I use Blackfly S (USB 3).
If I execute script:
script doen't work and I haven't any images. My output is:
Am I doing something wrong or can you find a solution?