This is a special resource to control sensors in SENSR.
You can add, delete or modify sensors via this resource.
GET§
-
/[SENSR version]/settings/sensor-ext/list§
Get the list of available config-id and config data type of a specific type of sensor.
You need at least one algo node to get the list.- Parameters
- sensor-type : The type of sensor (
lidar
/odom
/can
)
- sensor-type : The type of sensor (
- Return code
- 200 OK
- 404 NOT FOUND
- List of the types that SENSR API supports natively
Example§
$ curl -X GET 'http://localhost:9080/[SENSR version]/settings/sensor-ext/list?sensor-type=lidar' ** Respond ** [ { "uid": "String", "name": "String", "topic": "String", "sensor": "String", "stack_capacity": "Int", "detection_radius": "Float", "horizontal_angle_range": "Vector2", "use_lidar_timestamp" : "Bool", "use_intensity_filtering" : "Bool", "minimum_intensity": "Float", "retro_reflective_intensity": "Float", "arguments": "Table", "base_to_origin": { "tx": "Float", "ty": "Float" }, "sensor_to_base": { "tz": "Float", "qw": "Float", "qx": "Float", "qy": "Float", "qz": "Float" } } ]
- Parameters
-
/[SENSR version]/settings/sensor-ext§
Get an actual config of the desired sensor.
If you do not pass any sensor-id, this command returns the full sensor-ids in SENSR.
If you pass node-uri, this command returns the full sensor-ids in the specific node only.- Parameters
- sensor-id : ID of sensor.
- node-uri : ID of algo node.(optional)
- Return code
- 200 OK
- 400 BAD REQ
Example§
$ curl -X GET 'http://localhost:9080/[SENSR version]/settings/sensor-ext?sensor-id=lidar_0000' ** Respond ** { "uid": "lidar_0000", "name": "PointCloud", "topic": "/velodyne_points", "sensor": "ROS Message", "stack_capacity": 0, "detection_radius": 1000.0, "horizontal_angle_range": [-180.0, 180.0], "use_lidar_timestamp" : false, "use_intensity_filtering" : false, "minimum_intensity": 0.0, "retro_reflective_intensity": 200.0, "base_to_origin": { "tx": 0.0, "ty": 0.0 }, "sensor_to_base": { "tz": 0.0, "qw": 1.0, "qx": 0.0, "qy": 0.0, "qz": 0.0 }, "arguments": {} } $ curl -X GET 'http://localhost:9080/[SENSR version]/settings/sensor-ext' ** Respond ** [ "lidar_0000", "lidar_0001" ] $ curl -X GET 'http://localhost:9080/[SENSR version]/settings/sensor-ext?node-uri=algo_0000' ** Respond ** [ "lidar_0000" ]
- Parameters
PUT§
-
/[SENSR version]/settings/sensor-ext§
Add a new sensor to the desired algo node. If this command was successful the id of the newly added sensor is returned.
You should pass in the sensor data with this PUT command via the request body. See the POST section for the list of valid sensors.You should also call /commands/apply-change to apply your changes. * Parameters * node-uri : ID of the desired algo node. * sensor-type : The type of sensor (
lidar
/odom
/can
) * Return code * 200 OK * 400 BAD REQExample§
$ curl -X PUT 'http://localhost:9080/[SENSR version]/settings/sensor-ext?node-uri=algo_0000&sensor-type=lidar' --data '{ "name": "PointCloud", "topic": "/velodyne_points", "sensor": "ROS Message", "stack_capacity": 0, "detection_radius": 1000.0, "horizontal_angle_range": [-180.0, 180.0], "use_lidar_timestamp" : false, "use_intensity_filtering" : false, "minimum_intensity": 0.0, "retro_reflective_intensity": 200.0, "base_to_origin": { "tx": 0.0, "ty": 0.0 }, "sensor_to_base": { "tz": 0.0, "qw": 1.0, "qx": 0.0, "qy": 0.0, "qz": 0.0 }, "arguments": {} }' ** Respond ** "lidar_0001"
POST§
-
/[SENSR version]/settings/sensor-ext§
Update the config of the desired sensor. The "uid"-field of the body specifies which sensor this will be applied to. Also note that
topic
should be unique within an algo node.
You should also call /commands/apply-change to apply your changes.- Parameters
- Return code
- 200 OK
- 400 BAD REQ
- List of valid sensor
- "ROS Message"
- "Velodyne 16"
- "Velodyne 32"
- "Velodyne 64"
- "Velodyne 128"
- "Velodyne HDL-32"
- "Hesai 20A"
- "Hesai 20B"
- "Hesai 40P"
- "Hesai 40M"
- "Hesai XT-16"
- "Hesai XT-32"
- "Hesai QT"
- "Hesai 64"
- "Livox"
- "Innoviz Pro" // X86_64 only
- "Innoviz One" // X86_64 only
- "Ouster-OS"
- "Baraja"
- "Cepton Vista"
- "Quanergy"
- "Quanergy MQ-8"
- "Blickfeld Cube 1"
- "Blickfeld Cube Range 1"
- "Luminar Hydra"
- "Innovusion Falcon"
- "AEye 4Sight M"
Example§
$ curl -X POST 'http://[SENSR version]/localhost:9080/settings/sensor-ext' --data '{ "uid": "lidar_0000", "name": "PointCloud", "topic": "/velodyne_points", "sensor": "ROS Message", "stack_capacity": 0, "detection_radius": 1000.0, "horizontal_angle_range": [-180.0, 180.0], "use_lidar_timestamp" : false, "use_intensity_filtering" : false, "minimum_intensity": 0.0, "retro_reflective_intensity": 200.0, "base_to_origin": { "tx": 0.0, "ty": 0.0 }, "sensor_to_base": { "tz": 0.0, "qw": 1.0, "qx": 0.0, "qy": 0.0, "qz": 0.0 }, "arguments": {} }' ** Respond ** 200 OK