first commit, raspi temp display
This commit is contained in:
9
app/routes.py
Normal file
9
app/routes.py
Normal file
@@ -0,0 +1,9 @@
|
||||
from flask import render_template
|
||||
from app import app
|
||||
|
||||
@app.route('/')
|
||||
@app.route('/index')
|
||||
def index():
|
||||
device = {'name': 'find how to get name later'}
|
||||
status = {'temperature': float(open('/sys/class/thermal/thermal_zone0/temp').read())}
|
||||
return render_template('status.html', device=device, status=status)
|
||||
Reference in New Issue
Block a user