gusgonnet
Published © CC BY-NC-SA

Pool and Sauna Controller

Control your pool and sauna from anywhere!

BeginnerFull instructions provided5 hours4,297
Pool and Sauna Controller

Things used in this project

Story

Read more

Code

Plant UML code for the state machine of the firmware

Plain text
To draw the FSM image, copy paste this code in http://www.plantuml.com/plantuml/uml
@startuml
skinparam backgroundColor LightYellow
skinparam state {
  BackgroundColor LightBlue
  BorderColor Gray
  FontName Impact
}


[*] --> initState

note left of initState : The system boots\nin this state

initState: 10 seconds
initState -down--> offState: if system was\npreviously off
initState -down--> idleState: if system was\npreviously on


offState: system off
offState -left-> idleState: setOnOff("on")

idleState: heating off
idleState -down-> onState: temperature\n< target
idleState -right-> offState: setOnOff("off")

onState: heating on
onState -up-> idleState: temperature\n> target
onState -up-> offState: setOnOff("off")
@enduml

github repo

flash this code in your photon

Credits

gusgonnet

gusgonnet

37 projects • 306 followers
With a decade of Software Engineering experience in IoT, I focus on creating Particle IoT solutions coupled with mobile and web applications
Thanks to Sergio Boyd.

Comments