I am facing this problem, i know by going to the web page and setting it to local this gets fixed, but i need to know that how do i ensure that after reboot it also works everytime because right now after i restart my jetson this issue again coming -->>
Contacting sensor 169.254.16.106...
Will change udp_dest from '169.254.1.1' to automatically detected UDP DEST
Initializing connection to sensor 169.254.16.106 on lidar port 7502 with udp dest '@auto'...
[2025-04-01 10:45:14.027] [ouster::sensor] [info] Opening port: 7502
[2025-04-01 10:45:14.027] [ouster::sensor] [info] Opening port: 46089
Retrieved metadata:
serial no: 991952000289
firmware version: v2.3.0
product line: OS-1-16-A3
lidar mode: 1024x20
Exception in thread Thread-10:
Traceback (most recent call last):
File "/usr/lib/python3.8/threading.py", line 932, in _bootstrap_inner
self.run()
File "/usr/lib/python3.8/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/home/scooter/Desktop/Recording_ws/swift-pilot/swiftly/two_wheeler/modular/Lidar2.py", line 136, in run
self.lidar_callback()
File "/home/scooter/Desktop/Recording_ws/swift-pilot/swiftly/two_wheeler/modular/Lidar2.py", line 127, in lidar_callback
xyz, timestamp = self.sensor.get_xyz()
File "/home/scooter/Desktop/Recording_ws/swift-pilot/swiftly/two_wheeler/modular/Lidar2.py", line 41, in get_xyz
for packet, *_ in self.source:
File "/home/scooter/.local/lib/python3.8/site-packages/ouster/sdk/client/multi.py", line 45, in collate_scans
for idx, m in source:
File "/home/scooter/.local/lib/python3.8/site-packages/ouster/sdk/sensor/sensor_scan_source.py", line 173, in _scans_iter
raise ClientTimeout(f"No valid scans received within {self._timeout/1e9}s from sensor "
ouster.sdk.client.core.ClientTimeout: No valid scans received within 1.0s from sensor 169.254.16.106 using udp destination 169.254.1.1 on port 7502.
Here’s the code I am using:
from ouster.sdk import client, sensor
from ouster.sdk.client import LidarMode
from contextlib import closing
class OusterSensor:
def __init__(self, hostname):
self.hostname = hostname
self.config = client.SensorConfig()
self.config.lidar_mode = client.LidarMode.MODE_1024x20
self.config.udp_port_lidar = 7502
self.config.udp_port_imu = 7503
self.config.udp_dest = "169.254.1.1"
self.config.operating_mode = client.OperatingMode.OPERATING_NORMAL
client.set_config(self.hostname, self.config, persist=True, udp_dest_auto=False)
self.source = sensor.SensorScanSource(self.hostname)
self.metadata = self.source.metadata[0]
self.xyzlut = client.XYZLut(self.metadata, use_extrinsics=True)
self.interval = 0.05
# Pre-allocate buffer for timestamp to avoid creating new objects
self.timestamp_proto = Timestamp()
I need correct Initialisation parameters so that after restart , config persists.
Same problem i am facing when UDP Destination = Auto
Here’s my connection settings :
IPv4 Method : Manual
Address: 169.254.1.1
Mask: 255.255.0.0