influxdata / influxdata/telegraf
Modbus: Unsigned float
- Dominant language
- Go
- Stars
- 17.8k
- Forks
- 5.8k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 161
Description
### Use Case
I am using power meters that provide measurement values using a Non-IEEE floating point formats:
Unsigned Measurement (32 bit):
- Decade Exponent(Signed 8 bit)
- Binary Unsigned Value (24 bit)
Example: 123456*10–3 stored as FD01 E240(16)
Signed Measurement (32 bit)
- Decade Exponent (Signed 8 bit)
- Binary Signed value (24 bit)
Example: - 123456*10–3 stored as FDFE 1DC0(16)
I am looking for a way to configure/extend the modbus input plugin to handle these values.
Am I right that currently, only IEEE (signed) float values are supported? Can I just come up with new data_types like UFLOAT32 and MSIGN_FLOAT32 (as the mantissa holds the sign)?
I'd be able to implement it on my own, just checking what a sane convention would be.
Kind regards
nischu
### Expected behavior
I would like the Modbus input plugin to generate correct floating point values
### Actual behavior
I cannot really specify this custom data type
### Additional info
https://cdn.findernet.com/app/uploads/Benutzerhandbuch_Typ_7M38_DE.pdf page 52
Contributor guide
Research direction
Start with the Modbus input plugin's data type configuration and existing IEEE float handling. Determine how unsigned and signed 32-bit decade-exponent values should be represented and converted, then verify that the plugin can configure them and emits the expected floating-point measurements from the examples.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- data-engineering
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100