I am a new QNX user and have a list of questions that has been building
up, to which I have not easily been able to fnid answers. Any hints would
be appreciated.
I have inherited a system based on QNX version 4, but it is poorly
documented and I have no information on the kind of development system
that was used, except that it appears to have been running on QNX version
4.25, and the programs, which are written in C and C++ seem to have been
built with the Watcom compiler and toolset.
The target is an embedded pentium board running QNX version 4.25 and using
TCP/IP networking.
I have obtained the QNX RTP CD-ROM and installed it on a PC. This appears
to come with the GNU toolchain. The question is, will it be easy to
migrate the code from Watcom (i.e. does Watcom have any nonstandard
extensions that might have been used, or are there library differences
that could affect anything)? And when built on the QNX RTP system, will
the resulting binaries work on QNX 4.25 (and what about networking)?
I notice that the QNX RTP system seems to be linking with shared libraries
whereas it looks like the old code was statically linked. I assume copying
the shared libraries to the target would be enough to get it going, or
otherwise I could configure the GNU linker to do static linking.
If QNX RTP is not suitable for developing QNX 4 systems, then what system
should I use and how can I get it or set it up? I understand that my
company has licenses for QNX 4, but they are sadly disorganised and nobody
seems to know what the situation is. I notice that I can retrieve updated
versions of QNX 4 and the Watcom tools from the QNX WWW site; are these
likely to work with the existing licenses that we have, or are different
versions licenses separately?
Other questions on QNX RTP:
It installed ok, but did not automatically configure support for the
network adapter in the machine. nettrap showed “io-net -drtl” and after
some experimentation I found that executing “io-net -pttcpip -drtl” would
give me the en0 interface, but trying to configure it with ifconfig
results in errors, for example:
ifconfig en0 192.168.2.93 up
ifconfig: SIOCGIFMETRIC en0: Operation not supported
ifconfig: SIOCDIFADDR: Operation not supported
ifconfig: SIOCAIFADDR: Operation not supported
However if I instead run the Network Cfg tool in the Photon GUI and enter
the IP address then select “Apply”, it then works and “ifconfig en0” will
show the correct address. Trying to set the address with ifconfig still
fails, though.
I found a file buried deep in /etc somewhere which was executing io-net
and so I changed this to have the correct arguments, and that works. The
big problem is that I have to run the Network Cfg tool in the GUI each
time I boot the machine in order to set the IP address and enable the
interface.
The other problem is that the mouse (a microsoft serial type), while
working fine mostly, fails strangely when doing things such as dragging or
scrolling a window, or in fact any time when the screen is being redrawn
for any reason. Moving the mouse at such a time makes it skip around the
screen and the buttons get activated at random even though they are not
pressed. I am guessing that when the CPU is busy drawing the screen,
buffer overruns are occuring on the serial port from the mouse. Rebootnig
the system sometimes causes this problem to improve or get worse. I think
the display is using the “VESA” driver which appears to be supporting a
dumb framebuffer with completely software drawing. Perhaps this worsens
the problem.
Well there you have it - the questions of a QNX newbie. Any advice would
be much appreciated, especially as regards the network problem.
–
Mario Becroft <mb@gem.win.co.nz>