mirror of
https://github.com/cmur2/python-bme680.git
synced 2024-12-22 02:54:28 +01:00
Merge upstream
This commit is contained in:
commit
9f3be44151
@ -32,7 +32,7 @@ sensor.set_filter(bme680.FILTER_SIZE_3)
|
|||||||
def get_cpu_temperature():
|
def get_cpu_temperature():
|
||||||
process = Popen(['vcgencmd', 'measure_temp'], stdout=PIPE)
|
process = Popen(['vcgencmd', 'measure_temp'], stdout=PIPE)
|
||||||
output, _error = process.communicate()
|
output, _error = process.communicate()
|
||||||
return float(output[output.index('=') + 1:output.rindex("'")])
|
return float(output[output.index(b'=') + 1:output.rindex(b"'")])
|
||||||
|
|
||||||
|
|
||||||
factor = 1.0 # Smaller numbers adjust temp down, vice versa
|
factor = 1.0 # Smaller numbers adjust temp down, vice versa
|
||||||
|
@ -50,5 +50,5 @@ setup(
|
|||||||
classifiers=classifiers,
|
classifiers=classifiers,
|
||||||
packages=['bme680'],
|
packages=['bme680'],
|
||||||
py_modules=[],
|
py_modules=[],
|
||||||
install_requires=[]
|
install_requires=['smbus'] # preferably: install `python3-smbus` instead of relying on this
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user