Acess temperature readings

We use an optical Probe for DO measurements. The measurements are temperature depended. Sofar the temperature was hard coded. However, I would like to read the temperature before the pO2 Measurement.

Unfortunately, I am not able to access the temperature if the thermostat is already running.

(e.g. instantiate “Thermocontroller” and call “read_external_temperature” method)

Is there a way to access the temperature directly Or do I need to modify the Thermononctoller to publish the temperature reading via mqtt?

Access temperature readings.

We use an optical probe for DO measurements. The measurements are temperature dependent. So far the temperature has been hard coded. However, I would like to read the temperature before the pO2 measurement.

Unfortunately I cannot access the temperature if the thermostat is already running.

(e.g. instantiate “thermocontroller” and call “read_external_temperature” method).

Is there a way to access the temperature directly or do I need to modify the thermocontroller to publish the temperature reading via mqtt?

Kind regards

Johannes

I’m guessing you want to access the temperatures in Python? Recent versions (>= version 24.12.10) of our software store data like this locally, so you can use the following in your job:

from pioreactor.utils import JobManager

...

with JobManager() as jm:
    temp = float(jm.get_setting_from_running_job("temperature_automation", "temperature"))

Is that what you are looking for?