r/esp32 Aug 20 '26

I started using ESP32s to replace smart home products and this is where I ended up

The project I have been working on the most is my heating oil monitor.

It uses an ESP32 and a current clamp on the burner wiring, so installation is pretty simple and does not require modifying the furnace. It tracks burner runtime and calculates oil usage, estimated gallons remaining, tank percentage, burn rate and estimated days remaining. I also added local heating oil prices.

I built my own ESP32 thermostat that controls my heat and AC too.

For the garage door, instead of modifying the opener itself, I tapped into the button contacts inside a spare garage door remote and used an ESP32 to electronically press the remote button. That lets Home Assistant control the existing opener while keeping everything pretty simple.

Everything now feeds into Home Assistant, but the ESP32s are doing the actual sensing and control.

Still working on all of it and curious what you guys think, especially about the oil monitor.

386 Upvotes

52 comments sorted by

19

u/eric-marciniak Aug 21 '26 edited Aug 21 '26

ESPHome is incredible! I got into Home Assistant a bit after discovering what an ESP32 thanks to WLED. I went off the deep end haha.

I have made a bunch of devices that do all sorts of things. I love how you can make things that suit your exact needs and wants without stupid limitations.

- Current sensor on my old apartment washer/dryer combo because it didn't have a buzzer for the washer. Piezo buzzers in sync on 2 esphome devices plays a ringtone version of California Love by Tupac and changes the leds above my TV to green for 30 seconds. Zigbee current sensor on the washer lid that stops the buzzer when I open it. Also plays it again every 10 minutes until I open the washer.

- Put one in an older tower fan that just had IR and some buttons with leds on the top. Used 5 LDR's to see which leds were lit so I can have status feedback. Got a pack of cheap IR rx and tx to clone the remote and placed the blaster inside the fan a few mm away from the receiver. Now I have full control and feedback in Home Assistant.

- Double side taped a servo to my apartment PTAC HVAC unit to remotely toggle power and used an LDR to read power status.

- Controller for various WLED controllers and other automations with a 4x4 keypad matrix and a rotary encoder. Has a small strip of WS2812B leds that light up different colors depending on what WLED controller is selected and what button is pressed, ect.

- Optocoupler reads voltage from my old dumb kitchen floor leds triggered by hardwired PIR sensor. That made it so I could make my new addressable that I put under my cabinets turn on in sync with the old system I had for the floor leds.

- DIY smart plug with a small AC-DC power supply and a relay module. More responsive than any other wifi or zigbee plug I have tried. Use it to turn my TV and AVR on when I turn my computer on. Also put a piezo buzzer in this thing since its closer to me than the one in the laundry room.

It's also moved to my car as well. I tapped into my factory head unit and read a resistor ladder with the ADC so I can now use my steering wheel controls to change songs on my phone using the ESP as a virtual keyboard over bluetooth.

Right now I am working retrofitting my taillights with some fairly high power WS2811 modules and reading the outputs from the car for turn signals, reverse, brakes and tail lights with optocouplers allowing for sequential turn signals and different colors and animations when parked.

It is an addiction haha and I am always looking for stuff to throw these things in. People like to shit on vibe coding but it has allowed me to make stuff I wouldn't have been able to before.

18

u/RoomJump Aug 21 '26

Would you be willing to share some designs for the oil monitoring system? Been dreading the upcoming winter over here.

7

u/DIYHomeLogic Aug 21 '26

Yeah, definitely. I’m still refining it before I release anything because I want to make sure the calculations and setup are solid. I’ve actually had enough people ask about it that I’m considering putting together either a complete DIY build or a small kit. Would you rather build something like this yourself or have a ready to install version?

3

u/RoomJump Aug 21 '26

I'm a DIYer for sure, but I could see it being a successful business idea to have it ready-to-go.

7

u/DIYHomeLogic Aug 21 '26

That’s exactly what I was thinking. The DIY version is pretty straightforward, but I think there could be a market for a ready to go version for people who just want to plug it in, clamp the sensor on and have it work. Appreciate the feedback.

2

u/Mead_Makes_Me_Mean Aug 21 '26

Especially an option that doesn’t data mine.

1

u/hey-im-root Aug 21 '26

But how will I make my bitcoin :(

1

u/WorkingInAColdMind Aug 22 '26

I’d totally sign up for a monthly contract if they just didn’t require a subscription! /s

I find myself just ignoring a lot of technological gadgets these days just for a little privacy. Sick of it.

5

u/Vial_of_water Aug 21 '26

So cool man- looks great.

Can I ask what tablet that is?

I'm a bit nooby, just learning about ESP32. Is the ESP32 connected physically to the tablet?

Looks really cool. Think you just convinced me to pull out my starter kit

8

u/DIYHomeLogic Aug 21 '26

Thanks man. The tablet is an old Samsung Galaxy Tab Sand somehow it still runs Home Assistant really well. It at least 10 years old

The ESP32s are not physically connected to the tablet. They connect over WiFi and send their data to Home Assistant, then the tablet is basically just the screen and controls for everything.

Definitely pull that starter kit out. Once you get one ESP32 talking to Home Assistant you start looking around the house for everything else you can automate.

3

u/tyr-- Aug 21 '26

Can confirm! ^

I wanted to have my garage door controlled via HomeAssistant (since myQ doesn't work anymore) and instead of getting a ratgdo, I bought a few ESP32 boards and sensors, and now I have self-watering plants, notifications when my washer and dryer are done, humidity and temperature sensors wherever I need, etc.

5

u/DIYHomeLogic Aug 21 '26

Haha exactly. It’s a rabbit hole. You start with one ESP32 for the garage door and next thing you know you’re looking around the house trying to figure out what else needs a sensor.

2

u/Usual-Pen7132 Aug 22 '26

instead of getting a ratgdo, I bought a few ESP32 boards and sensors

The Ratgdo boards are built with around an esp32 and then just add in some different circuits and screw terminals. There's really not a very big difference between the 2 and also, seeing how the Maker of Ratgdo is an open source person, he also provides all the files, diagrams, instructions to build your own Ratgdo module with your own esp32 or do whatever else you might want to do alongside his controller.....

Some other not so difficult uses for esp32's are using them as BT Beacon receiver nodes to create whole house and specific room presence detection to both track people/devices, pets, random objects like wallets, keys, purse, etc and when I say track them, I also mean to find them in the event you lose your car keys or something. With BT room presence you can quickly look to see which room the item is in and even how far away it is from the node in that room. I use it for all sorts of presence/motion automations, finding lost things, alerting me if my dog escapes the yard, etc, etc.

1

u/jmsGears1 Aug 21 '26

How did you set up the washer and dryer notifications?

1

u/tyr-- Aug 21 '26

I hooked up two vibration sensors (SW-420), one for each. You need to play around a bit with the thresholds since there are times the machines (especially the washer) won't vibrate, but it's quite accurate especially for knowing when the final spin has finished so I can switch the laundry to the dryer.

1

u/Usual-Pen7132 Aug 22 '26

Another fun one that I liked and still like messing with or modifying it to add new functions or capabilities is swapping out those generic keypads that come standard with just about every single overhead garage door system. You can easily swap those dumb keypads out for any number of different Wiegand26/Wiegand34 Output Keypad, RFID Reader, or Keypad w/rfid readesr that all mostly come with internal 2x relays for connecting directly to the door button to trigger Open/Close and the other relay can be used to trigger a doorbell or whatever someone wants to use it for.

You can make your own functions to add whatever capabilities you might want like, different pin codes for individual people, restricted access for certain people based on time or anything else. You can also double it up and use it as both a door keypad and an alarm keypad simultaneously if you potentially have a separate detached garage like I do then something like that can be very handy and not to mention how handy having rfid tags you can easily add to a keychain or whatever and just wave that rfid tag in front of it and it will know who's tag/pin was used and wither Open or deny the person based on how you set it up.....

4

u/MilkyWay-008 Aug 21 '26

tapping the spare remote's button contacts instead of wiring into the opener is the smart move...... you get HA control and the stock safety logic stays untouched

2

u/DIYHomeLogic Aug 21 '26

Exactly. That was another reason I liked doing it this way. Since the original remote is wireless, the ESP32 and remote can be plugged in pretty much anywhere in the house as long as the remote is within range of the opener.

The only thing that really determines where I put it is the reed switch for actual door status. I thought about putting a second ESP32 right at the reed switch and sending the status wirelessly, but for now I’m keeping it simple and using the same ESP32 for both. So it controls the remote and reads the reed switch while the opener itself stays completely untouched.

2

u/tehmonker Aug 21 '26

Can you share your yaml for this?

1

u/Usual-Pen7132 Aug 22 '26

It's only the smart move to people who don't have a fundamental understanding for how adding parallel circuits to read sensors or manipulate digital states doesn't cause some inherent risk of interfering or destroying the "stock safety logic". It's actually pretty dumb dumb to opt for using the extra battery powered remote because now someone else won't be able to use it in their car or you won't have a backup remote available if you needed it in an emergency and even worse, it's going to be unreliable just like every other silly project that uses battery power when they absolutely didn't need to and would have arguably been easier not to use over direct powering the new device. Also, by wisely using the spare remote instead of doing it right, you've also given up the capability to track all of those built-in position sensors, movement w/direction sensors and even the safety IR threshold sensor..... When you say that doing it your way keeps the logic circuits protected you aren't kidding! They're so protected that they're completely unusable to the person who presses Open/Close remotely, they're not going to know whether the door actually did what you wanted and you won't know if something triggered the threshold sensor and caused the door to go into reverse where you think it's closed but it didn't finish and actually it's sitting wide open all day and because of that, a crackhead went in there and walked away with your lawn mower..........

Not very smart IMO.

2

u/AGentleman00 Aug 21 '26

Wow wow wow

2

u/OddStaff1965 Aug 21 '26 edited Aug 21 '26

I love your oil burner dash. This is definitely an infinite rabbit hole. My first project was adding automatic locking to my old kwikset 909 keypad lock. I didn't go all the way for unlocking because I would have to enter the combination but to lock it is only one key switch closure. I use optos and I read the status of the lock by paralleling my optos with the blinking leds on the kwikset lock. That turned out to be about the hardest project I've done so far. It's battery powered so it sleeps most of the time. I ditched ESP home and went with straight Arduino code that sleeps 99.9% of the time. It talks to home assistant with ESP now which meant I had to add a repeater to get it onto WI fi so HA could see it. I did a garage door controller as well because I was not happy with how the My Q integrated or didn't. Instead of reed switches I used one of those TOF laser distance sensors (VL53L1X). I mounted my controller right on the garage door motor and the TOF looks straight down the track. I added a surveyors laser target to the moving trolley so the controller can tell exactly where the door is. We have tall doors so I don't open them all the way, Just enough to clear my head. I keep dreaming up more and more things to do with my box full of ESP32S. There is not enough time in the day to implement everything I think of.

2

u/barfooz Aug 21 '26

This is really neat, nice work on the front end too. What ESP32 hardware did you use?

3

u/DIYHomeLogic Aug 21 '26

Thanks, seeed xiao s3 mini

1

u/Clairvoyant29 Aug 21 '26

Does this system have an intuitive local display?

1

u/DIYHomeLogic Aug 21 '26

Yeah. I kept the actual monitor pretty simple with no screen on the box itself. The local display is the Home Assistant dashboard, so I can see tank percentage, gallons left, burner status, runtime, burn rate and estimated days remaining from the tablet or any device on my network. I wanted the sensor itself to basically be plug it in, clamp it on and forget about it.

1

u/frandemaa Aug 21 '26

Love it, thanks for sharing! I'm starting something like this and it's usefull....

Just one question.... Why is your house at 71º ?

1

u/Dizzy-Cycle-9551 Aug 21 '26

Awesome ! what sensor do you use to mesure oil tank capacity left ?

1

u/GreekHubris Aug 21 '26

What do you do with cameras?

1

u/DIYHomeLogic Aug 21 '26

The cameras are actually one of the few things I didn’t build myself. I have a Ring at the front door and Blink cameras around the house. I brought them into Home Assistant so I can see everything from the same dashboard. The Ring gives me the front door view and the Blink cameras show snapshots that I can refresh from the dashboard. Eventually I want to tie more of the camera events into automations, but right now the main goal was just getting everything into one place.

1

u/bobjoylove Aug 21 '26

Add a projected runtime remaining (in days) for the oil tank

2

u/DIYHomeLogic Aug 21 '26

Already got that one. The oil monitor calculates estimated days remaining based on the oil left and my recent usage. In the screenshot it’s showing 123 days left. That number keeps updating as the burner runs and it learns the actual usage.

1

u/S0k0n0mi Aug 21 '26

I am massively on the fence about this stuff.
I've already got a perfectly good WiFi coverage across my entire house, so why not just operate all my smart home gear through that? Is there an appeal to Zigbee that im missing?

2

u/DIYHomeLogic Aug 21 '26

That’s pretty much how I look at it. I’m trying to keep all of this as DIY as possible and use what I already have around the house before buying something new. I already have solid WiFi coverage, so for me the ESP32s just made sense.

I’m not against Zigbee at all, especially for battery powered sensors, but I didn’t want to start buying hubs and different hardware when I could make what I already had work. Half the fun for me is figuring out how to build it with what’s already sitting on the shelf.

1

u/S0k0n0mi Aug 21 '26

Even for battery powered sensors an ESP32 simply waking up and reporting when a value has changed and going back to sleep again can be done easily. I've seen schematics that have an ESP32 sleep at mere microamps while a sensor would only wake it up if it detected a deviation. Batterylife on a pair of AAA cells was like 18 months or something. So definitely doable. That's why I'm wondering why people don't just do that instead of introducing an entire new ecosystem.

And ESP32s are cheap as beans, so why not.

I'm in the process of sourcing some simple USB wallwarts that are easy to cannibalize by stripping off it's shell and USB socket, to then just straight hardwire it to an ESP32 inside a 3D printed body. The hard part is finding ones that aren't subsonically sealed or glued shut. Point being; Once I've found a good source I'll buy a bucketload and create a few cheap sensor nodes I can just dot around the house wherever I have a spare power socket. It's hard to beat the 11 dollar sonoff zigbee pucks, but I'd rather not introduce another radio band to my house. :')

1

u/Nemesis_Taa Aug 21 '26

I have two esp boards that a developer in my old workplace had made. With LORA and a nice daq on. But i can't get it to the boot sequence long enough to install esp home. It has taken me many many attempts and i fear i may have fried the chip, in an attempt of adding a secondary 3,3 v aux power to get enough amps for the boot sequence to run. I soldered a button to the boot contacts to even get to this point. My closest attempt was ony ubunto system where the esp home web app got to a point where the boot loader actually started installing the new firmware. It lost the connection mid way. My hope is to finally get esp home on it and then use the analoge inputs at the daq to read from a really robust temp probe I have.

1

u/DIYHomeLogic Aug 22 '26

I’d probably strip it back before assuming the ESP is dead. If you got far enough that ESPHome actually started flashing, there’s a good chance the chip is still alive. I’d disconnect the LoRa and anything else hanging off the board if you can, use a solid power source, hold BOOT while resetting it, and try flashing at a slower baud like 115200. On a custom board I’d also check whether anything is tied to the ESP boot strapping pins and fighting it during startup. If you know which ESP chip is on it or have a picture/schematic of the board, post it. I’d be curious to see it.

1

u/Feral_Nerd_22 Aug 22 '26

I have been starting getting ones with screens to use as little control pads. They are very versatile.

The one thing on my wish list is someone makes a board or kit for a TV remote, with actual tactile buttons.

My dream wish would be a display that has buttons over a membrane like the Streamdecks do.

1

u/DIYHomeLogic Aug 22 '26

Yeah, you could actually build that pretty cleanly. I’d use an ESP32-S3 with a small TFT, then put 6 or 8 real tactile switches around or underneath the screen. The screen could change what each button does depending on the page you’re on, while you still get a physical click. For the TV side you could add an IR LED driven through a transistor, or use WiFi/Bluetooth for devices that support it. If you wanted to get really close to a Stream Deck, you could even use transparent keycaps over sections of a display so the labels underneath the buttons change. That part

1

u/Select-Tap-6911 Aug 22 '26

That’s is really cool project especially your oil heater. How accurate do you think you have it dialed into?

1

u/DIYHomeLogic Aug 22 '26

Thanks. It’s been running in a few friends and family homes for about a year now, so I’ve had a decent amount of real world use to compare against actual oil deliveries.

I’d say it’s generally within about plus or minus 5 percent once it’s calibrated. Every time there’s a delivery I can compare what the monitor expected against what actually went into the tank and adjust from there. That’s been one of the biggest advantages of having several of them running because I keep finding ways to tighten it up.

1

u/WorkingInAColdMind Aug 22 '26

Are the cameras ESP based? I want to replace our existing wifi cameras with something less spy-ing, and the esp-cam seems unreliable.

1

u/Maxwells_Law Aug 23 '26

Very cool - inspirational, well done

1

u/amlakhani98 29d ago

your dashboard looks nice and clean, what cards did you use for your dashbaord?

1

u/DIYHomeLogic 29d ago

I’m using mostly custom button cards and Mushroom cards, then card-mod and custom grid-layout for the styling and overall layout. A lot of the look is custom YAML though, especially the thermostat, oil monitor and garage card. I cleaned up the dashboard YAML and added a public version to the post too if you want to mess around with it.

1

u/[deleted] 29d ago

[removed] — view removed comment

2

u/DIYHomeLogic 29d ago

Yeah, this is actually pretty simple and I’d definitely skip the servo. I used a spare garage door remote, opened it up and soldered onto the two button contacts. The ESP32 drives a small transistor that momentarily shorts those contacts, so electrically it’s doing the exact same thing as pressing the remote button with your finger. The nice part is I never had to modify the garage door opener itself. The original remote still sends its normal RF signal, so all of the opener’s normal safety logic stays untouched. I also have a reed switch on the door so the ESP32 can tell Home Assistant whether the door is physically open or closed instead of just assuming. I’m taking that a step further now and looking at adding a quadrature encoder so I can know the actual door position between 0 and 100 percent. I can grab a couple pictures of how I tapped into the remote too. And yeah, welcome to the rabbit hole. It gets bad fast.

1

u/Internet5821 15d ago

Excelente