End of sms in gsm

need help to sent message from gsm module . A ctrl z character needs to be added at the end of the message to send it. Can anyone please advise how to do this in serial monitor ?

Why do you need to do it in the monitor? Why not just append it in your sketch when you get the end of the message?

AWOL:
Why do you need to do it in the monitor?
Why not just append it in your sketch when you get the end of the message?

because i need a program ,which can use serial monitor to send AT commands directly from serial monitor and show response from gsm.

my program

#include <NewSoftSerial.h> //Include the NewSoftSerial library to send serial commands to the modem
#include <string.h> //Used for string manipulations

char incoming_char=0; //Will hold the incoming character from the Serial Port.

NewSoftSerial cell(10,11); //Create a ‘fake’ serial port. Pin 2 is the Rx pin, pin 3 is the Tx pin.

void setup()
{
//Initialize serial ports for communication.
Serial.begin(9600);
cell.begin(9600);

//Let’s get started!
Serial.println(“Starting Communication…”);
}

void loop() {
//If a character comes in from the cellular module…
if(cell.available() >0)
{
incoming_char=cell.read(); //Get the character from the cellular serial port.
Serial.print(incoming_char); //Print the incoming character to the terminal.
}
//If a character is coming from the terminal to the Arduino…
if(Serial.available() >0)
{
incoming_char=Serial.read(); //Get the character coming from the terminal
cell.print(incoming_char); //Send the character to the cellular module.
}
}

Please repost using code tags.

I don't understand why your sketch can't append ctrl-z when you hit return, or something like that.

I guess this is just for testing the modem and you don't specifically need to use the Arduino serial monitor. If you use RealTerm instead, you can send control characters as well as normal printable characters.