Prosody installation guide: test programs: polltest

This is a data communications tester. It can generate and check test patterns using protocols which run over digital connections (i.e. no modems).

Go to directory $(TiNG)/test.

You must have downloaded firmware modules as listed below.

Run polltest with the appropriate options (the program is gen-LINUX_V6/polltest or gen-WINNT_V6/polltest depending on which operating system you are using).

Command line options are:

Option formatMeaning
-P <protocol> The communications protocol to use. One of these values:
  • v110
  • hdlc
  • rlp
  • raw
The known formats can be listed by specifying a question mark (?).
-c 1 check for errors and report error rate if non-zero
-c 2 as for "-c 1" but more verbose
-f <file> record incoming data into rxfile-0-0, rxfile-0-1 etc
-m <module> The Prosody module to use. This is the number of the module on the card.
-n <nchan> record this many channels (default = 1)
-i <timeslot> timeslot to use for input (see Test program timeslots). If you specify more than one channel, they use consecutive timeslots starting at this one. For example, the options "-n 3 -i64:20" use input timeslots 64:20, 64:21, and 64:22.
-o <timeslot> timeslot to use for output (see Test program timeslots). If you specify more than one channel, they use consecutive timeslots starting at this one. For example, the options "-n 3 -o64:3" use output timeslots 64:3, 64:4, and 64:5.
-X <limit> stop when this much data has been received (default=never). This is specified as the number of seconds of full speed communications that it would take to send the data (this is so that the same value can be used with different speeds).
-x <cardspec> Use a Prosody processor module on this card, specified as described in Test programs: Specifying Prosody Processor modules

For example, do a loopback test with a Prosody X card for 30-seconds worth of data:

	polltest -x x:1.2.3.4/mykey -Phdlc -c 1 -i 20:0 -o 20:0 -X 30

The firmware modules that are required depend on the options you specify. Here are the details:

ModuleWhen needed
datafeed always on Prosody X
datarx always
datatx
hdlcrx If you use '-P hdlc' for HDLC
hdlctx
v110rlpr If you use '-P rlp' for V.110 RLP
v110rlpt
syncrx If you use '-P raw' for raw data
synctx
v110 If you use '-P v110' for V.110

The following keys control it:

KeyFunction
q halts the program and prints total bytes sent/received etc
- halts one channel
u makes transmitters underrun
U makes transmitters resume after underrun
f makes transmitters send frames of 0xFF
0 makes transmitters send frames of 0x00

While the program is running, it updates a status line every second with two characters for every channel. The meaning of these characters is:

CharacterMeaning
. channel idle
T channel transmitted data in last second
U channel will under-run by command
u channel is under-running
R channel received correct data in last second
r channel received error data in last second
c channel received frame with bad CRC in last second
s channel is receiving no signal (i.e. no flags)
x channel has been closed and is stopping
_ channel is stopped

The source code for this program is provided (polltest.c).


This is one of the Prosody test programs .