summaryrefslogtreecommitdiff
path: root/examples/host
diff options
context:
space:
mode:
authorZhang, Zhenjiang <[email protected]>2026-07-17 13:47:18 +0800
committerZhang, Zhenjiang <[email protected]>2026-07-17 13:47:18 +0800
commit70113a39a3ffac7b310ff7d661fe744c35364c50 (patch)
tree684fd97195dcacda6132e9f5349bb797f4c903cf /examples/host
parent817807dc64ae3124a315f42d67eb00271c3846e0 (diff)
fix(class/audio): fix control request byte order and buffer usage in audio host
- Fix missing tu_htole16() conversions for wValue and wIndex in tuh_audio_set_sampling_freq, tuh_audio_get_sampling_freq, tuh_audio_feature_unit_set, and tuh_audio_feature_unit_get - Fix incorrect wIndex parameter order in feature unit requests (unit_id and itf_num were swapped) - Replace static freq_buf with per-endpoint ctrl buffer in tuh_audio_set_sampling_freq to avoid concurrency issues - Update audio_host README to match actual example behavior
Diffstat (limited to 'examples/host')
-rw-r--r--examples/host/audio_host/README.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/host/audio_host/README.md b/examples/host/audio_host/README.md
index 4d8f66b71..072adbbf9 100644
--- a/examples/host/audio_host/README.md
+++ b/examples/host/audio_host/README.md
@@ -54,9 +54,9 @@ make BOARD=<your_board> flash
3. Open a serial terminal to view output
4. The example will:
- Print device information when mounted
- - Set sampling frequency to 48kHz
+ - Set sampling frequency based on the device's advertised capabilities
- Receive audio samples from the device (IN endpoint)
- - Send test sine wave audio to the device (OUT endpoint)
+ - Loop back received audio to the device (OUT endpoint) for testing
## Serial Output Example