Lullaby
Pre-requisite
- The camera should have already started streaming LiveView before making any interactions.
- The camera should support the lullaby feature.
These methods send the command over the data channel of the running stream. The resulting playback state is delivered asynchronously on the onSSEMessage callback of InstaSDK, and should be used to render the player rather than assuming the command succeeded.
The same operations are available over the cloud without an active stream, see Device Control and Operations.
Play a Lullaby
To start playback, The following can be used:
request(optional): The request object containing the track id, the playback mode and the timer duration.
liveViewObject.lullabyPlay(request: LullabyPlayRequest?)
Pause a Lullaby
To pause playback, The following can be used:
liveViewObject.lullabyPause()
Resume a Lullaby
To resume playback, The following can be used:
liveViewObject.lullabyResume()
Stop a Lullaby
To stop playback, The following can be used:
liveViewObject.lullabyStoped()