The Developer Preview for Android 11 is now available; test it out and share your feedback.

androidx.media.session

Classes

MediaButtonReceiver A media button receiver receives and helps translate hardware media playback buttons, such as those found on wired and wireless headsets, into the appropriate callbacks in your app.