I am having trouble with 2 variables message2 is not getting anything
and runtimeend not changeing
I think your problem with
message2 is that you initialise it to 0. That isn’t a one off thing, it happens every time the piston fires. It is going to be set in one instance of the piston but used in a different one where it will be 0 again.
Not sure about the global. Bear in mind globals are read into cache when an instance fires up and only saved when it exits.
Full logs will help
logging is on full but this is all i got
3/20/2021, 7:30:47 AM +293ms
+48ms ╔Subscribing to devices…
+51ms ║Using Attribute subscription
+137ms ║Device missing from piston. Loading all from parent (83ms)
+172ms ║Using Attribute subscription
+183ms ║Subscribing to Beau’s Room Pump 2.power…
+202ms ║Piston controls pump status…
+227ms ╚Finished subscribing (183ms)
+337ms ╔Starting piston… (v0.3.113.20210211_HE)
+339ms ╚Piston successfully started (330ms)
Have you tried putting together a barebones piston to just log the pump’s power just to see if webcore actually gets information from it or can even subscribe to it?
I did it like logging works some times but not every time
this runs once then i get
║Using Attribute subscription
+39ms ║Device missing from piston. Loading all from parent (21ms)
+44ms ║Using Attribute subscription
+48ms ║Subscribing to Beau’s Room Pump 2.power…
how can I fix this
So full logs would help.
Please show us the executions as the piston receives events from the switch for power changes.
If you don’t see this, go to the switch (HE console -> Devices -> switch) and click on events and show us the events the device produced.
I think you are have a device problem at this point, and not a webcore problem.