ESP32 PH & TDS
-
- LED-Curious
- Reactions:
- Posts: 3
- Joined: Tue Nov 10, 2020 1:37 am
I am trying to get a Dfrobot PH sensor and EC sensor into HA. Since there are no direct esphome integrations for these what is the best way to bring the values in? Is MQTT the only simple option?
MQTT isn't too bad to add into your Arduino code. I think I would go that route.
Want to Support the Site?
Use this Amazon referral link and any purchase you make within 24 hrs will earn LEDgardener a commission at no cost to you!
Use this Amazon referral link and any purchase you make within 24 hrs will earn LEDgardener a commission at no cost to you!
-
- LED-Curious
- Reactions:
- Posts: 3
- Joined: Tue Nov 10, 2020 1:37 am
Can I hassle you for an example of your MQTT esp32 code. I cannot get the publish function to send calculated values from my sensors.
Sure thing. Here's my ESP32 code. Mind the noobiness of it.
Feel free to post your code as well and I can see if the problem stands out to me.
Feel free to post your code as well and I can see if the problem stands out to me.
- Attachments
-
- ControlBox_ESP32_07-17-2020.ino
- (23.28 KiB) Downloaded 125 times
Want to Support the Site?
Use this Amazon referral link and any purchase you make within 24 hrs will earn LEDgardener a commission at no cost to you!
Use this Amazon referral link and any purchase you make within 24 hrs will earn LEDgardener a commission at no cost to you!
-
- LED-Curious
- Reactions:
- Posts: 3
- Joined: Tue Nov 10, 2020 1:37 am
That was extremely helpful, made me realize I needed to convert my float values to strings in order for MQTT to publish them.
Thank you!
Thank you!
Great!
Want to Support the Site?
Use this Amazon referral link and any purchase you make within 24 hrs will earn LEDgardener a commission at no cost to you!
Use this Amazon referral link and any purchase you make within 24 hrs will earn LEDgardener a commission at no cost to you!
Hi,
without any detail, it is difficult to provide you an answer. At least what kind of code you use and what you have tried so far would be nice to know.
I use ESP32 with SEN0169. There are some examples at GitHub. I used greenponik together with additional ADC.
I posted my code here:
viewtopic.php?f=35&t=5696&start=20
I get an MQTT response. Maybe later I will improve the code.
Hope that helps.
BR
B
without any detail, it is difficult to provide you an answer. At least what kind of code you use and what you have tried so far would be nice to know.
I use ESP32 with SEN0169. There are some examples at GitHub. I used greenponik together with additional ADC.
I posted my code here:
viewtopic.php?f=35&t=5696&start=20
I get an MQTT response. Maybe later I will improve the code.
Hope that helps.
BR
B
I'm not running DF PH/EC Sensors ,i'm using Atlas EZO ,after doin a little search i found this that might be useful :
https://community.dfrobot.com/makelog-308339.html
DF Sensors with MQTT on ESP
hope it helps you
https://community.dfrobot.com/makelog-308339.html
DF Sensors with MQTT on ESP
hope it helps you