-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v1.1.2.38 Replaced calibration by sensor objects - Implemented a Rota…
…ting raspardas.log file
- Loading branch information
Showing
7 changed files
with
224 additions
and
208 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
from ardas import sensor_tools as st | ||
|
||
# Saves a set of sensors including its calibration in a binary '.ssr' file | ||
|
||
sensors = (st.UncalibratedFMSensor(sensor_id='0001', log_output=False), | ||
st.UncalibratedFMSensor(sensor_id='0002', log_output=False), | ||
st.FMSensor(sensor_id='0003', processing_parameters=(-16.9224032438, 0.0041525221, -1.31475837290789E-07, | ||
2.39122208189129E-012, -1.72530800355418E-017), | ||
quantity='temp.', units='°C', output_format='%6.3f', log_output=True), | ||
st.FMSensor(sensor_id='0004', processing_parameters=(-16.9224032438, 0.0041525221, -1.31475837290789E-07, | ||
2.39122208189129E-012, -1.72530800355418E-017), | ||
quantity='temp.', units='°C', output_format='%6.3f', log_output=True) | ||
) | ||
|
||
if __name__ == '__main__': | ||
for s in sensors: | ||
print(s.sensor_id + ' - ' + s.quantity + ' : ' + s.output_repr(10000)) | ||
s.save() | ||
print('reload sensor...') | ||
s = st.load_sensor('0003') | ||
print(s.sensor_id + ' - ' + s.quantity + ' : ' + s.output_repr(10000)) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
from ardas import sensor_tools as st | ||
|
||
# Saves a set of sensors including its calibration in a binary '.ssr' file | ||
|
||
sensors = (st.UncalibratedFMSensor(sensor_id='0000', log_output=False), | ||
) | ||
|
||
if __name__ == '__main__': | ||
for s in sensors: | ||
print(s.sensor_id + ' - ' + s.quantity + ' : ' + s.output_repr(10000)) | ||
s.save() | ||
|
Oops, something went wrong.