Smart IoT Ozone Machine / Relay / IoT Smart Appliance / Voice Control

Plus: voice control

I modified this puppet, the ultraviolet ozone tube, which was originally in the sterilization and disinfection cabinet to sterilize the tableware.
Expected: app smartconfig network settings, remote control switch, set scheduled operations, firmware one-key remote update function. First look at the results ~ (for easy identification, the ozone tube will flash twice when the device is started or reset)

Modification process ………….

Because our ozone tube eats AC 110V ~ 220V, we need relay to work with our IoT system. And we want it can be configured to work regularly .

** Household electricity is already very strong, not a joke, please be careful **

To make it can be controlled remotely , we use mqtt ,put code in mqtt_callback (arduino code put into ESP12 chip)

if (myString.indexOf("O3ON")>-1) {
digitalWrite(12,HIGH) ;
}
if (myString.indexOf("O3OFF")>-1) {
digitalWrite(12,LOW) ;
}

And we put working time configuration in a file saved in spiff of ESP12 chip , then code will check if it is time to work

if (get_weekday() !="" && get_weekday().indexOf(gg)>-1) {
if (get_hours() !=""&&get_hours().indexOf(yy)>-1) {
digitalWrite(12,HIGH) ;
}
} else {
digitalWrite(12,LOW) ;
}