# Tuning

See [Device API ](/frc-electronics/can-sensors/can-lidar-am-5684/device-api.md)section for specific methods to change these values

## Mode

* Selects the sensor’s ranging profile, balancing maximum distance, resistance to ambient light, and measurement robustness.&#x20;
* Three options: Short, Medium, and Long
* Recommendation is long range mode for most applications. It provides long range ranging while still being able to measure short distances with minimal noise. If short range accuracy with even less noise is needed, medium range is recommended.&#x20;
* Short range mode is not recommended. It is more difficult to tune and medium range mode can measure short distances accurately with far less tuning
* Default: Long&#x20;

## Timing Budget

* The amount of time (in microseconds) the sensor spends taking a single measurement
* Higher values -> More accurate, more stable readings
* Lower values -> Faster updates, but noisier results
* Default: 50,000 µs

## Intermeasurement Period

* Time between consecutive measurements (in milliseconds).
* Controls update rate of the sensor
* **Must be greater than or equal to the timing budget**
* Default: 50ms

## Timeout

* The amount of time (in microseconds) the sensor spends taking a single measurement.
* Does not improve accuracy
* Prevents code from waiting indefinitely if a reading fails
* Default: 100ms

## Sigma Threshold

* Controls how much measurement noise is allowed before rejecting a reading.
* Lower Values -> Stricter (more accurate, more readings will be rejected)
* Higher Values -> More tolerant (Accepts noisier data)
* Default: 360

## Minimum Signal Rate

* Minimum required signal strength for a measurement to be considered valid.
* Lower Values -> Accepts weaker signals (better long range)
* Higher Values -> Rejects weak/noisy readings
* Default: 0.05 MCPS (Mega counts per seconds)

## Region of Interest (ROI) Width and Height

* Defines the active portion of the sensor's field of view.
* Smaller ROI -> narrower “beam”, less noise, more targeted detection
* Larger ROI -> wider detection area
* Range: 1-16
* 16x16 is full field of view
* Default is 16x16


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.andymark.com/frc-electronics/can-sensors/can-lidar-am-5684/tuning.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
