OpenQNX :: The QNX Community Portal

May 18, 2008 - 01:36 AM
Google
  Web openqnx.com   
     Create an account Home · Submit News · QNX Forums · QNX Download · Search   
_
Main Menu
Who's Online
There are 41 unlogged users and 3 registered users online.

You can log-in or register for a user account here.

Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
epomatti
Post subject: Error running program - Strange chars on terminal  PostPosted: Nov 27, 2007 - 04:10 PM
Active Member


Joined: Nov 09, 2007
Posts: 12

Hi,

We have a program that run in QNX 4.21, developed in Watcom 9.51 ambient.

When it's runned on QNX 6.2.1, in command line, by "./" function, appear a lot of strange chars on terminal. Anything that I type after the error from script appear in strange format chars.

This software make directly communication between processes and serial communication.

We use QNX 4 because it's support this access in serial communication.

QNX 6.2.1 still have this property??
Someone have an idea about this error??

thanks
 
 View user's profile Send private message  
Reply with quote Back to top
mario
Post subject: RE: Error running program - Strange chars on terminal  PostPosted: Nov 27, 2007 - 04:46 PM
QNX Master


Joined: Sep 01, 2002
Posts: 2675

Sure QNX6 has support for serial device. What do you meain by "./" function.

Depending on what you program does on QNX4, it's possible that it was outputing on the screen some sort of control characters ( for bold, italic, etc ) and that these control characters have a different meaning on QNX6 which results in the console driver to go nuts.
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
epomatti
Post subject: RE: Error running program - Strange chars on terminal  PostPosted: Nov 27, 2007 - 05:03 PM
Active Member


Joined: Nov 09, 2007
Posts: 12

The program is a script at the end... to start the service I must type "./Front.end.encaix"

But about the serial device, the access that I am trying to say is a real-time access on serial communicatioin, that older versions of QNX accept, and other segments of Unix (Linux, e.p.) don't give this access. Just QNX do it.

It's used in communication with a external hardware that is used here.

Is there a way to run QNX 6 just in console mode?
 
 View user's profile Send private message  
Reply with quote Back to top
mario
Post subject: RE: Error running program - Strange chars on terminal  PostPosted: Nov 27, 2007 - 06:53 PM
QNX Master


Joined: Sep 01, 2002
Posts: 2675

I'm sorry I don't understand what you are trying to say.

If you want to run in console, just shutdown photon or create the file /etc/system/config/nophoton.
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
micro
Post subject: RE: Error running program - Strange chars on terminal  PostPosted: Nov 28, 2007 - 10:25 AM
Senior Member


Joined: Jul 22, 2004
Posts: 317

I think you are trying to put your Console in "ANSI" mode, which was done via TERM-env and stty i think, this is not working under QNX6, at least not on our workstation.
Therefore i guess you also change the codepage orkeysets, this will result in a scrambled console (also happens sometimes if you cat a binary-file wich has control-chars for the console in it). Generally you can still access the seriel device pretty easy, but your formatted output via ansi has to be replaced with QNX6-implementations.

For not running photon mario already suggestet just shutdown to console or "touch /etc/system/config/nophoton"
 
 View user's profile Send private message  
Reply with quote Back to top
Thunderblade
Post subject: RE: Error running program - Strange chars on terminal  PostPosted: Nov 28, 2007 - 11:41 AM
Senior Member


Joined: Apr 07, 2005
Posts: 257

Have you tried it on the current QNX version, 6.3.2? 6.2.1 is a little old.

If your program isn't a program but a script, maybe you can post it here?
 
 View user's profile Send private message  
Reply with quote Back to top
epomatti
Post subject: RE: Error running program - Strange chars on terminal  PostPosted: Nov 28, 2007 - 07:25 PM
Active Member


Joined: Nov 09, 2007
Posts: 12

I have tryed run the script just in Terminal mode, but did the same error, how expected =P

QNX 6.3.2 needs a key to install right?
I must buy it?

But how Thunderblade told, I try to post the code here, so I have the following message in the console:

I did type...
#vi Front.end.encaix

.. the message...
"This file contain NULs. They've been changed to \x80 chars"

And the file appears full of strange chars.
Just some 10 lines of text can be read.
 
 View user's profile Send private message  
Reply with quote Back to top
mario
Post subject: RE: Error running program - Strange chars on terminal  PostPosted: Nov 28, 2007 - 09:04 PM
QNX Master


Joined: Sep 01, 2002
Posts: 2675

6.3.2 need a key, but if you are using this for non-commercial use you don't have to pay. Just register on www.qnx.com to obtain a key.

It seems Front.end.encaix is NOT a script but rather an EXECUTABLE.

To post a file, click on the "Quote" or "Post Reply" button (instead of using the Quick Reply feature) which should then give you the option of attaching a file.

But I think that instead of attaching the program, you should attach its output:

./Front.end.encaix >file.txt

Then post the file ( as an attachment ) file.txt
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
epomatti
Post subject:   PostPosted: Nov 29, 2007 - 11:32 AM
Active Member


Joined: Nov 09, 2007
Posts: 12

sure, I got the key and I`ll try install it today.

I`ll try to attach a .tar file, that contains more 4 files.
I did try to open in .txt format, but I`ve got an error of encoding.

Follows the tar file. I hope that it works fine.



files.tar
 Description:

Download
 Filename:  files.tar
 Filesize:  7.97 KB
 Downloaded:  35 Time(s)

 
 View user's profile Send private message  
Reply with quote Back to top
noc
Post subject:   PostPosted: Nov 29, 2007 - 06:33 PM
Senior Member


Joined: Jul 06, 2002
Posts: 1629

epomatti,

You can't run QNX 4 programs (compiled by Watcom) on QNX 6.
If you have the source code, you will have to "port" it to QNX 6 and recompile with GCC compiler.
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
epomatti
Post subject:   PostPosted: Dec 03, 2007 - 12:12 PM
Active Member


Joined: Nov 09, 2007
Posts: 12

Ok

I'll contact our software developers and we'll find a way to solve this problem.

I'll post a reply about our progress.

Really thanks for Mario, Micro, Thunderblade and Noc
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2007 The PNphpBB Group
Credits
All logos and trademarks in this site are property of their respective owners. The comments are property of their posters.
Powered by OpenQNX: The QNX Community Portal Site
QNX and the QNX logo are registered trademarks of QNX Software Systems.