|
发表于 2020-11-30 16:34:40
5815 浏览 0 回复
MT6853 AP如何調用AT指令給Modem
AP在framework開了一個command介面讓module下AT command,
使用範例如下:
- import com.mediatek.telephony.MtkTelephonyManagerEx;
- String atCmd = "AT+EGCMD=XXXX";
- byte[] rawData = atCmd.getBytes();
- byte[] cmdByte = new byte[rawData.length + 1];
- byte[] cmdResp = new byte[2048];
- System.arraycopy(rawData, 0, cmdByte, 0, rawData.length);
- cmdByte[cmdByte.length - 1] = 0;
- int ret = MtkTelephonyManagerEx.getDefault().invokeOemRilRequestRaw(cmdByte, cmdResp);
复制代码 –String atCmd請填入個別需求的ATCMD
|
|
手机微信同号:13682654092
|
|
|
|
|
登录或注册
|