Skip to content

Channel Analysis

Arunkumar Mourougappane edited this page Oct 25, 2025 · 1 revision

Channel Analysis

Professional WiFi spectrum analysis and channel optimization guide for ESP32 WiFi Utility v4.2.0.

Overview

The Channel Analysis system provides enterprise-grade 2.4GHz spectrum analysis with AI-powered channel recommendations, congestion detection, and interference identification.

Quick Start

Basic Channel Scan

> mode station
> channel scan

Gets congestion levels for all channels in ~5 seconds.

AI Recommendations

> channel recommend

Analyzes spectrum and suggests optimal channels.

Channel Scanning

Quick Scan (Default)

Command:

> channel scan
> channel scan quick

Duration: ~5 seconds

Output:

Scanning 2.4GHz spectrum...
Channel 1: 3 networks (Light congestion) - 25%
Channel 2: 5 networks (Moderate congestion) - 42%
Channel 3: 7 networks (Moderate congestion) - 58%
Channel 4: 4 networks (Light congestion) - 33%
Channel 5: 6 networks (Moderate congestion) - 50%
Channel 6: 12 networks (Severe congestion) - 100%
Channel 7: 8 networks (Heavy congestion) - 67%
Channel 8: 6 networks (Moderate congestion) - 50%
Channel 9: 4 networks (Light congestion) - 33%
Channel 10: 5 networks (Moderate congestion) - 42%
Channel 11: 9 networks (Heavy congestion) - 75%
Channel 12: 2 networks (Clear) - 17%
Channel 13: 1 network (Clear) - 8%

Analysis complete in 5.2 seconds

Detailed Scan

Command:

> channel scan detailed

Duration: ~30 seconds

Features:

  • Extended sampling per channel
  • Statistical analysis
  • Interference pattern detection
  • Historical comparison

Continuous Monitoring

Start:

> channel monitor start

Stop:

> channel monitor stop

Status:

> channel status

Features:

  • Background spectrum monitoring
  • Configurable intervals (1-60 seconds)
  • Real-time congestion tracking
  • Trend analysis

Congestion Levels

5-Level Scale

Clear (0-20%)

  • 0-2 networks detected
  • Optimal performance
  • Minimal interference
  • Best choice for new AP

Light (20-40%)

  • 3-5 networks detected
  • Good performance
  • Minor interference possible
  • Acceptable choice

Moderate (40-60%)

  • 6-8 networks detected
  • Fair performance
  • Noticeable interference
  • Use if better unavailable

Heavy (60-80%)

  • 9-12 networks detected
  • Degraded performance
  • Significant interference
  • Avoid if possible

Severe (80-100%)

  • 13+ networks detected
  • Poor performance
  • Heavy interference
  • Not recommended

Congestion Calculation

// Simplified algorithm
networks_on_channel = count(networks[channel]);
max_networks = 15;  // Practical maximum
congestion = (networks_on_channel / max_networks) Γ— 100;
congestion = min(congestion, 100);  // Cap at 100%

AI Channel Recommendations

Getting Recommendations

Command:

> channel recommend

Example Output:

🧠 AI Channel Analysis Results:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

πŸ† Best Channel: 13 (Score: 9.2/10)
   β”œβ”€ Networks: 1 (Clear congestion)
   β”œβ”€ Signal Quality: Excellent
   β”œβ”€ Interference: Minimal
   └─ Reason: Minimal interference, optimal signal
              propagation, least utilized channel

πŸ“Œ Alternative: 1 (Score: 8.7/10)
   β”œβ”€ Networks: 3 (Light congestion)
   β”œβ”€ Signal Quality: Very Good
   β”œβ”€ Interference: Low
   └─ Reason: Low congestion, good compatibility
              with older devices

⚠️  Avoid: 6 (Score: 3.1/10)
   β”œβ”€ Networks: 12 (Severe congestion)
   β”œβ”€ Signal Quality: Poor
   β”œβ”€ Interference: High
   └─ Reason: Severe congestion, high packet loss
              likely, poor user experience

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Recommendation Algorithm

Scoring Factors:

  1. Network Count (40% weight)

    • Fewer networks = higher score
    • Linear penalty for additional networks
  2. Channel Overlap (30% weight)

    • Adjacent channel interference
    • Overlap coefficient calculation
    • Mathematical interference modeling
  3. Signal Strength (20% weight)

    • Average RSSI on channel
    • Weaker signals = less interference
  4. Channel Position (10% weight)

    • Non-overlapping channels preferred (1, 6, 11)
    • Edge channels bonus (1, 13)

Formula:

score = (1.0 - network_penalty) Γ— 0.4
      + (1.0 - overlap_penalty) Γ— 0.3
      + signal_quality Γ— 0.2
      + position_bonus Γ— 0.1

Channel Overlap & Interference

2.4GHz Channel Spacing

Channel Width: 22 MHz
Channel Spacing: 5 MHz

Result: Significant overlap between adjacent channels

Non-Overlapping Channels

Only 3 non-overlapping channels in 2.4GHz:

  • Channel 1 (2412 MHz)
  • Channel 6 (2437 MHz)
  • Channel 11 (2462 MHz)

Recommendation: Use only these for minimal interference.

Overlap Calculation

overlap = max(0, 1 - abs(ch1 - ch2) / 5)

Examples:
Channel 1 & 2: overlap = 0.8 (80% overlap)
Channel 1 & 6: overlap = 0.0 (no overlap)
Channel 6 & 7: overlap = 0.8 (80% overlap)

Interference Impact

High Overlap (>60%):

  • Packet collisions
  • Reduced throughput
  • Increased latency
  • Connection instability

Low Overlap (<20%):

  • Minimal impact
  • Normal performance
  • Stable connections

Web Interface

Channel Analysis Page

Access at http://[device-ip]/channels

Features:

  • Visual spectrum display
  • Color-coded congestion levels
  • Interactive channel selection
  • Real-time updates
  • Export functionality

Chart Visualization:

  • Bar graph showing network counts
  • Color gradients for congestion
  • Clickable channels for details
  • Responsive mobile design

Starting Analysis

  1. Navigate to /channels
  2. Click "Start Channel Scan"
  3. Wait for analysis (~5 seconds)
  4. Review results and recommendations
  5. Apply suggested channel to AP

Data Export

JSON Export

Command:

> channel export

Output Format:

{
  "timestamp": 1698192000,
  "scan_duration_ms": 5234,
  "channels": [
    {
      "number": 1,
      "frequency_mhz": 2412,
      "network_count": 3,
      "congestion_percent": 25,
      "congestion_level": "Light",
      "avg_rssi_dbm": -65,
      "networks": [
        {
          "ssid": "Network1",
          "bssid": "AA:BB:CC:DD:EE:FF",
          "rssi": -45
        }
      ]
    }
  ],
  "recommendations": {
    "best": 13,
    "alternative": 1,
    "avoid": [6, 11]
  }
}

Use Cases

  • External analysis tools
  • Long-term monitoring
  • Network planning
  • Documentation
  • Troubleshooting

Advanced Features

Interference Detection

Types Detected:

  1. Microwave Ovens

    • Broadband interference
    • Intermittent patterns
    • 2.4GHz frequency range
  2. Bluetooth Devices

    • Frequency hopping patterns
    • Short-duration interference
    • Similar frequency range
  3. Continuous Wave

    • Steady interference source
    • Specific frequency
    • Often from faulty equipment

Detection Method:

  • Signal pattern analysis
  • Frequency distribution
  • Temporal characteristics

Historical Trending

Track Over Time:

  • Channel congestion changes
  • New network appearances
  • Signal strength variations
  • Interference patterns

Benefits:

  • Identify busy times
  • Plan maintenance windows
  • Optimize long-term
  • Predict issues

Performance Metrics

Scan Speed

  • Quick Scan: 3-5 seconds
  • Detailed Scan: 25-30 seconds
  • Per Channel: ~200-400ms

Accuracy

  • Network Count: 100% accurate
  • RSSI Measurements: Β±1 dBm
  • Congestion Levels: Β±5%

Resource Usage

  • Memory: <8KB RAM during scan
  • Flash: ~45KB code size
  • CPU: ~40-60% during active scan
  • Power: ~260mA during scan

Best Practices

Optimal Channel Selection

  1. Run detailed scan during peak usage
  2. Review AI recommendations
  3. Consider non-overlapping channels (1, 6, 11)
  4. Check edge channels (1, 13) if congested
  5. Avoid heavily used channels
  6. Test selected channel
  7. Monitor performance

When to Rescan

  • New networks detected
  • Performance degradation
  • After moving AP
  • Neighborhood changes
  • Monthly routine check

AP Configuration

After finding optimal channel:

# Save with optimal channel
> ap config "MyNetwork" "SecurePass" 13 auto

# Restart in AP mode
> reset

Troubleshooting

Scan Fails

Causes:

  • Not in station mode
  • WiFi busy
  • Hardware error

Solutions:

> mode station
> channel scan

Inconsistent Results

Causes:

  • Networks turning on/off
  • Moving devices
  • Environmental changes

Solutions:

  • Run multiple scans
  • Use detailed scan mode
  • Average results

No Recommendations

Causes:

  • No scan data available
  • All channels equally congested

Solutions:

  • Run channel scan first
  • Try detailed scan
  • Check scan completed successfully

← Back to Home | Next: Performance Testing β†’

πŸ“‘ ESP32 WiFi Utility

🏠 Main

πŸ“¦ Setup

βš™οΈ Configuration

πŸ“Š Features

πŸ’» Development

πŸ†˜ Support

πŸ”— Links


Version: 4.2.0
License: MIT

Clone this wiki locally