自 2025 年 3 月 27 日起,我們建議您使用 android-latest-release
而非 aosp-main
建構及貢獻 AOSP。詳情請參閱「Android 開放原始碼計畫變更」。
USB-C 轉類比音訊轉接器
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
雖然部分新款 Android 手機不含 3.5 公釐耳機插孔,但使用者可能仍擁有 3.5 公釐耳機,希望能與這些裝置搭配使用。為方便使用者,本文將說明 USB-C 轉類比音訊轉接器規格,讓3.5 公釐耳機可連接至僅有 USB-C 連接埠的裝置。
本文件會說明最低要求:建議配件製造商在新增功能時,務必留意這些規定。
轉接器類型
只允許數位轉類轉換器。系統不支援 USB.org 的「USB Type-C Cable and Connector Specification, Release 1.2, Appendix A」中所述的純類比轉接器。
功能總覽
使用者可透過這個轉接器,將現有的 3.5 公釐配件插入具備 USB-C 連接埠的裝置。為此,轉接程式支援以下功能:
- 含有或不含麥克風的立體聲類比裝置
- 2 個輸出頻道的數位類比轉換
- 1 個輸入頻道的類比轉數位轉換
- 偵測類比裝置插入
- 偵測耳機麥克風
- 偵測輸出阻抗
- 將耳機按鈕事件轉譯為 HID 事件
類比介面
在裝置插入並正確識別之前,轉接器不得向 USB 主機提供任何 UAC 介面、播放或擷取端點。視偵測到的裝置類型而定,必須回報下列 UAC 終端類型:
- 耳機:低阻抗轉換器 (小於 1 千歐姆),沒有麥克風:0x0302
- 耳機。低阻抗轉換器 (含麥克風):0x0402
- Line in。高阻抗輸入:0x603
- Line out。高阻抗輸出:0x604
- Line in 和 Line out 或 Line in 和麥克風:0x400
轉接器應將從類比介面接收的按鈕事件,轉換為符合 Android 類比耳機規格的下列 HID 事件:
函式 |
對應 |
A |
HID 使用頁面:0x0C
HID 用途:0x0CD |
B |
HID 使用頁面:0x0C
HID 用途:0x0E9 |
C |
HID 使用頁面:0x0C
HID 用途:0x0EA |
D |
HID 使用頁面:0x0C
HID 用途:0x0CF |
這個頁面中的內容和程式碼範例均受《內容授權》中的授權所規範。Java 與 OpenJDK 是 Oracle 和/或其關係企業的商標或註冊商標。
上次更新時間:2025-07-27 (世界標準時間)。
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["缺少我需要的資訊","missingTheInformationINeed","thumb-down"],["過於複雜/步驟過多","tooComplicatedTooManySteps","thumb-down"],["過時","outOfDate","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["示例/程式碼問題","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-07-27 (世界標準時間)。"],[],[],null,["# USB-C-to-analog audio adapter\n\nWhile some new Android phones are being produced without a 3.5 mm jack, users\nmay still own 3.5 mm headsets that they want to use with those devices. To\nfacilitate that, this article specifies a USB-C-to-analog audio adapter spec to\nplug\n[3.5 mm headsets](/docs/core/interaction/accessories/headset/plug-headset-spec)\ninto devices that only have a\n[USB-C port](/docs/core/interaction/accessories/headset/usb-device).\n\n\nThis documentation specifies the minimum requirements: accessory manufacturers\nare encouraged to add features while keeping these requirements in mind.\n\nAdapter type\n------------\n\n\nOnly digital-to-analog adapters are allowed. Analog-only adapters following\n[USB.org's](http://www.usb.org/) \"USB Type-C Cable and Connector\nSpecification, Release 1.2, Appendix A\" are not supported.\n\nFunctional overview\n-------------------\n\n\nThe adapter allows users to plug their existing 3.5mm accessories into devices\nwith USB-C ports. To do this, the adapter supports:\n\n- Stereo analog devices with and without microphones\n- Digital to analog conversion of 2 output channels\n- Analog to digital conversion of 1 input channel\n- Detection of analog device insertion\n- Detection of headset microphone\n- Detection of output impedance\n- Translation of headset button events to HID events\n\nAnalog interface\n----------------\n\n\nThe adapter shall not present any UAC interface, playback, or capture endpoints\nto the USB host until a device is inserted and properly identified. Depending on\nthe type of device detected, the following UAC terminal types must be reported:\n\n- **Headphones**. Low impedance transducers, \\\u003c 1 kiloohm, no microphone: 0x0302\n- **Headset**. Low impedance transducers with microphone: 0x0402\n- **Line in**. High impedance input: 0x603\n- **Line out**. High impedance output: 0x604\n- **Line in and Line out** or **Line in and Mic**: 0x400\n\nButton functions\n----------------\n\n\nThe adapter shall convert button events received from the analog interface and\nconforming to the Android\n[analog headset\nspecification](/docs/core/interaction/accessories/headset/plug-headset-spec) to the following HID events:\n\n| Function | Mappings |\n|----------|---------------------------------------|\n| A | HID usage page: 0x0C HID usage: 0x0CD |\n| B | HID usage page: 0x0C HID usage: 0x0E9 |\n| C | HID usage page: 0x0C HID usage: 0x0EA |\n| D | HID usage page: 0x0C HID usage: 0x0CF |"]]