Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


Closed Thread
  Search this Thread
Old 01-15-2009, 04:36 AM   #1
Registered: Dec 2008
Distribution: Ubuntu Fedora
Posts: 445

Rep: Reputation: 18
sending control-Z to serial port

hello every body
I wrote a program for my serial port for acting like minicom (but very simple) and I wanted to communicate to a gprs modem that I connected it to my serial port. every thing is good and I can send any command and receive its answer and action except control-Z and that is neccesery for me to sending sms via gprs modem, first of all I ignored SIGTSTP in my program for preventing it to stop but it does not work then I wrote function to send 26 (I think code of control+Z)to serial port that it does not work again.
what can I do
please help me.

this is the signal handler and my fuction in my program:

void ctrlz()
char ch[2]="26";
SerialOpen( port);
SerialSetSpeed( port, speed);
SerialWrite( port, &ch, 2);
Old 01-15-2009, 05:49 PM   #2
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 740Reputation: 740Reputation: 740Reputation: 740Reputation: 740Reputation: 740Reputation: 740
Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate.
1 members found this post helpful.

Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
sending control-Z to serial port golden_boy615 Linux - Embedded & Single-board computer 1 01-21-2009 04:42 PM
Sending files over serial port. Fadoksi Linux - General 2 08-01-2007 08:36 AM
Sending and receiving data to through Serial Port kalyan.penujeevi Programming 1 08-07-2006 07:55 AM
serial port (ttyS1) - Sending commands via terminal... HELP!!! Nalorin Linux - Networking 2 08-21-2005 10:22 PM
shell script: sending data through the serial port funkymunky Programming 2 06-09-2004 11:47 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:44 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration