[RTTY] KAM not recognized by WriteLog
Kok Chen
chen at mac.com
Fri Mar 7 09:27:09 EST 2003
K4SB wrote:
> The basic difference between COMMAND mode and HOST is that in COMMAND,
> the TNC does all the necessary decoding and of course, then sends it
> to a dumb terminal. In HOST mode,
The HOST interface actually incorporates both the Command mode and
the Interactive mode of the KAM. The inability to enter the HOST
interface is
really the inability to switch from the TERMINAL interface, not the
inability to
switch from the Command mode, since the Command mode is part of the
HOST mode too.
First let me explain the difference between the Command mode and
the interactive mode while in the TERMINAL interface mode.
The Command mode of the KAM is the mode where you see the cmd:
prompt and it includes commands to set baud rates, date and time,
callsigns,
etc, and finally, to switch the KAM into one of the operating modes,
such as
RTTY or AMTOR, and dozens of other commands.
Once you send a command to switch the KAM into one of the operating
modes,
you have entered the Interactive mode. In this mode, all characters,
except for
certain escape sequences, are sent as data to the modulator and as
decoded
Baudot (or Morse or Amtor) streams from the demodulator. The escape
sequences in the Interactive mode are prefixed by the control-C
character
and includes directives that changes from receive to transmit mode and
for leaving the Interactive mode for the Command mode.
Now, let me explain the difference between the HOST and the TERMINAL
interfaces (there are other interface modes too, like NEWUSER, etc).
The problem with the TERMINAL interface scheme I have described above
is that
there is no way for a program to easily distinguish between data and
commands.
So, Kantronics introduced an interface called Host Mode. What the Host
Mode
really is just the encapsulation of dataflow (whether commands or data)
into
packetized form. Everything sent between the computer and the KAM are
preceeded by a 0xc0 character and terminated by the 0xc0 character.
Included
in each packet are two bytes, one is called the Stream ID and the other
is the
Port ID.
The Port ID identifies the part of the KAM you are talking to. In the
KAM Plus, for
example there is the VHF portion and HF portion. The VHF has port 1
and HF
is port 2.
A KAM'98 only has HF functionality and it uses only Port 1.
Now, it is the Stream ID that is the interesting byte. This is the ID
which controls
whether the packet contains data or command. By looking at this byte,
your
program would know if the packet contents are administrative characters
or
data from the demodulator. Similarly, the KAM knows whether you are
sending
a command or whether you are sending characters (data) to the FSK
modulator.
The actual contents of the packet are nothing but what you would have
sent
in the TERMINAL mode (i.e., Command or Interactive characters).
OK, after all that... the way you enter the Host Mode is to send
"INTERFACE HOST"
to the cmd: prompt. (Or short form to INT HOST.)
The way to exit the Host Mode is to send a special packet (remember, in
Host mode,
the KAM only recognizes packets) that is 0xc0 followed by the character
Q, followed
by another 0xc0. (There are various ways for you to send the 0xc0
character from a
terminal program, I won't get into that. The way to do it on Wintel
keyboards is
described in the KAM manual. )
This is why sometimes when you use a terminal emulator with the KAM,
all you see
are some weird characters, instead of readable English. The KAM is
stuck in Host
Mode!
If you cannot enter or exit HOST mode, I would suggest using a Terminal
Emulator
and to make sure the unit is placed in Terminal interface mode. I.e.,
if you see weird
characters, it is either the wrong baud rate, or it is stuck in Host
Mode.
If you can't find a Terminal emulator, the only other reliable way is
to apply a hardware
reset to the KAM. Depending on the model of the KAM, it might involve
removing the
cover and shorting out two pins. This will place the KAM into NEWUSER
mode and
most programs can take it from there. If your program can't handle
NEWUSER mode,
you will still need a terminal emulator to send the command INTERFACE
TERMINAL.
Having to roll my own contest software makes me have to dig into the
details (the
hard way).
73
Chen, W7AY
More information about the RTTY
mailing list