Optimizing first piston


#1

1) Give a description of the problem
This is my first real piston and I’d love some feedback. Overall, it seems to be working now that I understand the difference between conditions and triggers, that programmatic/physical interaction can’t be detected with my switches, etc… Can this be written in a more optimized way for webcore?

2) What is the expected behavior?

  • Every day at 5am the lights turn on
  • Every day at 30 minutes before sunset the lights turn on
  • Every day at 30 minutes after sunrise the lights turn off
  • Every day at 9pm turn lights turn off
  • If arriving home and it is between 9pm and 5am, turn the lights on for 15 minutes
  • If the lights are turned on manually, don’t turn off after sunrise or 9pm

3) What is happening/not happening?
(PUT YOUR INFO HERE)

4) Post a Green Snapshot of the pistonimage

5) Attach any logs (From ST IDE and by turning logging level to Full)