Action Codes and Variable Groups

This example illustrates how to customize baud rates and fax transmission features based on the fax number to which you are sending a fax.  It combines the use of action codes set from phone number look-up, and variable groups which set transmission parameters.  Setting different parameters can increase the probability of a successful transmission on the first attempt, and can speed fax negotiation by not attempting to connect at speeds which the receiving fax machine does not support.

Step 1:  Define the Variables in each Group

We are going to set groups of variables which implement three different transmission settings.  CopiaFacts allows up to eight variable groups to be used in a single application.

No restrictions: the fax will be attempted at the fastest speed.  This will be the default in this example.

Disabling either V.34 or ECM (error correction mode) depending on the board capabilities.  This will also disable higher speeds.

Setting a max baud rate of 9,600.

To implement this, the following lines should be added to the USR or UJP controlling the call.  In a Job Administration environment these can be added to the System, Owner or Jobtype UJP depending on how many jobs you want them to affect.

; define the default variables: these are not 'grouped' variables:

$var_def MAX_BAUD 33600       ; no limit

$var_def MIN_BAUD 7200        ; no slower then 7200

$var_def BM_DISABLE_V34 ""    ; affects Brooktrout TR1034 only

$var_def DIVA_DISABLE_ECM ""  ; affects Diva only

; define the first group overrides (delay G1/ to use, or action 201):

$var_def 1/MAX_BAUD 14400     ; if unable to limit V.34 or ECM

$var_def 1/MIN_BAUD 7200      ; no slower then 7200

$var_def 1/BM_DISABLE_V34 1   ; affects Brooktrout TR1034 only

$var_def 1/DIVA_DISABLE_ECM 1 ; affects Diva only

; define the second group overrides (delay G2/ to use, or action 202):

$var_def 2/MAX_BAUD 9600      ; if unable to limit V.34 or ECM

$var_def 2/BM_DISABLE_V34 1   ; affects Brooktrout TR1034 only

$var_def 2/DIVA_DISABLE_ECM 1 ; affects Diva only

; define the third group overrides (delay G3/ to use, or action 203):

$var_def 3/MAX_BAUD 7200      ; if unable to limit V.34 or ECM

$var_def 3/BM_DISABLE_V34 1   ; affects Brooktrout TR1034 only

$var_def 3/DIVA_DISABLE_ECM 1 ; affects Diva only

; specify that fax-failure retries should use first 14000, then 9600,

; then 7200 by using a G1/ G2/ G3/ prefix on the delay interval values.

$retry_delays F "G1/2 G2/2 G3/2" ; 2-min intervals, 3 retries, G1, G2, G3 vars

When setting up variable groups, we recommend that all variable names appear in each group, and in the default settings.  This ensures that when a different group is activated, all variables get the expected value.

Step 2: Define the Phone Number look-up list(s)

The basic principle is that a list or lists of numbers and associated action codes will be supplied.  The built-in action codes we will use are 201 to 215, which are pre-defined to select variable groups 1 to 15 respectively.  Currently you can specify action code lists either in a simple text file or in an NDX file maintained using PIN. SQL look-up is planned for a future release, but currently if you have the data in a SQL table you would need to dump this to a text file at intervals.

In this example, we will use a pre-defined list of phone-numbers in a text file.  There are two different ways to set this up; both methods use the FAXFACTS.CFG version of the $action_phone command:

Single List with Multiple Actions

First you can combine both lists into a single list, with the required action code following each number:

$action_phone @FFBASE\RESTRICT.TXT fax

For example a list of this type might contain:

6417416000        201


6417416913        202

where the columns are by default separated by a single tab character.  This allows phone numbers to be entered with embedded space and/or punctuation (which will be stripped).  If it is more convenient to use any white space as a delimiter, add the WSDelim keyword on the command:

$action_phone @FFBASE\RESTRICT.TXT fax WSDelim

Multiple Lists, One for Each Action

Secondly, you can specify separate lists of phone numbers to activate each group:

$action_phone @FFBASE\NOECMLIST.TXT 201 fax ; activate G1 vars if in this list

$action_phone @FFBASE\9600LIST.TXT 202 fax  ; activate G2 vars if in this list

In each case, the list will consist of just a telephone number on each line.  When a number is matched in the NOECMLIST.TXT, action code 201 will be assigned: action code 201 will activate variable group 1 for the call.  If an attempt fails with outcome class F, the definition above will cause variable group 2 to be used for the retries, overriding any variable group selected from the look-up. If a number appears in both lists, only the first action code will be used to activate a variable group.

Partial Matches

In both cases you can also specify a partial keyword on the $action_phone command: this will enable partial matching in the list.  For example if your list (in the USA) contains an entry 011 then any international number starting with this prefix will be allocated the action code.

$action_phone @FFBASE\RESTRICT.TXT fax Partial WSDelim

The fax keyword in the above examples restricts the action to FS files used for fax.  It may be omitted if you do not do voice or SMS broadcasting.

Step 3: Create and Maintain the Phone Number look-up list

Typically you would create an initial list from any existing data you have for 'problem' destination numbers.  Job Administration users can also use the JOBXFAIL utility to extract data on specific failure types from processed jobs.

Copia also plans to create a sample set of post-process infoboxes which will extract data from successful and failed calls.  This will enable the creation of an automatic feedback loop which should gradually improved both delivery success rates and system throughput.  This will be the subject of a separate Examples subtopic.