Hi
I am assembling a very simple project to monitor a battery voltage and switch on a pump in my boat using Bolt. I have managed to get the control of the relays to work, but every time the Bolt sends an update to the cloud (every 5 mins) my outputs reset and the relays change back to off.
Does anyone have a suggestion of how to fix this?
Code below
singleButton({name:“Bilge On”, action:“digitalWrite”,
pin:“2”, value:“HIGH”,bgcolor:“green”,
shape:“rectangle”,align:“left”,“text_color”:“white” })
singleButton({name:“Bilge Off”, action:“digitalWrite”,
pin:“2”, value:“LOW”, bgcolor:“red”,
shape:“rectangle”, align:“left”, text_color:“black”})
singleButton({name:“House Battery”, action:“digitalWrite”,
pin:“3”, value:“HIGH”,bgcolor:“green”,
shape:“rectangle”,align:“left”,“text_color”:“white” })
singleButton({name:“Start Battery”, action:“digitalWrite”,
pin:“3”, value:“LOW”, bgcolor:“red”,
shape:“rectangle”, align:“left”, text_color:“black”})
singleButton({name:“Lights On”, action:“digitalWrite”,
pin:“4”, value:“HIGH”,bgcolor:“green”,
shape:“rectangle”,align:“left”,“text_color”:“white” })
singleButton({name:“Lights Off”, action:“digitalWrite”,
pin:“4”, value:“LOW”, bgcolor:“red”,
shape:“rectangle”, align:“left”, text_color:“black”})