using telnet with QNX 4.25

I’m working on a project with a preexisting QNX 4.25 program interacts with certain hardware. I’m tasked with creating a Windows interface that allows a user with no knowledge of QNX to be able use this hardware. I’ve created a GUI that can connect to log the user into another computer through telnet. Now I’ve begun manually testing running QNX through telnet, and while I can successfully run the QNX program through telnet, it seems that after the program has begun running, I can no longer pass commands.

Would anyone happen to know if this is a limitation in the telnet protocol, or if there is some qnx or telnet setting I could change, and if not, would I be able to do what I need with SSH?

Telnet should behave not differently then a console, aside terminal issue. For example telnet on Windows only supports 7 bit, hence control character may not work, thing like F1 will send a different sequence then if entered directly on the console. Your QNX program might not handle that properly. Just a guess.

Thanks for the reply! I’m gonna keep at it.

Am I reading you correctly? You are using the telnet protocol from Windows to log into QNX? Once logged in you start a program. Then you can no longer run any other programs. Has the program that was started first finished?

Oh, no, my problem is passing user input to the program. For example, when the user presses 1, the program is supposed to do a certain thing, and when the user presses 9, the program is supposed to end.

The program accepts these key inputs when the program is run directly from QNX, but not when run through telnet. There is no response to keystrokes after the program is started.

If this is any help, here are the parts of the program that deal with those keystrokes:

[code] while (loop) {
if ((keystroke = wgetch(win)) != ERR) {

		if (keystroke == '9') {				
			loop = FALSE;


and here is the processkeystroke function:

void processKeystroke(char keystroke)
	switch(keystroke) {		

		case '0': // startup
                case '9':
               /* code to tell hardware to stop running */

This tells me what the program does, which looks fine. What are you doing in the telnet simulator? I recall that part could be a bit tricky. Do you login the way a telnet user would normally do this? Does the login start a shell or run the program directly?

The login starts the shell, and everything up until starting the program works just the same as it does when working in the QNX shell directly