Viewing 1 reply thread
  • Author
    Posts
    • #2479

      guido_ts
      Participant

        Hello IOT747 Support,

        we are using an IDC777 module with AudioAgent firmware V3.2.72 in a custom

        embedded design (Teensy 4.1 as UART host, paired to an iPhone as HFP AG).

        The module is in HFP HF role only (no AGHFP).

        == Setup summary ==

        Module connected via UART at 115200 baud. Configuration applied at startup

        via SET commands + WRITE + RESET:

        SET PROFILES=ON 1 0 1 0 1 0 1 1 1

        SET PROFILES2=1 0

        SET AUDIO=1 1

        SET AUDIO_DIGITAL=0 48000 64 00100100 00000000 (I2S, 48kHz, 16-bit, slave)

        SET HFP_CONFIG=ON OFF OFF ON 5 ON OFF ON OFF

        SET AUTOCONN=2 3

        SET AUTOCONN_CONFIG=ON OFF 1 4 5 ON

        WRITE + hardware reset

        Pairing and HFP audio (CVSD and mSBC) work reliably with the configuration

        above.

        == Problem ==

        We need to receive HFP indicator notifications from the phone (+CIND, +CIEV,

        +CSQ replies) so we can drive a signal-strength / battery-status display.

        According to the manual page 28, AT notifications must be enabled in

        HFP_CONFIG to receive them, so we changed:

        SET HFP_CONFIG=ON ON OFF ON 5 ON OFF ON OFF

        ^^^ enable_at_notifications = ON

        After WRITE + RESET, +CIND/+CSQ replies do come through correctly. However

        voice calls no longer work: SCO is never established. The phone signals the

        call active very briefly and then ends it again.

        == Trace of an outgoing call (enable_at_notifications=ON) ==

        Host: CALL 13 OUTGOING

        Module: OK

        Module: ATH 13 7

        Module: OK

        Module: +CIEV: 3,2 (callsetup = dialing)

        Module: ABS_VOL 13 15

        Module: ATH 13 12

        Module: +VGS=15

        Module: +BCS:2 (codec selection from phone: mSBC)

        Module: OK

        Module: ATH 13 7

        Module: OK

        Module: +CIEV: 3,3 (callsetup = alerting)

        Module: ATH 13 15

        Module: +CIEV: 2,1 (call = active) <– very briefly

        Module: +CIEV: 3,0 (callsetup = idle)

        Module: +CIEV: 2,0 (call = ended) <– immediately

        Module: CALL_IDLE HFP 13

        There is NO SCO_OPEN notification at any point. The host did not send any

        hangup. The phone (iPhone) appears to abandon the call because the SCO

        link cannot be established.

        For comparison, when we use enable_at_notifications=OFF, the same call

        sequence produces:

        Host: CALL 13 OUTGOING

        Module: OK

        Module: SCO_OPEN <– SCO comes up immediately

        Module: CALL_ACTIVE HFP 13

        …audio flows correctly…

        == What we tried ==

        1. Manually sending the codec confirmation back to the AG:

        On receipt of “+BCS:” the host sends “AT 13 AT+BCS=”

        (both via the regular command queue and bypassing the queue with a

        direct serial write).

        Result: same as above. SCO is never opened. Phone ends the call.

        2. Setting at_hfp_unhandled=ON in addition (HFP_CONFIG=ON ON ON ON 5 ON OFF ON OFF):

        Result: phone behaves the same; in some cases the call drops earlier.

        We assume the module starts answering “+BCS” with ERROR which actively

        breaks the negotiation.

        3. Manually requesting SCO_OPEN from the host (enqueueCommand(“SCO_OPEN 13”))

        when +CIEV: 3,2 / 3,3 / 2,1 are received:

        Module replies OK, but the SCO link is still never established (no

        SCO_OPEN notification follows). Subsequent SCO_OPEN attempts time out.

        Phone still drops the call quickly.

        == Question ==

        Is this a known limitation? Specifically:

        – With enable_at_notifications=ON, does the module still respond to +BCS

        internally on the HFP link, or is the host expected to take over the

        full codec negotiation?

        – Is there a recommended way to receive +CIND / +CSQ / +CIEV indicator

        updates from the AG without breaking automatic HFP codec negotiation?

        – Is there a non-Apple-specific way to query phone signal strength and

        battery level via the IDC777 (AudioAgent commands or AT pass-through)

        while keeping HFP audio fully functional?

        We would also be interested if there is a way to toggle

        enable_at_notifications at runtime without going through WRITE + RESET

        (which currently kills the BT link).

        Module info:

        IOT747 Copyright 2022

        AudioAgent IDC777 V3.2.72

        Build: 0400427b

        Bluetooth address: 245DFC03994B

        Phone: iPhone (iOS 17.x), HFP 1.7/1.8.

        Thanks in advance,

        Guido

      • #2480

        IOT747 Team
        Keymaster

          Hello Guido,

          This is strange as enabling this should just mean the AT commands are displayed via UART, but shouldn’t be changing behaviour otherwise. We tried with an iPhone SE and we could not replicat ethe issue. See below the UART log.

          1) With enable_at_notifications=ON, does the module still respond to +BCS

          internally on the HFP link, or is the host expected to take over the

          full codec negotiation?

          >> If it displays ATH for the AT command it shows this is has been handled by the AT parser and the appropriate response has been sent, eg:

          ATH 13 12

          +BCS: 2

          If it just showed: AT ,

          Then it has not been handled, and might require a response depending on the AT command.

          With enable_at_notifications=ON, it should just be for display purposes, it is not meant to affect behaviour.

          2) Is there a recommended way to receive +CIND / +CSQ / +CIEV indicator

          updates from the AG without breaking automatic HFP codec negotiation?

          >> You can set enable_at_notifications=ON, or send AT commands directly using the command: AT . 

          3) Is there a non-Apple-specific way to query phone signal strength and

          battery level via the IDC777 (AudioAgent commands or AT pass-through)

          while keeping HFP audio fully functional?

          >> You can use the command: AT

          to send AT commands to the connected AG.

          Eg.

          AT 13 AT+CIND?

          OK

          ATH 13 25

          +CIND: 0,0,1,1,0,5,0

          ATH 13 7

          OK

          AT 13 AT+CIND=?

          OK

          ATH 13 133

          +CIND: (“call”,(0,1)),(“callsetup”,(0-3)),(“service”,(0-1)),(“signal”,(0-5)),(“roam”,(0,1)),(“battchg”,(0-5)),(“callheld”,(0-2))

          ATH 13 7

          OK

          AT 13 10

          ERROR

          4) We would also be interested if there is a way to toggle

          enable_at_notifications at runtime without going through WRITE + RESET

          >> You can actually change between these at run time, and the AT information should be enabled/disabled accordingly :

          set HFP_CONFIG=ON ON OFF ON 5 ON OFF ON OFF

          set HFP_CONFIG=ON OFF OFF ON 5 ON OFF ON OFF

          Details of iPhone test with AT notifications enabled.

          call 13 outgoing 121
          OK
          ATH 13 7
          OK
          ATH 13 15
          +CIEV: 3,2
          ATH 13 11
          +BCS:2
          ATH 13 7
          OK
          SCO_OPEN
          ATH 13 15
          +CIEV: 3,3
          CALL_ACTIVE HFP 13
          ATH 13 15
          +CIEV: 2,1
          ATH 13 15
          +CIEV: 3,0
          call 13 end
          OK
          SCO_CLOSE
          ATH 13 7
          OK
          CALL_IDLE HFP 13
          ATH 13 15
          +CIEV: 2,0

      Viewing 1 reply thread

      You must be logged in to reply to this topic.