|
PebbleOS
|
Pebble Protocol music backend for Music. More...
Data Structures | |
| struct | MusicEndpointPlayStateInfo |
| Payload of MusicEndpointCmdIDPlayStateInfoResponse. More... | |
Functions | |
| void | music_endpoint_handle_mobile_app_info_event (const PebbleRemoteAppInfoEvent *app_info_event) |
| Handle the mobile app info event. | |
| void | music_endpoint_handle_mobile_app_event (const PebbleCommSessionEvent *app_event) |
| Handle a comm session event. | |
Pebble Protocol music backend for Music.
Used with phone apps that do not run on iOS, where the Apple Media Service is used instead. Commands go to the phone over the system session on endpoint 0x20; responses update the music service.
| struct MusicEndpointPlayStateInfo |
Payload of MusicEndpointCmdIDPlayStateInfoResponse.
An optional byte of MusicEndpointSkipSeeksFlag bits may follow; check the message length before reading it.
| enum MusicEndpointCmdID |
Music endpoint message identifier, the first byte of every message.
| Enumerator | |
|---|---|
| MusicEndpointCmdIDTogglePlayPause | Watch to phone: toggle play/pause. |
| MusicEndpointCmdIDPause | Watch to phone: pause. |
| MusicEndpointCmdIDPlay | Watch to phone: play. |
| MusicEndpointCmdIDNextTrack | Watch to phone: next track. |
| MusicEndpointCmdIDPreviousTrack | Watch to phone: previous track. |
| MusicEndpointCmdIDVolumeUp | Watch to phone: volume up. |
| MusicEndpointCmdIDVolumeDown | Watch to phone: volume down. |
| MusicEndpointCmdIDGetAllInfo | Watch to phone: request all the info responses. |
| MusicEndpointCmdIDNowPlayingInfoResponse | Phone to watch: artist, album and title, then optional extended fields. |
| MusicEndpointCmdIDPlayStateInfoResponse | Phone to watch: MusicEndpointPlayStateInfo. |
| MusicEndpointCmdIDVolumeInfoResponse | Phone to watch: volume percentage, one byte. |
| MusicEndpointCmdIDPlayerInfoResponse | Phone to watch: player package and name. |
| MusicEndpointCmdIDInvalid | No equivalent command. |
Bits of the optional byte trailing MusicEndpointPlayStateInfo.
Phone apps that predate it send the shorter message, which reads as no bits set.
| Enumerator | |
|---|---|
| MusicEndpointSkipSeeksWithinTrack | Next/previous track commands seek within the track. |
| void music_endpoint_handle_mobile_app_event | ( | const PebbleCommSessionEvent * | app_event | ) |
Handle a comm session event.
Disconnects this backend when the system session closes.
| app_event | Session event. |
| void music_endpoint_handle_mobile_app_info_event | ( | const PebbleRemoteAppInfoEvent * | app_info_event | ) |
Handle the mobile app info event.
Connects this backend, disconnecting AMS, when the phone app runs on Android, macOS, Linux or Windows.
| app_info_event | Event reported by the phone app. |