My php file has the following code:
$serial->deviceOpen();
$serial->sendMessage('AT+CMGF=1');
$serial->sendMessage(chr(13));
$serial->sendMessage('AT+CMGS="+3XXXXX"');
$serial->sendMessage(chr(13));
$serial->sendMessage("THIS IS TEST");
$serial->sendMessage(chr(26));
sleep(6);
$read=$serial->readPort();
My code includes AT commands and it can now send sms to any number via gsm modem. Now I want to obtain the delivery status. I have used the AT commands for delivery status in putty software and got correct results. I want to see the report by my php code. How can this be done?
You may check delivery status by new incoming sms that will inform about success. It should not be hard to access it via this AT cmds:
AT+CNMI New SMS message indication
AT+ CMGL List SMS messages from preferred storage
AT+CMGR Read SMS message