UNPKG

win-stream-audio

Version:

šŸŽ§ Stream Windows system audio to Android devices over WiFi with professional audio controls, EQ, pitch shifting, and effects

175 lines (125 loc) • 5.66 kB
# šŸŽ§ Win Stream Audio **Professional Windows audio streaming to Android devices over WiFi** Stream your Windows system audio (music, videos, games, calls) to your Android phone with professional audio controls, EQ, pitch shifting, and effects - all in real-time! [![npm version](https://badge.fury.io/js/win-stream-audio.svg)](https://badge.fury.io/js/win-stream-audio) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) ## ✨ Features - šŸŽµ **Stream all Windows system audio** to Android devices - šŸŽ›ļø **Professional AudioPilot interface** with cockpit-style controls - šŸŽšļø **3-band EQ** (Bass, Mid, Treble) with real-time adjustment - šŸŽµ **Pitch shifting** with voice presets (Male, Female, Child, Robot) - šŸŽ­ **Audio effects** (Reverb, Echo, Distortion, Chorus) - šŸ“Š **Real-time audio visualization** with waveform and VU meters - šŸ“± **Screen wake system** to prevent Android sleep - šŸ”„ **Auto-reconnection** with seamless audio resumption - 🌐 **Works over internet** with ngrok/localtunnel support - šŸŽ® **Perfect for gaming, music, videos, and calls** ## šŸš€ Quick Start ### Using NPX (Recommended) ```bash npx win-stream-audio ``` The CLI will prompt you for: - **Port number** (default: 8080) - **Auto-open browser** (default: yes) ### Manual Installation ```bash npm install -g win-stream-audio win-stream-audio ``` ## šŸ“‹ Setup Instructions ### 1. Enable Windows Stereo Mix (Required) **This is crucial for streaming system audio!** 1. Right-click speaker icon → "Open Sound settings" 2. Click "Sound Control Panel" → "Recording" tab 3. Right-click empty space → "Show Disabled Devices" 4. Find "Stereo Mix" → Right-click → "Enable" 5. Right-click "Stereo Mix" → "Set as Default Device" ### 2. Start Streaming 1. **On PC**: Run `npx win-stream-audio` 2. **On PC**: Open the "PC Audio Source" URL and select "Stereo Mix" 3. **On Android**: Open the "AudioPilot Receiver" URL 4. **On Android**: Click "šŸ”— Establish Link" and enjoy! ## šŸŽ›ļø AudioPilot Professional Interface ### System Controls - **šŸ”— Establish Link** - Connect to PC audio stream - **šŸ“± Screen Lock** - Keep Android screen awake - **⚔ Low Latency** - Reduce audio delay (2-chunk buffer) - **🌐 Internet Mode** - Optimize for internet streaming (10-chunk buffer) - **šŸŽ›ļø Audio Filter** - Enable/disable noise reduction ### Audio Processing - **šŸŽšļø 3-Band EQ**: Bass (80Hz), Mid (1kHz), Treble (8kHz) - **šŸŽµ Pitch Control**: -1200 to +1200 cents with presets - **šŸŽ­ Audio Effects**: Professional reverb, echo, distortion, chorus - **šŸ”Š Master Volume**: Rotary knob control ### Voice Presets - **ā™‚ļø Male**: -200 cents (deeper voice) - **ā™€ļø Female**: +300 cents (higher voice) - **šŸ‘¶ Child**: +600 cents (much higher) - **šŸ¤– Robot**: -800 cents (very deep/robotic) ## 🌐 URLs and Access When you run the command, you'll get: ``` šŸ“± Main Interface: http://YOUR_IP:8080 šŸŽ¤ PC Audio Source: http://YOUR_IP:8080/simple-source.html šŸŽ§ AudioPilot Receiver: http://YOUR_IP:8080/audiopilot.html ``` ## šŸ”§ Troubleshooting ### Common Issues **āŒ "No Stereo Mix option"** - Update your audio drivers - Some laptops/PCs don't have this feature - Use Virtual Audio Cable as alternative **āŒ No sound on Android** - Ensure Stereo Mix is set as default recording device - Check Android volume and browser audio permissions - Make sure PC is actually playing audio **āŒ Connection issues** - Ensure both devices are on same WiFi network - Check Windows Firewall settings - Try using localhost on PC instead of IP address **āŒ High latency** - Use 5GHz WiFi if available - Enable "Low Latency Mode" on Android - Close other network-intensive applications ## 🌐 Internet Streaming To stream over the internet: 1. **Install ngrok**: `npm install -g ngrok` 2. **Start win-stream-audio**: `npx win-stream-audio` 3. **In another terminal**: `ngrok http 8080` 4. **Use the HTTPS URL** provided by ngrok ## šŸŽÆ Use Cases - šŸŽ® **Gaming**: Hear PC game audio on your phone while gaming - šŸŽµ **Music**: Use your phone as a wireless speaker - šŸŽ¬ **Videos**: Watch PC videos with audio on your phone - šŸ’¬ **Calls**: Route PC call audio to your phone - šŸ”Š **Presentations**: Wireless audio for presentations - šŸŽ™ļø **Voice changing**: Real-time voice effects for streaming ## šŸ› ļø Technical Details - **Audio Format**: Raw PCM audio (48kHz stereo) - **Latency**: ~200-600ms depending on network and settings - **Protocol**: WebSocket for real-time streaming - **Compatibility**: Windows 10/11, Android 6+ - **Network**: Works on local WiFi and internet ## šŸ“± Android Setup 1. Connect to same WiFi as PC 2. Open browser (Chrome recommended) 3. Navigate to the AudioPilot URL 4. Allow audio autoplay if prompted 5. Click "šŸ”— Establish Link" and connect ## šŸ”’ Security Notes - Only works on local network by default - No internet connection required for local use - Audio data stays on your local network - No data is stored or transmitted externally ## šŸ†˜ Getting Help 1. **Check Setup**: Ensure Stereo Mix is enabled and set as default 2. **Test Connection**: Visit `/status` endpoint to check server status 3. **Use Localhost**: Try `localhost:8080` on PC instead of IP 4. **Check Firewall**: Ensure Windows Firewall allows the connection ## šŸ“„ License MIT License - Feel free to use and modify! ## šŸ¤ Contributing Contributions are welcome! Please feel free to submit a Pull Request. --- **šŸŽ‰ Enjoy streaming your PC audio to your Android phone wirelessly with professional controls!**