docs: add some docs

I made this a while back, it is very incomplete, just adding in case anyone's looking for the opcodes
This commit is contained in:
Kavish Devar
2026-04-28 16:19:17 +05:30
parent ddcf15eefe
commit 30d16e9977
4 changed files with 106 additions and 47 deletions

View File

@@ -16,53 +16,53 @@ Bytes that are not used are set to `0x00`. From what I've observed, the `data3`
## Identifiers and details
| Command identifier | Description |
|--------------|---------------------|
| 0x01 | Mic Mode |
| 0x05 | Button Send Mode |
| 0x06 | Owns connection |
| 0x0A | Ear Detection |
| 0x12 | VoiceTrigger for Siri |
| 0x14 | SingleClickMode |
| 0x15 | DoubleClickMode |
| 0x16 | ClickHoldMode |
| 0x17 | DoubleClickInterval |
| 0x18 | ClickHoldInterval |
| 0x1A | ListeningModeConfigs |
| 0x1B | OneBudANCMode |
| 0x1C | CrownRotationDirection |
| 0x0D | ListeningMode |
| 0x1E | AutoAnswerMode |
| 0x1F | Chime Volume |
| 0x20 | Connect Automatically |
| 0x23 | VolumeSwipeInterval |
| 0x24 | Call Management Config |
| 0x25 | VolumeSwipeMode |
| 0x26 | Adaptive Volume Config |
| 0x27 | Software Mute config |
| 0x28 | Conversation Detect config |
| 0x29 | SSL |
| 0x2C | Hearing Aid Enrolled and Hearing Aid Enabled |
| 0x2E | AutoANC Strength |
| 0x2F | HPS Gain Swipe |
| 0x30 | HRM enable/disable state |
| 0x31 | In Case Tone config |
| 0x32 | Siri Multitone config |
| 0x33 | Hearing Assist config |
| 0x34 | Allow Off Option for Listening Mode config |
| 0x35 | Sleep Detection config |
| 0x36 | Allow Auto Connect |
| 0x37 | PPE Toggle config |
| 0x38 | Personal Protective Equipment Cap Level config |
| 0x39 | Raw Gestures config |
| 0x3A | Temporary Pairing Config |
| 0x3B | Dynamic End of Charge config |
| 0x3C | System Siri message config |
| 0x3D | Hearing Aid Generic config |
| 0x3E | Uplink EQ Bud config |
| 0x3F | Uplink EQ Source config |
| 0x40 | In Case Tone Volume |
| 0x41 | Disable Button Input config |
| Command identifier | Description |
| ------------------ | ---------------------------------------------- |
| 0x01 | Mic Mode |
| 0x05 | Button Send Mode |
| 0x06 | Owns connection |
| 0x0A | Ear Detection |
| 0x12 | VoiceTrigger for Siri |
| 0x14 | SingleClickMode |
| 0x15 | DoubleClickMode |
| 0x16 | ClickHoldMode |
| 0x17 | DoubleClickInterval |
| 0x18 | ClickHoldInterval |
| 0x1A | ListeningModeConfigs |
| 0x1B | OneBudANCMode |
| 0x1C | CrownRotationDirection |
| 0x0D | ListeningMode |
| 0x1E | AutoAnswerMode |
| 0x1F | Chime Volume |
| 0x20 | Connect Automatically |
| 0x23 | VolumeSwipeInterval |
| 0x24 | Call Management Config |
| 0x25 | VolumeSwipeMode |
| 0x26 | Adaptive Volume Config |
| 0x27 | Software Mute config |
| 0x28 | Conversation Detect config |
| 0x29 | SSL |
| 0x2C | Hearing Aid Enrolled and Hearing Aid Enabled |
| 0x2E | AutoANC Strength |
| 0x2F | HPS Gain Swipe |
| 0x30 | HRM enable/disable state |
| 0x31 | In Case Tone config |
| 0x32 | Siri Multitone config |
| 0x33 | Hearing Assist config |
| 0x34 | Allow Off Option for Listening Mode config |
| 0x35 | Sleep Detection config |
| 0x36 | Allow Auto Connect |
| 0x37 | PPE Toggle config |
| 0x38 | Personal Protective Equipment Cap Level config |
| 0x39 | Raw Gestures config |
| 0x3A | Temporary Pairing Config |
| 0x3B | Dynamic End of Charge config |
| 0x3C | System Siri message config |
| 0x3D | Hearing Aid Generic config |
| 0x3E | Uplink EQ Bud config |
| 0x3F | Uplink EQ Source config |
| 0x40 | In Case Tone Volume |
| 0x41 | Disable Button Input config |
## Command Details

26
docs/device-info.md Normal file
View File

@@ -0,0 +1,26 @@
---
opcode: 0x001D
title: Device Information
description: Information about AirPods, such as model, firmware version, and serial number. This can not be requested from the accessory; it is only sent by the accessory to the host upon connection.
---
## Device information
The device information packet is sent by the accessory to the host upon connection. It contains various details about the AirPods, including model number, software version, and serial number.
Each `null` indicates the start of a new string field.
The data is in this order:
- Name
- Model number
- Manufacturer (always "Apple Inc.")
- Serial number
- Version 1
- Version 2
- Hardware revision (?) (I have `1.0.0`)
- Updater app version (?) (I have `com.apple.accessory.updater.app.71`)
- Serial number (Left Bud)
- Serial number (Right Bud)
- Version (?) (I have `8454371`)
- A few more bytes, I don't know what they are

33
docs/opcodes.md Normal file
View File

@@ -0,0 +1,33 @@
# AACP opcodes
AACP (Apple Accessory Communication Protocol) uses various opcodes to define different types of actions and commands. Each opcode is a 16-bit integer that specifies the kind of operation being performed. The opcode is sent in little-endian format as part of the AACP packet structure.
| Opcode (Hex) | Destination | Description |
| ------------ | ----------- | ------------------------------------------------------------------ |
| 0x0001 | Accessory | Unknown |
| 0x0004 | Host | [Battery report](/docs/battery_report.md) |
| 0x0006 | Host | [Ear detection](/docs/ear-detection_report.md) |
| 0x0009 | Both | [Control commands](/docs/control_commands.md) |
| 0x000D | Accessory | [Audio source req](/docs/audio-source.md) |
| 0x000E | Host | [Audio source resp](/docs/audio-source.md) |
| 0x000F | Accessory | [Notification register](/docs/notification-register.md) |
| 0x0010 | Accessory | [Smart routing relay](/docs/smart-routing-relay.md#send) |
| 0x0011 | Host | [Smart routing response](/docs/smart-routing-relay.md#receive) |
| 0x0014 | Accessory | Send connected device MAC |
| 0x0017 | Both | Multiple things - undocumented |
| 0x0019 | Host | [Stem press](/docs/stem-press.md) |
| 0x001B | Accessory | [Timestamp](/docs/timestamp.md) |
| 0x001D | Host | [Device Information](/docs/device-info.md) |
| 0x001E | Accessory | [Rename device](/docs/rename.md) |
| 0x0022 | Accessory | Unknown |
| 0x0029 | Accessory | [Host capabilities](/docs/host-capabilities.md#another-opcode) (?) |
| 0x002B | Host | Paired devices (?) |
| 0x002D | Accessory | [List of connected dev. req](/docs/connected-devices.md#send) |
| 0x002E | Host | [List of connected devices](/docs/connected-devices.md#receive) |
| 0x0030 | Accessory | [BLE keys req](/docs/ble-keys.md) |
| 0x0031 | Host | [BLE keys response](/docs/ble-keys.md) |
| 0x004B | Host | [Conversation awareness](/docs/conversational-awareness.md) |
| 0x004D | Accessory | [Host capabilities](/docs/host-capabilities.md) |
| 0x004F | Both | Information req/res (doesn't work, even with apple's DID) |
| 0x0053 | Both | [EQ data](/docs/eq.md) |