Motivation
Every CSI crowd counting paper in the vault (Wi-CaL ↗, Zou et al. 2018 ↗, Golam Mowla 2024 ↗, EasyCount ↗, Torun et al. 2026 ↗) relies on manual occupancy annotation or scripted scenarios. This makes data collection expensive, error-prone, and difficult to repeat over long durations.
The mobile app can broadcast BLE advertisements at a known interval. A central BLE listener counts unique advertisement sources = automated people count. This provides continuous, timestamped ground truth that can run for hours or days without human intervention.
Setup
Device Deployment
- CSI TX/RX pairs: Deploy 2-4 ESP32-C5 or Raspberry Pi pairs in the room
- BLE listeners: 1-2 Raspberry Pi sniffers configured in BLE scan mode
- Scan window: continuous
- Filter: only count advertisements matching the app's service UUID
- Mobile app on participants' phones:
- BLE advertisement interval: 1 second (BLE 5.0 extended advertising)
- Unique device identifier in advertisement payload
- TCP/UDP reporting to collection server (heartbeat every 10s)
Room Configuration
- Room dimensions: measure and record (needed for Fresnel zone calculations)
- Furniture layout: photograph and document
- TX/RX positions: record GPS-free coordinates (tape measure from room corners)
- Door/window state: record (affects multipath)
Data Collection Architecture
Mobile App (BLE TX) ──BLE Adv──> Raspberry Pi (BLE Scanner)
│
▼
Collection Server
▲
│
ESP32-C5 (CSI TX) ───WiFi───> ESP32-C5 (CSI RX) ──TCP──┘
Procedure
Phase A: Controlled Validation (1 day)
- Empty room baseline: 10 min CSI + BLE recording with 0 occupants
- Incremental occupancy: add 1 person every 5 minutes, up to 10 people
- Each person carries a phone with the BLE app running
- Manual count at each transition as ground truth for BLE accuracy validation
- Record: CSI data (amplitude + phase, all subcarriers), BLE scan results (MAC, RSSI, timestamp), manual count log
Phase B: Natural Occupancy (3-5 days)
- Deploy in a real meeting room or study area
- Run continuously during working hours (8:00-18:00)
- People enter/leave naturally, all carrying phones with the app
- BLE listener produces automatic occupancy timeline
- CSI devices record continuously
- Spot-check manual counts 3x daily to validate BLE accuracy
Phase C: Stress Testing (1 day)
- Rapid entry/exit: 5 people enter simultaneously, leave simultaneously
- Partial phone coverage: 3 of 5 people have the app (test undercounting)
- BLE interference: test with other BLE devices in range (smartwatches, headphones)
- Edge cases: person stands directly in TX-RX line-of-sight
Expected Outputs
dataset/exp001/csi/— raw CSI captures (amplitude + phase per subcarrier per packet)dataset/exp001/ble/— BLE scan logs (timestamp, MAC/UUID, RSSI)dataset/exp001/ground_truth/— manual count log + BLE-derived count timeline- Synchronization: all devices NTP-synced or PTP-synced to <100ms accuracy
Success Criteria
- BLE-derived occupancy count matches manual count within +/-1 person for >90% of time windows
- CSI data quality: >95% packet capture rate, no hardware dropouts
- Continuous recording: >8 hours without intervention
- Data synchronized across all sources to <500ms
Related Work in Vault
- BLE Can See ↗ — BLE occupancy detection with nRF52840, 95% accuracy. Shows BLE alone is viable for ground truth.
- Human Sensing RF Survey ↗ — comprehensive survey of BLE + WiFi occupancy methods
- Zou et al. 2018 ↗ — CSI features for crowd counting in smart buildings
- Wi-CaL ↗ — ESP32 CSI crowd counting with 4 link pairs, our closest methodological reference
- Zhen et al. 2022 ↗ — adaptive BLE beacon deployment optimization for indoor crowd monitoring
Dependencies
- Mobile app must support BLE extended advertising with configurable UUID
- Collection server (can be Raspberry Pi or laptop) with TCP listener for CSI data and BLE log aggregation
- NTP synchronization across all devices
Notes
This experiment is the foundation for all subsequent experiments (EXP-002 through EXP-005). The automated ground truth pipeline must be validated before it can be trusted for model training and evaluation.