home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 13 / CDA13.ISO / DOC / HOWTO / OTHER_FO / SGML / AX25_HOW.GZ / AX25-HOWTO.sgml
Encoding:
SGML Document  |  1996-06-23  |  78.8 KB  |  2,107 lines

  1. <!doctype linuxdoc system>
  2.  
  3. <!-- This is the Linux AX25-HOWTO. It describes how to install and configure
  4.     AX.25 networking support for Linux. Any comments or feedback should
  5.     be directed to the author terry@perf.no.itg.telecom.com.au
  6.  -->
  7.  
  8. <article>
  9.  
  10. <title>Linux AX25-HOWTO, Amateur Radio.
  11. <author>Terry Dawson, VK2KTJ, <tt>terry@perf.no.itg.telecom.com.au</tt>
  12. <date>v1.1, 14 June 1996
  13.  
  14. <abstract>
  15. The Linux Operating System is perhaps the only operating system in the world
  16. that can boast native and standard support for the AX.25 packet radio protocol
  17. utilised by Amateur Radio Operators worldwide. This document aims to describe
  18. how to install and configure this support.
  19. </abstract>
  20.  
  21. <!-- Table of contents -->
  22. <toc>
  23.  
  24. <!-- Begin the document -->
  25.  
  26. <sect><heading>Introduction.
  27.  
  28. <p>
  29. This document was originally an appendix to the HAM-HOWTO, but grew too large
  30. to be reasonably managed in that fashion. This document describes how to
  31. install and configure the native AX.25 and NetRom support for Linux. A few
  32. typical configurations are described that could be used as models to work
  33. from.
  34.  
  35. <sect1><heading>Changes from the previous version
  36.  
  37. <p>
  38. <verb>
  39. Additions:
  40.     Baycom support - ye gads!
  41.  
  42. Corrections/Updates:
  43.     Included SLIP support in kernel config - oops.
  44.     2.0.0 kernel and ax25-tools update.
  45.     Updated net-tools to 1.32-alpha version.
  46.     Removed Jonathons `special' net-tools.
  47.     A bit of shuffling about to make more sense.
  48.     Updated the example configurations.
  49.     A minor copyright ooops.
  50. </verb>
  51.  
  52. <sect1><heading>Other related documentation.
  53.  
  54. <p>
  55. There is a lot of related documentation. There are many documents that relate
  56. to Linux networking in more general ways and I strongly recommend you also
  57. read these as they will assist you in your efforts and provide you with
  58. stronger insight into other possible configurations.
  59.  
  60. They are:
  61.  
  62. <url url="http://sunsite.unc.edu/mdw/HOWTO/HAM-HOWTO.html"
  63.     name="The HAM-HOWTO">
  64.  
  65. <url url="http://sunsite.unc.edu/mdw/HOWTO/NET-2-HOWTO.html"
  66.     name="the Net-2-HOWTO">
  67.  
  68. <url url="http://sunsite.unc.edu/mdw/HOWTO/Ethernet-HOWTO.html"
  69.     name="the Ethernet-HOWTO">
  70.  
  71. <url url="http://sunsite.unc.edu/mdw/HOWTO/IPX-HOWTO.html"
  72.     name="the IPX-HOWTO">
  73.  
  74. and
  75.  
  76. <url url="http://sunsite.unc.edu/mdw/HOWTO/Firewall-HOWTO.html"
  77.     name="the Firewall-HOWTO">
  78.  
  79. <sect><heading>Where to obtain new versions of this document.
  80.  
  81. <p>
  82. The best place to obtain the latest version of this document is from a
  83. Linux Documentation Project archive. The Linux Documentation Project runs
  84. a Web Server and this document appears there as
  85. <url url="http://sunsite.unc.edu/mdw/HOWTO/AX25-HOWTO.html"
  86.     name="The AX25-HOWTO">. You can always contact me, but I pass new
  87. versions of the document directly to the LDP HOWTO coordinator, so if it
  88. isn't there then chances are I haven't finished it.
  89.  
  90.  
  91. <sect><heading>Linux and the AX.25 and NetRom Packet Radio Protocols.
  92.  
  93. <p>
  94. The <em>AX.25</em> protocol offers both connected and connectionless modes of
  95. operation, and is used either by itself for point-point links, or to carry
  96. other protocols such as TCP/IP and NetRom.
  97.  
  98. It is similar to X.25 level 2 in structure, with some extensions to make it
  99. more useful in the amateur radio environment.
  100.  
  101. The NetRom protocol is an attempt at a full network protocol and uses AX.25 at
  102. its lowest layer as a datalink protocol. It provides a network layer that is
  103. an adapted form of AX.25.
  104.  
  105. Alan Cox developed some early kernel based AX.25 software support for Linux.
  106. Jonathon Naylor <tt><g4klx@g4klx.demon.co.uk></tt> has taken up ongoing
  107. development of the code, has added NetRom support and is now the developer
  108. of the AX.25 related kernel code and utilities. DAMA support was developed by
  109. Joerg, DL1BKE. Finally Baycom support was added by Thomas Sailer,
  110. <tt><sailer@ife.ee.ethz.ch></tt>.
  111.  
  112. The Linux code supports KISS based TNC's (Terminal Node Controllers),
  113. the Ottawa PI card, the Gracilis PacketTwin card and other Z8530 SCC based
  114. cards with the generic SCC driver and both the Parallel and Serial port Baycom
  115. modems.
  116.  
  117. The User programs contain a simple PMS (Personal Message System), a beacon
  118. facility, a line mode connect program, `listen' an example of how to capture
  119. all AX.25 frames at raw interface level and programs to configure the NetRom
  120. protocol. Included also are an AX.25 server style program to handle and
  121. despatch incoming AX.25 connections and a NetRom daemon which does most of
  122. the hard work for NetRom support.
  123.  
  124. <sect><heading>The AX.25/NetRom software components.
  125.  
  126. <p>
  127. The AX.25 software is comprised of three components, the kernel source, the
  128. network configuration tools and the utility programs.
  129.  
  130. The version 1.3.xx Linux kernels include the AX.25, NetRom, Z8530 SCC, PI
  131. card and PacketTwin drivers by default. I recommend you obtain and use the
  132. version 1.3.xx kernel source.
  133. <p>
  134. These are three reasons I'm recommending you use the alpha version software
  135. even though most everyone else will recommend you don't use it:
  136. <itemize>
  137. <item>it makes the process of building and configuring the software a whole lot
  138. simpler. There are no patches to apply it is a simple matter of configuring
  139. and compiling a kernel with the appropriate options enabled.
  140. <item>it is the most recent software and is most likely to provide the most
  141. satisfactory results.
  142. <item>like all new software, it needs testing and bug reports. The more people
  143. that take the software and attempt to use it in their own configurations the
  144. more likely it will be that bugs are uncovered and the easier it will be to
  145. get the software debugged. Join the team, contribute bug reports and help
  146. everybody.
  147. </itemize>
  148.  
  149. Be warned though, this software is <bf>alpha</bf> and may have problem that
  150. you wouldn't otherwise encounter. Please take all the usual precautions and
  151. be sure to keep a working kernel as backup when testing new kernels. It is
  152. wise to test a new kernel by booting from it from floppy before actually 
  153. installing it with <em>lilo</em>, though I haven't bothered for about 90
  154. kernels revisions so I'm fairly confident you can pretty safely run with alpha
  155. kernels.
  156.  
  157. <sect1><heading>Finding the kernel, tools and utility packages.
  158.  
  159. <p>
  160. <sect2><heading>The kernel source:
  161.  
  162. <p>
  163. The kernel source can be found in its usual place at:
  164.  
  165. <bf>ftp.funet.fi</bf>
  166. <tscreen><verb>
  167. /pub/Linux/PEOPLE/Linus/v2.0/
  168. </verb></tscreen>
  169.  
  170. <sect2><heading>The network tools:
  171.  
  172. <p>
  173. The latest alpha release of the standard Linux network tools support
  174. AX.25 and NetRom and can be found at:
  175.  
  176. <bf>ftp.inka.de</bf>
  177. <tscreen><verb>
  178. /pub/comp/Linux/networking/net-tools/net-tools-1.32-alpha.tar.gz
  179. </verb></tscreen>
  180.  
  181. or:
  182.  
  183. <bf>ftp.linux.org.uk</bf>
  184. <tscreen><verb>
  185. /pub/linux/Networking/PROGRAMS/NetTools/net-tools-1.32-alpha.tar.gz
  186. </verb></tscreen>
  187. <p>
  188.  
  189. The latest ipfwadm package can be found at:
  190.  
  191. <bf>ftp.xos.nl</bf>
  192. <tscreen><verb>
  193. /pub/linux/ipfwadm/
  194. </verb></tscreen>
  195.  
  196. <sect2><heading>The AX25 utilities:
  197.  
  198. <p>
  199. The AX.25 utility programs can be found at:
  200.  
  201. <bf>sunsite.unc.edu</bf>
  202. <tscreen><verb>
  203. /pub/Linux/apps/ham/ax25-utils-2.0.0.tar.gz
  204. </verb></tscreen>
  205.  
  206. or:
  207.  
  208. <bf>ftp.ucsd.edu</bf>
  209. <tscreen><verb>
  210. /hamradio/packet/tcpip/incoming/ax25-utils-2.0.0.tar.gz
  211. </verb></tscreen>
  212.  
  213. <sect><heading>Installing the AX.25/NetRom software.
  214.  
  215. <p>
  216. To successfully install AX.25 support on your linux system you must configure
  217. and install an appropriate kernel and then install the AX.25 utilities.
  218.  
  219. <sect1><heading>Compiling the kernel.
  220.  
  221. <p>
  222. If you are already familiar with the process of compiling the Linux Kernel
  223. then you can skip this section, just be sure to select the appropriate options
  224. when compiling the kernel. If you are not, then read on.
  225. <p>
  226. The normal place for the kernel source to be unpacked to is the
  227. <tt>/usr/src</tt> directory into a subdirectory called <tt>linux</tt>.
  228. To do this you should be logged in as <tt>root</tt> and execute a series
  229. of commands similar to the following:
  230.  
  231. <tscreen><verb>
  232. # mv linux linux.old
  233. # cd /usr/src
  234. # gzip -dc linux-2.0.0.tar.gz | tar xvofp -
  235. # cd linux
  236. </verb></tscreen>
  237.  
  238. After you have unpacked the kernel source into place you need to run the
  239. configuration script and choose the options that suit your hardware
  240. configuration and the options that you wish built into your kernel.
  241. You do this by using the command:
  242.  
  243. <tscreen><verb>
  244. # make config
  245. </verb></tscreen>
  246.  
  247. You might also try:
  248.  
  249. <tscreen><verb>
  250. # make menuconfig
  251. </verb></tscreen>
  252.  
  253. if you prefer a full screen menu based method. I'm going to describe the
  254. original method, but you use whichever you are most comfortable with.
  255.  
  256. In either case you will be offered a range of options at which you must
  257. answer `Y' or `N'. (Note you may also answer `M' if you are using modules.
  258. For the sake of simplicity I will assume you are not, please make appropriate
  259. modifications if you are).
  260.  
  261. The options most relevant to an AX.25 configuration are:
  262.  
  263. <verb>
  264. Networking support (CONFIG_NET) [Y/n/?]                             Y
  265. Loopback device support (CONFIG_BLK_DEV_LOOP) [N/y/m/?]             Y
  266. Network firewalls (CONFIG_FIREWALL) [N/y/?]
  267. TCP/IP networking (CONFIG_INET) [Y/n/?]                             Y
  268. IP: forwarding/gatewaying (CONFIG_IP_FORWARD) [N/y/?]
  269. IP: firewalling (CONFIG_IP_FIREWALL) [N/y/?] (NEW)
  270. IP: tunneling (CONFIG_NET_IPIP) [N/y/m/?] (NEW)
  271. Amateur Radio AX.25 Level 2 (CONFIG_AX25) [N/y/?]                   Y
  272. AX.25 over Ethernet (CONFIG_BPQETHER) [N/y/?] (NEW)
  273. Amateur Radio NET/ROM (CONFIG_NETROM) [N/y/?] (NEW)
  274. Kernel/User network link driver(ALPHA) (CONFIG_NETLINK) [N/y/?] 
  275. Network device support (CONFIG_NETDEVICES) [Y/n/?]                  Y
  276. SLIP (serial line) support (CONFIG_SLIP) [N/y/m/?]                  Y
  277. Radio network interfaces (CONFIG_NET_RADIO) [N/y/?]
  278. BAYCOM ser12 and par96 kiss emulation driver for AX.25 (CONFIG_BAYCOM) [N/y/m/?]
  279. Z8530 SCC kiss emulation driver for AX.25 (CONFIG_SCC) [N/y/m/?] 
  280. Other ISA cards (CONFIG_NET_ISA) [N/y/?]
  281. Ottawa PI and PI/2 support (CONFIG_PI) [N/y/?] (NEW) 
  282. Gracilis PackeTwin support (CONFIG_PT) [N/y/?] (NEW) 
  283. Standard/generic serial support (CONFIG_SERIAL) [Y/n/?] 
  284. </verb>
  285.  
  286. The options I have flagged with a `Y' are those that you <bf>must</bf> must
  287. answer `Y' to. The rest are dependent on what hardware you have and what
  288. options you want to include. Some of these options are described in more
  289. detail later on, so if you don't know what you want yet, then read ahead
  290. and come back to this step later.
  291.  
  292. After you have completed the kernel configuration you should be able to
  293. cleanly compile your new kernel:
  294.  
  295. <tscreen><verb>
  296. # make dep
  297. # make clean
  298. # make zImage
  299. </verb></tscreen>
  300.  
  301. Make sure you move your <tt>arch/i386/boot/zImage</tt> file wherever you
  302. want it and then run <em>lilo</em> to ensure that you actually boot from
  303. it.
  304.  
  305. <sect1><heading>The network configuration tools.
  306.  
  307. <p>
  308. After you have compiled the kernel you should compile the new network
  309. configuration tools. These tools allow you to modify the configuration of
  310. network devices and to add routes to the routing table.
  311.  
  312. The new alpha release of the standard <tt>net-tools</tt> package includes
  313. support for AX.25 and NetRom support. I've tested this and it seems to
  314. work well for me.
  315.  
  316. <sect2><heading>Building the standard net-tools release.
  317.  
  318. <p>
  319. Don't forget to read the <tt>Release</tt> file and follow any instructions
  320. there. The steps I used to compile the tools were:
  321.  
  322. <tscreen><verb>
  323. # cd /usr/src
  324. # tar xvfz net-tools-1.32-alpha.tar.gz
  325. # cd net-tools-1.32-alpha
  326. # make config
  327. </verb></tscreen>
  328.  
  329. At this stage you will be presented with a series of configuration questions,
  330. similar to the kernel configuration questions. Be sure to include support for
  331. all of the protocols and network devices types that you intend to use. If you
  332. do not know how to answer a particular question then answer `Y'.
  333. <p>
  334. The tools compiled cleanly against a <tt>2.0.0</tt> kernel without error.
  335. <p>
  336. When the compilation is complete, you should need only use the:
  337.  
  338. <tscreen><verb>
  339. # make install
  340. </verb></tscreen>
  341.  
  342. command to install the programs in their proper place.
  343.  
  344. <p>
  345. If you wish to use the IP firewall facilities then you will need the latest
  346. firewall administration tool <tt>ipfwadm</tt>. This tool replaces the older
  347. <tt>ipfw</tt> tool which will not work with new kernels.
  348. <p>
  349. I compiled the <tt>ipfwadm</tt> utility with the following commands:
  350. <tscreen><verb>
  351. # cd /usr/src
  352. # tar xvfz ipfwadm-2.0beta2.tar.gz
  353. # cd ipfwadm-2.0beta2
  354. # make install
  355. # cp ipfwadm.8 /usr/man/man8
  356. # cp ipfw.4 /usr/man/man4
  357. </verb></tscreen>
  358.  
  359.  
  360. <sect1><heading>The AX.25 user programs.
  361.  
  362. <p>
  363. After you have successfully compiled and booted your new kernel, you need to
  364. compile the user programs. To compile and install the user programs you should
  365. use a series of commands similar to the following:
  366.  
  367. <tscreen><verb>
  368. # cd /usr/local
  369. # gzip -dc ax25-utils-2.0.0.tar.gz | tar xvvof -
  370. # cd ax25-utils-2.0
  371. # make install
  372. </verb></tscreen>
  373.  
  374. The files will be installed under the <tt>/usr/local</tt> directory by default
  375. in subdirectories: <tt>bin, sbin, etc</tt> and <tt>man</tt>.
  376.  
  377. If you get messages something like:
  378. <verb>
  379. gcc -Wall -Wstrict-prototypes -O2 -I../lib -c call.c
  380. call.c: In function `statline':
  381. call.c:268: warning: implicit declaration of function `attron'
  382. call.c:268: `A_REVERSE' undeclared (first use this function)
  383. call.c:268: (Each undeclared identifier is reported only once
  384. call.c:268: for each function it appears in.)
  385. </verb>
  386.  
  387. then you should read the <tt>README.ncurses</tt> file in the top level
  388. directory. You can do as Jonathon suggests, or you can try replacing:
  389. <verb>
  390. #include <curses.h>
  391. </verb>
  392. with:
  393. <verb>
  394. #include <ncurses/curses.h>
  395. </verb>
  396. in the:
  397. <verb>
  398. call/call.c
  399. call/menu.c
  400. </verb>
  401. files.
  402.  
  403. <sect><heading>Configuring a RAW AX.25 connected mode interface.
  404.  
  405. <p>
  406. The first stage to configuration of an AX.25 interface is to configure it
  407. to work as a `vanilla' AX.25 interface with no TCP/IP. The following
  408. configuration will get you to the point of being able to make AX.25 calls
  409. from your Linux machine to other AX.25 nodes.
  410. <p>
  411. The AX.25 software has been designed to work with a TNC in <em>kiss</em>
  412. mode or with other cards such as the Ottawa PI2 card, PacketTwin and other
  413. SCC cards via special drivers that emulate a <em>kiss</em> tnc.
  414. <p>
  415. For real KISS TNC's there are two steps to complete in order to create an
  416. AX.25 port ready to use to make outgoing calls. For other types of hardware
  417. you need only complete the first step.
  418.  
  419. <sect1><heading>Creating the <tt>/usr/local/etc/axports</tt> file.
  420.  
  421. <p>
  422. The AX.25 ports have a configuration file that is read by many programs that
  423. want to find information about an AX.25 port. This file is called the:
  424.  
  425. <tscreen><verb>
  426. /usr/local/etc/axports
  427. </verb></tscreen>
  428.  
  429. file. The format of the file is as follows:
  430.  
  431. <tscreen><verb>
  432. portname  callsign  baudrate  paclen  window  description
  433. </verb></tscreen>
  434.  
  435. where:
  436.  
  437. <descrip>
  438. <tag>portname</tag>is a text name that you will refer to the port by.
  439. <tag>callsign</tag>is the AX.25 callsign you want to assign to the port.
  440. <tag>baudrate</tag>is the speed at which you wish the port to communicate with
  441. your TNC.
  442. <tag>paclen</tag>is the maximum packet length you want to configure the port
  443. to use for AX.25 connected mode connections.
  444. <tag>window</tag>is the AX.25 window (K) parameter. This is the same as the
  445. <tt>MAXFRAME</tt> setting of many tnc's.
  446. <tag>description</tag>is a textual description of the port.
  447. </descrip>
  448.  
  449. In my case, mine looks like:
  450.  
  451. <tscreen><verb>
  452. radio    VK2KTJ-0        4800    256     2       144.800 MHz
  453. </verb></tscreen>
  454.  
  455. <sect1><heading>Creating the AX.25 device
  456.  
  457. <p>
  458. If you are using an SCC card like the PI2 or PacketTwin then you do not need
  459. to create the network device, as the kernel driver will automatically do this
  460. for you. If you are using a KISS TNC then you will need to create the AX.25
  461. interface as it will not already exist. Creating an AX.25 port is very similar
  462. to creating a slip device.
  463. <p>
  464. You will need to have the TNC preconfigured and connected to your serial port.
  465. You can use a communications program like <em>minicom</em> or <em>seyon</em>
  466. to configure the TNC into kiss mode if you wish.
  467. <p>
  468. You use the <em>axattach</em> program in much the same way as you would use
  469. the <em>slattach</em> program (refer to the NET-2-HOWTO for more information
  470. on slattach and the other network software for Linux). For example:
  471.  
  472. <tscreen><verb>
  473. # /usr/local/sbin/axattach /dev/ttyS0 radio
  474. </verb></tscreen>
  475.  
  476. would configure your <tt>/dev/ttyS1</tt> serial device to be a <em>kiss</em>
  477. interface configured as per the details for the line beginning with the
  478. portname "radio" in the <tt>/usr/local/etc/axports</tt> file.
  479.  
  480. All this step has done is to actually activate the device in the kernel, you
  481. need to run other programs before you an actually make use of the port.
  482.  
  483. <sect2><heading>Setting the callsign for SCC cards.
  484.  
  485. <p>
  486. If you are using a PI or PacketTwin card then you should use the
  487. <em>axparms -setcall</em> command to change the callsign of the appropriate
  488. port to that which you intend to use. Refer to the PI/PacketTwin section for
  489. the names of the network devices to use.
  490.  
  491. <sect2><heading>Testing the interface.
  492.  
  493. <p>
  494. You now should be able to make outgoing AX.25 connections. To test AX.25
  495. connected mode you could use the <em>call</em> program as demonstrated:
  496.  
  497. <tscreen><verb>
  498. /usr/local/bin/call radio VK2DAY via VK2SUT
  499. </verb></tscreen>
  500.  
  501. Note: you must tell call which AX.25 port you wish to make the call on,
  502. as the same AX.25 node might be reachable on any of the ports you have
  503. configured.
  504. <p>
  505. The <em>call</em> program is a linemode terminal program for making
  506. AX.25 calls. It recognises lines that start with `<tt>~</tt>' as command lines.
  507. The `<tt>~.</tt>' command will close the connection.
  508. <p>
  509. Please refer to the man pages in <tt>/usr/local/man</tt> and the
  510. <tt>README</tt> file in <tt>ax25-utils-2.0.0</tt> distribution for more
  511. information.
  512.  
  513.  
  514. <sect><heading>Configuring an AX.25 interface for tcp/ip.
  515.  
  516. <p>
  517. It is very simple to configure an AX.25 port to carry tcp/ip. Jonathon has
  518. modified the <em>axattach</em> command so that you can include the IP address
  519. that you want the interface to be configured with on the command line. For
  520. example, to modify the example presented earlier, I could use the command:
  521.  
  522. <tscreen><verb>
  523. # /usr/local/sbin/axattach -i 44.136.8.5 -m 512 /dev/ttyS0 radio
  524. # /sbin/route add -net 44.136.8.0 sl0
  525. # /sbin/route add default sl0
  526. </verb></tscreen>
  527.  
  528. to create the AX.25 interface with an IP address of <tt>44.136.8.6</tt> and
  529. an <tt>MTU</tt> of <tt>512</tt> bytes. You should still use the
  530. <em>ifconfig</em> to configure the other parameters if necessary.
  531. <p>
  532. You do not need to do it this way, you can of course just use the
  533. <em>ifconfig</em> program to configure the ip address and netmask details for
  534. the port and add a route via the port, just as you would for any other
  535. tcp/ip interface.
  536.  
  537. <tscreen><verb>
  538. # /sbin/ifconfig sl0 44.136.8.5
  539. # /sbin/ifconfig sl0 netmask 255.255.255.0
  540. # /sbin/ifconfig sl0 broadcast 44.136.8.255
  541. # /sbin/ifconfig sl0 arp mtu 256 up
  542. # /sbin/route add -net 44.136.8.0 sl0
  543. # /sbin/route add default sl0
  544. </verb></tscreen>
  545.  
  546. The commands listed above are typical of the sort of configuration many of
  547. you would be familiar with if you have used NOS or any of its derivatives
  548. or any other tcp/ip software. Note that the default route might not be required
  549. in your configuration if you have some other network device configured.
  550.  
  551. To test it out, try a ping or a telnet to a local host.
  552.  
  553. <tscreen><verb>
  554. # ping -i 5 44.136.8.58
  555. </verb></tscreen>
  556.  
  557. Note the use of the `<tt>-i 5</tt>' arguments to <em>ping</em> to tell it to
  558. send pings every 5 seconds instead of its default of 1 second.
  559.  
  560. <sect><heading>Configuring an AX.25 interface for NetRom.
  561.  
  562. <p>
  563. To configure NetRom on an AX.25 interface you must configure two files.
  564.  
  565. <sect1><heading>Configuring <tt>/usr/local/etc/nrports</tt>
  566.  
  567. <p>
  568. The first is the <tt>/usr/local/etc/nrports</tt> file. This file describes
  569. the NetRom port in much the same way as the <tt>/usr/local/etc/axports</tt>
  570. file describes the AX.25 ports.
  571. <p>
  572. This file is formatted as follows:
  573.  
  574. <tscreen><verb>
  575. name callsign  alias  paclen   description
  576. </verb></tscreen>
  577.  
  578. Where:
  579. <descrip>
  580. <tag>name</tag>is the text name that you wish to refer to the port by.
  581. <tag>callsign</tag>is the callsign that the NetRom traffic from this port will
  582. use.
  583. <tag>alias</tag>is the NetRom alias this port will have assigned to it.
  584. <tag>paclen</tag>is the maximum size of NetRom frames transmitted by this port.
  585. <tag>description</tag>is a free text description of the port.
  586. </descrip>
  587.  
  588. An example would look something like the following:
  589.  
  590. <tscreen><verb>
  591. netrom  VK2KTJ-1        LINUX   235     Linux Switch Port
  592. </verb></tscreen>
  593.  
  594. Note that the ports are referred to by name by programs such as <em>call</em>.
  595.  
  596. <sect1><heading>Configuring <tt>/usr/local/etc/nrbroadcast</tt>
  597.  
  598. <p>
  599. The second file is the <tt>/usr/local/etc/nrbroadcast</tt> file.
  600.  
  601. This file is formatted as follows:
  602.  
  603. <tscreen><verb>
  604. axport min_obs def_qual worst_qual verbose
  605. </verb></tscreen>
  606.  
  607. Where:
  608. <descrip>
  609. <tag>axport</tag>is the port name obtained from the
  610. <tt>/usr/local/etc/axports</tt> file. If you do not have an entry in
  611. <tt>/usr/local/etc/nrbroadcasts</tt> for a port then this means that no NetRom
  612. routing will occur and any received NetRom broadcasts will be ignored for that
  613. port.
  614. <tag>min_obs</tag>is the minimum obselesence value for the port.
  615. <tag>def_qual</tag>is the default quality for the port.
  616. <tag>worst_qual</tag>is the worst quality value for the port, any routes under
  617. this quality will be ignored.
  618. <tag>verbose</tag>is a flag determining whether full NetRom routing broadcasts
  619. will occur from this port or only a routing broadcast advertising the node
  620. itself.
  621. </descrip>
  622.  
  623. An example would look something like the following:
  624.  
  625. <tscreen><verb>
  626. radio    1       200      10         1
  627. </verb></tscreen>
  628.  
  629. <sect1><heading>Creating the NetRom device
  630.  
  631. <p>
  632. When you have the two configuration files completed you must create the
  633. NetRom device in much the same way as you did for the AX.25 devices.
  634. This time you use the <em>nrattach</em> command:
  635.  
  636. <tscreen><verb>
  637. # nrattach netrom
  638. </verb></tscreen>
  639.  
  640. This command would start the NetRom device (<tt>nr0</tt>) named <tt>netrom</tt>
  641. configured with the details specified in the <tt>/usr/local/etc/nrports</tt>
  642. file.
  643.  
  644. <sect1><heading>Starting the NetRom daemon
  645.  
  646. <p>
  647. The NetRom daemon manages the NetRom routing tables and generates the NetRom
  648. routing broadcasts. You start NetRom with the command:
  649.  
  650. <tscreen><verb>
  651. # /usr/local/sbin/netromd
  652. </verb></tscreen>
  653.  
  654. You should soon see the <tt>/proc/net/nr_neigh</tt> file filling up with
  655. information about your NetRom neighbours.
  656. <p>
  657. Remember to put the <tt>/usr/local/sbin/netromd</tt> command in your
  658. <em>rc</em> files so that it is started automatically each time you reboot.
  659.  
  660. <sect><heading>Configuring IP on a NetRom interface.
  661.  
  662. <p>
  663. Configuring a NetRom interface for tcp/ip is almost identical to
  664. configuring an AX.25 interface for tcp/ip.
  665. <p>
  666. Again you can either specify the ip address and mtu on the <em>nrattach</em>
  667. command line, or use the <em>ifconfig</em> and <em>route</em> commands, but
  668. you need to manually add <em>arp</em> entries for hosts you wish to route to
  669. because there is no mechanism available for your machine to learn what
  670. NetRom address it should use to reach a particular IP host.
  671. <p>
  672. So, to create an <tt>nr0</tt> device with an IP address of <tt>44.136.8.5</tt>
  673. and an mtu of <tt>512</tt> and configured with the details from the
  674. <tt>/usr/local/etc/nrports</tt> file for a NetRom port named <tt>netrom</tt>
  675. you would use:
  676.  
  677. <tscreen><verb>
  678. # /usr/local/sbin/nrattach -i 44.136.8.5 -m 512 netrom
  679. # route add 44.136.8.5 nr0
  680. </verb></tscreen>
  681.  
  682. or you could use something like the following commands manually:
  683.  
  684. <tscreen><verb>
  685. # ifconfig nr0 44.136.8.5 hw netrom VK2KTJ-1
  686. # route add 44.136.8.5 nr0
  687. </verb></tscreen>
  688.  
  689. Then for each IP host you wish to reach via NetRom you need to set route and
  690. arp entries. To reach a destination host with an IP address of
  691. <tt>44.136.80.4</tt> at NetRom address <tt>BBS:VK3BBS</tt> via a NetRom
  692. neighbour with callsign <tt>VK2SUT-0</tt> you would use commands as follows:
  693.  
  694. <tscreen><verb>
  695. # route add 44.136.80.4 nr0
  696. # arp -t netrom -s 44.136.80.4 vk2sut-0
  697. # nrparms -nodes vk3bbs + BBS 120 6 sl0 vk2sut-0
  698. </verb></tscreen>
  699.  
  700. The `<tt>120</tt>' and `<tt>6</tt>' arguments to the <em>nrparms</em> command
  701. are the NetRom <em>quality</em> and <em>obsolescence count</em> values for the
  702. route.
  703.  
  704. <sect><heading>Configuring an Ethernet device for AX.25 ala BPQ
  705.  
  706. <p>
  707. Linux support BPQ Ethernet compatibility. This enables you to run the AX.25
  708. protocol over your Ethernet LAN and to interwork your linux machine with
  709. other BPQ machines on the LAN.
  710. <p>
  711. Configuration is quite straightforward. You firstly must have configured
  712. a standard Ethernet device. This means you will have compiled your kernel
  713. to support your Ethernet card, and executed configuration commands similar
  714. to the following:
  715.  
  716. <tscreen><verb>
  717. # ifconfig eth0 44.136.8.5 netmask 255.255.255.248 up
  718. # ifconfig eth0 broadcast 44.136.8.103
  719. # route add -net 44.136.8.96 netmask 255.255.255.248 eth0
  720. </verb></tscreen>
  721.  
  722. To configure the BPQ support you need to associate an AX.25 callsign with your
  723. Ethernet hardware address. You should use the following:
  724.  
  725. <tscreen><verb>
  726. # axparms -dev eth0 vk2ktj-9
  727. </verb></tscreen>
  728.  
  729. This says that AX.25 callsign <tt>vk2ktj-9</tt> is associated with
  730. the <tt>eth0</tt> device.
  731.  
  732. BPQ Ethernet normally uses a multicast address. The Linux implementation does
  733. not, and instead it uses the normal Ethernet broadcast address. The NET.CFG
  734. file for the BPQ ODI driver should therefore look similar to this:
  735.  
  736. <tscreen><verb>
  737. LINK SUPPORT
  738.  
  739.         MAX STACKS 1
  740.         MAX BOARDS 1
  741.  
  742. LINK DRIVER E2000                    ; or other MLID to suit your card
  743.  
  744.         INT 10                       ;
  745.         PORT 300                     ; to suit your card
  746.  
  747.         FRAME ETHERNET_II
  748.  
  749.         PROTOCOL BPQ 8FF ETHERNET_II ; required for BPQ - can change PID
  750.  
  751. BPQPARMS                             ; optional - only needed if you want
  752.                                      ; to override the default target addr
  753.  
  754.         ETH_ADDR  FF:FF:FF:FF:FF:FF  ; Target address
  755. </verb></tscreen>
  756.  
  757.  
  758. <sect><heading>Ottawa PI/PI2 card driver and Gracilis PacketTwin driver.
  759.  
  760. <p>
  761. The Ottawa PI and the Gracilis PacketTwin are Z8530 SCC based card for IBM PC
  762. type machines that are in common usage by Amateur Radio operators worldwide.
  763. The PI card supports a high speed half duplex (single DMA channel) port, and a
  764. low speed (<9k6bps interrupt driven) half duplex port. The PI2 is a new
  765. version of the card that supports an on board radio modem and improved
  766. hardware design. The PacketTwin card supports two high speed port and is
  767. capable of accepting on board modems.
  768. <p>
  769. The PI card driver was written by
  770. <tt>David Perry, <dp@hydra.carleton.edu></tt>
  771. The PacketTwin card driver was written by
  772. <tt>Craig Small VK2XLZ, <csmall@triode.apana.org.au></tt>.
  773. Both drivers are a standard feature of the 1.3.xx kernel.
  774. <p>
  775. Please refer to the AX.25 section above for details on how to configure
  776. the kernel to include the PI card or the PacketTwin card drivers.
  777. <p>
  778. Once you have the appropriate driver configured into your kernel then you
  779. should reboot and when you do, you should see mention of the PI or PacketTwin
  780. card driver in the messages that appear on the screen while the kernel is
  781. booting. The drivers test each of the I/O port addresses that the card might
  782. be configured for and reports any that it finds. You should then look at the
  783. <tt>/proc/net/dev</tt> file and you should see reference to devices called
  784. <tt>pi0a</tt> and <tt>pi0b</tt> or <tt>pt0a</tt> and <tt>pt0b</tt> for the
  785. PI and PacketTwin cards respectively.
  786. <p>
  787. If the devices don't appear then recheck that you have configured and compiled
  788. your kernel correctly and that you are in fact actually running your new
  789. kernel. If you still don't then this suggests that your PI or PacketTwin card
  790. was not detected by the kernel while it booted and may indicate that you have
  791. some sort of hardware conflicting with your PI/PT card that prevented it being
  792. detected.
  793. <p>
  794. If all of the above went as planned then you will need to configure your PI/PT
  795. card with an AX.25 address and for IP. The configuration of the PI/PT cards is
  796. virtually identical to that of any other IP interface. Something like the
  797. following should work ok for you:
  798.  
  799. <tscreen><verb>
  800. # /usr/local/sbin/axparms -setcall pi0a VK2KTJ-2
  801. # /sbin/ifconfig pi0a 44.136.8.5
  802. # /sbin/ifconfig pi0a netmask 255.255.255.0
  803. # /sbin/ifconfig pi0a broadcast 44.136.8.255
  804. # /sbin/ifconfig pi0a arp mtu 256 up
  805. # /sbin/route add -net 44.136.8.0 pi0a
  806. # /sbin/route add default pi0a
  807. </verb></tscreen>
  808.  
  809. Note that <tt>pi0a</tt> refers to the `a' port on the first PI card found, and
  810. that <tt>pi0b</tt> would therefore refer to the `b' port on the first PI card
  811. found. <tt>pt0a</tt> would therefore be the first port on the first
  812. PacketTwin card detected.
  813. <p>
  814. Note also the use of the <em>axparms -setcall</em> command to set the
  815. AX.25 callsign of the port.
  816. <p>
  817. As usual, when this has been done you can test the interface with the
  818. <em>ping</em> or telnet command to ensure it is working.
  819.  
  820. <sect><heading>Z8530 SCC Kiss Emulation
  821.  
  822. <p>
  823. Joerg Reuter, DL1BKE has developed generic support for Z8530 SCC based cards.
  824. His driver is configurable to support a range of different types of cards
  825. and present an interface that looks like a KISS TNC so you can treat it as
  826. though it were a KISS TNC.
  827.  
  828. <sect1><heading>Obtaining and building the configuration tool package.
  829.  
  830. <p>
  831. The kernel driver is included in the standard kernel distribution, but there
  832. are a suite of configuration tools that you will need to obtain as well.
  833. <p>
  834. To compile the kernel support you must be sure to answer `<tt>Y</tt>' to:
  835. `<tt>Z8530 SCC kiss emulation driver for AX.25</tt>' when asked during a
  836. kernel `<tt>make config</tt>'.
  837. <p>
  838. You can obtain the configuration tools package from:
  839.  
  840. <bf>ftp.ucsd.edu</bf>
  841. <tscreen><verb>
  842. /hamradio/packet/tcpip/incoming/z8530drv-2.0.dl1bke.real.tar.gz
  843. </verb></tscreen>
  844.  
  845. <p>
  846. The following command were what I used to compile and install the package
  847. for kernel version 1.3.93:
  848. <tscreen><verb>
  849. # cd /usr/src
  850. # gzip -dc z8530drv-2.0.dl1bke.real.tar.gz | tar xvpofz -
  851. # cd z8530drv
  852. # rm gencfg sccinit sccstat
  853. # make dep
  854. # make utils
  855. # make install
  856. </verb></tscreen>
  857.  
  858. Note: I've not followed the instructions included because the version of
  859. driver in the 2.0.0 kernel is actually newer than that included in the
  860. package and the normal installation process would have overwritten the
  861. new kernel source with the older version.
  862. <p>
  863. After the above is complete you should have three new programs installed
  864. in your <tt>/sbin</tt> directory: <em>gencfg</em>, <em>sccinit</em> and
  865. <em>sccstat</em>. It is these programs that you will use to configure the
  866. driver for your card.
  867. <p>
  868. You will also have a group of new special device files created in your
  869. <tt>/dev</tt> called <tt>scc0</tt> .. <tt>scc7</tt>. These will be used
  870. later and will be the `KISS' devices you will end up using.
  871.  
  872. <sect1><heading>Configuring the driver for your card.
  873.  
  874. <p>
  875. The z8530 SCC driver has been designed to be as flexible as possible so as
  876. to support as many different types of cards as possible. With this flexibility
  877. has come some cost in configuration.
  878. <p>
  879. There is more comprehensive documentation in the package and you should
  880. read this if you have any problems. You should particularly look at
  881. <tt>doc/scc_eng.doc</tt> or <tt>doc/scc_ger.doc</tt> for more detailed
  882. information. I've paraphrased the important details, but as a result there
  883. is a lot of lower level detail that I have not included.
  884. <p>
  885. The main configuration file is read by the <em>sccinit</em> program and is
  886. called <tt>/etc/z8530drv.rc</tt>. This file is broken into two main stages:
  887. Configuration of the hardware parameters and channel configuration. After
  888. you have configured this file you need only add:
  889.  
  890. <tscreen><verb>
  891. # sccinit
  892. </verb></tscreen>
  893.  
  894. into the <tt>rc</tt> file that configures your network and the driver will
  895. be initialised according to the contents of the configuration file. You must
  896. do this before you attempt to use the driver.
  897.  
  898.  
  899. <sect2><heading>Configuration of the hardware parameters.
  900.  
  901. <p>
  902. The first section is broken into stanzas, each stanza representing an 8530
  903. chip. Each stanza is a list of keywords with arguments. You may specify up
  904. to four SCC chips in this file by default. The <tt>#define MAXSCC 4</tt> in
  905. <tt>scc.c</tt> can be increased if you require support for more.
  906. <p>
  907. The allowable keywords and arguments are:
  908.  
  909. <descrip>
  910. <tag>chip</tag>the <tt>chip</tt> keyword is used to separate stanzas. It will
  911. take anything as an argument. The arguments are not used.
  912. <tag>data_a</tag>this keyword is used to specify the address of the data
  913. port for the z8530 channel `A'. The argument is a hexadecimal number
  914. e.g. 0x300
  915. <tag>ctrl_a</tag>this keyword is used to specify the address of the control
  916. port for the z8530 channel `A'. The arguments is a hexadecimal number
  917. e.g. 0x304
  918. <tag>data_b</tag>this keyword is used to specify the address of the data
  919. port for the z8530 channel `B'. The argument is a hexadecimal number
  920. e.g. 0x301
  921. <tag>ctrl_b</tag>this keyword is used to specify the address of the control
  922. port for the z8530 channel `B'. The arguments is a hexadecimal number
  923. e.g. 0x305
  924. <tag>irq</tag>this keyword is used to specify the IRQ used by the 8530 SCC
  925. described in this stanza. The argument is an integer e.g. 5
  926. <tag>pclock</tag>this keyword is used to specify the frequency of the clock
  927. at the PCLK pin of the 8530. The argument is an integer frequency in Hz which
  928. defaults to 4915200 if the keyword is not supplied.
  929. <tag>board</tag>the type of board supporting this 8530 SCC. The argument is
  930. a character string. The allowed values are:
  931. <descrip>
  932. <tag>PA0HZP</tag>the PA0HZP SCC Card
  933. <tag>EAGLE</tag>the Eagle card
  934. <tag>PC100</tag>the DRSI PC100 SCC card
  935. <tag>PRIMUS</tag>the PRIMUS-PC (DG9BL) card
  936. <tag>BAYCOM</tag>BayCom (U)SCC card
  937. </descrip>
  938. <tag>escc</tag>this keyword is optional and is used to enable support for the
  939. Extended SCC chips (ESCC) such as the 8580, 85180, or the 85280. The argument
  940. is a character string with allowed values of `yes' or `no'. The default is
  941. `no'.
  942. <tag>vector</tag>this keyword is optional and specifies the address of the
  943. vector latch (also known as "intack port") for PA0HZP cards. There can be only
  944. one vector latch for all chips. The default is 0.
  945. <tag>special</tag>this keyword is optional and specifies the address of the
  946. special function register on several cards. The default is 0.
  947. <tag>option</tag>this keyword is optional and defaults to 0.
  948. </descrip>
  949.  
  950. Some example configurations for the more popular cards are as follows:
  951.  
  952. <descrip>
  953. <tag>BayCom USCC</tag><tscreen><verb>
  954. chip    1
  955. data_a  0x300
  956. ctrl_a  0x304
  957. data_b  0x301
  958. ctrl_b  0x305
  959. irq     5
  960. board   BAYCOM
  961. #
  962. # SCC chip 2
  963. #
  964. chip    2
  965. data_a  0x302
  966. ctrl_a  0x306
  967. data_b  0x303
  968. ctrl_b  0x307
  969. board   BAYCOM
  970. </verb></tscreen>
  971. <tag>PA0HZP SCC card</tag><tscreen><verb>
  972. chip 1
  973. data_a 0x153
  974. data_b 0x151
  975. ctrl_a 0x152
  976. ctrl_b 0x150
  977. irq 9
  978. pclock 4915200
  979. board PA0HZP
  980. vector 0x168
  981. escc no
  982. #
  983. #
  984. #
  985. chip 2
  986. data_a 0x157
  987. data_b 0x155
  988. ctrl_a 0x156
  989. ctrl_b 0x154
  990. irq 9
  991. pclock 4915200
  992. board PA0HZP
  993. vector 0x168
  994. escc no
  995. </verb></tscreen>
  996. <tag>DRSI SCC card</tag><tscreen><verb>
  997. chip 1
  998. data_a 0x303
  999. data_b 0x301
  1000. ctrl_a 0x302
  1001. ctrl_b 0x300
  1002. irq 7
  1003. pclock 4915200
  1004. board DRSI
  1005. escc no
  1006. </verb></tscreen>
  1007. </descrip>
  1008.  
  1009. If you already have a working configuration for your card under NOS, then
  1010. you can use the <em>gencfg</em> command to convert the PE1CHL NOS driver
  1011. commands into a form suitable for use in the z8530 driver configuration
  1012. file.
  1013. <p>
  1014. To use <em>gencfg</em> you simply invoke it with the same parameters as you
  1015. used for the PE1CHL driver in NET/NOS. For example:
  1016. <tscreen><verb>
  1017. # gencfg 2 0x150 4 2 0 1 0x168 9 4915200
  1018. </verb></tscreen>
  1019. will generate a skeleton configuration for the OptoSCC card.
  1020.  
  1021. <sect2><heading>Channel Configuration
  1022.  
  1023. <p>
  1024. The Channel Configuration section is where you specify all of the other
  1025. parameters associated with the port you are configuring. Again this
  1026. section is broken into stanzas. One stanza represents one logical port, and
  1027. therefore there would be two of these for each one of the hardware parameters
  1028. stanzas as each 8530 SCC supports two ports.
  1029. <p>
  1030. These keywords and arguments are also written to the <tt>/etc/z8530drv.rc</tt>
  1031. file and must appear <bf>after</bf> the hardware parameters section.
  1032. <p>
  1033. Sequence is very important in this section, but if you stick with the suggested
  1034. sequence it should work ok. The keywords and arguments are:
  1035. <descrip>
  1036. <tag>device</tag>this keyword must be the first line of a port definition and
  1037. specifies the name of the special device file that the rest of the
  1038. configuration applies to. e.g. <tt>/dev/scc0</tt>
  1039. <tag>speed</tag>this keyword specifies the speed in bits per second of the
  1040. interface. The argument is an integer: e.g. <tt>1200</tt>
  1041. <tag>clock</tag>this keyword specifies where the clock for the data will
  1042. be sourced. Allowable values are:
  1043.     <descrip>
  1044.     <tag>dpll</tag>normal halfduplex operation
  1045.     <tag>external</tag>MODEM supplies its own Rx/Tx clock
  1046.     <tag>divider</tag>use fullduplex divider if installed.
  1047.     </descrip>
  1048. <tag>mode</tag>this keyword specifies the data coding to be used. Allowable
  1049. arguments are: <tt>nrzi</tt> or <tt>nrz</tt>
  1050. <tag>rxbuffers</tag>this keyword specifies the number of receive buffers to
  1051. allocate memory for. The argument is an integer, e.g. 8.
  1052. <tag>txbuffers</tag>this keyword specifies the number of transmit buffers to
  1053. allocate memory for. The argument is an integer, e.g. 8.
  1054. <tag>bufsize</tag>this keyword specifies the size of the receive and transmit
  1055. buffers. The arguments is in bytes and represents the total length of the
  1056. frame, so it must also take into account the AX.25 headers and not just the
  1057. length of the data field. This keyword is optional and default to <tt>384</tt>
  1058. <tag>txdelay</tag>the KISS transmit delay value, the argument is an integer in mS.
  1059. <tag>persist</tag>the KISS persist value, the argument is an integer.
  1060. <tag>slot</tag>the KISS slot time value, the argument is an integer in mS.
  1061. <tag>tail</tag>the KISS transmit tail value, the argument is an integer in mS.
  1062. <tag>fulldup</tag>the KISS full duplex flag, the argument is an integer.
  1063. <tt>1</tt>==Full Duplex, <tt>0</tt>==Half Duplex.
  1064. <tag>wait</tag>the KISS wait value, the argument is an integer in mS.
  1065. <tag>min</tag>the KISS min value, the argument is an integer in S.
  1066. <tag>maxkey</tag>the KISS maximum keyup time, the argument is an integer in S.
  1067. <tag>idle</tag>the KISS idle timer value, the argument is an integer in S.
  1068. <tag>maxdef</tag>the KISS maxdef value, the argument is an integer.
  1069. <tag>group</tag>the KISS group value, the argument is an integer.
  1070. <tag>txoff</tag>the KISS txoff value, the argument is an integer in mS.
  1071. <tag>softdcd</tag>the KISS softdcd value, the argument is an integer.
  1072. <tag>slip</tag>the KISS slip flag, the argument is an integer.
  1073. </descrip>
  1074.  
  1075. <sect1><heading>Using the driver.
  1076.  
  1077. <p>
  1078. To use the driver you simply treat the <tt>/dev/scc*</tt> devices just as
  1079. you would a serial tty device with a KISS TNC connected to it. For example,
  1080. to configure Linux Kernel networking to use your SCC card you could use
  1081. something like:
  1082. <tscreen><verb>
  1083. # axattach -s 4800 /dev/scc0 VK2KTJ
  1084. </verb></tscreen>
  1085.  
  1086. You can also use NOS to attach to it in precisely the same way. From JNOS
  1087. for example you would use something like:
  1088.  
  1089. <tscreen><verb>
  1090. attach asy scc0 0 ax25 scc0 256 256 4800
  1091. </verb></tscreen>
  1092.  
  1093. <sect1><heading>The <em>sccstat</em> and <em>sccparam</em> tools.
  1094.  
  1095. <p>
  1096. To assist in the diagnosis of problems you can use the <em>sccstat</em>
  1097. program to display the current configuration of an SCC device. To use it
  1098. try:
  1099.  
  1100. <tscreen><verb>
  1101. # sccstat /dev/scc0
  1102. </verb></tscreen>
  1103.  
  1104. you will displayed a very large amount of information relating to the
  1105. configuration and health of the <tt>/dev/scc0</tt> SCC port.
  1106.  
  1107. <p>
  1108. The <em>sccparam</em> command allows you to change or modify a configuration
  1109. after you have booted. Its syntax is very similar to the NOS <tt>param</tt>
  1110. command, so to set the <tt>txtail</tt> setting of a device to 100mS you
  1111. would use:
  1112.  
  1113. <tscreen><verb>
  1114. # sccparam /dev/scc0 txtail 0x8
  1115. </verb></tscreen>
  1116.  
  1117. <sect><heading>Configuring an interface for a Baycom modem.
  1118.  
  1119. <p>
  1120. Thomas Sailer, <tt><sailer@ife.ee.ethz.ch></tt>, despite the popularly
  1121. held belief that it would not work very well, has developed Linux support for
  1122. Baycom modems. His driver supports the <tt>Ser12</tt> serial port,
  1123. <tt>Par96</tt> and the enhanced <tt>Par97</tt> parallel port modems.
  1124. <p>
  1125. When the driver is running it follows the standard of looking like a KISS
  1126. interface, so you treat it in much the same way as you would the PI card,
  1127. PacketTwin or SCC driver ports.
  1128.  
  1129. <sect1><heading>Compiling the kernel
  1130.  
  1131. <p>
  1132. The driver is only available as a module, so you must have compiled module
  1133. support into your kernel, and also selected the appopriate options to support
  1134. the Baycom driver during the <tt>make config</tt> stage when compiling your
  1135. kernel.
  1136. <p>
  1137. The relevant options that you must answer `<tt>Y</tt>' for are:
  1138. <tscreen><verb>
  1139. Radio network interfaces (CONFIG_NET_RADIO) [N/y/?]
  1140. BAYCOM ser12 and par96 kiss emulation driver for AX.25 (CONFIG_BAYCOM) [N/y/m/?]
  1141. </verb></tscreen>
  1142.  
  1143. <sect1><heading>Creating the <tt>/dev</tt> device files.
  1144.  
  1145. <p>
  1146. The Baycom driver uses special device files in the <tt>/dev</tt> directory.
  1147. You need to create these manually. The following commands should work ok
  1148. for you:
  1149. <tscreen><verb>
  1150. # mknod /dev/bc0 c 60 0
  1151. # mknod /dev/bc1 c 60 1
  1152. # mknod /dev/bc2 c 60 2
  1153. # mknod /dev/bc3 c 60 3
  1154. </verb></tscreen>
  1155. You will use these later.
  1156.  
  1157. <sect1><heading>Loading the module.
  1158.  
  1159. <p>
  1160. When the kernel compilation is complete and you have installed the module
  1161. <tt>baycom.o</tt> wherever you normally keep your modules (conventionally
  1162. they are stored in <tt>/lib/modules/2.0.0/</tt>), you must start the module.
  1163. The module takes configuration paramters from the <em>insmod</em> command
  1164. line, so you must start it manually from an <em>rc</em> file or if you use
  1165. the <em>kerneld</em> program you must configure it with the relevant paramters
  1166. so that it supplies them when it loads the module.
  1167. <p>
  1168. If you use <em>kerneld</em> you will need to add the following line to your
  1169. <tt>/etc/conf.modules</tt> file:
  1170. <tscreen><verb>
  1171. alias char-major-60 baycom
  1172. </verb></tscreen>
  1173. <p>
  1174. There are four main items to specify when loading the module, they are:
  1175. <descrip>
  1176. <tag>modem</tag>the baycom modem type you are configuring it for.
  1177.     <enum>
  1178.     <item>Ser12 type modem.
  1179.     <item>Par96 or Par97 type modem.
  1180.     </enum>
  1181. <tag>iobase</tag>the i/o address of the serial or parallel port you will use.
  1182.     <descrip>
  1183.     <tag>0x3f8</tag>COM1:
  1184.     <tag>0x2f8</tag>COM2:
  1185.     <tag>0x378</tag>LPT1:
  1186.     <tag>0x278</tag>LPT2:
  1187.     </descrip>
  1188. <tag>irq</tag>the Interrupt Request (IRQ) line your port will use.
  1189.     <descrip>
  1190.     <tag>4</tag>COM1:
  1191.     <tag>3</tag>COM2:
  1192.     <tag>7</tag>LPT1:
  1193.     <tag>5</tag>LPT2:
  1194.     </descrip>
  1195. <tag>options</tag>some baycom specific options.
  1196.     <descrip>
  1197.     <tag>0</tag>use hardware generated DCD signal.
  1198.     <tag>1</tag>use software DCD signal.
  1199.     </descrip>
  1200. </descrip>
  1201.  
  1202. <sect1><heading>A small trap to be aware of.
  1203.  
  1204. <p>
  1205. Because the Baycom driver uses the serial and parallel ports of your machines,
  1206. and because it is a low level driver for these, it competes with the existing
  1207. serial and parallel drivers in the kernel. There are some ways of working
  1208. around this problem. The first way is to make sure that you load the Baycom
  1209. module first so that it takes the hardware it needs before the serial or
  1210. parallel device driver modules load and search for their own. With the serial
  1211. driver you have the luxury of being able to disable it for a single port
  1212. using the <em>setserial</em> command, this will be demonstrated in the
  1213. examples. If you are using the parallel port modems then beware of the
  1214. <tt>lp.o</tt> Line Printer and <tt>plip.o</tt> Parallel Line IP modules.
  1215.  
  1216. <sect1><heading>Some example configurations.
  1217.  
  1218. <p>
  1219. These examples are for the two most common configurations.
  1220. <p>
  1221. Disable the serial driver for COM1: then configure the Baycom driver for a
  1222. Ser12 serial port modem on COM1: with the software DCD option enabled:
  1223. <tscreen><verb>
  1224. # setserial /dev/ttyS0 uart none
  1225. # insmod baycom modem=1 iobase=0x3f8 irq=4 options=1
  1226. </verb></tscreen>
  1227.  
  1228. Par96 parallel port type modem on LPT1: using hardware DCD detection:
  1229. <tscreen><verb>
  1230. # insmod baycom modem=2 iobase=0x378 irq=7 options=0
  1231. </verb></tscreen>
  1232.  
  1233. The first device created is <tt>/dev/bc0</tt>, the second is <tt>/dev/bc1</tt>
  1234. etc.
  1235.  
  1236. <sect1><heading>Configuring multiple devices.
  1237.  
  1238. <p>
  1239. Using the <em>insmod</em> program and its command line arguments you can only
  1240. configure one Baycom modem. There is a <em>setbaycom</em> utility which I have
  1241. not yet located that will allow you to configure others. If you happen to find
  1242. it please let me know where it is kept so that I can include details for it
  1243. here.
  1244.  
  1245. <sect1><heading>Actually using the devices.
  1246.  
  1247. <p>
  1248. This device driver when loaded looks like a serial tty driver with a KISS
  1249. TNC attached. This means that configuration of the AX.25 software for this
  1250. driver is identical to the configuration for a KISS TNC presented earlier.
  1251. You need to use the <em>axattach</em> program and add the port to your
  1252. <tt>/usr/local/etc/axports</tt> file. The only difference is that you would
  1253. use the device <tt>/dev/bc0</tt> instead of <tt>/dev/ttyS0</tt>.
  1254.  
  1255. <sect><heading>Configuring <em>ax25d</em> to accept incoming AX.25/Netrom connections.
  1256.  
  1257. <p>
  1258. Linux is a powerful operating system and offers a great deal of flexibility
  1259. in how it is configured. With this flexibility comes a cost in configuring
  1260. it to do what you want. When configuring your Linux machine to accept incoming
  1261. AX.25 or NetRom connections there are a number of questions you need to ask
  1262. yourself. The most important of which is: "What do I want users to see when
  1263. they connect?". As detailed in the HAM-HOWTO there are BBS systems that are
  1264. being developed that you might want users to see when they connect,
  1265. alternatively you might want to give users a login prompt so that they can
  1266. make use of a shell account, or you might even have written your own program,
  1267. such as a customised database or a game, that you want people to connect to.
  1268. Whatever you choose, you must tell the AX.25 software about this so that it
  1269. knows what software to run when it accepts an incoming AX.25 connection.
  1270.  
  1271. <sect1><heading>Creating the <tt>/usr/local/etc/ax25d.conf</tt> file.
  1272.  
  1273. <p>
  1274. This file is the configuration file for the <em>ax25d</em> AX.25 daemon which
  1275. handles incoming AX.25 and NetRom connections.
  1276. <p>
  1277. The file is a little cryptic looking at first, but you'll soon discover
  1278. it is very simple in practice, with a small trap for you to be wary of.
  1279. <p>
  1280. The format of the <tt>ax25d.conf</tt> file is as follows:
  1281.  
  1282. <tscreen><verb>
  1283. # This is a comment and is ignored by the ax25d program.
  1284. [<interface_call>]
  1285. <peer1>  window T1 T2 T3 N2 <mode> <uid> <cmd> <cmd-name> <arguments>
  1286. <peer2>  window T1 T2 T3 N2 <mode> <uid> <cmd> <cmd-name> <arguments>
  1287. defaults window T1 T2 T3 N2 <mode> <uid> <cmd> <cmd-name> <arguments>
  1288. <peer3>  window T1 T2 T3 N2 <mode> <uid> <cmd> <cmd-name> <arguments>
  1289. ...
  1290. default  window T1 T2 T3 N2 <mode> <uid> <cmd> <cmd-name> <arguments>
  1291. </verb></tscreen>
  1292.  
  1293. Where:
  1294. <descrip>
  1295. <tag>#</tag>at the start of a line marks a comment and is completely ignored
  1296. by the <em>ax25d</em> program.
  1297. <tag><interface_call></tag>is the AX.25 callsign of the AX.25 or
  1298. NetRom interface that this particular paragraph is for.
  1299. <tag><peer></tag>is the callsign of the peer node that this particular
  1300. configuration applies to. If you don't specify an SSID here then any SSID will
  1301. match.
  1302. <tag>window</tag>is the AX.25 Window parameter (K) or MAXFRAME parameter for
  1303. this configuration.
  1304. <tag>T1</tag>is the Frame retransmission (T1) timer in half second units.
  1305. <tag>T2</tag>is the amount of time the AX.25 software will wait for another
  1306. incoming frame before preparing a response in 1 second units.
  1307. <tag>T3</tag>is the amount of time of inactivity before the AX.25 software
  1308. will disconnect the session in 1 second units.
  1309. <tag>N2</tag>is the number of consecutive retransmissions that will occur
  1310. before the connection is closed.
  1311. <tag><mode></tag>provides a mechanism for determining certain types of
  1312. general permissions. The modes are enabled or disabled by setting or resetting
  1313. bits in an 8 bit map. You set that map by setting <mode> to the sum of
  1314. the following values:
  1315. <descrip>
  1316. <tag>1</tag>Setup utmp, and run on a ptty (planned).
  1317. <tag>2</tag>UNUSED.
  1318. <tag>4</tag>UNUSED.
  1319. <tag>8</tag>UNUSED.
  1320. <tag>16</tag>UNUSED.
  1321. <tag>32</tag>UNUSED.
  1322. <tag>64</tag>Disallow digipeated uplinks, only allow direct connections.
  1323. <tag>128</tag>Lockout, Barred, immediate disconnect.
  1324. </descrip>
  1325. <tag><uid></tag>is the userid that the program to be run to support the
  1326. connection should be run as.
  1327. <tag><cmd></tag>is the full pathname of the command to be run, with no arguments specified.
  1328. <tag><cmd-name></tag>is the text that should appear in a <em>ps</em> as the
  1329. command name running (normally the same as <cmd> except without the
  1330. directory path information.
  1331. <tag><arguments></tag>are the command line argument to be passed to the
  1332. <:cmd> when it is run. You pass useful information into these arguments
  1333. by use of the following tokens:
  1334. <descrip>
  1335. <tag>%U</tag>AX.25 callsign of the connected party without the SSID, in
  1336. uppercase.
  1337. <tag>%u</tag>AX.25 callsign of the connected party without the SSID, in
  1338. lowercase.
  1339. <tag>%S</tag>AX.25 callsign of the connected party with the SSID, in
  1340. uppercase.
  1341. <tag>%s</tag>AX.25 callsign of the connected party with the SSID, in
  1342. lowercase.
  1343. </descrip>
  1344. </descrip>
  1345.  
  1346. You need one section in the above format for each AX.25 or NetRom interface
  1347. you want to accept incoming AX.25 or NetRom connections on.
  1348.  
  1349. There are two special lines in the paragraph, one starts with the string
  1350. `<tt>defaults</tt>' and other starts with the string `<tt>default</tt>'
  1351. (yes there is a difference). These lines serve special functions.
  1352.  
  1353. The `<tt>default</tt>' lines purpose should be obvious, this line acts as a
  1354. catch-all, so that any incoming connection on the <interface_call>
  1355. interface that doesn't have a specific rule will match the `<tt>default</tt>'
  1356. rule. If you don't have a `<tt>default</tt>' rule, then any connections not
  1357. matching any specific rule will be disconnected immediately without notice.
  1358.  
  1359. The `<tt>defaults</tt>' line is a little more subtle, and here is the trap
  1360. I mentioned earlier. In any of the fields for any definition for a peer you
  1361. can use the `*' character to say `use the default value'. The
  1362. `<tt>default</tt>' line is what sets those default values. The kernel software
  1363. itself has some defaults which will be used if you don't specify any. The trap
  1364. is that the these defaults apply <bf>only</bf> to those rules <bf>below</bf>
  1365. the `<tt>default</tt>' line not to those above. You may have more than one
  1366. `<tt>default</tt>' rule per interface definition, and in this way you may
  1367. create groups of default configurations.
  1368.  
  1369. <sect1><heading>A simple example <tt>ax25d.conf</tt> file.
  1370.  
  1371. <p>
  1372. Ok, an illustrative example:
  1373.  
  1374. <tscreen><verb>
  1375. # ax25d.conf for VK2KTJ - 21/11/95
  1376. # This configuration uses the AX.25 port defined earlier.
  1377. [VK2KTJ-1]
  1378. NOCALL     *     *  *  *  *   0    guest /usr/games/fortune
  1379. defaults   1    10  *  *  *   0    root  /usr/local/sbin/axspawn axspawn %u +
  1380. VK2XLZ-1   *     *  *  *  *   *      *     *         *
  1381. VK2DAY-1   *     *  *  *  *   *      *     *         *
  1382. default    1    10  5 100 5   0    root  /usr/local/bin/pms pms -a -o vk2ktj
  1383. #
  1384. </verb></tscreen>
  1385.  
  1386. This example says that anybody connecting to the interface on my machine with
  1387. the callsign <tt>VK2KTJ-1</tt> will have the following rules applied:
  1388.  
  1389. Anyone whose callsign is set to `NOCALL' should use the kernel default
  1390. parameters and have the <em>fortune</em> program run as <tt>guest</tt> for
  1391. them.
  1392.  
  1393. The <tt>defaults</tt> line changes two parameters from the kernel defaults
  1394. (Window and T1) and will run the <em>/usr/local/sbin/axspawn</em> program for
  1395. them. Any copies of <em>/usr/local/sbin/axspawn</em> run this way will appear
  1396. as <em>axspawn</em> in a <em>ps</em> listing for convenience. The next two
  1397. lines definitions for two stations who will receive those permissions.
  1398.  
  1399. The last line in the paragraph is the `catch all' definition that everybody
  1400. else will get (including VK2XLZ and VK2DAY using any other SSID other than -1).
  1401. This definition sets all of the parameters implicitly and will cause the
  1402. <em>pms</em> program to be run with a command line argument indicating that
  1403. it is being run for an AX.25 connection (assuming <tt>VK2KTJ-1</tt> to be an
  1404. AX.25 interface) and that the owner callsign is <tt>VK2KTJ</tt>. (See the
  1405. `Configuring the PMS' section below for more details).
  1406. <p>
  1407. If you wanted to define rules for another interface, a NetRom interface for
  1408. example, then you would add another paragraph coded in the same way with rules
  1409. and callsign appropriate to it.
  1410. <p>
  1411. This example is a contrived one but I think it illustrates clearly the
  1412. important features of the syntax of the configuration file. Jonathon includes
  1413. a much longer and more detailed example in the <tt>ax25-utils</tt> package that
  1414. you should look at if you need more information.
  1415.  
  1416. <sect1><heading>Starting <em>ax25d</em>
  1417.  
  1418. <p>
  1419. When you have the two configuration files completed you start <em>ax25d</em>
  1420. with the command:
  1421.  
  1422. <tscreen><verb>
  1423. # /usr/local/sbin/ax25d
  1424. </verb></tscreen>
  1425.  
  1426. When this is run people should be able to make AX.25 connections to your
  1427. Linux machine. Remember to put the <tt>ax25d</tt> command in your <em>rc</em>
  1428. files so that it is started automatically when you reboot each time.
  1429.  
  1430. <sect1><heading>Configuring <em>axspawn</em>.
  1431.  
  1432. <p>
  1433. The <em>axspawn</em> program is a simple program that allows AX.25 stations
  1434. who connect to be log in to your machine. It is invoked from the <em>ax25d</em>
  1435. program as described above. To allow a user to log in to your machine you
  1436. should add a line similar to the following into your
  1437. <tt>/usr/local/etc/ax25d.conf</tt> file:
  1438. <tscreen><verb>
  1439. default * * * * * 1 root /usr/local/sbin/axspawn axspawn %u
  1440. </verb></tscreen>
  1441. If the line ends in the <tt>+</tt> character then the connecting user must
  1442. hit return before they will be allowed to login. The default is to not wait.
  1443. Any individual host configurations that follow this line will have the
  1444. <em>axspawn</em> program run when they connect. When <em>axspawn</em> is
  1445. run it first checks that the command line argument it is supplied is a legal
  1446. callsign, strips the SSID, then it checks that <tt>/etc/passwd</tt> file to
  1447. see if that user has an account configured. If there is an account, and the
  1448. password is either <tt>""</tt> (null) or <tt>+</tt> then the user is logged
  1449. in, if there is anything in the password field the user is prompted to enter
  1450. a password. If there is not an existing account in the <tt>/etc/passwd</tt>
  1451. file then <em>axspawn</em> may be configured to automatically create one.
  1452.  
  1453. <sect2><heading>Creating the <tt>/usr/local/etc/axspawn.conf</tt> file.
  1454.  
  1455. <p>
  1456. You can alter the behaviour of <em>axspawn</em> in various ways by use of
  1457. the <tt>/usr/local/etc/axspawn.conf</tt> file. This file is formatted as
  1458. follows:
  1459. <tscreen><verb>
  1460. # /usr/local/etc/axspawn.conf
  1461. #
  1462. # allow automatic creation of user accounts
  1463. create    yes
  1464. #
  1465. # guest user if above is 'no' or everything else fails. Disable with "no"
  1466. guest     no
  1467. #
  1468. # group id or name for autoaccount
  1469. group     ax25
  1470. #
  1471. # first user id to use
  1472. first_uid 2001
  1473. #
  1474. # maximum user id
  1475. max_uid   3000
  1476. #
  1477. # where to add the home directory for the new users
  1478. home      /home/ax25
  1479. #
  1480. # user shell
  1481. shell     /bin/bash
  1482. #
  1483. # bind user id to callsign for outgoing connects.
  1484. associate yes
  1485. </verb></tscreen>
  1486.  
  1487. The eight configurable characteristics of <em>axspawn</em> are as follows:
  1488.  
  1489. <descrip>
  1490. <tag>#</tag>indicates a comment.
  1491. <tag>create</tag>if this field is set to <tt>yes</tt> then <em>axspawn</em>
  1492. will attempt to automatically create a user account for any user who connects
  1493. and does not already have an entry in the <tt>/etc/passwd</tt> file.
  1494. <tag>guest</tag>this field names the login name of the account that will
  1495. be used for people who connect who do not already have accounts if
  1496. <em>create</em> is set to <tt>no</tt>. This is usually <tt>ax25</tt> or
  1497. <tt>guest</tt>.
  1498. <tag>group</tag>this field names the group name that will be used for any
  1499. users who connect and do not already have an entry in the <tt>/etc/passwd</tt>
  1500. file.
  1501. <tag>first_uid</tag>this is the number of the first userid that will be
  1502. automatically created for new users.
  1503. <tag>max_uid</tag>this is the maximum number that will be used for the userid
  1504. of new users.
  1505. <tag>home</tag>this is the home (login) directory of new users.
  1506. <tag>shell</tag>this is the login shell of any new users.
  1507. <tag>associate</tag>this flag indicates whether outgoing AX.25 connections
  1508. made by this user after they login will use their own callsign, or your
  1509. stations callsign.
  1510. </descrip>
  1511.  
  1512. <sect1><heading>Configuring the <em>pms</em>
  1513.  
  1514. <p>
  1515. The <em>pms</em> program is an implementation of a simple personal message
  1516. system. It was originally written by Alan Cox. Dave Brown, N2RJT,
  1517. <tt><dcb@vectorbd.com></tt> has taken on further development of it.
  1518. At present it is still very simple, supporting only the ability to send
  1519. mail to the owner of the system and to obtain some limited system information
  1520. but Dave is working to expand its capability to make it more useful.
  1521. <p>
  1522. Configuring the <em>pms</em> program is still a little clumsy at the moment
  1523. because it is new but bare with it while Dave works on it. The only difficult
  1524. part is modifying the source code to support your local mail delivery agent
  1525. and whether you use the <em>ttylinkd</em> program or the <em>talk-ax25</em>
  1526. program.
  1527. <p>
  1528. After that is done there are a couple of simple files that you should create
  1529. that give users some information about the system and then you need to add
  1530. appropriate entries into the <tt>ax25d.conf</tt> file so that connected users
  1531. are presented with the PMS.
  1532. <p>
  1533. <sect2><heading>Customising <tt>pms.c</tt>
  1534.  
  1535. <p>
  1536. If you take a look at the <tt>pms.c</tt> file in the <tt>ax25-utils</tt>
  1537. package you will see that there a few items that you can configure.
  1538. Perhaps the most important to configure is the one that allows you to specify
  1539. what local mail delivery agent you use. In most installations the
  1540. <em>deliver</em> program may well work, but in the minimal installation on
  1541. my gateway machine I needed to modify the line that previously said:
  1542. <verb>
  1543. #define MAIL_DELIVERY_AGENT     "deliver %s"
  1544. </verb>
  1545. to:
  1546. <verb>
  1547. #define MAIL_DELIVERY_AGENT     "/bin/mail.local %s"
  1548. </verb>
  1549.  
  1550. There is no easy way of knowing what local delivery agent your machine is
  1551. configured to use, so perhaps you could simply look for either of these files
  1552. in the obvious places and choose whichever seems to be there.
  1553. <p>
  1554. I also have the <em>ttylinkd</em> program installed, so I needed to modify
  1555. the section relating to it. I keep my copy of the <em>ttylinkd</em> program in
  1556. my <tt>/usr/sbin</tt> directory, so I modified the line that previously said:
  1557.  
  1558. <verb>
  1559. /* #define MY_TALK              "/usr/local/sbin/ttylinkd" */
  1560. </verb>
  1561. to:
  1562. <verb>
  1563. #define MY_TALK              "/usr/sbin/ttylinkd"
  1564. </verb>
  1565. <p>
  1566. If you use the <em>talk-ax25</em> program then you would remove the <tt>/*</tt>
  1567. and <tt>*/</tt> from around that line instead.
  1568. <p>
  1569. There is one last definition that might be useful to you, and that is if you
  1570. have a default email gateway. This line is the line containing the string
  1571. <tt>MY_GATEWAY</tt>. If you have an email gateway that you use, then you should
  1572. remove the comments from this line and change the address to that of your
  1573. gateway.
  1574.  
  1575. <sect2><heading>Create the <tt>/usr/local/pms/motd</tt> file.
  1576.  
  1577. <p>
  1578. The <tt>/usr/local/pms/motd</tt> file contains the `message of the day' that
  1579. users will be presented with after they connect and receive the usual BBS
  1580. id header. The file is a simple text file, any text you include in this file
  1581. will be sent to users.
  1582.  
  1583. <sect2><heading>Create the <tt>/usr/local/pms/info</tt> file.
  1584.  
  1585. <p>
  1586. The <tt>/usr/local/pms/info</tt> file is also a simple text file in which
  1587. you would put more detailed information about your station or configuration.
  1588. This file is presented to users in response to their issuing of the
  1589. <tt>Info</tt> command from the <tt>PMS></tt> prompt.
  1590.  
  1591. <sect2><heading>Associate AX.25 callsigns with system users.
  1592.  
  1593. <p>
  1594. When a connected user sends mail to an AX.25 callsign, the <em>pms</em> expects
  1595. that callsign to be mapped, or associated with a real system user on your
  1596. machine.
  1597. <p>
  1598. You make this association with the <em>axparms</em> command. An example looks
  1599. like:
  1600. <tscreen><verb>
  1601. # axparms -assoc vk2ktj terry
  1602. </verb></tscreen>
  1603.  
  1604. This command associates that AX.25 callsign <tt>vk2ktj</tt> with the user
  1605. <tt>terry</tt> on the machine, so any mail for <tt>vk2ktj</tt> on the
  1606. <em>pms</em> will be sent to <tt>terry</tt>.
  1607. <p>
  1608. Remember to put these associations into your <em>rc</em> file so that they
  1609. are available each time your reboot.
  1610.  
  1611. <sect2><heading>Add the PMS to the <tt>/usr/local/etc/ax25d.conf</tt> file.
  1612.  
  1613. <p>
  1614. Adding the <em>pms</em> to your <tt>ax25d.conf</tt> file is very simple.
  1615. There is one small thing you need to think about though. Dave has added command
  1616. line arguments to the PMS to allow it to handle a number of different text
  1617. end-of-line conventions. AX.25 and NetRom by convention expect the end-of-line
  1618. to be <em>carriage return, linefeed</em> while the standard unix end-of-line is
  1619. just <em>newline</em>. So, for example, if you wanted to add an entry that
  1620. meant that the default action for a connection received on an AX.25 port is
  1621. to start the PMS then you would add a line that looked something like:
  1622.  
  1623. <tscreen><verb>
  1624. default  1  10 5 100 5   0    root  /usr/local/bin/pms pms -a -o vk2ktj
  1625. </verb></tscreen>
  1626.  
  1627. This simply runs the <em>pms</em> program, telling it that it is an AX.25
  1628. connection it is connected to and that the PMS owner is <tt>vk2ktj</tt>.
  1629. Check the <em>man</em> page for what you should specify for other connection
  1630. methods.
  1631.  
  1632. <sect2><heading>Test the PMS.
  1633.  
  1634. <p>
  1635. To test the PMS, you can try the following command from the command line:
  1636. <verb>
  1637. # /usr/local/bin/pms -u vk2ktj -o vk2ktj
  1638. </verb>
  1639. Substitute your own callsign for mine and this will run the pms, telling it
  1640. that it is to use the unix end-of-line convention, and that user logging in
  1641. is <tt>vk2ktj</tt>. You can do all the things connected users can.
  1642. <p>
  1643. Additionally you might try getting some other node to connect to you to
  1644. confirm that your <tt>ax25d.conf</tt> configuration works.
  1645.  
  1646. <sect><heading>HOWTO link NOS and the Linux kernel networking software
  1647.  
  1648. <p>
  1649. Many people like to run some version of NOS under Linux because it has
  1650. all of the features and facilities they are used to. Most of those people
  1651. would also like to have the NOS running on their machine capable of talking
  1652. to the Linux kernel so that they can offer some of the linux capabilities
  1653. to radio users.
  1654.  
  1655. <sect1><heading>Linking NOS and Linux using a pipe device
  1656.  
  1657. <p>
  1658. Brandon S. Allbery, KF8NH, contributed the following information to explain
  1659. how to interconnect the NOS running on a Linux machine with the kernel
  1660. code using the Linux pipe device.
  1661. <p>
  1662. Since both Linux and NOS support the slip protocol it is possible to link
  1663. the two together by creating a slip link. You could do this by using two
  1664. serial ports with a loopback cable between them, but this would be slow
  1665. and costly. Linux provides a feature that many other Unix-like operating
  1666. systems provide called `pipes'. These are special pseudo devices that
  1667. look like a standard tty device to software but in fact loopback to another
  1668. pipe device. To use these pipes the first program must open the <bf>master</bf>
  1669. end of the pipe, and the open then the second program can open the
  1670. <bf>slave</bf> end of the pipe. When both ends are open the programs can
  1671. communicate with each other simply by writing characters to the pipes in the
  1672. way they would if they were terminal devices.
  1673. <p>
  1674. To use this feature to connect the Linux Kernel and a copy of NOS, or some
  1675. other program you first must choose a pipe device to use. You can find one
  1676. by looking in your <tt>/dev</tt> directory. The master end of the pipes are
  1677. named: <tt>ptyp[1-f]</tt> and the slave end of the pipes are known as:
  1678. <tt>ttyp[1-f]</tt>. Remember they come in pairs, so if you select
  1679. <tt>/dev/ptypf</tt> as your master end then you must use <tt>/dev/ttypf</tt>
  1680. as the slave end.
  1681. <p>
  1682. Once you have chosen a pipe device pair to use you should allocate the master
  1683. end to you linux kernel and the slave end to the NOS program, as the Linux
  1684. kernel starts first and the master end of the pipe must be opened first.
  1685. You must also remember that your Linux kernel must have a different IP address
  1686. to your NOS, so you will need to allocate a unique address for it if you
  1687. haven't already.
  1688. <p>
  1689. You configure the pipe just as if it were a serial device, so to create
  1690. the slip link from your linux kernel you can use commands similar to the
  1691. following:
  1692. <p>
  1693. <tscreen><verb>
  1694. # /sbin/slattach -s 38400 -p slip /dev/ptypf &
  1695. # /sbin/ifconfig sl0 broadcast 44.255.255.255 pointopoint 44.70.248.67 /
  1696.     mtu 1536 44.70.4.88
  1697. # /sbin/route add 44.70.248.67 sl0
  1698. # /sbin/route add -net 44.0.0.0 gw 44.70.248.67
  1699. </verb></tscreen>
  1700. <p>
  1701. In this example the Linux kernel has been given IP address <tt>44.70.4.88</tt>
  1702. and the NOS program is using IP address <tt>44.70.248.67</tt>. The
  1703. <em>route</em> command in the last line simply tells your linux kernel to route
  1704. all datagrams for the amprnet via the slip link created by the
  1705. <em>slattach</em> command. Normally you would put these commands into your
  1706. <tt>/etc/rc.d/rc.inet2</tt> file after all your other network configuration
  1707. is complete so that the slip link is created automatically when you reboot.
  1708. Note: there is no advantage in using <em>cslip</em> instead of <em>slip</em>
  1709. as it actually reduces performance because the link is only a virtual
  1710. one and occurs fast enough that having to compress the headers first takes
  1711. longer than transmitting the uncompressed datagram.
  1712. <p>
  1713. To configure the NOS end of the link you could try the following:
  1714. <p>
  1715. <tscreen><verb>
  1716. # you can call the interface anything you want; I use "linux" for convenience.
  1717. attach asy ttypf - slip linux 1024 1024 38400
  1718. route addprivate 44.70.4.88 linux
  1719. </verb></tscreen>
  1720. <p>
  1721. These commands will create a slip port named `linux' via the slave end of
  1722. the pipe device pair to your linux kernel, and a route to it to make it
  1723. work. When you have started NOS you should be able to ping and telnet to
  1724. your NOS from your Linux machine and vice versa. If not, double check that
  1725. you have made no mistakes especially that you have the addresses configured
  1726. properly and have the pipe devices around the right way.
  1727.  
  1728. <sect><heading>Some sample configurations.
  1729.  
  1730. <p>
  1731. Following are examples of the most common types of configurations. These
  1732. are guides only as there are as many ways of configuring your network as there
  1733. are networks to configure, but they may give you a start.
  1734.  
  1735. <sect1><heading>Small Ethernet LAN with Linux as a router to Radio LAN
  1736.  
  1737. <p>
  1738. Many of you may have small local area networks at home and want to
  1739. connect the machines on that network to your local radio LAN. This is
  1740. the type of configuration I use at home. I arranged to have a suitable
  1741. block of addresses allocated to me that I could capture in a single route
  1742. for convenience and I use these on my Ethernet LAN. Your local IP coordinator
  1743. will assist you in doing this if you want to try it as well. The addresses
  1744. for the Ethernet LAN form a subset of the radio LAN addresses. The following
  1745. configuration is the actual one for my linux router on my network at home:
  1746.  
  1747. <tscreen><verb>
  1748.                                           .      .   .    .    . .
  1749.   ---                                .
  1750.    | Network       /---------\     .    Network
  1751.    | 44.136.8.96/29|         |    .     44.136.8/24        \ | /
  1752.    |               | Linux   |   .                          \|/
  1753.    |               |         |  .                            |
  1754.    |          eth0 | Router  |  .  /-----\    /----------\   |
  1755.    |---------------|         |-----| TNC |----| Radio    |---/
  1756.    |   44.136.8.97 |  and    |  .  \-----/    \----------/
  1757.    |               |         | sl0
  1758.    |               | Server  | 44.136.8.5
  1759.    |               |         |    .
  1760.    |               |         |     .
  1761.    |               \_________/       .
  1762.   ---                                     .      .   .    .    . .
  1763. </verb></tscreen>
  1764. <tscreen><verb>
  1765. #!/bin/sh
  1766. # /etc/rc.net
  1767. # This configuration provides one KISS based AX.25 port and one
  1768. # Ethernet device.
  1769.  
  1770. echo "/etc/rc.net"
  1771. echo "  Configuring:"
  1772.  
  1773. echo -n "    loopback:"
  1774. /sbin/ifconfig lo 127.0.0.1
  1775. /sbin/route add 127.0.0.1
  1776. echo " done."
  1777.  
  1778. echo -n "    ethernet:"
  1779. /sbin/ifconfig eth0 44.136.8.97 netmask 255.255.255.248 \
  1780.         broadcast 44.136.8.103 up
  1781. /sbin/route add 44.136.8.97 eth0
  1782. /sbin/route add -net 44.136.8.96 netmask 255.255.255.248 eth0
  1783. echo " done."
  1784.  
  1785. echo -n "    AX.25: "
  1786. axattach -i 44.136.8.5 -m 512 /dev/ttyS1 4800
  1787. ifconfig sl0 netmask 255.255.255.0 broadcast 44.136.8.255
  1788. route add -host 44.136.8.5 sl0
  1789. route add -net 44.136.8.0 window 1024 sl0
  1790.  
  1791. echo -n "    Netrom: "
  1792. nrattach -i 44.136.8.5 netrom
  1793.  
  1794. echo "  Routing:"
  1795. /sbin/route add default gw 44.136.8.68 window 1024 sl0
  1796. echo "    default route."
  1797. echo done.
  1798.  
  1799. # end
  1800. </verb></tscreen>
  1801.  
  1802. <tt>/usr/local/etc/axports</tt>
  1803. <tscreen><verb>
  1804. # name  callsign        speed   paclen  window  description
  1805. 4800    VK2KTJ-0        4800    256     2       144.800 MHz
  1806. </verb></tscreen>
  1807.  
  1808. <tt>/usr/local/etc/nrports</tt>
  1809. <tscreen><verb>
  1810. # name  callsign        alias   paclen  description
  1811. netrom  VK2KTJ-1        LINUX   235     Linux Switch Port
  1812. </verb></tscreen>
  1813.  
  1814. <tt>/usr/local/etc/nrbroadcast</tt>
  1815. <tscreen><verb>
  1816. # ax25_name     min_obs def_qual        worst_qual      verbose
  1817. 4800            1       120             10              1
  1818. </verb></tscreen>
  1819.  
  1820. <itemize>
  1821. <item>You must have IP_FORWARDING enabled in your kernel.
  1822. <item>The AX.25 configuration files are pretty much those used as examples
  1823. in the earlier sections, refer to those where necessary.
  1824. <item>I've chosen to use an IP address for my radio port that is not within
  1825. my home network block. I needn't have done so, I could have easily used
  1826. <tt>44.136.8.97</tt> for that port too.
  1827. <item><tt>44.136.8.68</tt> is my local IPIP encapsulated gateway and hence
  1828. is where I point my default route.
  1829. <item>Each of the machines on my Ethernet network have a route:
  1830. <tscreen><verb>
  1831. route add -net 44.0.0.0 gw 44.136.8.97 window 512 mss 512 eth0
  1832. </verb></tscreen>
  1833. The use of the <em>mss</em> and <em>window</em> parameters means that I can
  1834. get optimum performance from both local Ethernet and radio based connections.
  1835. <item>I also run my sendmail, http, ftp and other daemons on the router machine
  1836. so that it needs to be the only machine to provide others with facilities.
  1837. <item>The router machine is a lowly 386DX20 with a 20Mb harddrive and a very
  1838. minimal linux configuration.
  1839. </itemize>
  1840.  
  1841. <sect1><heading>IPIP encapsulated gateway configuration.
  1842.  
  1843. <p>
  1844. Linux is now very commonly used for tcp/ip encapsulated gateways around
  1845. the world. The new tunnel driver supports multiple encapsulated routes
  1846. and makes the older <em>ipip</em> daemon obsolete.
  1847. <p>
  1848. A typical configuration would look similar to the following.
  1849.  
  1850. <tscreen><verb>
  1851.                                           .      .   .    .    . .
  1852.   ---                                .
  1853.    | Network       /---------\     .    Network
  1854.    | 154.27.3/24   |         |    .     44.136.16/24       \ | /
  1855.    |               | Linux   |   .                          \|/
  1856.    |               |         |  .                            |
  1857.    |          eth0 | IPIP    |  .  /-----\    /----------\   |
  1858. ---|---------------|         |-----| TNC |----| Radio    |---/
  1859.    |   154.27.3.20 | Gateway |  .  \-----/    \----------/
  1860.    |               |         | sl0
  1861.    |               |         | 44.136.16.1
  1862.    |               |         |    .
  1863.    |               |         |     .
  1864.    |               \_________/       .
  1865.   ---                                     .      .   .    .    . .
  1866. </verb></tscreen>
  1867.  
  1868. The configuration files of interest are:
  1869.  
  1870. <tscreen><verb>
  1871. # /etc/rc.net
  1872. # This file is a simple configuration that provides one KISS AX.25
  1873. # radio port, one Ethernet device, and utilises the kernel tunnel driver
  1874. # to perform the IPIP encapsulation/decapsulation
  1875. #
  1876. echo "/etc/rc.net"
  1877. echo "  Configuring:"
  1878. #
  1879. echo -n "    loopback:"
  1880. /sbin/ifconfig lo 127.0.0.1
  1881. /sbin/route add 127.0.0.1
  1882. echo " done."
  1883. #
  1884. echo -n "    ethernet:"
  1885. /sbin/ifconfig eth0 154.27.3.20 netmask 255.255.255.0 \
  1886.         broadcast 154.27.3.255 up
  1887. /sbin/route add 154.27.3.20 eth0
  1888. /sbin/route add -net 154.27.3.0 netmask 255.255.255.0 eth0
  1889. echo " done."
  1890. #
  1891. echo -n "    AX.25: "
  1892. axattach -i 44.136.16.1 -m 512 /dev/ttyS1 4800
  1893. /sbin/ifconfig sl0 netmask 255.255.255.0 broadcast 44.136.16.255
  1894. /sbin/route add -host 44.136.16.1 sl0
  1895. /sbin/route add -net 44.136.16.0 netmask 255.255.255.0 window 1024 sl0
  1896. #
  1897. echo -n "    tunnel:"
  1898. /sbin/ifconfig tunl0 44.136.16.1 mtu 512 up
  1899. #
  1900. echo done.
  1901. #
  1902. echo -n "Routing ... "
  1903. source /etc/ipip.routes
  1904. echo done.
  1905. #
  1906. # end.
  1907. </verb></tscreen>
  1908.  
  1909. and:
  1910.  
  1911. <tscreen><verb>
  1912. # /etc/ipip.routes
  1913. # This file is generated using the munge script
  1914. #
  1915. /sbin/route add 44.134.8.0 netmask 255.255.255.0 tunl0 gw 134.43.26.1
  1916. /sbin/route add 44.34.9.0 netmask 255.255.255.0 tunl0 gw 174.84.6.17
  1917. /sbin/route add 44.13.28.0 netmask 255.255.255.0 tunl0 gw 212.37.126.3
  1918.    ...
  1919.    ...
  1920.    ...
  1921. </verb></tscreen>
  1922.  
  1923. <tt>/usr/local/etc/axports</tt>
  1924. <tscreen><verb>
  1925. # name  callsign        speed   paclen  window  description
  1926. 4800    VK2KTJ-0        4800    256     2       144.800 MHz
  1927. </verb></tscreen>
  1928.  
  1929. Some points to note here are:
  1930.  
  1931. <itemize>
  1932. <item>The new tunnel driver uses the <em>gw</em> field in the routing table
  1933. in place of the <em>pointopoint</em> parameter to specify the address of
  1934. the remote IPIP gateway. This is why it now supports multiple routes per
  1935. interface.
  1936. <item>You <bf>can</bf> configure two network devices with the same address.
  1937. In this example both the <tt>sl0</tt> and the <tt>tunl0</tt> devices have
  1938. been configured with the IP address of the radio port. This is done so that
  1939. the remote gateway sees the correct address from your gateway in encapsulated
  1940. datagrams sent to it.
  1941. <item>The route commands used to specify the encapsulated routes can be
  1942. automatically generated by a modified version of the <em>munge</em> script.
  1943. This is included below. The route commands would then be written to a separate
  1944. file and read in using the <em>bash</em> <tt>source /etc/ipip.routes</tt>
  1945. command (assuming you called the file with the routing commands
  1946. <tt>/etc/ipip.routes</tt>) as illustrated. The source file must be in the
  1947. NOS route command format.
  1948. <item>Note the use of the <em>window</em> argument on the <em>route</em>
  1949. command. Setting this parameter to an appropriate value improves the
  1950. performance of your radio link.
  1951. </itemize>
  1952.  
  1953. <p>
  1954. The new tunnel-munge script:
  1955.  
  1956. <tscreen><verb>
  1957. #!/bin/sh
  1958. #
  1959. # From: Ron Atkinson <n8fow@hamgate.cc.wayne.edu>
  1960. #
  1961. #  This script is basically the 'munge' script written by Bdale N3EUA
  1962. #  for the IPIP daemon and is modified by Ron Atkinson N8FOW. It's 
  1963. #  purpose is to convert a KA9Q NOS format gateways route file 
  1964. #  (usually called 'encap.txt') into a Linux routing table format
  1965. #  for the IP tunnel driver.               
  1966. #
  1967. #     Usage: Gateway file on stdin, Linux route format file on stdout.
  1968. #               eg.  tunnel-munge < encap.txt > ampr-routes
  1969. #
  1970. # NOTE: Before you use this script be sure to check or change the 
  1971. #       following items:
  1972. #
  1973. #     1) Change the 'Local routes' and 'Misc user routes' sections
  1974. #        to routes that apply to your own area (remove mine please!)
  1975. #     2) On the fgrep line be sure to change the IP address to YOUR
  1976. #        gateway Internet address. Failure to do so will cause serious
  1977. #        routing loops.
  1978. #     3) The default interface name is 'tunl0'. Make sure this is
  1979. #        correct for your system.
  1980.  
  1981. echo "#"
  1982. echo "# IP tunnel route table built by $LOGNAME on `date`"
  1983. echo "# by tunnel-munge script v960307."
  1984. echo "#"
  1985. echo "# Local routes"
  1986. echo "route add -net 44.xxx.xxx.xxx netmask 255.mmm.mmm.mmm dev sl0"
  1987. echo "#"
  1988. echo "# Misc user routes"
  1989. echo "#"
  1990. echo "# remote routes"
  1991.  
  1992. fgrep encap | grep "^route" | grep -v " XXX.XXX.XXX.XXX" | \
  1993. awk '{
  1994.     split($3, s, "/")
  1995.     split(s[1], n,".")
  1996.     if    (n[1] == "")    n[1]="0"
  1997.     if    (n[2] == "")    n[2]="0"
  1998.     if    (n[3] == "")    n[3]="0"
  1999.     if    (n[4] == "")    n[4]="0"
  2000.     if    (s[2] == "1")    mask="128.0.0.0"
  2001.     else if    (s[2] == "2")    mask="192.0.0.0"
  2002.     else if    (s[2] == "3")    mask="224.0.0.0"
  2003.     else if    (s[2] == "4")    mask="240.0.0.0"
  2004.     else if    (s[2] == "5")    mask="248.0.0.0"
  2005.     else if    (s[2] == "6")    mask="252.0.0.0"
  2006.     else if    (s[2] == "7")    mask="254.0.0.0"
  2007.     else if    (s[2] == "8")    mask="255.0.0.0"
  2008.     else if    (s[2] == "9")    mask="255.128.0.0"
  2009.     else if    (s[2] == "10")    mask="255.192.0.0"
  2010.     else if    (s[2] == "11")    mask="255.224.0.0"
  2011.     else if    (s[2] == "12")    mask="255.240.0.0"
  2012.     else if    (s[2] == "13")    mask="255.248.0.0"
  2013.     else if    (s[2] == "14")    mask="255.252.0.0"
  2014.     else if    (s[2] == "15")    mask="255.254.0.0"
  2015.     else if    (s[2] == "16")    mask="255.255.0.0"
  2016.     else if    (s[2] == "17")    mask="255.255.128.0"
  2017.     else if    (s[2] == "18")    mask="255.255.192.0"
  2018.     else if    (s[2] == "19")    mask="255.255.224.0"
  2019.     else if    (s[2] == "20")    mask="255.255.240.0"
  2020.     else if    (s[2] == "21")    mask="255.255.248.0"
  2021.     else if    (s[2] == "22")    mask="255.255.252.0"
  2022.     else if    (s[2] == "23")    mask="255.255.254.0"
  2023.     else if    (s[2] == "24")    mask="255.255.255.0"
  2024.     else if    (s[2] == "25")    mask="255.255.255.128"
  2025.     else if    (s[2] == "26")    mask="255.255.255.192"
  2026.     else if    (s[2] == "27")    mask="255.255.255.224"
  2027.     else if    (s[2] == "28")    mask="255.255.255.240"
  2028.     else if    (s[2] == "29")    mask="255.255.255.248"
  2029.     else if    (s[2] == "30")    mask="255.255.255.252"
  2030.     else if    (s[2] == "31")    mask="255.255.255.254"
  2031.     else             mask="255.255.255.255"
  2032.  
  2033. if (mask == "255.255.255.255")    
  2034.     printf "route add -host %s.%s.%s.%s gw %s dev tunl0\n"\
  2035.         ,n[1],n[2],n[3],n[4],$5
  2036. else                
  2037.     printf "route add -net %s.%s.%s.%s gw %s netmask %s dev tunl0\n"\
  2038.         ,n[1],n[2],n[3],n[4],$5,mask
  2039.  }'
  2040.  
  2041. echo "#"
  2042. echo "# default the rest of amprnet via mirrorshades.ucsd.edu"
  2043. echo "route add -net 44.0.0.0 gw 128.54.16.18 netmask 255.0.0.0 dev tunl0"
  2044. echo "#"
  2045. echo "# the end"
  2046. </verb></tscreen>
  2047.  
  2048.  
  2049. <sect><heading>Discussion relating to Amateur Radio and Linux.
  2050.  
  2051. <p>
  2052. There are various places that discussion relating to Amateur Radio and Linux
  2053. take place. They take place in the <tt>comp.os.linux.*</tt> newsgroups, they
  2054. also take place on the <tt>HAMS</tt> list on <tt>vger.rutgers.edu</tt>. Other
  2055. places where they are held include the <tt>tcp-group</tt> mailing list at
  2056. <tt>ucsd.edu</tt> (the home of amateur radio tcp/ip discussions), and you
  2057. might also try the <tt>#linpeople</tt> channel on the <tt>linuxnet</tt>
  2058. irc network.
  2059.  
  2060. To join the Linux <bf>linux-hams</bf> channel on the mail list server, send
  2061. mail to:
  2062. <tscreen><verb>
  2063. Majordomo@vger.rutgers.edu
  2064. </verb></tscreen>
  2065. with the line:
  2066. <tscreen><verb>
  2067. subscribe linux-hams 
  2068. </verb></tscreen>
  2069. in the message body. The subject line is ignored.
  2070.  
  2071. To join the <tt>tcp-group</tt> send mail to:
  2072. <tscreen><verb>
  2073. listserver@ucsd.edu
  2074. </verb></tscreen>
  2075. with the line:
  2076. <tscreen><verb>
  2077. subscribe tcp-group
  2078. </verb></tscreen>
  2079. in the body of the text.
  2080.  
  2081. <bf>Note:</bf> Please remember that the <tt>tcp-group</tt> is primarily for
  2082. discussion of the use of advanced protocols, of which tcp/ip is one, in
  2083. Amateur Radio. <em>Linux specific questions should not ordinarily go there.</em>
  2084.  
  2085. <sect><heading>Copyright.
  2086.  
  2087. <p>
  2088. The AX25-HOWTO, information on how to install and configure some of the more
  2089. important packages providing AX25 support for Linux.
  2090. Copyright (c) 1996 Terry Dawson.
  2091.  
  2092. This program is free software; you can redistribute it and/or modify it under
  2093. the terms of the GNU General Public License as published by the Free Software
  2094. Foundation; either version 2 of the License, or (at your option) any later
  2095. version.
  2096.  
  2097. This program is distributed in the hope that it will be useful, but WITHOUT
  2098. ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  2099. FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
  2100.  
  2101. You should have received a copy of the GNU General Public License along with
  2102. this program; if not, write to the:
  2103.  
  2104. Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2105.  
  2106. </article>
  2107.