PackeTwin, WA4DSY Grapes 56k modem
RedHat 6.1 Linux
HOWTO
I would like to acknowledge those who have helped me with this project. Thanks to Mr. Klaus Kedula, Mr. Dale Hetherington, Mr. Douglas Drye, Paul Williamson and Mr. Brian Kantor for taking the time to help me with this project. This paper does not discuss AX25-Utils installation, which is used to attach the ports to both LinFBB(xFBB) and Jnos/Tnos applications.
Configuring the PackeTwin card was fairly simple. At first I tried to configure Port B as the 56k and make use of the onboard connector. Even though the manual stated that 56k DMA mode would work on either port, I was not successful. After several attempts I moved the 56k serial sync chipset to Port A and set that for DMA mode. Originally I am used IRQ 2 and DMA 3 for card access on a Pentium 133, which worked, but had problems with the DMA mode on a 400MHz Pentium. Now both machines are in the interrupt mode. The DMA problem was garbled output data (even though the trace screen in Jnos looked good). To fix this I disabled the DMA mode by setting the dmascc_cfg dmascc0 -- DMA 0 in the config file (discussed late on). You can pickup the serial sync chips from a electronic supply a lot cheaper than Pacomm. I found them for about $1.00 each.
Once the PackeTwin card is in place, I ran make menuconfig on the /usr/src/linux directory to compile in the High Speed DMA SCC driver for AX.25. Dont forget to enable Serial port KISS driver as well (usually done when installing AX25-Utils). My baseline is the 2.2.13 kernel. For the most part I use monolithic kernels but have used modules at times. Rebuild the kernel with make clean, make dep and make bzImage. Copy the new kernel to /boot directory and add the new image to /etc/lilo.conf. Dont forget to run lilo after the changes before rebooting.
Ok, now when you boot the kernel should see the dmascc0 and dmascc1 interfaces. Now we need to add the dmascc_cfg configuration tool found at: http://www.nt.tuwien.ac.at/~kkudielk/Linux/
Use tar xvfz dmascc_cfg-0.7.tar.gz to uncompress the tool and run make in the resultant directory. This will produce a dmascc_cfg binary which I copied to the /usr/sbin directory. I placed the configuration script in the /etc/rc.local file at the bottom of the original script. There I made changes to the txdelay (currently set at 150) and DMA mode (currently set too 0 for interrupt mode only). You may have to do some adjustments to suite your area.
/usr/sbin/dmascc_cfg dmascc0 --speed 0 --nrzi 0 --clocks 0x08 \
--txdelay 10 --txtime 3 --sqdelay 1 --slottime 10 \
--waittime 100 --persist 32 --dma 0
Now when you boot up, your card is configured and ready too go. I make use of the kissattach command set to bring the interface to the axports file. Along with the dmascc_cfg I make use of the ifconfig to set IP address, netmask and broadcast address of each interface. I also load things like rc.ipchains, rc.xFBB, and rc.portsentry in the rc.local file. The dmascc0 and dmascc1 interfaces are shared by both LinFBB (xFBB) and Jnos/Tnos. I found it better to enter the LinFBB bbs application by connecting first to the AX25 Node (node-3.0) first and then using the bbs command (defined in the /etc/ax25/node.conf) to reach the application. If I try to connect directly the 256 paclen limitation of FBB creates fragmentation on the MTU level. I also noticed that using the telnet to either the Jnos/Tnos application went smooth as well.
/etc/rc.local
# Interface eth0 is the adsl Ethernet port
# Interface eth1 is the intranet inside Ethernet port
# Interface sl0 is an external Slattach port
# IPCHAINS firewall ruleset applies to above interfaces
# JNOS slattach link
slattach -s 38400 -p slip /dev/ptypf &
sleep 3
/sbin/ifconfig sl0 44.bbb.cccc.115 pointopoint 44.bbb.cccc.14 up
/sbin/ifconfig sl0 broadcast 44.255.255.255
/sbin/ifconfig sl0 mtu 576
/sbin/route add 44.bbb.cccc.14 sl0
#
# Port 'A'
# Set the PackeTwin configs with dmascc_cfg
/usr/sbin/dmascc_cfg dmascc0 --speed 0
/usr/sbin/dmascc_cfg dmascc0 --nrzi 0
/usr/sbin/dmascc_cfg dmascc0 --clocks 0x08
/usr/sbin/dmascc_cfg dmascc0 --txdelay 15
/usr/sbin/dmascc_cfg dmascc0 --txtime 3
/usr/sbin/dmascc_cfg dmascc0 --sqdelay 1
/usr/sbin/dmascc_cfg dmascc0 --slottime 10
/usr/sbin/dmascc_cfg dmascc0 --waittime 100
/usr/sbin/dmascc_cfg dmascc0 --persist 32
/usr/sbin/dmascc_cfg dmascc0 --dma 0
#
# PORT 'B'
# Set the PackeTwin configs with dmascc_cfg
/usr/sbin/dmascc_cfg dmascc1 --speed 9600
/usr/sbin/dmascc_cfg dmascc1 --nrzi 0
/usr/sbin/dmascc_cfg dmascc1 --clocks 0x08
/usr/sbin/dmascc_cfg dmascc1 --txdelay 10
/usr/sbin/dmascc_cfg dmascc1 --txtime 3
/usr/sbin/dmascc_cfg dmascc1 --sqdelay 1
/usr/sbin/dmascc_cfg dmascc1 --slottime 10
/usr/sbin/dmascc_cfg dmascc1 --waittime 100
/usr/sbin/dmascc_cfg dmascc1 --persist 64
/usr/sbin/dmascc_cfg dmascc1 --dma 0
#
# KC6IKE-15
# DMASCC0 First port on PackeTwin card 'A'. Portname 'dmascc0'
/sbin/ifconfig dmascc0 44.bbb.ccc.12 hw ax25 KC6IKE-14 up
/sbin/ifconfig dmascc0 netmask 255.255.255.0 mtu 1500
/sbin/ifconfig dmascc0 broadcast 44.bbb.ccc.255
#
# KC6IKE-14
# DMASCC1 Second port on PackeTwin card 'B'. Portname 'dmascc1'
/sbin/ifconfig dmascc1 44.bbb.ccc.9 hw ax25 KC6IKE-13 up
/sbin/ifconfig dmascc1 netmask 255.255.255.0 mtu 256
/sbin/ifconfig dmascc1 broadcast 44.bbb.ccc.255
#
# ATTACH DMASCC interfaces to TNOS with ptypX/ttypX pairs
/usr/sbin/net2kiss -i dmascc0 /dev/ptypa &
sleep 2
/usr/sbin/net2kiss -i dmascc1 /dev/ptypb &
sleep 2
#
# BOOT Port statements
#
# Dual TNC in kiss mode
/usr/sbin/mkiss -s 9600 /dev/ttyS1 /dev/ptyq0 /dev/ptyq1
/usr/sbin/kissattach /dev/ttyq0 145 44.bbb.cccc.13
/usr/sbin/kissattach /dev/ttyq1 439 44.bbb.ccc.12
# KC6IKE-12
/sbin/ifconfig ax0 mtu 256 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
# KC6IKE-11
/sbin/ifconfig ax1 mtu 256 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
kissparms -p 145 -t 30 -s 100 -r 63
kissparms -p 439 -t 10 -s 100 -r 63
# Attach AX0 & AX1 interfaces to Jnos for Dual Port Data Engine
net2kiss -i ax0 /dev/ptypc &
sleep 2
net2kiss -i ax1 /dev/ptypd &
sleep 2
#
# AXIP for KC6IKE-7
/usr/sbin/kissattach /dev/ptyqd axip 44.bbb.cccc.115
/sbin/ifconfig ax2 mtu 256 netmask 255.255.255.0 broadcast 44.bbb.cccc.255
#
# Attach LOOP1 & LOOP2 ports
/usr/sbin/kissnetd /dev/ptyp3 /dev/ptyp4 &
sleep 2
kissattach /dev/ttyp3 ax3 44.bbb.ccc.9
kissattach /dev/ttyp4 ax4 44.bbb.ccc.9
/sbin/ifconfig ax3 mtu 256 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
/sbin/ifconfig ax4 mtu 256 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
#
#
# NETROM
/usr/sbin/nrattach -i 44.bbb.ccc.9 -m 236 netrom
/usr/sbin/nrattach -i 44.bbb.ccc.9 -m 236 netnod
/usr/sbin/nrattach -i 44.bbb.ccc.9 -m 236 netbbs
#/usr/sbin/nrattach -i 44.bbb.ccc.9 -m 236 netdx
/sbin/ifconfig nr0 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
/sbin/ifconfig nr1 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
/sbin/ifconfig nr2 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
#/sbin/ifconfig nr3 netmask 255.255.255.0 broadcast 44.bbb.ccc.255
# NR0 First netrom port.[fake node] Portname 'netrom'
# NR1 Second netrom port.[real node] Portname 'netnod'
# NR2 Third netrom port. Portname 'netbbs'
# NR3 Forth netrom port. Portname 'netdx'
# NRPARMS
#/usr/sbin/nrparms -node AA6QN-3 + SEE 222 6 axip AA6QN-3
#
# Start Daemons for AX25-UTILS
/usr/sbin/ax25d
/usr/sbin/netromd
/usr/sbin/mheardd
/usr/sbin/ax25ipd &
/usr/sbin/rxecho
#
# BEACONS
/usr/sbin/beacon -c KC6IKE-3 -d UNIX -t 30 dmascc0 "SAW:KC6IKE-3 AX25-UTILS/LINUX RH 6.1"
/usr/sbin/beacon -c KC6IKE-3 -d UNIX -t 30 dmascc1 "SAW:KC6IKE-3 AX25-UTILS/LINUX RH 6.1"
/usr/sbin/beacon -c KC6IKE-3 -d UNIX -t 30 145 "SAW:KC6IKE-3 AX25-UTILS/LINUX RH 6.1"
/usr/sbin/beacon -c KC6IKE-3 -d UNIX -t 30 439 "SAW:KC6IKE-3 AX25-UTILS/LINUX RH 6.1"
#
# Users
/usr/sbin/axparms -assoc aa6qn aa6qn
/usr/sbin/axparms -assoc kc6ike kc6ike
#
# Routes
/sbin/route add 44.bbb.cccc.110 eth1
/sbin/route add 44.bbb.cccc.111 eth1
/sbin/route add 44.bbb.cccc.112 eth1
/sbin/route add 44.bbb.cccc.113 eth1
/sbin/route add 44.bbb.cccc.114 eth1
/sbin/route add 44.bbb.cccc.149 dmascc0
/sbin/route add 44.bbb.cccc.32 gw 44.bbb.cccc.112 eth1
/sbin/route add 44.bbb.cccc.8 dmascc0
/sbin/route add 44.bbb.cccc.100 dmascc0
# Mount CDROM
mount /dev/cdrom /cdrom
#Remove tnos lock file
rm /nos/tnos.lock
#Start xFBB
/etc/rc.d/rc.xfbb
# EOF
/etc/ax25/axports
# /etc/ax25/axports
# Name Callsign speed paclen window description
#Due to xFBB having a max MTU of 256! grrrrrr
dmascc0 KC6IKE-14 56000 256 4 56K bps packet 433.050 MHz
dmascc1 KC6IKE-13 9600 256 2 9600 bps packet 145.730 MHz
145 KC6IKE-12 9600 256 1 1200 bps Port A DE 145.010 MHz
439 KC6IKE-11 9600 256 2 9600 bps Port B DE 439.025 MHz
axip KC6IKE-7 9600 256 4 AXIP Link
ax3 LOOP1 9600 256 4 Loopback 1
ax4 LOOP2 9600 256 4 Loopback 2
/etc/ax25/ax25d.conf
# /etc/ax25/ax25d.conf
[SAW VIA 145]
NOCALL * * * * * * L
default * * * * * * - root /usr/sbin/node node
#
[KC6IKE-3 VIA 145]
NOCALL * * * * * * L
default * * * * * 0 - root /usr/sbin/node node
#
[SAW VIA 439]
NOCALL * * * * * * L
default * * * * * * - root /usr/sbin/node node
#
[KC6IKE-3 VIA 439]
NOCALL * * * * * * L
default * * * * * 0 - root /usr/sbin/node node
#
[SAW VIA dmascc0]
NOCALL * * * * * * L
default * * * * * * - root /usr/sbin/node node
#
[KC6IKE-3 VIA dmascc0]
NOCALL * * * * * * L
default * * * * * 0 - root /usr/sbin/node node
#
<netnod>
NOCALL * * * * * * L
default * * * * * * - root /usr/sbin/node node
#
/etc/ax25/node.conf
# /etc/ax25/node.conf - LinuxNode configuration file
#
# see node.conf(5)
# Idle timeout (seconds).
#
IdleTimeout 900
# Timeout when gatewaying (seconds).
#
ConnTimeout 14400
# Visible hostname. Will be shown at telnet login.
#
HostName kc6ike.ampr.org
# Node ID.
#
NodeId SAW:KC6IKE-3
# ReConnect flag.
#
ReConnect on
# "Local" network.
#
LocalNet 44.bbb.cccc.0/16
# Command aliases.
#
Alias CAllbook 'telnet %{2:44.bbb.cccc.32} 1235 %1'
Alias CONVers 'telnet %{2:44.bbb.cccc.14} 3600 "/n %u %{1:32768}\n/w *"'
Alias BBS 'c ax4 kc6ike-0'
Alias JNOS 'telnet %{2:44.bbb.cccc.14}'
# Hidden ports.
#
#HiddenPorts 2
# External commands
#
# Flags: 1 Run command through pipe
# 2 Reconnect prompt
#
ExtCmd PMS 3 root /usr/sbin/pms pms -u \%U -o KC6IKE
ExtCmd ECho 1 nobody /bin/echo echo \%U\%u \%S\%s \%P\%p \%R\%r \%T\%t \%\% \%0 \%1 \%2 \%3 \%4 \%5 \%6 \%7 \%8 \%9
ExtCmd TIme 1 nobody /bin/echo echo %N Node session started at %I, current time is \%I.
# Netrom port name. This port is used for outgoing netrom connects.
#
NrPort netnod
# Logging level
#
LogLevel 3
# The escape character (CTRL-T)
#
EscapeChar ^T
# Resolve ip numbers to addresses?
#
ResolveAddrs off
# Node prompt.
#
NodePrompt "\n"
/etc/ax25/fbb/port.sys
# FBB7.01
#
#
#Ports TNCs
2 7
#
# Interface 9 = LINUX
#
#Com Interface Adress (Hex) Baud
1 9 **** 9600
2 9 e21 0
#
#
#TNC NbCh Com MultCh Pacln Maxfr NbFwd MxBloc M/P-Fwd Mode Freq
0 0 0 0 0 0 0 0 00/01 ---- File-fwd.
1 4 1 145 250 1 2 10 10/60 XUWYL 145.010
2 4 1 439 250 2 2 10 20/60 XUWYL 439.025
3 4 1 axip 250 4 2 10 30/60 XUWYL AXIP
4 4 1 ax3 250 4 2 10 30/60 XUWY LOOP
5 2 1 netbbs 236 4 1 10 30/60 XUWY NETROM
6 4 1 dmascc0 250 4 2 10 40/60 XUWYL 433.050
#Only 7 ports allowed! grrrrr
# 6 4 1 dmascc1 250 2 2 10 30/60 XUWY 145.730
7 4 2 0 250 2 1 10 0/60 TUWY TELNET
#
# End of file.
#
/nos/autoexec.nos
#============================================================
# AUTOEXEC.NOS FOR [ kc6ike ] ALIAS [ 44.bbb.cccc.14]
# Date Last Updated: 7/22/99
# Time Last Updated: 0700 UTC This File Intended for Version: 111d linux
# This System Designed by: John Feist
#============================================================
#
#
domain suffix ampr.org.
domain translate off
domain maxwait 15
domain maxclients 20
domain verbose off
domain dns off
domain retries 4
domain cache clean on
domain cache wait 300
domain addserver 44.bbb.cccc.14
domain addserver 44.bbb.cccc.112
attend off
errors off
#
hostname kc6ike.ampr.org
#
ax25 mycall kc6ike-6
ax25 bbscall kc6ike-8
ax25 ttycall kc6ike-9
#ax25 alias SanTee2
#
ip address [44.bbb.cccc.14]
#
# ****************** AX25 Parameters
#
ax25 bcinterval 1800
ax25 blimit 5
ax25 bctext "kc6ike - Santee, CA JNOS/U TCPIP Mailbox System"
ax25 hsize 30
ax25 irtt 2500
ax25 maxframe 1
ax25 paclen 256
ax25 pthresh 128
ax25 ret 10
ax25 t3 0
ax25 t4 300
ax25 timer linear
ax25 filter 0
ax25 version 2
ax25 window 2048
ax25 maxwait 30000
#
# ********************* IP Parameters
#
ip hsize 22
ip rtimer 30
ip ttl 150
#
# ********************* TCP Parameters
#
tcp retries 10
tcp bl 10
tcp irtt 2000
tcp mss 2008
tcp timertype linear
tcp tra no
tcp window 2008
tcp maxwait 30000
#
# ********************** Interface Configurations #
# attach slip|ax25|nrs
# Attach the PackeTwin card. Using the /etc/rc.d/rc.local
# ptypx/ttypx pairs
#attach asy ttypb - ax25 9k6 1024 1024 9600
attach asy ttypa - ax25 56k 2048 1500 56000
# Below is attached via /etc/rc.d/rc.local file ptypx/ttypx pairs
# Kantronics Data Engine
attach asy ttypc - ax25 2m01 2048 256 9600
attach asy ttypd - ax25 439 2048 256 9600
attach asy ttypf - slip lan 2048 1024 38400
#Pseudo slip to sl0 in linux kernel aka slattach ptype
asyconfig lan rxq 10
asyconfig lan txq 10
# AXIP links
attach axip x6qn 256 44.bbb.cccc.112 kc6ike-11
ifc x6qn descr "AXIP to AA6QN"
attach axip 6ike 256 44.bbb.cccc.115 kc6ike-12
ifc 6ike descr "AXIP to KC6IKE FBB"
#
#
# ********************** Interface Descriptions #
ifc lan broadcast 44.bbb.ccc.255
ifc lan netmask 0xffffff00
#ifc lan ipa 198.253.78.234
#
#439.025 local tcpip- Data Engine
ifc 439 linkaddress kc6ike
ifc 439 ax25 bctext "Network node\r(SAW)"
ifc 439 broadcast 44.bbb.ccc.255
ifc 439 netmask 0xffffff00
ifc 439 ax25 maxframe 1
ifc 439 ax25 paclen 256
ifc 439 ipaddress 44.bbb.cccc.14
#
#2m01 local tcpip port- Data Engine
ifc 2m01 linkaddress kc6ike
ifc 2m01 ax25 bctext "Network node\r(SAW)"
#Above id is so that kanodes will recognise this system as a node
ifc 2m01 broadcast 44.bbb.ccc.255
ifc 2m01 netmask 0xffffff00
ifc 2m01 ax25 maxframe 1
ifc 2m01 ax25 paclen 127
ifc 2m01 ipaddress 44.bbb.cccc.14
#ifc 2m01 ax25 t2 400
#ifc 2m01 tcp mss 108
#ifc 2m01 tcp win 216
#
#WA4DSY 56k baud system with MMT 432-28S 28<->432 transverter
ifc 56k linkaddress kc6ike
ifc 56k broadcast 44.bbb.ccc.255
ifc 56k netmask 0xffffff00
ifc 56k ax25 maxframe 1
ifc 56k ax25 paclen 256
ifc 56k tcp mss 536
ifc 56k mtu 576
ifc 56k tcp win 1800
#
#
arp pub 44.bbb.cccc.14 ether 00:A0:24:C6:65:5A lan
arp pub 44.bbb.cccc.14 ax25 kc6ike-8 2m01
arp pub 44.bbb.cccc.14 ax25 kc6ike-8 439
arp pub 44.bbb.cccc.14 ax25 kc6ike-8 56k
#
ip hp lan on
ip hp 439 on
ip hp 2m01 on
ip hp 56k on
#
ifconfig 439 descr "439.025 MHz @ 9600bd"
ifconfig 2m01 descr "145.010 MHz @ 1200bd"
ifconfig 56k descr "433.050 MHz port 56000 baud"
#
# ********************** Parameters Settings for TNC's #
param 439 1 10
param 439 2 10
param 439 3 5
param 439 5 0
#
#145.010 Mhx tcpipt- KAM
param 2m01 1 30
param 2m01 2 50
param 2m01 3 6
param 2m01 5 0
#
# ******************** Servers to be Turned on
#
start ax25
start convers
start finger
start ftp
start forward
start ident
# Turned off netrom, using ax25-util node3.0
#start netrom
start smtp
start telnet
start ttylink
start rip
#
# ********************* SMTP/FTP Commands #
remote -s goldie
smtp maxclients 10
smtp batch off
smtp timer 1800
smtp mode route
smtp quiet yes
smtp usemx yes
smtp tdisc 600
smtp t4 600
ftptdisc 600
#
# ***************** Active and Mail Beacons #
ax25 filter 0
ax25 hsize 10
ax25 hport x6qn on
ax25 bcport 439 on
ax25 bcport 2m01 on
ax25 bcport x6qn on
ax25 digipeat 439 on
ax25 digipeat 2m01 on
ax25 digipeat x6qn on
ax25 digipeat 56k on
mode 56k datagram
mode x6qn datagram
#
# ***************** MBOX Commands
#
mbox haddress kc6ike.#sca.ca.usa.noam
mbox header on
mbox mailfor 900
mbox mailfor exclude kc6ike sysop check deadbeaf
mbox new on
mbox sendquery on
mbox smtp no
mbox secure no
mbox tdisc 900
mbox timer 1800
mbox zipcode
mbox mailfor watch kc6ike
#^^^^This is not useful until status windows is completed
bulletin check yes
bulletin date yes
bulletin return yes
bulletin loophold 2
bulletin holdold 30
mb show on
mb password ""
#
#******************** NET/ROM SETUP
#netrom not used .ax25-utils/node.conf
# ******************* CONVERS STUFF
convers host SAWconv
convers umaxq 0
convers hmaxq 0
convers maxwait 600
convers channel 143
convers mycall kc6ike-5
convers interface lan on
convers interface 439 on
convers interface 2m01 on
convers interface 56k on
# # ******************* Misc Parameters, Routes
# CALLBOOK
callserver2 hostname 44.bbb.cccc.32
#
log yes
strace off
trace 2m01 311
trace 439 311
trace 56k 511
#trace lan 311
#watchdog on
history 10
smtp kick
ftype binary
#ax route add mail 2m01 n6hb-2
#source encap_ax
#source encap.txt
route add 44.bbb.cccc.32 lan 44.bbb.cccc.115
route add 44.bbb.cccc.100 56k 44.bbb.cccc.100
route add 44.bbb.cccc.8 56k 44.bbb.cccc.8
route add 44.bbb.cccc.149 56k 44.bbb.cccc.149
route add 44.4/16 lan 44.bbb.cccc.115
#
route add default lan 44.bbb.cccc.115
#
ax25 route add kb5mu-1 56k
ax25 route add ke6uez-6 56k
ax25 route add aa6qn-3 x6qn
#
ax25 route mode kb5mu-1 56k datagram
ax25 route mode ke6uez-6 56k datagram
ax25 route mode aa6qn-3 x6qn datagram
#
arp add 44.bbb.cccc.8 ax25 kb5mu-1 56k
arp add 44.bbb.cccc.149 ax25 ke6uez-6 56k
arp add 44.bbb.cccc.32 ax25 aa6qn-3 lan
#
# RIP statements
rip add 44.bbb.cccc.100 300 4
rip accept 44.bbb.cccc.100
rip request 44.bbb.cccc.100
# KB5MU 44.bbb.cccc.8
rip add 44.bbb.cccc.8 900 4 2
rip accept 44.bbb.cccc.8
rip request 44.bbb.cccc.8
# KE6UEZ
rip add 44.bbb.cccc.149 900 4 2
rip accept 44.bbb.cccc.149
rip request 44.bbb.cccc.149
##
str on
#***********************************************************************
#
# THE END
#
#==============================================================