Skip to content

Instantly share code, notes, and snippets.

View tuck1s's full-sized avatar

tuck1s tuck1s

View GitHub Profile
@hosackm
hosackm / flaskaudiostream.py
Created September 2, 2015 22:30
Flask streaming an audio file
from flask import Flask, Response
app = Flask(__name__)
@app.route("/wav")
def streamwav():
def generate():
with open("signals/song.wav", "rb") as fwav:
data = fwav.read(1024)