def measure_temperature():
    measurement = sensor.getMeasurement()
    return jsonify(value=measurement.value, time=measurement.timeStamp)
def get_heater_command():
    # Returns true if the heater is to be turned on or false otherwise
    measurement = sensor.getMeasurement()
    command = controller.get_command(measurement.value)
    return command