MD500_Pilot

Untitled

May 21st, 2020
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.49 KB | None | 0 0
  1. @app.route('/environmentals')
  2. def environmentals():
  3.     environmental_keys = ['pi_cpu_temp', 'enclosure_temp', 'enclosure_humidity',
  4.                           'enclosure_baro', 'shed_temp', 'shed_humidity']
  5.     environmental_data = {}
  6.     for key in environmental_keys:
  7.         environmental_data[key] = environmentals_data('readone', key, 0)
  8.         #environmental_data[key] = read_mysql_database('environmental', key)
  9.  
  10.     return render_template('environmentals.html',**environmental_data)
Advertisement
Add Comment
Please, Sign In to add comment