Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/wsen-hids/examples/comfort_monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ def comfort_label(humidity):
else:
return "Humid"


while True:
humidity, temperature = sensor.read_one_shot()
comfort = comfort_label(humidity)
Expand Down
1 change: 1 addition & 0 deletions lib/wsen-hids/examples/dew_point.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ def dew_point_celsius(temperature_c, humidity):
dp = (b * gamma) / (a - gamma)
return dp


humidity, temperature = sensor.read_one_shot()
dew_point = dew_point_celsius(temperature, humidity)

Expand Down
1 change: 1 addition & 0 deletions lib/wsen-pads/examples/altitude.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
def pressure_to_altitude(p):
return 44330 * (1 - (p / SEA_LEVEL_PRESSURE) ** EXPONENT)


for _ in range(10):
pressure, temp = sensor.read()

Expand Down
1 change: 1 addition & 0 deletions lib/wsen-pads/examples/pressure_trend.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ def get_trend(values):
else:
return "falling"


while True:
pressure = sensor.pressure_hpa()

Expand Down
1 change: 1 addition & 0 deletions lib/wsen-pads/examples/temp_pressure_display.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ def bar_graph(value, vmin, vmax, width=20):

return "[" + "#" * filled + "-" * (width - filled) + "]"


while True:
pressure, temp = sensor.read()
temp_bar = bar_graph(temp, TEMP_MIN, TEMP_MAX)
Expand Down
5 changes: 5 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,15 @@ select = [
"E", # pycodestyle
"E203", # (preview) whitespace before ':', ';', or ','
"E225", # (preview) missing whitespace around operator
"E231", # (preview) missing whitespace after ','
"E261", # (preview) at least two spaces before inline comment
"E262", # (preview) inline comment must start with '# '
"E265", # (preview) block comment must start with '# '
"E275", # (preview) missing whitespace after keyword
"E301", # (preview) blank line between methods
"E302", # (preview) expected 2 blank lines before function/class definition
"E303", # (preview) too many blank lines
"E305", # (preview) expected 2 blank lines after function/class definition
"EXE", # flake8-executable
"F", # Pyflakes
"G", # flake8-logging-format
Expand All @@ -78,6 +82,7 @@ select = [
"T20", # flake8-print: no print() in production code
"TCH", # flake8-type-checking
"W", # pycodestyle
"W391", # (preview) too many newlines at end of file
"YTT", # flake8-2020
]
ignore = [
Expand Down
Loading