Home
Developer Resources
QNX RTOS v4
QNX RTOS v4 Knowledge Base

QNX RTOS v4 Knowledge Base

Foundry27
Foundry27
QNX RTOS v4 project
Resources

QNX RTOS v4 Knowledge Base

Title Setting up terminal in QANSI mode once it has been started
Ref. No. QNX.000009927
Category(ies) Utilities
Issue We use the QNX terminal settings in general, but we want to have the terminal set up in QANSI mode.

Is there a way from a program to tell Pterm to switch over, rather then having to call up the configuration dialog?








Solution Here is a solution:

function vi2 {
x09echo '^[?1+qc'
x09export TERM=qansi
x09stty load
x09/home/name/bin/vi2 $*
x09echo '^[[?0+qc'
x09export TERM=qnx
x09stty load
}

There are also escape sequences that can be used instead of stty protocol, they work with boath pterm and Dev.ansi:

CSI ? 0 + q (or ESC [ ? 0 + q) --> switch form ANSI to QNX

ESC ? 1 + q --> switch form QNX to ANSI