Adaptive sensitivity: auto-tune LiDAR Lite mode based on signal strength

Open
#3 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
arduino, cpp
Domain
embedded-iot

Research direction

First verify NorthernWidget/Project-Apis#18 and the 32-byte register map redesign, since both are prerequisites. Then trace the library's ranging cycle and SensitivityMode handling, using register 0x0A for signal strength and 0x0B for configuration. Done means an opt-in adaptive mode with hysteresis that preserves the default behavior and switches modes only when warranted.

Written by the indexing model from the issue text.

Description

enhancement

Summary

Once signal strength is exposed by the firmware (see NorthernWidget/Project-Apis#18), the library should optionally use it to automatically select the optimal SensitivityMode for current conditions.

Motivation

Conditions that affect LiDAR Lite return quality (target reflectivity, range, ambient light) vary in the field. Static sensitivity settings are a compromise. An adaptive loop could improve range and reduce false positives without manual reconfiguration.

Proposed approach

  • Add an opt-in autoSensitivity mode (off by default to preserve existing behaviour).
  • After each ranging cycle, read the signal strength value from firmware register 0x0A.
  • Apply a simple hysteresis scheme to switch between SensitivityMode values — avoid hunting between modes on noisy boundaries.
  • Write the new mode to firmware register 0x0B (config, writable) when a switch is warranted.

Notes

  • The feedback loop runs at the firmware's ~200 ms cadence; mode changes take effect on the next firmware cycle, so there is inherent lag. Keep the hysteresis wide enough to avoid oscillation.
  • A firmware-side implementation would be more responsive (direct LiDAR Lite register access), but the library approach is easier to iterate on without a firmware flash.

Dependencies

  • Requires firmware support: NorthernWidget/Project-Apis#18 (signal strength at register 0x0A).
  • Requires the 32-byte register map redesign to be in place (config at 0x0B, not 0x01).
Dominant language
C++
Stars
0
Forks
0
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from NorthernWidget/Apis_Library

All issues in NorthernWidget/Apis_Library

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.