Skip to content

peter-byte-code/running-beat-companion

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🏃‍♂️ Running Beat Companion

An interactive web app that matches music beats to your running pace in real-time using your iPhone's motion sensors.

✨ What It Does

  • Auto-pace Detection: Uses your iPhone's accelerometer to detect your steps
  • Dynamic BPM Matching: Adjusts music tempo (60-200 BPM) to match your movement
  • Multi-layered Audio: Kick drums, bass, and hi-hats that evolve with your intensity
  • 4 Intensity Zones: From warm-up beats to high-energy sprint rhythms
  • Visual Feedback: Step detection indicators and gradient backgrounds
  • Smart Decay: Music slows down naturally when you stop moving

🎵 Try It Live

🔗 Launch Running Beat Companion

Best experienced on iPhone with Safari for full motion detection

🚀 Quick Start

# Clone and run locally
git clone https://github.com/peter-byte-code/running-beat-companion.git
cd running-beat-companion
npm install
npm start

Opens on http://localhost:3000 - though motion detection requires iPhone testing.

📱 How to Use

  1. Open on iPhone Safari (motion sensors required)
  2. Tap "Enable Motion Detection" and grant permission
  3. Start Workout and begin moving
  4. Adjust sensitivity with the vertical slider if needed
  5. Enjoy your personalized running soundtrack!

🛠️ Built With

  • React - UI framework
  • Tone.js - Web Audio API for beat generation
  • DeviceMotionEvent API - iPhone motion sensor access
  • Tailwind CSS - Styling
  • GitHub Pages - Deployment

🎯 Features

  • ✅ Real-time step detection and BPM matching
  • ✅ iOS 18 compatible motion permissions
  • ✅ Adjustable sensitivity (100%-300%)
  • ✅ Manual BPM control fallback
  • ✅ Progressive Web App (add to home screen)
  • ✅ No data storage - everything runs in browser

🔧 Development

See README-HANDOVER.md for detailed development setup, architecture details, and contribution guidelines.

📄 License

MIT License - feel free to use this for your own running adventures!


Turn your runs into a rhythm! 🎵🏃‍♂️