Trying to write a program to do the following via Python on a Raspberry pi.
I am used to programming in Visual Basic, find it difficult in Python with no GOTO/select.
Have tried with “while loops” and now using “if-elif-else”.
Any suggestions on how to achieve it .
Thanks David.
Control of electric heaters in central heating system supplied from the Solar PV panels.
Have 4 heaters to turn on.
I need to turn on 1 then check – Power_result (tests whether grid or battery power is being used)
If True turn off, if False leave heater on
Repeat for other 3 heaters.
If not all 4 on keep checking, and turn on/off as required
Need to monitor Power_Result all the time
so as to turn some heaters off if True.