2022-11-09, 04:00 PM
ops good luck!
openplotter-i2c 3.x.x released
|
2022-11-09, 04:00 PM
ops good luck!
2022-11-12, 08:04 PM
Is there a way to apply a calibration factor to a sensor value? What are magnitude and sensor settings?
2022-11-12, 08:21 PM
(2022-11-12, 08:04 PM)tobias.e Wrote: Is there a way to apply a calibration factor to a sensor value? What are magnitude and sensor settings? Yes, you can set an offset for each magnitude. Sensors setings are general settings affecting all magnitudes and a magnitude setting will affect only that magnitude. check ADS1115, it has both sensor and magnitude settings.
2022-11-12, 09:22 PM
(2022-11-12, 08:21 PM)Sailoog Wrote:(2022-11-12, 08:04 PM)tobias.e Wrote: Is there a way to apply a calibration factor to a sensor value? What are magnitude and sensor settings? Hi Sailoog, thanks for the quick reply. The offset is added to the value, but i would like to multiply by a factor ( INA219 using a different shunt). Best regards, Tobias
2022-11-14, 01:44 PM
RichFind, tobias.e, let's follow this discussion here please: https://forum.openmarine.net/showthread.php?tid=4310
2022-11-14, 08:35 PM
Hi Sailoog,
the other tread is great, as it allows to use the full potential of the INA219. But I think, to be able to scale any sensor data would still be a useful feature for openplotter-i2c. So instead of Code: value=value_raw + offset generate Code: value=scaling_factor * value_raw + offset Best regards, Tobias
2022-11-15, 11:48 AM
Yes, good idea. We could add a new field "Scaling factor" with 1 as default value next to the offset field.
Scaling factor added to openplotter-i2c v3.3.5:
Please test and report, thanks. Also added settings for INA219: https://forum.openmarine.net/showthread.php?tid=4310
Hi Sailoog,
Thank you for including this! Scaling seems to work just fine, but generation of default scaling values seems to be a problem. I just changed the scaling value for temperature on the BMP280, and singnalK stopped getting values from I2C. Debug output from openpoltter-i2c was ( several lines per second): Code: Error reading BMP280: 'factor' After also setting a factor for pressure on the BMP280, Errors for this sensor were gone, but the INA219 was still complaining: Code: Error processing INA219: local variable 'current_lsb' referenced before assignment This disappears after pressing edit and OK for each measurement. Looks like the default value of 1.0 works only as long as no scaling factor has been set for any sensor. One further observation: after setting all scaling values to 1, data was sent to signalK only once, and was not updated for several minutes. As soon as i changed the update interval for e.g. pressure, data for pressure was updated accordingly. Best regards, Tobias |
« Next Oldest | Next Newest »
|