;
;  Copyright (C) 2000-2001  Henk de Groot - PE1DNN
;
;  This program is free software; you can redistribute it and/or modify
;  it under the terms of the GNU General Public License as published by
;  the Free Software Foundation; either version 2 of the License, or
;  (at your option) any later version.
;
;  This program is distributed in the hope that it will be useful,
;  but WITHOUT ANY WARRANTY; without even the implied warranty of
;  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;  GNU General Public License for more details.
;
;  You should have received a copy of the GNU General Public License
;  along with this program; if not, write to the Free Software
;  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
;  Please note that the GPL allows you to use the driver, NOT the radio.
;  In order to use the radio, you need a license from the communications
;  authority of your country.
;
;------------------------------------------------------------------------------
;
;  DIGI_NED Digi for use in high volume traffic areas. Changes from the
;  default are explained. For full explanation of the rules see the files
;  that came with DIGI_NED in the distribution! This is a drop-in
;  replacement for the default digi_ned.ini file. Of course you still have
;  to put your call in the digi_call: rule!

;
version: 2
;
;------------------------------------------------------------------------------
;
;  Start of the rules, start with the beacons. 30 minute intervals are more
;  than enough, changed 20 to 30. Reduced the path, digis are not that
;  interesting far away. You can always load a POS file to see them! Changed
;  WIDE3-3 to WIDE2-2
;
send: 30 all DIGI_DEST,WIDE,WIDE2-2
digibcon.ini
;
;  Send our station identification every 5 minutes. Note that this may be
;  required to fulfill your license requirements. In this case I did not
;  add any digipeaters since this is only a local identification.
;
send: 5 all ID
digi_id.ini
;
;------------------------------------------------------------------------------
;
;  Serial line handling
;
;  Set for weather station, once every 30 minute seems enough for me.
;  For a tracker use decrease the value to 2 or so. Only 1 string is send.
; 
;serial: 30 all com3 4800 GPSODN,WIDE,WIDE3-3
;$GPRMC
;
;------------------------------------------------------------------------------
;
;  Telemetry transmission. Telemetry data to send is read from a LPT port.
;
;  Decreased rate to once per 30 minutes.
;
;telemetry: 30 all lpt2/1,off,off,off,off,lpt2_8 DIGI_DEST
;
;send: 30 all DIGI_DEST
;digi_tlm.ini
;
;tele_info: digi_tlm.ini
;
;------------------------------------------------------------------------------
;
;  Commands to execute directly after the .ini file is processed.
;
;command: !out 2 10101011
;
;------------------------------------------------------------------------------
;
;  Digipeat frames with these digipeater calls.
;
digipeat: all DIGI_CALL all
digipeat: all relay,trace,wide all
digipeat: 1 local 1
digipeat: 2 local 2
digipeat: all worm allbut
;
;------------------------------------------------------------------------------
;
;  Inteligent digipeating rules for reduced traffic
;
;  Handling of WIDEn-N
;  -------------------
;
;  To reduce traffic WIDE7-n and WIDE6-n calls are reduced to only hop 5
;  times by changing them to WIDE5-n calls. This is gently, we could have
;  thrown these packets away!
;
;  We use the "replace" operation instead of "swap" so bypasses like adding
;  new digipeaters after the WIDEn-N call will not work (they are wiped out).
;
;------------------------------------------------------------------------------
;
;  7 Hops
;
;  WIDE7-7 should become WIDE7-6, now becomes WIDE5-4 (1 hop done 4 to go)
;
digipeat: all wide7-7 all replace0 wide5-4
;
;------------------------------------------------------------------------------
;
;  6 Hops
;
;  WIDE7-6 should become WIDE7-5, now becomes WIDE5-3 (2 hops done 3 to go)
;  WIDE6-6 should become WIDE6-5, now becomes WIDE5-4 (1 hop done 4 to go)
;
digipeat: all wide7-6 all replace0 wide5-3
digipeat: all wide6-6 all replace0 wide5-4
;
;------------------------------------------------------------------------------
;
;  5 Hops
;
;  WIDE7-5 should become WIDE7-4, now becomes WIDE5-2 (3 hops done 2 to go)
;  WIDE6-5 should become WIDE6-4, now becomes WIDE5-3 (2 hops done 3 to go)
;
digipeat: all wide7-5 all replace0 wide5-2
digipeat: all wide6-5 all replace0 wide5-3
digipeat: all wide5-5 all replace0 wide5-4
;
;------------------------------------------------------------------------------
;
;  4 Hops
;
;  WIDE7-4 should become WIDE7-3, now becomes WIDE5-1 (4 hops done 1 to go)
;  WIDE6-4 should become WIDE6-3, now becomes WIDE5-2 (3 hops done 2 to go)
;
digipeat: all wide7-4 all replace0 wide5-1
digipeat: all wide6-4 all replace0 wide5-2
digipeat: all wide5-4 all replace0 wide5-3
digipeat: all wide4-4 all replace0 wide4-3
;
;------------------------------------------------------------------------------
;
;  3 Hops
;
;  WIDE7-3 should become WIDE7-2, now becomes WIDE5*  (5 hops done, finished)
;  WIDE6-3 should become WIDE6-2, now becomes WIDE5-1 (4 hops done 1 to go)
;
digipeat: all wide7-3 all replace wide5
digipeat: all wide6-3 all replace0 wide5-1
digipeat: all wide5-3 all replace0 wide5-2
digipeat: all wide4-3 all replace0 wide4-2
digipeat: all wide3-3 all replace0 wide3-2
;
;------------------------------------------------------------------------------
;
;  2 Hops
;
;  WIDE7-2 should become WIDE7-1, now ignored         (5 hops already done)
;  WIDE6-2 should become WIDE6-1, now becomes WIDE5*  (5 hops done, finished)
;
;digipeat: all wide7-2 all replace wide5
digipeat: all wide6-2 all replace wide5
digipeat: all wide5-2 all replace0 wide5-1
digipeat: all wide4-2 all replace0 wide4-1
digipeat: all wide3-2 all replace0 wide3-1
digipeat: all wide2-2 all replace0 wide2-1
;
;------------------------------------------------------------------------------
;
;  1 Hop
;
;  WIDE7-1 should become WIDE7*, now ignored         (5 hops already done)
;  WIDE6-1 should become WIDE6*, now ignored         (5 hops already done)
;
;digipeat: all wide7-1 all replace wide5
;digipeat: all wide6-1 all replace wide5
digipeat: all wide5-1 all replace wide5
digipeat: all wide4-1 all replace wide4
digipeat: all wide3-1 all replace wide3
digipeat: all wide2-1 all replace wide2
digipeat: all wide1-1 all replace wide1
;
;------------------------------------------------------------------------------
;
;  0 Hops, and strange WIDE formats are not repeated anymore (deleted)!
;
;------------------------------------------------------------------------------
;
;  Handling of TRACEn-N
;  ---------------------
;
;  We convert all TRACEn-N calls to WIDEn-N to keep the packets short.
;
;  To reduce traffic TRACE7-n and TRACE6-n calls are reduced to only hop 5
;  times by changing them to WIDE5-n calls. This is gently, we could have
;  thrown these packets away! For comment see WIDEn-N.
;
;------------------------------------------------------------------------------
;
;  7 Hops
;
digipeat: all trace7-7 all replace0 wide5-4
;
;------------------------------------------------------------------------------
;
;  6 Hops
;
digipeat: all trace7-6 all replace0 wide5-3
digipeat: all trace6-6 all replace0 wide5-4
;
;------------------------------------------------------------------------------
;
;  5 Hops
;
digipeat: all trace7-5 all replace0 wide5-2
digipeat: all trace6-5 all replace0 wide5-3
digipeat: all trace5-5 all replace0 wide5-4
;
;------------------------------------------------------------------------------
;
;  4 Hops
;
digipeat: all trace7-4 all replace0 wide5-1
digipeat: all trace6-4 all replace0 wide5-2
digipeat: all trace5-4 all replace0 wide5-3
digipeat: all trace4-4 all replace0 wide4-3
;
;------------------------------------------------------------------------------
;
;  3 Hops
;
digipeat: all trace7-3 all replace wide5
digipeat: all trace6-3 all replace0 wide5-1
digipeat: all trace5-3 all replace0 wide5-2
digipeat: all trace4-3 all replace0 wide4-2
digipeat: all trace3-3 all replace0 wide3-2
;
;------------------------------------------------------------------------------
;
;  2 Hops
;
;digipeat: all trace7-2 all replace wide5
digipeat: all trace6-2 all replace wide5
digipeat: all trace5-2 all replace0 wide5-1
digipeat: all trace4-2 all replace0 wide4-1
digipeat: all trace3-2 all replace0 wide3-1
digipeat: all trace2-2 all replace0 wide2-1
;
;------------------------------------------------------------------------------
;
;  1 Hop
;
;digipeat: all trace7-1 all replace wide5
;digipeat: all trace6-1 all replace wide5
digipeat: all trace5-1 all replace wide5
digipeat: all trace4-1 all replace wide4
digipeat: all trace3-1 all replace wide3
digipeat: all trace2-1 all replace wide2
digipeat: all trace1-1 all replace wide1
;
;------------------------------------------------------------------------------
;
;  0 Hops, and strange TRACE formats are not repeated anymore (deleted)!
;
;------------------------------------------------------------------------------
;
;  If a packet "ended" at WIDE or TRACE its finised (deleted)!
;
;------------------------------------------------------------------------------
;
;  Handling of destination-SSID based digipeating
;  ----------------------------------------------
;
;  Reduced the maximum number of hops to 5 for SSID's 6 and 7
;
digito: all *-1 all 0 add DIGI_CALL
digito: all *-2 all 1 add0 DIGI_CALL
digito: all *-3 all 2 add0 DIGI_CALL
digito: all *-4 all 3 add0 DIGI_CALL
digito: all *-5 all 4 add0 DIGI_CALL
digito: all *-6 all 4 add0 DIGI_CALL
digito: all *-7 all 4 add0 DIGI_CALL
;
digissid: all *-1 all 0 keep
digissid: all *-2 all 1 keep0
digissid: all *-3 all 2 keep0
digissid: all *-4 all 3 keep0
digissid: all *-5 all 3 keep0
digissid: all *-6 all 3 keep0
digissid: all *-7 all 3 keep0
;
; SSID directional digipeating
; ----------------------------
;
;  Now using WIDEn-N type calls, that gives a smaller packet
;
digito: 1 *-8 all 0 add WIDE2-2
digito: 1 *-9 all 0 add WIDE2-2
digito: 1 *-10 all 0 add WIDE2-2
digito: 1 *-11 all 0 add WIDE2-2
;
digito: 1 *-12 all 0 add WIDE3-3
digito: 1 *-13 all 0 add WIDE3-3
digito: 1 *-14 all 0 add WIDE3-3
digito: 1 *-15 all 0 add WIDE3-3
;
;  ssid_ignore_prefix:
;
ssid_ignore_prefix: ~
;
;------------------------------------------------------------------------------
;
;  Packets with no existing digipeaters are not digipeated (deleted)!
;
;------------------------------------------------------------------------------
;
;  Preemptive digipeating.
;
preempt: all RELAY IGNORE
preempt: all DIGI_CALL
;
;  If the next call appears in a preempted digipeater list and is not
;  already used then retain the call by relocating the call after the
;  preempted call.
;
preempt_keep: PA*,PE*,PD*,PI*
;
;  Some calls should never be relocated, even they match with
;  "preempt_keep:". These are named in here.
;
preempt_never_keep: RELAY*,WIDE*,TRACE*
;
;------------------------------------------------------------------------------
;
;  Local ports. Left commented out, this is for a "fill-in" digi, not
;  for a WIDE!
;
;local: 2
;
;------------------------------------------------------------------------------
;
;  How many calls kept in the digipeater software
;
;  The "size_heard_list" defines how many calls are remembered
;  for the "mheard" and "dx" queries. If it is too small then
;  the DX function cannot give accurate long-term reports.
;
size_heard_list: 100
;
;  Show a lower number of calls on a MH query, only the latest 16, this are
;  4 packets.
;
size_heard_show: 16
;
;------------------------------------------------------------------------------
;
;  How many seconds old data transmissions are remembered to prevent loops.
;
;  We want fixed stations to beacon no more that once per 30 minutes. To
;  allow timing differences we set the keep_time: to 29 minutes. So packets
;  with the same content are not again digipeated when they appear again
;  within 29 minutes. This is 20 x 60 = 1740 seconds.
;
;  Effect: Static data can only appear at 29 minute intervals MAX, not more
;  unless the station is direct. Your local digi will repeat your direct
;  packet but the next one will not do so when the same packet appears within
;  29 minutes. Becaude data from mobile stations changes all the time, their
;  packets get through!
;
keep_time: 1740
;
;  Messages and data need retransmission until acked, to this is still 10
;  seconds.
;
short_keep_time: 10
data_prefix: :?
;
;------------------------------------------------------------------------------
;
message_file: digi_ned.mes
;
message_keep_time: 900
;
message_path: all WIDE
;
max_msg_hops: 2
;
;------------------------------------------------------------------------------
;
;  DX function handling.
;  ---------------------
;
digi_pos_file: digibcon.ini
;
;  Reduce the number of data, only 2 responses for all an 2 hours
;
dx_times: all,2
;
dx_metric: km
;
dx_level: all 25-2000 1
;
dx_path: all DX,WIDE
;
dx_portname: 1 2 mtr
dx_portname: 2 70 cm
;
;dx_portname: 1 VHF
;dx_portname: 2 UHF
;
;dx_portname: 1 144.800
;dx_portname: 2 431.0375
;
;------------------------------------------------------------------------------
;
;  Satellite Tracking Attributes
;  -----------------------------
;
;  (commented out, already present above)
;  Position of the digi...
;digi_pos: 3256.84N 08001.92W (KG4ECV-10)
;  ...or specify as:
;digi_pos_file: digibcon.ini
;
digi_altitude: 10
;
digi_use_local: 1
;
digi_utc_offset: +2
;
sat_in_range_interval: 1
;
;  Increased interval from 10 to 15 minutes
;
sat_out_of_range_interval: 15
;
track_duration: 105
;
satellite_file: digi_ned.sat
;
update_tle_file: digi_ned.tle
;
sat_obj_format: 2
;
;------------------------------------------------------------------------------
;
;  Calls we don't want to repeat.
;
block: N0CALL,NOCALL,MYCALL
;
;allow_to: 2 MAIL*,FBB*
;
;allow_from: 1,2 PE*,PA*,PI*
;allow_from: 2 PD*
;
;  Calls that are not allowed to query the digipeater
;
msg_block: N0CALL,NOCALL,MYCALL
;
;------------------------------------------------------------------------------
;
;  Kenwood mode
;
;  Changed to kenwood_mode: 2, throw away packets that are too long
;
kenwood_mode: 2
;
;------------------------------------------------------------------------------
;
digi_owner: PE1DNN,PE1DNN-7,PE1MEW
;
;------------------------------------------------------------------------------
;
;  Use 1 to enable, 0 to disable this feature.
;
enable_exit: 1
;
;------------------------------------------------------------------------------
;
;  Logfiles
;
;logfile: digi_ned.log
;
;tnclogfile: digi_ned.tnc
;
;------------------------------------------------------------------------------
;
;  DIGI_CALL of the digi and the destination to which the DIGI_NED digi
;  can send beacons.
;
digi_call: PE1DNN-2
;
digi_dest: APND0S
;
