Review a Wi-Fi site survey and roaming decisions
Evaluate roaming, airtime, and operations evidence by comparing a seeded walk-path survey with threshold and hysteresis decisions.

Radio Remi
Record the input, rule, output and unresolved evidence before making a release or site decision.
Predict the reading, then compare it with the measurement.
Python 3 in your browser (JupyterLite)
Python · no installOpen the notebook in your browser and run each Python cell; no install or account is needed.
Three ways to run: use JupyterLite here with no install; run main.py locally from the downloadable lab folder; or open the same notebook in Google Colab.
Steps
Step 1
- Do
- In the notebook editor, inspect the notebook input cell and run step 1 to see the synthetic walk path.
- You will see
Run the cell. You should see:
- The walk-path table lists 9 positions and RSSI in dBm for AP-A, AP-B and AP-C.
- Why it matters
- A named position and AP identity make the candidate signal difference inspectable before applying a roaming rule.
Code for step 1#!/usr/bin/env python3 """Seeded synthetic Wi-Fi RSSI survey; no radio was measured.""" import argparse import random SEED = 210 BASE = [(-48,-78,-89),(-53,-74,-86),(-59,-70,-82),(-64,-67,-77),(-68,-63,-72),(-72,-59,-67),(-77,-54,-63),(-81,-50,-59),(-85,-48,-55)] APS = ('AP-A','AP-B','AP-C') def survey(): rng = random.Random(SEED) return [tuple(base + rng.choice((-1,0,1)) for base in row) for row in BASE] def choose(rows, threshold=-67, hysteresis=6): current = 0; events=[]; trace=[] for position, row in enumerate(rows): best=max(range(3), key=lambda i: row[i]) if best != current and row[current] <= threshold and row[best]-row[current] >= hysteresis: events.append((position, APS[current], APS[best], row[best]-row[current])) current=best trace.append(APS[current]) return trace,events def pingpong(): return [(-68,-66,-82),(-66,-68,-82),(-68,-66,-82),(-66,-68,-82),(-68,-66,-82),(-66,-68,-82)] def run_step(n): rows=survey(); chosen,events=choose(rows) if n==1: lines=['SYNTHETIC walk-path RSSI, seed=210','position AP-A AP-B AP-C (dBm)']+[f'{i:>8} {a:>4} {b:>4} {c:>4}' for i,(a,b,c) in enumerate(rows)] elif n==2: lines=['Rule: serving <= -67 dBm and improvement >= 6 dB','Position serving candidate candidate-minus-serving'] for i,row in enumerate(rows): best=max(range(3),key=lambda k:row[k]); serving=APS.index(chosen[i]); lines.append(f'{i:>8} {chosen[i]:>7} {APS[best]:>9} {row[best]-row[serving]:>4} dB') elif n==3: lines=['Roam events with threshold=-67, hysteresis=6','position old new improvement']+[f'{p:>8} {a:>4} {b:>4} {d:>4} dB' for p,a,b,d in events] lines.append(f'total events={len(events)}; final AP={chosen[-1]}') elif n==4: zero,zero_events=choose(rows,hysteresis=0) lines=['Sticky-client comparison on same synthetic path','position AP-A AP-B hys=6 hys=0']+[f'{i:>8} {rows[i][0]:>4} {rows[i][1]:>4} {chosen[i]:>5} {zero[i]:>5}' for i in (3,4,5)] lines.append(f'first roam: hys=6 at {events[0][0]}; hys=0 at {zero_events[0][0]}') elif n==5: close=pingpong(); no,ne=choose(close,threshold=-65,hysteresis=0); yes,ye=choose(close,threshold=-65,hysteresis=6) lines=['SYNTHETIC overlap-zone readings; threshold=-65','position AP-A AP-B hys=0 hys=6']+[f'{i:>8} {a:>4} {b:>4} {no[i]:>5} {yes[i]:>5}' for i,(a,b,_) in enumerate(close)] lines.append(f'roams: hys=0 {len(ne)}; hys=6 {len(ye)}') elif n==6: _,ne=choose(pingpong(),threshold=-65,hysteresis=0); _,ye=choose(pingpong(),threshold=-65,hysteresis=6) lines=['DECISION: keep -67 dBm threshold and 6 dB hysteresis for trial',f'walk-path roams={len(events)}; first at position {events[0][0]}',f'overlap-zone roams: no hysteresis={len(ne)}, 6 dB={len(ye)}','sticky boundary: investigate packet loss before tuning','GAP: real client roam logs, packet continuity, measured site RSSI','LIMIT: synthetic table cannot prove deployed roaming'] else: raise ValueError('step must be 1..6') lines.append(f'STEP {n} complete'); print('\n'.join(lines)) run_step(1)
Step 1 · Python 3 in your browser (JupyterLite); numbered callout added to a real capture. Step 2
- Do
- In the notebook editor, run step 2 in the notebook and inspect the threshold and hysteresis rule.
- You will see
Run the cell. You should see:
- The rule prints threshold=-67 dBm and hysteresis=6 dB, then lists the selected AP at each position.
- Why it matters
- A candidate must improve the RSSI by 6 dB once the serving AP is weak; the client owns this decision.
Code for step 2run_step(2)
Step 2 · Python 3 in your browser (JupyterLite); numbered callout added to a real capture. Step 3
- Do
- In the notebook editor, run step 3 in the notebook and inspect the roam event list.
- You will see
Run the cell. You should see:
- The event list names the old AP, new AP, position and RSSI difference for every switch.
- Why it matters
- A roam event is a rule output for these sampled readings; it is not a packet-loss measurement.
Code for step 3run_step(3)
Step 3 · Python 3 in your browser (JupyterLite); numbered callout added to a real capture. Step 4
- Do
- In the notebook editor, run step 4 in the notebook and inspect the sticky-client comparison.
- You will see
Run the cell. You should see:
- At the boundary the current AP remains selected despite a better candidate; a zero-hysteresis comparison switches earlier.
- Why it matters
- This exposes a cost of hysteresis: delaying a switch can leave a client on a weaker AP.
Code for step 4run_step(4)
Step 4 · Python 3 in your browser (JupyterLite); numbered callout added to a real capture. Step 5
- Do
- In the notebook editor, run step 5 in the notebook and inspect the ping-pong trace.
- You will see
Run the cell. You should see:
- Alternating close AP readings switch repeatedly with zero hysteresis and remain stable with 6 dB hysteresis.
- Why it matters
- A deadband can suppress repeated switching in a noisy overlap zone.
Code for step 5run_step(5)
Step 5 · Python 3 in your browser (JupyterLite); numbered callout added to a real capture. Step 6
- Do
- In the notebook editor, run step 6 in the notebook and inspect the decision and limits.
- You will see
Run the cell. You should see:
- The result card records the chosen rule, sticky case, ping-pong counts and a field-test gap.
- Why it matters
- A real acceptance needs device-specific roam logs, packet continuity and measured RSSI at the site.
Code for step 6run_step(6)
Step 6 · Python 3 in your browser (JupyterLite); numbered callout added to a real capture.
Chapter checks
These questions refer to the chapter’s examples. Use the return links to review their answers.
Why should Wi-Fi architecture reviews separate stationary-device reconnect evidence from mobile-device roaming evidence?
Return to the chapter’s knowledge checkA station joins an access point but cannot reach the local service. Which map helps locate the break?
Return to the chapter’s knowledge check
Caution
Before you start
Read this before you start.
These synthetic RSSI readings and a simple client rule do not establish actual device roaming, packet continuity, or site coverage.
Technical details
- Version tested
- Version tested: Python 3.12.7 / Pyodide 0.27.6 in JupyterLite 0.6.4; Chromium 148.0.7778.96; captureSource playwright:jupyterlite. Date: 2026-10-08.
https://iotclass.org/labs/wifi-roaming-survey.html