EricHigdon / OctoPrint-RGB_status

Adds RGB LED support to OctoPrint with the ability to choose effects based on the current status of your printer
33 stars 12 forks source link

wipe color after octoprint shutdown #55

Closed Gifford47 closed 2 years ago

Gifford47 commented 4 years ago

the problem: after octoprint shutdown the last effect is killed but the leds remain white. a fix would be: wipe color after shutdown event

Gifford47 commented 4 years ago

ok, i have tried several times, but i couldn't figure out why the leds don't turn off. either on direct startup or on shutdown. the problem is that the white color needs the most current and therefore the pi registers voltage problems on startup.

recently i tried the following without success:

    def on_shutdown(self):
    self.run_effect('Color Wipe', (0, 0, 0,), delay=10)
        self.kill_effect()

does anyone have any idea why the color wipe is not being performed?

EricHigdon commented 4 years ago

@Gifford47 see my comment on your pull request (#56). color_wipe is not a method on the plugin class. You should use self.run_effect() with the necessary parameters.

Edit: wow, I read your code snippet wrong. The code above should work fine. I’ll have to look into it.

Gifford47 commented 2 years ago

in the latest code, the color is wiped correctly. no need for investigation anymore. thanks for feedback!