Page 1 of 1

How to convert ADC voltage to CO2-value

Posted: Wednesday 14 February 2024 16:17
by HoogendoornJH
I have a ADC voltage-value from a ShellyUNI which must be converted to a CO2-value (CO2 = 200 * ADC-value). How can this be done?
ADCvalue.jpg
ADCvalue.jpg (38.62 KiB) Viewed 4411 times

Re: How to convert ADC voltage to CO2-value

Posted: Wednesday 14 February 2024 16:52
by waltervl
As you don't know Lua you better start with Dzvents.
Look for example to this topic where someone has something similar. https://www.domoticz.com/forum/viewtopic.php?t=33414

Re: How to convert ADC voltage to CO2-value

Posted: Wednesday 14 February 2024 20:42
by HvdW
Converted to a CO2 value, a CarbonDioxide value?

Re: How to convert ADC voltage to CO2-value

Posted: Wednesday 14 February 2024 20:57
by FireWizard
Hi @HoogendoornJH,

As the Shelly Uni is able to send the ADC value to MQTT topic "shellies/shellyuni-ID-Number/adc/0, I would send it to Node-RED and multiply the value with 200. The result can be easily send with MQTT to Domoticz.

Or use DzVents and multiply it there as Waltervl said.

Regards

Re: How to convert ADC voltage to CO2-value

Posted: Thursday 15 February 2024 0:20
by waltervl
HvdW wrote: Wednesday 14 February 2024 20:42 Converted to a CO2 value, a CarbonDioxide value?
He probably has a CO2 measuring device hooked up to the Shelly ADC (Analog DC) input. So a certain voltage level defines a certain CO2 level.

Re: How to convert ADC voltage to CO2-value

Posted: Friday 16 February 2024 15:57
by HoogendoornJH
waltervl wrote: Wednesday 14 February 2024 16:52 As you don't know Lua you better start with Dzvents.
Look for example to this topic where someone has something similar. https://www.domoticz.com/forum/viewtopic.php?t=33414
This works. Thanks a lot, waltervl.