Closed
Description
Environment
- Development Kit: none
- Module or chip used: ESP32-WROOM-32
- IDF version (run
git describe --tags
to find it):
framework-espidf 3.40200.210118 (4.2.0) - Build System: CMake (PlatformIO)
- Compiler version (run
xtensa-esp32-elf-gcc --version
to find it):
toolchain-xtensa32 2.80400.210114 (8.4.0) - Operating System: Windows
- (Windows only) environment type: PlatformIO
- Using an IDE?: VSCode/PlatformIO
- Power Supply: USB
Problem Description
I have tested the Bluetooth classic hands-free unit example. I want to get a ring indication from my phone. When I connect with my Android phone, I can see the ring indication event. But when I connect with my iPhone, I get battery level indication events, when my phone rings.
Expected Behavior
Get ring indication event when connected to iPhone and incoming call
Actual Behavior
Battery level indication event when connected to iPhone and incoming call
Steps to reproduce
- Start hfp_hf example
- Connect phone to esp32
- Call phone
Code to reproduce this issue
HFP Example: https://github.com/espressif/esp-idf/tree/master/examples/bluetooth/bluedroid/classic_bt/hfp_hf
Debug Logs
Android 8.0.0:
I (1044242) BT_HF: APP HFP event: CONNECTION_STATE_EVT
I (1044242) BT_HF: --connection state connected, peer feats 0x0, chld_feats 0x0
I (1044382) BT_HF: APP HFP event: CALL_IND_EVT
I (1044382) BT_HF: --Call indicator NO call in progress
I (1044382) BT_HF: APP HFP event: CALL_SETUP_IND_EVT
I (1044382) BT_HF: --Call setup indicator NONE
I (1044392) BT_HF: APP HFP event: NETWORK_STATE_EVT
I (1044402) BT_HF: --NETWORK STATE available
I (1044402) BT_HF: APP HFP event: SIGNAL_STRENGTH_IND_EVT
I (1044412) BT_HF: -- signal strength: 2
I (1044412) BT_HF: APP HFP event: ROAMING_STATUS_IND_EVT
I (1044422) BT_HF: --ROAMING: inactive
I (1044422) BT_HF: APP HFP event: BATTERY_LEVEL_IND_EVT
I (1044432) BT_HF: --battery level 5
I (1044432) BT_HF: APP HFP event: CALL_HELD_IND_EVT
I (1044442) BT_HF: --Call held indicator NONE held
I (1044532) BT_HF: APP HFP event: CONNECTION_STATE_EVT
I (1044532) BT_HF: --connection state slc_connected, peer feats 0xfe7, chld_feats 0x3f
I (1070502) BT_HF: APP HFP event: NETWORK_STATE_EVT
I (1070502) BT_HF: --NETWORK STATE available
Now, when I call the Android phone, I get this output
I (1072982) BT_HF: APP HFP event: RING_IND_EVT
I (1072982) BT_HF: APP HFP event: CLIP_EVT
I (1072982) BT_HF: --clip number ..........
iPhone iOS 14.3
I (11612) BT_HF: APP HFP event: CONNECTION_STATE_EVT
I (11612) BT_HF: --connection state connected, peer feats 0x0, chld_feats 0x0
I (12022) BT_HF: APP HFP event: NETWORK_STATE_EVT
I (12022) BT_HF: --NETWORK STATE available
I (12022) BT_HF: APP HFP event: CALL_IND_EVT
I (12032) BT_HF: --Call indicator NO call in progress
I (12032) BT_HF: APP HFP event: CALL_SETUP_IND_EVT
I (12042) BT_HF: --Call setup indicator NONE
I (12042) BT_HF: APP HFP event: BATTERY_LEVEL_IND_EVT
I (12052) BT_HF: --battery level 4
I (12052) BT_HF: APP HFP event: SIGNAL_STRENGTH_IND_EVT
I (12062) BT_HF: -- signal strength: 3
I (12062) BT_HF: APP HFP event: ROAMING_STATUS_IND_EVT
I (12072) BT_HF: --ROAMING: inactive
I (12082) BT_HF: APP HFP event: CALL_HELD_IND_EVT
I (12082) BT_HF: --Call held indicator NONE held
I (12092) BT_HF: APP HFP event: CONNECTION_STATE_EVT
I (12092) BT_HF: --connection state slc_connected, peer feats 0x3ef, chld_feats 0x3f
I (12102) BT_HF: APP HFP event: INBAND_RING_TONE_EVT
I (12102) BT_HF: --inband ring state Provided
When I call my iPhone now, I get a battery level report event. The battery is reported 1 as soon as the phone rings and 0, when the phone stops ringing.
I (39192) BT_HF: APP HFP event: BATTERY_LEVEL_IND_EVT
I (39192) BT_HF: --battery level 1
I (41162) BT_HF: APP HFP event: BATTERY_LEVEL_IND_EVT
I (41172) BT_HF: --battery level 0
Other items if possible
n/a
Activity