Adding AT commands to activate call audio over USB endpoint

Bob Ham bob.ham at puri.sm
Wed Aug 8 10:31:53 UTC 2018


On 07/08/18 12:49, Aleksander Morgado wrote:
>> We're using a SIMCom SIM7100 modem which has the ability to exchange
>> call audio data over a USB serial endpoint⁰.  To enable this, the modem
>> needs an AT command after the call has connected, AT+CPCMREG=1, and a
>> command after call has disconnected, AT+CPCMREG=0.
>>
> 
> Would these commands be needed as soon as a call is started (even if
> not established)? or just when established?

After you send ATD.  The SIMCom docs say after your receive "VOICE CALL:
BEGIN" but it also says "If you want hear the ring back tone, you can
run "AT+CPCMREG=1" command after ATDXXX;" which is what we'd want.  I've
tested sending it immediately after ATD and that works.

> Also, how would it work for received calls, at which point should the
> command be executed?

I believe you get "VOICE CALL: BEGIN" when you answer the call so after
that.

To summarise:

--------------------------------------------------
  Command    |         When            | Call type
--------------------------------------------------
AT+CPCMREG=1 | After ATD               | outgoing
AT+CPCMREG=1 | After VOICE CALL: BEGIN | incoming
AT+CPCMREG=0 | After VOICE CALL: END   |   both
--------------------------------------------------


>> Not knowing the internals of ModemManager too well, I'm wondering if
>> anyone could advise on an appropriate way to add these AT commands for
>> our particular modem?

> The way to do this would be to define a new async command in the Voice
> interface struct (mm-iface-modem-voice.h) and then in the same voice
> interface implementation setup the logic to call that command whenever
> needed, but only if it is implemented (e.g. in this case we would have
> NULL defaults as others modems don't need this). Once that logic is in
> place, we would need a new "simcom" plugin (there is none right now),
> which creates a new MMBroadbandModemSimcom that implements the voice
> interface and subclasses the specific command.

I'm still trying to get my head around this.  There doesn't seem to be
anything similar in the voice interface, can you suggest another
interface with some similar functionality?

I don't understand the setup function you suggest.  What would this do?
If there is a SIMCom-specific subclass for the modem which adds the
AT+CPCMREG calls to the existing ATD calls or "VOICE CALL" handlers,
what would the MMIfaceModemVoice setup function do?

Cheers,

Bob

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/modemmanager-devel/attachments/20180808/15cb972b/attachment.sig>


More information about the ModemManager-devel mailing list