-
Notifications
You must be signed in to change notification settings - Fork 0
Core Music Control Overview
Mr.P edited this page Aug 29, 2026
·
2 revisions
Music Control sends playback and playback-volume commands through a connected AIBuds device.
Browse the generated Wiki navigation for the pages in this section.
- Connect to the Device - Wait until the device is connected and ready.
-
Check Protocol Conformance - Verify support for
DeviceMusicControlAPI. - Choose a Command - Play, pause, select the next or previous track, or adjust playback volume.
- Handle Completion - Update application UI only after the command reports success.
-
playMusicstarts or resumes playback. -
pauseMusicpauses playback. -
playNextMusicandplayPreviousMusicnavigate the playback queue. - The public protocol does not define a stop command.
-
musicVolumeUpandmusicVolumeDownmove by one device-defined step. -
muteandunmutecontrol playback muting. -
setMusicVolumeaccepts an explicit level from 0 through 100.
Music Control is accessed through DeviceMusicControlAPI:
guard let device = device as? DeviceMusicControlAPI else {
print("Device does not support DeviceMusicControlAPI")
return
}id<AIBudsDeviceMusicControlAPI> device = (id<AIBudsDeviceMusicControlAPI>)self.device;
if (![device conformsToProtocol:@protocol(AIBudsDeviceMusicControlAPI)]) {
NSLog(@"Device does not support AIBudsDeviceMusicControlAPI");
return;
}- Check Protocol Conformance: The SDK exposes no separate Boolean support query.
-
Handle Every Completion: Check
successand reporterrorwhen a command fails. - Debounce Sliders: Avoid sending every intermediate explicit volume value.
-
Observe Playback Changes: Use
didMediaPlayStatusChangedwhen the UI must follow device notifications.
- The SDK does not expose the active player, track metadata, or playback queue through this protocol.
- Command success confirms command execution, not a permanent playback state.
- Volume Control and Music Control are separate protocols even though both include volume-related operations.
AIBuds SDK documentation · Full documentation · API Reference
- Introduction
- Getting Started
- Core Concepts
-
Core Features
- Basic Features
- Device Info
- Find Device
- Physical Operations
- Work Mode
- Work Status
- Wear Detection
- Volume Control
- Music Control
- TWS
- Equalizer
- ANC
- Audio
- Camera
- Remote Camera
- File Import
- Teleprompter
- Segment Navigation
- Live Streaming
- Device Applications
- OTA
- Camera OTA
- Service Auth
- AI Services
- Voice Assistant
- Logging
- Advanced Topics
- Releases
- Troubleshooting