LedringAnimationSystem

This class contains a system animation that can be played on Homey's LED Ring.

Extends

Methods

registerScreensaver

(async) registerScreensaver(screensaverName): Promise.<any>

Register this animation as a screensaver. This is a shorthand method to ManagerLedring#registerScreensaver.

Parameters

Name Type Description
screensaverName
String

The name of the screensaver, as defined in /app.json

Returns

Promise.<any>

start

(async) start(): Promise.<any>

Start the animation.

Returns

Promise.<any>

stop

(async) stop(): Promise.<any>

Stop the animation.

Returns

Promise.<any>

unregister

(async) unregister(): Promise.<LedringAnimation>

Unregister the animation. This is a shorthand method to ManagerLedring#unregisterAnimation.

Returns

Promise.<LedringAnimation>

unregisterScreensaver

(async) unregisterScreensaver(screensaverName): Promise.<any>

Unregister this animation as a screensaver. This is a shorthand method to ManagerLedring#unregisterScreensaver.

Parameters

Name Type Description
screensaverName
String

The name of the screensaver, as defined in /app.json

Returns

Promise.<any>

updateFrames

(async) updateFrames(frames): Promise.<any>

Update the animation frames.

Parameters

Name Type Description
frames
Array.<LedringAnimation.Frame>

Returns

Promise.<any>

Events

finish

.on('finish')

When the animation has finished (duration has been reached)

start

.on('start')

When the animation has started

stop

.on('stop')

When the animation has stopped