Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How to send ctrl+c through hyperterminal session

1,596 views
Skip to first unread message

csmi...@gmail.com

unread,
Aug 8, 2008, 5:48:46 PM8/8/08
to
I have a command prompt session running via my debug machine (PC) and
my windows ce embedded board. I have a hyperterminal session running
and I want to send a ctrl+c command from the hyperterminal, how would
i do that. When I press ctrl+c in the hyperterminal window is displays
some odd character but I don't think it is sending a ctrl+c command
over to the embedder side.

Thanks

Paul G. Tobey [eMVP]

unread,
Aug 11, 2008, 12:29:25 PM8/11/08
to
I think that it *is* sending Ctrl+C. It might depend on how Hyperterminal
is configured, but I think that ANSI or TTY configuration should be sending
precisely the character that you are typing. What makes you say that it's
not sending the right character?

Paul T.

<csmi...@gmail.com> wrote in message
news:af6fc42b-5891-4a59...@b1g2000hsg.googlegroups.com...

csmi...@gmail.com

unread,
Aug 11, 2008, 4:48:49 PM8/11/08
to
On Aug 11, 11:29 am, "Paul G. Tobey [eMVP]" <p space tobey no spam AT

no instrument no spam DOT com> wrote:
> I think that it *is* sending Ctrl+C.  It might depend on how Hyperterminal
> is configured, but I think that ANSI or TTY configuration should be sending
> precisely the character that you are typing.  What makes you say that it's
> not sending the right character?
>
> Paul T.
>
> <csmit...@gmail.com> wrote in message

>
> news:af6fc42b-5891-4a59...@b1g2000hsg.googlegroups.com...
>
>
>
> >I have a command prompt session running via my debug machine (PC) and
> > my windows ce embedded board. I have a hyperterminal session running
> > and I want to send a ctrl+c command from the hyperterminal, how would
> > i do that. When I press ctrl+c in the hyperterminal window is displays
> > some odd character but I don't think it is sending a ctrl+c command
> > over to the embedder side.
>
> > Thanks- Hide quoted text -
>
> - Show quoted text -

Well just that I thought ctrl+c would end any application launched
from the cmd window that is running remotely from the device to the
hyperterminal

Paul G. Tobey [eMVP]

unread,
Aug 11, 2008, 5:25:25 PM8/11/08
to
Nothing is assured. If it's a console program and if it's waiting at a
console I/O routine at the time that you press Ctrl+c, then I think it
should exit. There's no magic in Ctrl+c, however. It's not going to
terminate some long-running network I/O that your program might be doing or
stop file I/O because Ctrl+c occurred. It won't terminate a program that
doesn't check for it.

If it were me, I'd verify that Ctrl+c is getting sent by Hyperterminal (you
could do a capture of the text sent to your PC on another port from
Hyperterminal and then read the text file with a binary editor to see what
ASCII code is where you pressed Ctrl+c; it should be 0x03, of course). If
that all seems fine, I'd write a simple console program that uses whatever
I/O function you're using to read the incoming key data (getch() or
whatever), and see if that exits. I'd probably also try Ctrl+c, Enter, if
just Ctrl+c by itself didn't work.

Paul T.

<csmi...@gmail.com> wrote in message
news:7bf5dd54-1fb1-47ba...@e53g2000hsa.googlegroups.com...

Helge Kruse

unread,
Aug 12, 2008, 2:46:14 AM8/12/08
to
The Windows CE telnet service has very limited functionality in compare
with e Unix like telnet daemon. In the Unix world the daemon interprets
some special key codes. It can work in RAW or COOKED mode, where
characters are sent immediately to the application or some line editing
takes place and so forth. When the telnet daemon receives a Ctrl-C it
sends a signal SIGHUP (or SIGTERM, I am not sure) to the application
what causes it to terminate. In RAW mode the characters are sent
directly to the application that is responsible to interpret them
somehow. To control such daemons you will find a huge termio library
(in Unix systems).

In this vocabulary the Windows CE telnet service is always in raw mode.
There is no Ctrl-C command, since nobody interprets the characters and
sends any signal.

Regards,
Helge

"Paul G. Tobey [eMVP]" <p space tobey no spam AT no instrument no spam

DOT com> wrote in message
news:Ok0cFj$%23IHA...@TK2MSFTNGP04.phx.gbl...

csmi...@gmail.com

unread,
Aug 13, 2008, 10:49:24 AM8/13/08
to
On Aug 12, 1:46 am, "Helge Kruse" <Helge.Kruse-nos...@gmx.net> wrote:
> The Windows CE telnet service has very limited functionality in compare
> with e Unix like telnet daemon. In the Unix world the daemon interprets
> some special key codes. It can work in RAW or COOKED mode, where
> characters are sent immediately to the application or some line editing
> takes place and so forth. When the telnet daemon receives a Ctrl-C it
> sends a signal SIGHUP (or SIGTERM, I am not sure) to the application
> what causes it to terminate. In RAW mode the characters are sent
> directly to the application that is responsible to interpret them
> somehow. To control such daemons you will find a huge termio library
> (in Unix systems).
>
> In this vocabulary the Windows CE telnet service is always in raw mode.
> There is no Ctrl-C command, since nobody interprets the characters and
> sends any signal.
>
> Regards,
> Helge
>
> "Paul G. Tobey [eMVP]" <p space tobey no spam AT no instrument no spamDOT com> wrote in message

>
> news:Ok0cFj$%23IHA...@TK2MSFTNGP04.phx.gbl...
>
>
>
> > Nothing is assured.  If it's a console program and if it's waiting at
> > a console I/O routine at the time that you press Ctrl+c, then I think
> > it should exit.  There's no magic in Ctrl+c, however.  It's not going
> > to terminate some long-running network I/O that your program might be
> > doing or stop file I/O because Ctrl+c occurred.  It won't terminate a
> > program that doesn't check for it.
>
> > If it were me, I'd verify that Ctrl+c is getting sent by
> > Hyperterminal (you could do a capture of the text sent to your PC on
> > another port from Hyperterminal and then read the text file with a
> > binary editor to see what ASCII code is where you pressed Ctrl+c; it
> > should be 0x03, of course).  If that all seems fine, I'd write a
> > simple console program that uses whatever I/O function you're using
> > to read the incoming key data (getch() or whatever), and see if that
> > exits.  I'd probably also try Ctrl+c, Enter, if just Ctrl+c by itself
> > didn't work.
>
> > Paul T.
>
> > hyperterminal- Hide quoted text -

>
> - Show quoted text -

"There is no Ctrl-C command..." that is what I was thinking. So I
would need some other keyboard combination or special key to trap and
then terminate my application, that is running on the CE device?

Thanks for all the input

gma...@skyproductions.com

unread,
Oct 13, 2014, 12:10:40 PM10/13/14
to
I know this is an old post but I thought I would shed some light. I needed to control a projector through 232 and couldn't use hyperterminal in my end result. spent quite a while figuring it out. Panasonic said I had to use hyperterminal and gave me the "Use CTRL-C, CTRL-B" line. After a few means of translation, I was able to send a hex value of "02" for CTRL-B and "03" for CTRL-C. You can use binary converters to see what the binary codes are. I'm not sure if this is only specific to the application I'm using it for but this may help others make some progress.
0 new messages