


PGEN(1)                  PGEN Manual Page                 PGEN(1)


NNAAMMEE
       ppggeenn,,  pphhoonnee,,  ppggeett,,  aapp,, aappttss,, ssttaauutt - generate, receive,
       echo, and log 802.11 QoS and voip frames

SSYYNNOOPPSSIISS
       ppggeenn [-period] [-wmeload] [-broadcastflag] ipaddr

       pphhoonnee [-period] ipaddr

       ppggeett [-hist]

       aapp

       aappttss [testname]

       ssttaauutt ipaddr


DDEESSCCRRIIPPTTIIOONN
       PPggeenn and companion  programs  may  be  used  to  send  and
       receive  UDP  frames.  They is useful for testing Diffserv
       queues that use dscp or vlan classification.  It  is  also
       useful for generating traffic profiles of various kinds.

       The  programs  are compiled from the same source file, but
       linked with different names.  It is a single  source  file
       for  ease of development.  The code is simple and meant to
       be easily modified for test generation and traffic  analy
       sis.

       The  programs  send  and receive UDP packets on port 12345
       which is a compilation constant.  The programs  that  send
       packets  (  ppggeenn,,  pphhoonnee  ) must be given a destination IP
       address.  The address can be given  on  the  command  line
       either as a host name (e.g. "pgen test_machine_1") or with
       dot notation (e.g. "phone 192.168.171.22").

       The ppggeett,, aapp,, aanndd aappsstt programs do not require an address.
       PPggeett simply logs all packets received on its port.  The aapp
       program echoes each received packet back  to  the  sender.
       AAppttss is described below.

       The  default behavior for PPggeenn is to send a packet every 2
       seconds to the destination.  The "-period <value>"  option
       can  be  given  on  the  command line to change the packet
       interval to <value> microseconds.  For example,
            "pgen -period 5000"
            "pgen -period 500000"
       will send a packet every 5 ms, or 1/sec respectively.

       The default diffserv priority sent by  pgen  is  zero  (no
       priority).   If pgen is used with the -wmeload option, the
       program will cycle through the list of dscp types compiled
       into  the  program.   This version of the program does not



Version alpha              7 June 2005                          1





PGEN(1)                  PGEN Manual Page                 PGEN(1)


       contain a mechanism for modifying the list without editing
       and compiling the source.

       The  "-broadcastflag" option causes pgen to send broadcast
       packets rather than  the  normal  unicast  packets.    The
       broadcast address is compiled into the program.

       The pphhoonnee program sends a 128-byte UDP frame to the desti
       nation every <period> seconds.    The  default  value  for
       <period>  is 10ms, but this can be changed via the -period
       option on the command line.  After each packet is sent the
       program  waits  for  a  response.   The read will time out
       after 1 sec.  In this version of the program, the  timeout
       value  can  be  changed  by editing the source code.   The
       program attempts to time the interval  between  sending  a
       frame  and  receiving a response.   The message number and
       response time  are  printed  after  every  exchange.   The
       expected output looks like this:


                 % phone borg
                 phone mode
                 dst: 10.10.10.169
                 r128 msg(0) delta    0:91
                 r128 msg(1) delta    0:9
                 r128 msg(2) delta    0:9
                 r128 msg(3) delta    0:8
                 r128 msg(4) delta    0:18
                 r128 msg(5) delta    0:9
                 r128 msg(6) delta    0:8
                 r128 msg(7) delta    0:13
                 r128 msg(8) delta    0:8
                 r128 msg(9) delta    0:8
                 r128 msg(10) delta   0:19
                 r128 msg(11) delta   0:10
                 r128 msg(12) delta   0:9
                 r128 msg(13) delta   0:8
                 r128 msg(14) delta   0:8

       The  received  message size is noted by the "r128" and the
       message numbers is also  indicated.   The  time  delta  is
       printed  to  the right.  The notation is seconds:microsec
       onds.   Sometimes it is useful to operate the  phone  pro
       gram  at  a  slower  than  normal  rate,  e.g.       phone
       -period 500000 192.168.171.99  in  order  to  examine  the
       packets in transit through intermediate equipment.

       This  version  of the program does not include a timestamp
       in the message.

       If the phone program is run with the -hist option, then it
       remains  silent  as  messages  are  received.  Instead the
       interval time for each message is logged  in  a  histogram
       data  structure.    The  contents  of  the  structure  are



Version alpha              7 June 2005                          2





PGEN(1)                  PGEN Manual Page                 PGEN(1)


       printed after every 1000 iterations of the packet exchange
       loop.  Expected output looks like this:

         [greg@xtp]$ phone -hist borg
         phone mode
         dst: 10.10.10.169
         avg 63.765999   min(0.000000)   max(8181.000000)
          10     20     30     40     50    100    500   1000   2000   5000      0
           513   384    76     0     0     0    13     4     1     5     4

       The histogram buckets start at 10us and range to 5ms.   In
       this example about half of the 1000 packets were echoed in
       10us, and 384 were echoed in the 10-20us range.


       The  ppggeett  program listens on the port and prints whatever
       it receives.

       The aappttss and ssttaauutt programs are derived from aapp  and  uuppssdd
       respectively.  AAppssdd with no arguments will print a list of
       available tests meant to coincide with wifi APSD test pro
       cedures,  e.g.  "B.2".   Operate the program by giving the
       name of a test as the (single) argument, e.g. "apts  B.2".
       The  ssttaauutt  program complements aappttss by providing the Sta
       tion Under Test functionality.  Operate the  station  pro
       gram by giving it the ip address of the aappttss program, e.g.
       "staut 192.168.1.10".  The program will send  a  frame  to
       the  apts  program  which  will  respond with a frame that
       selects the test behavior  at  the  station.   Unlike  the
       other  programs  uuppssdd  or  pphhoonnee,, statistics gathering and
       timing information is meant to be collected by  a  passive
       sniffer application.



DDIIAAGGNNOOSSTTIICCSS
       Missing arguments and some errors are diagnosed.

NNOOTTEESS
       It is not possible to operate pgen and pget simultaneously
       on the same system because they bind to the same port.

       This is an engineering  test  program,  not  a  "product".
       Don't expect too much.

BBUUGGSS
       There   are  several  optional  behaviors  and  flags  not
       described on this man page.  If you have  this  man  page,
       you also have the source code (hint).

       The  delta  time  reporting  needs  to  be  calibrated and
       amended with a method uses  round-trip  timestamps.   This
       version  of  the  program  doesn't generate or record vlan
       tags.



Version alpha              7 June 2005                          3





PGEN(1)                  PGEN Manual Page                 PGEN(1)


       The program should figure out  the  broadcast  IP  address
       instead  of using a compiled-in value although this is not
       an important feature of the program and probably could  be
       removed.

       The  raw  socket  interface  may  not exist or may require
       additional code on some platforms.


















































Version alpha              7 June 2005                          4


