1
私は流れるコマンドを通してPDUモードでSMSを送ります。 「長さ」は、pduの長さを示すラベルです。ラベルからpduの長さの値を取る方法
私のコードは、AT + CMGS = 20または長さは何でも書いていますが、コードに静的な値を書くのではなく、ラベルの値を取りたいと思っています。ワーキング。
私が間違ったやり方でコードを書く方法は誰でも助けてくれますか?
string recievedData = ExecCommand(port, "AT", 500000, "No phone connected");
recievedData = ExecCommand(port, "AT+CMGF=0", 500000, "Failed to set message format.");
string command = "AT+CMGS=\""+ length +" \"";
recievedData = ExecCommand(port, command, 500000, "Failed to accept phoneNo");
command = p1 + char.ConvertFromUtf32(26) + "\r";
recievedData = ExecCommand(port, command, 5000, "Failed to send message");