Hi all,
Presently, I am working on the early stages of a Bluetooth audio project. To get started, I looked through and flashed the code for the a2dp_sink example for the ESP32 (I am using the ESP32 WROOM).
My goal, at this stage, is to capture and record the incoming Bluetooth audio bytes and store them in a text file which can be accessed by a separate program which will plot a graph based on each digital value of the received audio. After looking through the code, I determined (possibly incorrectly) that the bt_app_a2d_data_cb function in the bt_app_av class would be the correct location to capture my desired data (prior to being written to I2S).
However, the 'data' variable at this location seems to hold an array of the data (unless I am totally off-base), meaning I would have to loop through the array and append each value to a text file every single time the function is called. Is there a better way of doing this? I am inexperienced with A2DP, but I would have assumed that the bytes of digital audio data were stored into the 'data' array one byte at a time, so (to me) it would be logical to capture these bytes wherever that takes place.
Unfortunately, since I am still new to the ESP32 environment as well as A2DP in general, I am struggling to find exactly where in the code I should modify to accomplish my specific goal. Therefore, if anyone who is more familiar with the a2dp_sink example could offer some guidance, it would be much appreciated! Thanks!
Capture and Record A2DP Values
-
- Posts: 1
- Joined: Mon Apr 01, 2019 1:23 pm
Return to “General Discussion”
Jump to
- English Forum
- Explore
- News
- General Discussion
- FAQ
- Documentation
- Documentation
- Sample Code
- Discussion Forum
- Hardware
- ESP-IDF
- ESP-BOX
- ESP-ADF
- ESP-MDF
- ESP-WHO
- ESP-SkaiNet
- ESP32 Arduino
- IDEs for ESP-IDF
- ESP-AT
- ESP IoT Solution
- ESP RainMaker
- Rust
- ESP8266
- Report Bugs
- Showcase
- Chinese Forum 中文社区
- 活动区
- 乐鑫活动专区
- 讨论区
- 全国大学生物联网设计竞赛乐鑫答疑专区
- ESP-IDF 中文讨论版
- 《ESP32-C3 物联网工程开发实战》书籍讨论版
- 中文文档讨论版
- ESP-AT 中文讨论版
- ESP-BOX 中文讨论版
- ESP IoT Solution 中文讨论版
- ESP-ADF 中文讨论版
- ESP Mesh 中文讨论版
- ESP Cloud 中文讨论版
- ESP-WHO 中文讨论版
- ESP-SkaiNet 中文讨论版
- ESP 生产支持讨论版
- 硬件问题讨论
- 项目展示
Who is online
Users browsing this forum: No registered users and 150 guests
- All times are UTC
- Top
- Delete cookies
About Us
Espressif Systems is a fabless semiconductor company providing cutting-edge low power WiFi SoCs and wireless solutions for wireless communications and Internet of Things applications. ESP8266EX and ESP32 are some of our products.