The Shelly Plus Uni is a Pretty Cool Little Device

As I continue connecting things in my camper, I have discovered how cool the Shelly Plus Uni is… especially when tasmotized. First, it can be powered directly off of the 12v battery bank. Second, the ADC range is much higher than ESP devices. Third, the outputs handle higher voltages. As such, this device is quite versatile without additional components.

A couple of use cases in my camper:

Tank Level Sensors - I have three Uni’s for the three tanks - fresh, gray and black. Using the uni outputs, I activate the sensor for 15 seconds to allow it to normalize. Then using the ADC inputs I measure voltage - empty is roughly 9v, full is roughly 2.5v - and then turn the tank sensor back off. Using tasmota’s adcparams, this voltage is inversely converted to 0-100%. Fresh water readings run on a 30 minute schedule and subsequently kick off the gray then black water unis.

Camper Ceiling/Exhaust Fan - my camper fan has two buttons - a speed control button (4 speeds) and an off button. I paralleled the two Uni outputs to these buttons. I then tied the Uni adc input to the output of the fan control board. Similar to the tanks, at full speed, the adc reads basically zero. When the fan is off, the adc reads full battery voltage. In tasmota, I assigned a third (virtual) relay to an unused GPIO. I then created rules that turn on that virtual relay when adc voltage goes below 90% of the battery voltage and turns off that virtual relay at/above 90%. Additionally, I created rules that when the virtual relay is turned on or off, the speed and off outputs momentarily close accordingly. So, now I have a simple virtual switch that toggles the fan on/off and maintains accurate status when the fan is operated manually. The kicker - battery voltages drop during a boondocking trip, so to accurately determine 90% of the “off” voltage, I created an additional rule that updates an “off” voltage variable every 60 seconds -if- the fan has been off for 30 seconds. All of this is done through tasmota so the only things I expose are a power toggle switch and a speed “button”.

Agreed! I had a Qubino flush 1D relay that I absolutely hated because of various problems like missed relay events. But it was useful because it had a temperature probe capability that I used.

I bought an Uni Plus a few months back to replace it and it’s been awesome! Highly recommend them.

1 Like

3-Speed 1-button Fan as Slide/Dimmer Control

Alright, so I'm starting to think that a tasmotized Shelly plus uni can turn any dumb device into a smart one. This time it's a different fan - with one button that cycles between off and three speeds - 0-1-2-3. Same concept - I paralleled one digital output to either side of the button and tied the ADC to the output positive on the fan control board. This time I assigned a virtual PWM to an unused GPIO so I can expose the fan as a slide-type dimmer control.

One tasmota rule takes the ADC reading to determine if the fan is currently off, low, med or high and sets the dimmer state accordingly. When the slide dimmer is manually controlled, another rule converts the dimmer value to the target fan speed. That rule then determines how many button presses are required to get to the target fan speed (thankfully modulo is one of the 6 arithmetic functions supported in rules), and closes/opens the relay that many times. A third rule allows toggling the fan through tasmota/mqtt/http - it stores the current fan speed and restores it on the next toggle.

Now my single-button dumb fan can be controlled the same as any smart fan control.

PS: the subject fan is my daughter's bunk fan in the camper.

Edit: I just brought this into HomeKit and it is pretty cool. I can just tell Siri to set the camper bunk fan to high medium or low and no matter what setting the fan is currently at, it sets the right speed. Now I’m starting to think about dissecting my kitchen appliances to see if they can be tasmotized. :rofl:

2 Likes

AKA your boss. :rofl:

1 Like