PiBrewing / craftbeerpi4

GNU General Public License v3.0
58 stars 28 forks source link

Add Sensor Temperature Offset to MQTTSensor #139

Closed stamandster closed 3 months ago

stamandster commented 4 months ago

I'm not sure how to adjust the code myself, or else I'd do it. But it would be great to add the option to adjust Temp Offset just like the Onewire Sensor. Unfortunately, for things like Tasmota, sometimes the source only allows adjustment of ALL sensors on the device.

avollkopf commented 4 months ago

If I remember correctly, this has been discussed in the past and we somehow decided to not implement it as it should be corrected at the sensor itself to avoid double correction. But I will re-review it, once I have successfully updated the brewfather api calls.

stamandster commented 4 months ago

I appreciate that @avollkopf . I know it's not a little thing to add this, but just having the option is super helpful for me (and maybe others). It also falls inline with options of the other sensors for consistency sake. If you do adjust it (please please please!), it may be good to consider adding a little description that says something like "Be careful not to duplicate Temperature Offsets, make change here or at the sensor."

lalo-uy commented 4 months ago

You can add individual offsets at Tasmota with rules. Catch the original mqtt msg, add the offset and publish the new value on a different topic.

El El mar, 18 jun. 2024 a la(s) 12:50, stamandster @.***> escribió:

I appreciate that @avollkopf https://github.com/avollkopf . I know it's not a little thing to add this, but just having the option is super helpful for me. If you do adjust it, I think it's good to consider adding a little description that says something like "Be careful not to duplicate Temperature Offsets, make change here or at the sensor."

— Reply to this email directly, view it on GitHub https://github.com/PiBrewing/craftbeerpi4/issues/139#issuecomment-2176431551, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACXBW4LE746BDBN7OHO3O4DZIBJKPAVCNFSM6AAAAABJLY2LHSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNZWGQZTCNJVGE . You are receiving this because you are subscribed to this thread.Message ID: @.***>

stamandster commented 4 months ago

Yes, I know that is a potential, however in order to get 1s reads I need to query Status8 via HTTP at 1s interval with a python script. This is provides the existing temperature not the offset adjusted using the rule.

lalo-uy commented 4 months ago

Ok, but a 20L kettle have a lot of thermal inertia, 10s teleperiod is quite ok. In a RIMS a short cicle could have sense.

El El mar, 18 jun. 2024 a la(s) 13:17, stamandster @.***> escribió:

Yes, I know that is a potential, however in order to get 1s reads I need to query Status8 via HTTP at 1s interval with a python script. This is provides the existing temperature not the offset adjusted using the rule.

— Reply to this email directly, view it on GitHub https://github.com/PiBrewing/craftbeerpi4/issues/139#issuecomment-2176492596, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACXBW4L2ZF4UXFSEP2CN7PDZIBMRBAVCNFSM6AAAAABJLY2LHSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNZWGQ4TENJZGY . You are receiving this because you commented.Message ID: @.***>

stamandster commented 4 months ago

Yes, RIMS is the primary application. Though, another two other cases for this could be used during recirculation through the chiller for a whirl pool hop addition to make sure the incoming wort through the chiller is being adequately chilled to reach a specific whirl pool temperature. Also, I run my pump during the ramp to boil so that there's turbulence and mixture of cold/hot pockets within the liquid mass. The tele 10s period is too long in both situations.

avollkopf commented 3 months ago

Latest version in dev branch has changes to address your request. Install version, it'll add a parameter mqtt_offset to config.yaml. Default is false. Set it manually to yes and restart cbpi -> Offset for mqtt sensor plugin is enabled. By reverting mqtt_offset to false, parameter is disabled in mqtt sensor plugin