TryStart with Measured RSSI (dBm) at -65, then move the slider toward a stronger signal.
ObserveAt the default -65 dBm, the card reads NEAR (1–3m) and Strength: 44%. Watch the zone label and bar change as you move the slider.
ExplainMeasured RSSI (dBm) selects a zone by fixed signal cutoffs. The strength bar scales that same input across the slider range.
Technical boundaries. The input spans -100 to -20 dBm in steps of 1; strength is (RSSI + 100) × 100 / 80, clamped to 0–100%. The mapping assumes cutoffs of -50, -70 and -90 dBm for the displayed distance bands, without modelling walls or antenna orientation.
NoteTry It: RSSI Proximity Estimator
Adjust the RSSI value to see how signal strength maps to proximity zones, matching the classification used in the scanner code above.
{const rssi = rssi_val;let zone, color, desc, range;if (rssi >=-50) { zone ="IMMEDIATE"; color ="#16A085"; range ="< 1m"; desc ="Device is within arm's reach. Reliable for tap-to-pair interactions."; }elseif (rssi >=-70) { zone ="NEAR"; color ="#3498DB"; range ="1–3m"; desc ="Device is in the same room area. Good for indoor tracking."; }elseif (rssi >=-90) { zone ="FAR"; color ="#E67E22"; range ="3–10m"; desc ="Device is nearby but possibly obstructed. Position accuracy degrades."; }else { zone ="VERY FAR"; color ="#E74C3C"; range ="> 10m"; desc ="Weak signal — device may be through walls or at long range."; }const pct =Math.max(0,Math.min(100, (rssi +100) *100/80));returnhtml`<div style="background:#f8f9fa;padding:1rem;border-radius:8px;border-left:4px solid ${color};margin-top:0.5rem;"> <div style="display:flex;align-items:center;gap:12px;margin-bottom:8px;"> <span style="font-size:24px;font-weight:bold;color:${color};">${zone}</span> <span style="font-size:14px;color:#7F8C8D;">(${range})</span> </div> <div style="background:#dee2e6;border-radius:4px;height:16px;margin-bottom:8px;"> <div style="background:${color};height:100%;border-radius:4px;width:${pct}%;transition:width 0.2s;"></div> </div> <p style="font-size:13px;margin:0;">${desc}</p> <p style="font-size:12px;color:#7F8C8D;margin:4px 0 0;">Signal: ${rssi} dBm | Strength: ${pct.toFixed(0)}%</p> </div>`;}
Checkpoint: you should now see scan results in the Serial Monitor. Each line should include a device name if one was advertised, an address, an RSSI value in dBm, and a proximity label such as NEAR or FAR.