I have issues with ToF sensor on a https://shop.luxonis.com/products/oak-d-sr-poe?variant=46456301027551
I am unable to get a preview of the ToF image, the get function never returns:
auto imgFrame = qDepth->get<dai::ImgFrame>(); // Blocking call
I think that somehow the configured embedded ToF resolution is wrong, it should be 640x480? The resolution is currently 1280x3848. The output from my program is linked in github, the commit's parent is v2.29.0. Here is a snippet from the debug logs below:
>> Registered camera ToF33D (s5k33d) as /dev/Camera_0
camera socket: 0, name: tof
config - w: 1280, h: 3848, type: TOF
The code used:
pnerholm/depthai-coreblob/bug/tof/examples/ToF/tof_poe.cpp
pnerholm/depthai-coreblob/bug/tof/examples/CMakeLists.txt
The Logs:
➜ examples git:(bug/tof) ✗ ./tof_poe
[14442C107112B4CF00] [169.254.1.101] [4.887] [system] [warning] PRINT:LeonCss: [OK]: INIT_NOC: noc probes timer create
[OK]: INIT_NOC: noc probes timer start
[OK]: INIT_NOC: ddr bandwith profiling!
GPIO boot mode 0x3, interface SPI_MASTER_EFF
Setting aons(0..4) back to boot from flash (offset = 0)
====ENABLE WATCHDOG====1
initial keepalive, countdown: 7
PLL0: 700000 AUX_IO0: 24000 AUX_IO1: 24000 MCFG: 24000 MECFG: 24000
Board init ret 3
DepthAI Firmware - version: 4d360b5c56225f23e9a3d3a3999ce46c90cfdeaf
eeprom configuration version: 55AA0007
Reading VERSION 7 --- ->
eeprom configuration load from user area, status: 0
Reading VERSION 7 --- ->
Found a device/board entry matching the eeprom data - Board: OAK-D SR POE (R3M3E3) Device: OAK-D-SR-POE
Board options: 00001901
Overriding GPIO bootstrap with boot mode from eeprom boardOptions. Boot mode: 0x3
--> brdInit ...
brdInitAuxDevices: Error: SC = 27: io_initialize expander_cam_gpios_1 [OK]
spi_N25Q_init: Flash JEDEC ID: 20 bb 19
Initialized pin: 43, mode: 7, level: 0, pad: 0x00000010
Initialized pin: 59, mode: 7, level: 1, pad: 0x00000010
Initialized pin: 51, mode: 7, level: 1, pad: 0x00000010
Initialized pin: 61, mode: 7, level: 0, pad: 0x00000050
Initialized pin: 60, mode: 7, level: 0, pad: 0x00000010
Initialized pin: 30, mode: 7, level: 1, pad: 0x00000010
inited hal ---
def: 53 46 45 34 10 06 08 34 10 53 14 45 46 08 06
val: 16 11 45 15 15 06 08 15 15 16 14 45 11 08 06
Opening bus for IR driver: 1
Failed to probe IR driver LM3644
Opening bus for IR driver: 2
LM3644 detected, ID = 0x02
===== IR write bus 2: 0x07 = 0x89
===== IR write bus 2: 0x02 = 0x01
===== IR write bus 2: 0x03 = 0x00
===== IR write bus 2: 0x04 = 0x00
===== IR write bus 2: 0x05 = 0x00
===== IR write bus 2: 0x06 = 0x00
===== IR write bus 2: 0x07 = 0x09
===== IR write bus 2: 0x08 = 0x1a
===== IR write bus 2: 0x09 = 0x08
===== IR write bus 2: 0x01 = 0x24
Opening bus for IR driver: 3
Failed to probe IR driver LM3644
Closing EEPROm!
MyriaX board configuration
pll0 frequency: 700000, ref0 frequency: 24000
Setup network with bootloader config
OsDrvCprSysDeviceAction() for PCIe failed: 13
nexus0: <RTEMS Nexus device>
pcib0: <MyriadX PCIe RC> on nexus0
PCIE_REGS_PCIE_CFG_ADR = 0x60100
PCIE_REGS_PCIE_PLL_CNTRL_ADR = 0x1
pcib0: Link training complete, PCIe downstream link is UP
pcib0: myriad_pcie_err_interrupt: SMLH LINK UP
pcib0: myriad_pcie_err_interrupt: SMLH LINK DOWN
pcib0: myriad_pcie_err_interrupt: RDLH LINK UP
pcib0: myriad_pcie_err_interrupt: RDLH LINK DOWN
pcib0: myriad_pcie_err_interrupt: CORE RST
pcib0: myriad_pcie_err_interrupt: CORE RSTN
pci0: <PCI bus> on pcib0
memcpy_dma_init: got DMA id 62
re0: <Realtek PCIe GBE Family Controller> mem 0x1000000-0x1000fff,0x1004000-0x1007fff at device 0.0 on pci0
re0: Using Memory Mapping!
re0: Using 1 MSI message
Overriden invalid mac address, mac: 44:A9:2C:3D:28:F2
re0: version:1.95.00
re0: Ethernet address: 0x83eccb90
This product is covered by one or more of the following patents:
US6,570,884, US6,115,776, and US6,327,625.
info: re0: Ethernet address: 44:a9:2c:3d:28:f2
myriad_mmc2: <MyriadX MMC> on nexus0
myriad_mmc2: Memory resource: rid 0 tag 0x0 handle 0x33000000 size 0x1
myriad_mmc2: Found that the memory was NULL - releasing.
myriad_mmc2: Error getting voltage regulator resource.
myriad_mmc2: Found that the memory was NULL - releasing.
myriad_mmc2: Error getting card detect resource.
myriad_mmc2: Memory resource: rid 3 tag 0x0 handle 0x20280000 size 0x1
myriad_mmc2: Memory resource: rid 4 tag 0x0 handle 0x83cfdbc8 size 0x1
myriad_mmc2: IRQ resource: start 0xa001b: irq = 27, priority = 10
myriad_mmc2: Doing host configuration ... 5
myriad_mmc2: CFG 0x0 = 0xffb23840
myriad_mmc2: CFG 0x4 = 0x1c008be
myriad_mmc2: CFG 0x24 = 0xb00a621
myriad_mmc2: CFG 0x2c = 0xa000
myriad_mmc2: Polling CFG 0x40 for 0x40
myriad_mmc2: Polling complete, value became 0x5c
myriad_mmc2: Base clock = 200000000 Hz
myriad_mmc2: Re-tuning mode is 1
myriad_mmc2: Re-Tuning timer count is 1 seconds
myriad_mmc2: SDR50 needs tuning.
myriad_mmc2: Supports Vdd=3.3
myriad_mmc2: Supports Vdd=3.0
myriad_mmc2: Supports Vdd=1.8
myriad_mmc2: Supports 8-bit bus width
myriad_mmc2: Supports High Speed
myriad_mmc2: Supports DDR50, DDR52 @ 1.8V
myriad_mmc2: Supports HS200 @ 1.8V
myriad_mmc2: Supports Driver Type A
myriad_mmc2: Supports Driver Type C
myriad_mmc2: Supports Driver Type D
myriad_mmc2: Data timeout counter value = 0xc
myriad_mmc2: Data timeout clock frequency = 48000 kHz, timeout count = 0xc
myriad_mmc2: No voltage regulator.
myriad_mmc2: Card detect task up!
myriad_mmc2: Card attached!
mmc0: <MMC/SD bus> on myriad_mmc2
myriad_mmc2: Updating card mode to SD
myriad_mmc2: Updating card mode to MMC
Probed device vendor id: 0x0, device id 0x0
mmc0: No information for this mode.
mmcsd0: 16GB <MMCHC DF4016 0.1 SN 3BCED228 MFG 02/2023 by 69 0x0000> at mmc0 200.0MHz/8bit/1-block
mmcsd0boot0: 4MB partition 1 at mmcsd0
mmcsd1boot1: 4MB partition 2 at mmcsd0
mmcsd0rpmb: 4MB partition 3 at mmcsd0
net.inet.tcp.delayed_ack: 1 -> 0
info: lo0: link state changed to UP
ifconfig: inet6: bad value
ifcommand setting static ip: 169.254.1.101 mask: 255.255.255.0, gateway: 168.254.1.100
route: writing to routing socket: Network is unreachable
ifcommand failed: exit_code = 1
=== Network ready!
Is booted from flash by bootloader: 0
Started device discovery service!
Waiting for broadcast message..
=== Enumerating on socket: Cam_A / RGB / Center
skipped OV7251
skipped AR0234
>> Registered camera ToF33D (s5k33d) as /dev/Camera_0
camera socket: 0, name: tof
config - w: 1280, h: 3848, type: TOF
Adding socket 0: cam 22. Sen name: S5K33D
=== Enumerating on socket: Cam_B / Left
>> Registered camera TG161B (ov9282) as /dev/Camera_1
camera socket: 1, name: left
config - w: 1280, h: 720, type: COLOR
config - w: 1280, h: 800, type: COLOR
config - w: 640, h: 400, type: COLOR
Adding socket 1: cam 5. Sen name: OV9782
=== Enumerating on socket: Cam_C / Right
>> Registered camera TG161B (ov9282) as /dev/Camera_2
camera socket: 2, name: right
config - w: 1280, h: 720, type: COLOR
config - w: 1280, h: 800, type: COLOR
config - w: 640, h: 400, type: COLOR
Adding socket 2: cam 5. Sen name: OV9782
Found a device/board entry matching the eeprom data - Board: OAK-D SR POE (R3M3E3) Device: OAK-D-SR-POE
Initializing XLink...
info: re0: link state changed to DOWN
initial keepalive, countdown: 6
initial keepalive, countdown: 5
info: re0: link state changed to UP
re0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=8219b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,WOL_MAGIC,LINKSTATE>
ether 44:a9:2c:3d:28:f2
inet 169.254.1.101 netmask 0xffffff00 broadcast 169.254.1.255
media: Ethernet autoselect (1000baseT <full-duplex>)
status: active
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Received device discovery request, sending back - mxid: 14442C107112B4CF00, state: 1
Done!
Temperature: Driver registered.
Temperature: Initialized driver.
Temperature: Sensor opened: CSS.
Temperature: Sensor opened: MSS.
Temperature: Sensor opened: UPA.
Temperature: Sensor opened: DSS.
[14442C107112B4CF00] [169.254.1.101] [4.909] [system] [warning] PRINT:LeonCss: I: [Timesync] [ 8465150] [XLin] startSync:186 Timesync | Callback not set
Connected cameras: [14442C107112B4CF00] [169.254.1.101] [4.975] [system] [warning] PRINT:LeonCss: [1970-01-01 00:00:04.971] [info] Time taken to build the pipeline: 40ms
== FSYNC enabled for cam mask 0x0
CAM ID: 0, width: 1280, height: 3848, orientation: 3
s5k33d_set_config: [0] 1280 x 3848, 60.00 fps, fsync delay 1133333 ns, readout order 0
getDefaultDtp: camType:22, color:1, orientation:3
DTP: ext_dtp_database
Loaded DTP, handle 0x84417da8
== SW-SYNC: 0, cam mask 0x1
!!! Master Slave config is: master_all !!!
Starting camera 0, server 0x84417da8
[E] app_guzzi_command_callback():173: command->id:1
[E] app_guzzi_command_callback():193: command "1 0" sent
[14442C107112B4CF00] [169.254.1.101] [4.976] [system] [warning] PRINT:LeonMss: sippPalThreadCreate: Thread /SIPP created
LRT - build pipeline call
[14442C107112B4CF00] [169.254.1.101] [4.997] [system] [warning] PRINT:LeonCss: [E] iq_debug_create():161: iq_debug address 0x877c98c0
[14442C107112B4CF00] [169.254.1.101] [5.008] [system] [warning] PRINT:LeonCss: [E] hai_cm_driver_load_dtp():852: Features for camera ToF33D (s5k33d) are received
[E] set_dtp_ids():396: //VIV HAL: Undefined VCM DTP ID 0
[E] set_dtp_ids():405: //VIV HAL: Undefined NVM DTP ID 0
[E] set_dtp_ids():414: //VIV HAL: Undefined lights DTP ID 0
camera_id 0: 3A-sync to camera_alt_id 0
[E] camera_control_start():360: Camera_id = 0 started.
[E] lens_move_to_def_pos_do():251: Error executing af_move_to_pos()!
[E] hai_cm_sensor_select_mode():164: No suitable sensor mode. Selecting default one - 0 for start 1280x3848 at 0x0 fps min 60.000000 max 60.000000
[E] hai_cm_sensor_select_mode():164: No suitable sensor mode. Selecting default one - 0 for start 1280x3848 at 0x0 fps min 60.000000 max 60.000000
============================ Configuring S5k33d with mode 0 - Camera_0_sen, lpfr 3092
3
[14442C107112B4CF00] [169.254.1.101] [5.393] [system] [warning] PRINT:LeonCss: [E] vpipe_conv_config():1465: Exit Ok
[E] callback():133: Camera CB START_DONE event.
[14442C107112B4CF00] [169.254.1.101] [5.404] [system] [warning] PRINT:LeonCss: inc_camera_process set exposure and gain
Starting Guzzi command handling loop...
[14442C107112B4CF00] [169.254.1.101] [6.042] [system] [warning] PRINT:LeonCss: initial keepalive, countdown: 4
[14442C107112B4CF00] [169.254.1.101] [8.396] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [11.399] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [14.402] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [17.405] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [20.397] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [23.400] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [26.403] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [29.395] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [32.398] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [35.401] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [38.404] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0
[14442C107112B4CF00] [169.254.1.101] [41.396] [system] [warning] PRINT:LeonCss: W: 6 - 0 - 0