CPU and resource usage
High CPU usage
High CPU usage
Symptom: TCP Streamer consumes excessive CPU resources, causing system slowdown or thermal issues.Normal CPU usage:
- Idle (not streaming): <1% CPU
- Active streaming: 1-5% CPU on modern systems
- Peak during buffering: 5-10% CPU briefly
-
Increase buffer size
- Change from 256 or 512 to 1024 or 2048 samples
- Reduces callback frequency from audio system
- Trade-off: Slightly higher minimum latency
- Recommended: 1024 for balanced performance
Buffer Size Callbacks/sec (48kHz) CPU Impact 256 ~188/sec High 512 ~94/sec Medium 1024 ~47/sec Low 2048 ~23/sec Very Low -
Lower sample rate
- Switch from 48 kHz to 44.1 kHz
- Reduces data processing by ~8%
- Use if 48 kHz isn’t required for your use case
-
Disable unused features
- Turn off adaptive buffering if network is stable
- Disable silence detection if not needed
- Reduce activity log verbosity
-
Check for background interference
- Antivirus scanning audio data
- Other audio applications competing for resources
- System performing background tasks (updates, indexing)
-
Hardware acceleration (v1.7.0+)
- Hybrid spin-wait strategy reduces CPU usage while maintaining precision
- Automatic in v1.7.0+, no configuration needed
Memory usage concerns
Memory usage concerns
Symptom: TCP Streamer memory usage seems high or grows over time.Normal memory usage:Large buffer configurations:
- Base application: ~50-100 MB
- Ring buffer (8000ms WASAPI): ~2.3 MB
- Ring buffer (5000ms standard): ~1.4 MB
- Total typical usage: ~100-150 MB
- 15 second buffer at 48kHz: ~2.9 MB
- 20 second buffer at 48kHz: ~3.8 MB
- Memory usage is minimal even with large buffers
-
Check for memory leaks
- Monitor memory usage over time
- If it continuously grows without limit, report as bug
- Normal usage should stabilize after initial buffer allocation
-
Restart the application
- Clears any accumulated memory
- Resets buffer allocations
-
Reduce buffer size
- Only if memory is severely constrained
- Impact is minimal unless using 30+ second buffers
Ring buffer memory usage is constant during streaming and is released when streaming stops. Memory should not grow indefinitely.
Application responsiveness
Application responsiveness
Symptom: UI feels sluggish or unresponsive during streaming.Causes and solutions:
-
High CPU usage
- See “High CPU usage” section above
- Increase buffer size to reduce processing frequency
-
Slow disk I/O
- If logs are being written to slow disk
- Move application to SSD if on HDD
- Reduce logging verbosity
-
UI update frequency
- Real-time statistics update frequently
- Normal behavior, should not cause significant issues
- If problematic, minimize window to tray
-
System-wide performance issues
- Check overall system resources
- Close unnecessary applications
- Ensure adequate free RAM
Buffer optimization
Buffer underruns/dropouts
Buffer underruns/dropouts
Symptom: Audio has brief gaps, clicks, or pops indicating buffer starvation.Understanding buffers in TCP Streamer:
- Audio buffer: Hardware buffer (256-2048 samples, ~5-43ms)
- Ring buffer: Software buffer (2000-15000ms)
- Network buffer: TCP send buffer (system-managed)
-
Ring buffer too small for network jitter
- WiFi has variable latency
- Small buffer can’t absorb jitter spikes
-
Network congestion
- Packets delayed or lost
- Buffer drains waiting for network
-
CPU starvation
- System can’t keep up with audio callbacks
- Processing delays cause buffer gaps
-
Enable adaptive buffering
- Automatically adjusts buffer size based on jitter
- Prevents underruns without manual tuning
- Set appropriate min/max range for your network
-
Increase base ring buffer
- Ethernet: 2000-4000ms
- WiFi: 4000-8000ms
- WiFi (Poor): 8000-15000ms
-
Use network presets
- Ethernet: Optimized for stable wired
- WiFi: Balanced for wireless
- WiFi (Poor): Maximum stability
-
Increase audio buffer size
- 512 → 1024 or 1024 → 2048
- Gives more time between callbacks
- Reduces real-time processing pressure
-
Enable high priority thread (Advanced)
- Gives audio processing priority over other tasks
- Can reduce latency jitter
- May impact other applications
Excessive latency
Excessive latency
Symptom: Audio arrives at the server with noticeable delay (seconds behind real-time).Latency components:Reducing latency:
-
Use wired Ethernet
- Eliminates WiFi jitter
- Allows smaller ring buffer (2000ms)
- Network delay drops to 1-5ms
- Can achieve ~2 second total latency
-
Decrease ring buffer
- Only if network is very stable
- Monitor network quality indicator
- Should stay “Excellent” or “Good”
- Risk: More dropouts if jitter increases
-
Use smaller audio buffer
- 1024 → 512 or 512 → 256
- Reduces first-stage latency
- Impact is small (a few milliseconds)
- May increase CPU usage
-
Disable adaptive buffering
- If network is stable, fixed buffer is smaller
- Adaptive buffer tends toward maximum under uncertainty
-
Server-side latency compensation
- Snapcast and similar servers can adjust client delays
- Use server configuration to sync multiple clients
- TCP Streamer latency is consistent and predictable
| Configuration | Ring Buffer | Network | Total (approx) |
|---|---|---|---|
| Ethernet (optimal) | 2000ms | 1-5ms | ~2 seconds |
| WiFi (good signal) | 4000ms | 10-30ms | ~4 seconds |
| WiFi (poor signal) | 8000ms | 30-100ms | ~8 seconds |
| WASAPI WiFi laptop | 4000-12000ms | 20-50ms | 4-12 seconds |
For multi-room synchronized audio, latency consistency matters more than absolute latency. TCP Streamer provides stable, predictable latency that servers can compensate.
Buffer constantly resizing (adaptive)
Buffer constantly resizing (adaptive)
Symptom: Activity log shows frequent “Buffer resized” messages.Normal behavior:
- Adaptive buffer checks jitter every 10 seconds
- Adjusts if jitter trends above or below thresholds
- Should stabilize after 30-60 seconds
- Occasional adjustments are normal
-
Unstable network
- WiFi signal fluctuating
- Interference from other devices
- Congestion from other traffic
- Move closer to router
- Switch to 5GHz WiFi band
- Use wired Ethernet
- Increase adaptive buffer maximum
-
Aggressive min/max range
- Small difference between min and max
- Insufficient headroom for jitter variation
- Widen the min/max range
- Example: 2000-6000ms → 2000-10000ms
- Allows more gradual adjustments
-
System resource contention
- Other applications causing scheduling jitter
- Antivirus scanning
- System updates
- Close unnecessary applications
- Pause system updates during critical streaming
- Disable real-time antivirus scanning of audio processes
Network performance
Network quality degradation
Network quality degradation
Symptom: Network quality indicator shows “Fair” or “Poor” when expecting “Excellent” or “Good”.Network quality thresholds:
- Excellent: Jitter < 5ms
- Good: Jitter 5-20ms
- Fair: Jitter 20-50ms
- Poor: Jitter > 50ms
-
Check ping statistics
-
Test network throughput
-
Check WiFi signal strength
- Windows: Settings → Network & Internet → WiFi → Hardware properties
- macOS: Hold Option, click WiFi icon (RSSI, noise, rate)
- Linux:
iwconfigornmcli dev wifi
Signal Strength Quality Expected Jitter > -50 dBm Excellent <5ms -50 to -60 dBm Good 5-15ms -60 to -70 dBm Fair 15-50ms < -70 dBm Poor >50ms
-
WiFi optimization
- Move closer to access point
- Switch to 5GHz band (less interference, shorter range)
- Avoid physical obstructions (walls, metal objects)
- Change WiFi channel to avoid interference
- Update router firmware
-
Reduce network congestion
- Pause downloads/uploads during streaming
- Enable QoS (Quality of Service) on router
- Use DSCP/TOS tagging in TCP Streamer Advanced settings
- Prioritize audio traffic over bulk data
-
Use wired connection
- Ethernet eliminates WiFi variability
- Consistent <1ms jitter typical
- Most reliable solution for critical streaming
Wired Ethernet should always show “Excellent” network quality. If not, investigate server resource issues or network infrastructure problems.
Bandwidth consumption
Bandwidth consumption
Symptom: Concerned about network bandwidth usage or data caps.Calculating bandwidth:Hourly/daily data usage:
Reducing bandwidth:
| Configuration | Per Hour | Per Day (24h) |
|---|---|---|
| 48 kHz | ~660 MB | ~15.8 GB |
| 44.1 kHz | ~609 MB | ~14.6 GB |
-
Enable silence detection
- Stops transmission during silence
- Savings depend on content:
- Music: 10-20% (brief pauses between tracks)
- Podcasts/Audiobooks: 30-50% (pauses between speech)
- Variable content: Up to 70%
-
Lower sample rate
- 48 kHz → 44.1 kHz saves ~8%
- Imperceptible quality difference for most content
-
Stream only when needed
- Use auto-stream sparingly
- Manually start/stop streaming
- Leverage silence detection timeout
-
Consider compression (future)
- Current version uses raw PCM (no compression)
- Compressed formats (FLAC, Opus) would reduce bandwidth significantly
- Not currently supported (would require server-side changes)
TCP Streamer shows real-time bitrate and total data sent in the statistics panel. Monitor this to understand your actual bandwidth usage patterns.
Jitter monitoring and analysis
Jitter monitoring and analysis
Symptom: Want to understand jitter patterns and optimize for network conditions.Understanding jitter:Jitter is variation in packet timing. High jitter requires larger buffers to maintain continuous playback.Built-in jitter monitoring:Jitter patterns:
- Real-time jitter display in Advanced tab
- Network quality score derived from jitter
- Adaptive buffer uses jitter to resize automatically
-
Steady low jitter (<5ms)
- Wired Ethernet typical
- Can use minimum buffer settings
-
Steady moderate jitter (5-20ms)
- Good WiFi typical
- Use WiFi preset settings
-
Variable jitter (spikes to 50ms+)
- WiFi interference or congestion
- Enable adaptive buffering
- Consider wired connection
-
Periodic jitter spikes
- Often caused by background tasks
- Identify with system monitoring
- Schedule intensive tasks outside streaming hours
Advanced performance tuning
Precision pacer optimization
Precision pacer optimization
Background: TCP Streamer v1.7.0+ uses a Token Bucket algorithm with hybrid spin-wait for mathematically perfect audio pacing.How it works:
Recommendations:
- Calculates exact time for each audio chunk
- Prevents micro-bursts that cause network jitter
- Hybrid spin-wait provides sub-millisecond precision
- Automatically optimized in v1.7.0+
| Chunk Size | Updates/sec | CPU Impact | Timing Precision |
|---|---|---|---|
| 128 | ~375/sec | High | Excellent |
| 256 | ~188/sec | Medium | Excellent |
| 512 | ~94/sec | Low | Good |
| 1024 | ~47/sec | Very Low | Good |
| 2048 | ~23/sec | Minimal | Adequate |
| 4096 | ~12/sec | Minimal | Adequate |
- Low-latency: 256-512 samples
- Balanced: 1024 samples (default)
- Low CPU: 2048-4096 samples
The precision pacer automatically prevents network bursts. You typically don’t need to adjust chunk size unless optimizing for specific constraints.
DSCP/TOS QoS tagging
DSCP/TOS QoS tagging
Background: DSCP (Differentiated Services Code Point) tags packets for Quality of Service priority on routers.Available options in Advanced settings:
- VoIP (EF - Expedited Forwarding): Highest priority, low latency
- Low Delay: High priority for time-sensitive data
- Throughput: Optimize for high bandwidth
- Default (Best Effort): No special priority
- Network congestion: Other traffic competes with audio stream
- Shared connections: Multiple users or devices
- QoS-enabled router: Router must respect DSCP tags
- Requires router QoS support
- May require administrator privileges
- ISP may strip DSCP tags at WAN boundary
- Only helps on local network unless ISP honors tags
- Enable QoS on router
- Configure DSCP/WMM mapping
- Select “VoIP” or “Low Delay” in TCP Streamer
- Test with network quality monitoring
High priority thread
High priority thread
Feature: Elevates audio processing thread priority for reduced latency jitter.Benefits:
- Reduces scheduling delays from OS
- Lower jitter in audio callbacks
- More consistent timing under system load
- May impact other applications
- Potential for system instability if misconfigured
- Higher power consumption (prevents CPU idle states)
- System under heavy load during streaming
- Other real-time applications competing
- Experiencing buffer underruns despite adequate buffer size
- System already performs well
- Battery-powered devices (laptop streaming on battery)
- Shared systems where other applications have priority
- Measure performance without high priority
- Enable high priority thread
- Monitor CPU usage and jitter
- Compare audio quality and dropout frequency
- Disable if no improvement or adverse effects
Most users don’t need high priority thread. Try other optimizations (buffer size, network preset) first.
Performance checklist
Use this checklist to systematically optimize TCP Streamer performance:Basic optimization
Basic optimization
Using appropriate network preset (Ethernet/WiFi/WiFi Poor)
Adaptive buffering enabled with appropriate min/max
Buffer size set to 1024 or higher
Sample rate matches device native rate
Silence detection tuned with visual RMS meter
Auto-reconnect enabled for resilience
Network optimization
Network optimization
Using wired Ethernet if possible
WiFi signal strength > -60 dBm
Network quality shows “Good” or “Excellent”
Jitter consistently < 20ms
No packet loss to server
QoS/DSCP configured if network supports it
System optimization
System optimization
TCP Streamer updated to latest version
Audio drivers updated
No antivirus interference
Adequate system resources available
No competing real-time applications
Power management not throttling CPU
Benchmarking and monitoring
Built-in statistics
TCP Streamer provides real-time metrics:- Bitrate: Current data rate (should match calculated rate)
- Uptime: Streaming session duration
- Data Sent: Total bytes transmitted
- Network Quality: Derived from jitter measurements
- Jitter: Real-time network timing variance
- Buffer Usage: Ring buffer fill percentage
Establishing baseline
- Optimal conditions: Test with wired Ethernet, no load
- Record metrics: Note CPU usage, jitter, network quality
- Typical conditions: Test with actual network and load
- Compare: Identify performance gaps
- Optimize: Apply settings to close gaps
Continuous monitoring
For long-term streaming:- Check statistics periodically
- Watch for network quality degradation
- Monitor activity log for errors
- Track buffer resize frequency
- Note any audio quality changes
Platform-specific performance
For platform-specific optimizations, see:Getting help
When reporting performance issues, include:- Operating system and version
- TCP Streamer version
- Hardware specs (CPU, RAM)
- Network configuration (Ethernet/WiFi, speed)
- Current settings (buffer sizes, sample rate, etc.)
- Statistics from UI (CPU%, jitter, network quality)
- Description of performance problem
- Steps to reproduce