The device assignment calibration now takes up to 3 parameters per device
The plugin no longer takes the input and output parameter names in its configuration. The whole setup now lives in the fields of each assigned device or group as a "calibrations" array with up to 3 entries, one per parameter. This is meant for trucks with several fuel tanks: one plugin instance now calibrates all of them instead of one plugin per tank.
Each entry has:
- input: name of the message parameter with the raw value
- output: name of the parameter to store the calibrated value into, optional. If omitted, the input parameter is overwritten
- table: calibration points, the same x/y points as before
- min_y, max_y: optional values written when the input is below or above the table range, as before
Example of device assignment fields:
{
"calibrations": [
{"input": "lls.value.1", "output": "fuel.volume.1", "table": [{"x": 0, "y": 0}, {"x": 1000, "y": 100}], "min_y": 0, "max_y": 100},
{"input": "lls.value.2", "table": [{"x": 0, "y": 0}, {"x": 1000, "y": 120}]}
]
}
Each calibration is applied independently. If one of them fails, for example the input is out of the table range and no min_y/max_y is set, the other calibrated values are still written to the message and the failure is reported in the plugin log. The message is registered without any calibrated value only when all calibrations failed. Error texts in the plugin log now start with the input parameter name.
Migration. All existing plugins and their assignments are converted automatically, no action is needed for plugins created in the panel. The previous format (in_name and out_name in the plugin configuration, a flat "points" table in the assignment fields) keeps working until October 1, 2026 to let integrations that create these plugins via the REST API switch to the new format. After that date the old configuration fields are rejected by the API and assignments without "calibrations" are not calibrated, with the reason "failed to get 'fields.calibrations'" in the plugin log.