File tree Expand file tree Collapse file tree
components/sec_touch_sniffer Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -99,4 +99,4 @@ Note: discovered state is held in RAM only. After a device restart or firmware f
99992 . Turning scan mode on stops normal polling and listener updates; the text sensor populates with discovered IDs across the configured range.
1001003 . Turning scan mode off mid-scan resumes normal polling immediately; the saved position is used when scan mode is turned on again.
1011014 . When scan mode runs to completion, polling resumes automatically and the binary sensor reflects the off state.
102- 5 . IDs with registered listeners do not appear in passive capture output, but do appear in scan mode output.
102+ 5 . IDs with registered listeners do not appear in passive capture output and are skipped in scan mode, so they do not appear in scan output either.
Original file line number Diff line number Diff line change @@ -60,6 +60,8 @@ void SecTouchSniffer::toggle_scan() {
6060
6161 if (this ->scan_end_ == 0 ) {
6262 ESP_LOGW (TAG, " toggle_scan() called but no scan range configured — ignoring" );
63+ this ->is_scanning_ = false ;
64+ this ->update_scan_switch_ ();
6365 return ;
6466 }
6567
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ struct SniffedEntry {
1919class SecTouchSniffer : public Component , public text_sensor ::TextSensor {
2020 static constexpr const char *TAG = " SecTouchSniffer" ;
2121 // Text sensor payload cap: keeps output within comfortable MQTT/API packet sizes.
22- // Each entry is ~35 chars; 255 chars fits ~7 entries before truncation.
22+ // Each entry is ~35 chars; 2048 chars fits ~58 entries before truncation.
2323 static constexpr size_t MAX_STATE_LEN = 2048 ;
2424
2525 public:
You can’t perform that action at this time.
0 commit comments