This subVI sends an SMS to the selected mobile phone. The subVI (Fig. 1) consists of three subVIs which perform the sending of the SMS. The SMS is sent in text mode. First, the modem receives the number of the mobile phone, followed by the text message.
Fig. 1 Sending SMS message
The date and time when the message is sent is automatically added at the beginning of the message. The message must be ended with Ctrl-Z. The ASCII code for the Ctrl-Z character is 26. Below is a simple example of sending the SMS message. The responses from the GSM modem are marked in blue.
AT + CMGF = 1
OK
AT + CMGS = "+381628869066"
> SMS message from Wavecom GSM modem! Ctrl-Z
+ CMGS: 138
OK