Send USSD code to modem in C# and ERROR in return always

前端 未结 2 1435
刺人心
刺人心 2021-01-21 15:50

I am sending USSD code on modem through serial port. But always it is giving ERROR in response.

AT commands I am sending are: in sequence:

serialPort.Wri         


        
2条回答
  •  情歌与酒
    2021-01-21 16:40

    Don't use \n in end of command, use only \r.

    Form of CUSD command is: AT+CUSD=1,"*135#",15.

    In C# it should be:

    serialPort.Write("AT+CMGF=0" + "\r");
    serialPort.Write("AT+CUSD=1,\"*135#\",15" + "\r");
    

提交回复
热议问题