mirror of
https://github.com/ARM-software/devlib.git
synced 2025-01-31 10:10:46 +00:00
Instruments: Add millisecond MeasurementType and conversion
Allows for reporting times in milliseconds as used with the acmecape instrument.
This commit is contained in:
parent
2de2b36387
commit
9b465c2766
@ -76,11 +76,19 @@ _measurement_types = [
|
||||
MeasurementType('time', 'seconds',
|
||||
conversions={
|
||||
'time_us': lambda x: x * 1000000,
|
||||
'time_ms': lambda x: x * 1000,
|
||||
}
|
||||
),
|
||||
MeasurementType('time_us', 'microseconds',
|
||||
conversions={
|
||||
'time': lambda x: x / 1000000,
|
||||
'time_ms': lambda x: x / 1000,
|
||||
}
|
||||
),
|
||||
MeasurementType('time_ms', 'milliseconds',
|
||||
conversions={
|
||||
'time': lambda x: x / 1000,
|
||||
'time_us': lambda x: x * 1000,
|
||||
}
|
||||
),
|
||||
MeasurementType('temperature', 'degrees'),
|
||||
|
Loading…
x
Reference in New Issue
Block a user