| 1 | <!DOCTYPE doctype PUBLIC "-//w3c//dtd html 4.0 transitional//en"> |
| 2 | <html> |
| 3 | <head> |
| 4 | |
| 5 | <meta http-equiv="Content-Type" |
| 6 | content="text/html; charset=iso-8859-1"> |
| 7 | |
| 8 | <meta name="Author" content="David Ranch"> |
| 9 | <title>LinPac User Manual</title> |
| 10 | </head> |
| 11 | <body> |
| 12 | |
| 13 | <center> |
| 14 | <h1> LinPac - Packet Radio Terminal for Linux<br> |
| 15 | |
| 16 | <hr width="100%"></h1> |
| 17 | </center> |
| 18 | |
| 19 | <center>Version 0.28 |
| 20 | <p>(c) 2020 - 1998 by David Ranch KI6ZHD</p> |
| 21 | </center> |
| 22 | |
| 23 | <p><br> |
| 24 | </p> |
| 25 | |
| 26 | <center> |
| 27 | <h2> User manual</h2> |
| 28 | </center> |
| 29 | |
| 30 | <b>Index</b> |
| 31 | <p>1 <a href="#POS1">What is LinPac</a> </p> |
| 32 | |
| 33 | <p>2 <a href="#POS2">First configuration</a> </p> |
| 34 | |
| 35 | <p>3 <a href="#POS3">LinPac controls</a> <br> |
| 36 | 3.1 <a href="#POS3_1">Keyboard</a> <br> |
| 37 | 3.2 <a href="#POS3_2">Entering commands</a> <br> |
| 38 | 3.3 <a href="#POS3_3">Initiating a connection</a> <br> |
| 39 | 3.4 <a href="#POS3_4">Receiving and sending files</a> <br> |
| 40 | 3.5 <a href="#POS3_5">Remote commands</a> <br> |
| 41 | 3.6 <a href="#POS3_6">Character encoding</a> <br> |
| 42 | 3.7 <a href="#POS3_7">Huffman compression</a> </p> |
| 43 | |
| 44 | <p>4 <a href="#POS4">Variables</a> <br> |
| 45 | 4.1 <a href="#POS4_1">Special variables</a> </p> |
| 46 | |
| 47 | <p>5 <a href="#POS5">Station database</a> <br> |
| 48 | 5.1 <a href="#POS5_1">The station.data file format</a> <br> |
| 49 | 5.2 <a href="#POS5_2">The 'Name' command</a> <br> |
| 50 | 5.3 <a href="#POS5_3">Using the database</a> </p> |
| 51 | |
| 52 | <p>6 <a href="#POS6">About macros</a> <br> |
| 53 | 6.1 <a href="#POS6_1">Creating macros</a> <br> |
| 54 | 6.2 <a href="#POS6_2">Commands used in macros</a> <br> |
| 55 | 6.3 <a href="#POS6_3">Special system macros</a> </p> |
| 56 | |
| 57 | <p>7 <a href="#POS7">Creating new commands</a> </p> |
| 58 | |
| 59 | <p>8 <a href="#POS8">Standard applications</a> <br> |
| 60 | 8.1 <a href="#POS8_1">File transfer protocols</a> <br> |
| 61 | 8.2 <a href="#POS8_2">Automatic password generation</a> <br> |
| 62 | 8.2.1 <a href="#POS8_2_1">Login passwords</a> <br> |
| 63 | 8.2.2 <a href="#POS8_2_2">Sysop and general use passwords</a> <br> |
| 64 | 8.3 <a href="#POS8_3">Utilities for mail exchange</a> <br> |
| 65 | 8.4 <a href="#POS8_4">Mail client</a> <br> |
| 66 | 8.5 <a href="#POS8_5">Logbook</a> </p> |
| 67 | |
| 68 | <p>9 <a href="#POS9">Command line options</a> </p> |
| 69 | |
| 70 | <p>10 <a href="#POS10">Copying</a> </p> |
| 71 | |
| 72 | <p>Appendix A: <a href="#POSAppendixA">List of LinPac commands</a> </p> |
| 73 | |
| 74 | <p>Appendix B: <a href="#POSFAQ">Linpac FAQ / Questions and Answers / Getting more help</a> </p> |
| 75 | |
| 76 | <p>Appendix C: <a href="#POSErrata">Errata</a> </p> |
| 77 | |
| 78 | <p> |
| 79 | <hr> |
| 80 | <p> |
| 81 | |
| 82 | <p><a name="POS1"></a> </p> |
| 83 | |
| 84 | <h2> 1 What is LinPac</h2> |
| 85 | LinPac is a packet radio terminal for Linux that allows wide configurability |
| 86 | and easy addition of new functions and special functions needed by the user. The |
| 87 | aim is to minimize the amount of 'hard coded' functions and create a complete |
| 88 | set of applications that can be easy expanded and/or completely reconfigured. |
| 89 | <p>All functions described in this manual match the standard configuration |
| 90 | that comes with the distribution package. </p> |
| 91 | |
| 92 | <p><a name="POS2"></a> </p> |
| 93 | |
| 94 | <h2> 2 First configuration</h2> |
| 95 | When linpac is started for the first time on your computer, it automaticaly |
| 96 | creates the directory called <code>LinPac</code> in the running user's home |
| 97 | directory. This directory will contain the user's personal LinPac configuration |
| 98 | settings. After creating this directory, LinPac asks for basic callsign, port |
| 99 | and other information and prepares a useable configuration for you. An example setup |
| 100 | dialog is as shown, where we are using the bogus call "n0call" logging into |
| 101 | the local home BBS "n0ary-1": |
| 102 | <ul> |
| 103 | <pre> |
| 104 | $ linpac |
| 105 | |
| 106 | Hello dear user. You seem to run LinPac for the first time. |
| 107 | LinPac has to create a directory in your home directory for storing |
| 108 | your personal configuration. |
| 109 | |
| 110 | For creating your personal configuration please answer following questions: |
| 111 | |
| 112 | Your callsign: |
| 113 | n0call |
| 114 | |
| 115 | Enter your home BBS callsign with SSID : |
| 116 | n0ary-1 |
| 117 | |
| 118 | Enter the name of port to connect N0ARY-1 |
| 119 | d710 |
| 120 | |
| 121 | Enter the digipeaters used to connect N0ARY-1 or press enter |
| 122 | when no digipeaters are used: |
| 123 | |
| 124 | |
| 125 | Enter the full hierarchical address of N0ARY-1 |
| 126 | (e.g. #MOR.CZE.EU) |
| 127 | #NCA.CA.USA.NOAM |
| 128 | |
| 129 | Thank you, N0CALL |
| 130 | Please wait a moment for creating your personal configuration |
| 131 | Installation done. |
| 132 | Press ENTER to run LinPac |
| 133 | </pre> |
| 134 | </ul> |
| 135 | |
| 136 | <p>The above information is then stored in the <code>$HOME/LinPac/macro/init.mac</code> file as |
| 137 | various 'functions'. These functions are based on the very simple interpreted |
| 138 | language (actually it's not a language but something like the batch files in |
| 139 | DOS). In the LinPac/macro directory are all the scripts written in this |
| 140 | language. The init.mac macro is loaded at start of loading Linpac and contains |
| 141 | the commands to setup the callsigns and other settings. You can modify this file |
| 142 | to change the initial configuration of LinPac. Other macros can be run in LinPac |
| 143 | as desired or required. The simplest case of a macro is a normal text file that is |
| 144 | just printed to the screen (or sent to the remote peer) when executed. The language |
| 145 | is described in <a href="#POS6">chapter 6</a>. </p> |
| 146 | |
| 147 | <p>You may also want to review or change following macro files: </p> |
| 148 | |
| 149 | <ul> |
| 150 | <li><b>info.mac</b> - contains information about your system</li> |
| 151 | <li><b>ctext.mac</b> - executed when the peer connects and should |
| 152 | contain the greeting text</li> |
| 153 | <li><b>quit.mac</b> - called when user enters the Quit command (end |
| 154 | of connection) and should print some farewell text and disconnect</li> |
| 155 | </ul> |
| 156 | |
| 157 | <p>After this you should be able to make your first connection. |
| 158 | </p> |
| 159 | |
| 160 | <p><a name="POS3"></a> </p> |
| 161 | |
| 162 | <h2> 3 LinPac controls</h2> |
| 163 | <p>After automatically running the LinPac setup routine, the main screen should appear. |
| 164 | If you see a segmentation fault, please see <a href="https://sourceforge.net/p/linpac/bugs/24/"> |
| 165 | Linux AX.25 issues with long predictable network interface names</a> for a work around. |
| 166 | Moving on, in Linpac's main interface in the standard configuraion, the screen is divided |
| 167 | into five parts (described from the top of the screen to the bottom):</p> |
| 168 | |
| 169 | <ul> |
| 170 | <li> <b>QSO window</b>: this window contains the text that came from the |
| 171 | peer and also the sent text and some special messages (different text colours).</li> |
| 172 | <li> <b>Status line</b>: displays your callsign, current time and some |
| 173 | information about the current connection.</li> |
| 174 | <li> <b>Editor</b>: allows you to enter the text you want to send to |
| 175 | the peer or the commands you want to execute</li> |
| 176 | <li> <b>Channel list</b>: displays the list of channels with the callsign |
| 177 | of connected users. The currently selected channel is highlighted.</li> |
| 178 | <li> <b>Monitor </b>: displays the traffic on your radio ports</li> |
| 179 | |
| 180 | </ul> |
| 181 | |
| 182 | <p>LinPac is mostly driven by commands. The commands are entered using the |
| 183 | editor and must start with a colon (':') in the first column. Lines that |
| 184 | don't begin with a colon are sent to the peer, if connected.</p> |
| 185 | |
| 186 | <p>LinPac allows up to eight connections to be made simultaneously. For each connection |
| 187 | one channel is used. You can switch between channels by pressing the F1 - |
| 188 | F8 keys. Each has its own QSO window, status line and editor. The channel |
| 189 | list and the monitor are common across all the channels. </p> |
| 190 | |
| 191 | <p>There is a special channel invoked by pressing F10. This channel has no |
| 192 | QSO window and doesn't allow making a connection. The text written is sent |
| 193 | out immediately using UI frames (beacon). </p> |
| 194 | |
| 195 | <p><a name="POS3_1"></a> </p> |
| 196 | |
| 197 | <h3> 3.1 Keyboard</h3> |
| 198 | The following list contains the important shortcuts: |
| 199 | <ul> |
| 200 | <p><b><u>Global</u></b> <br> |
| 201 | <b>F1 - F8</b> : switch to channel 1 - 8 <br> |
| 202 | <b>F10</b> : switch to monitor <br> |
| 203 | <b>Alt-X</b> : end of LinPac </p> |
| 204 | |
| 205 | <p><b><u>QSO Window</u></b> <br> |
| 206 | <b>PgUp</b>, <b>PgDn</b>, <b>ctrl-R</b>, <b>ctrl-V</b> : scroll one page |
| 207 | up / down <br> |
| 208 | <b>ctrl-E</b>, <b>ctrl-X</b> : scroll one line up / down <br> |
| 209 | <b>ctrl-B</b> : skip to end of buffer </p> |
| 210 | |
| 211 | <p><b><u>Editor</u></b> <br> |
| 212 | <b>Cursor keys</b>, <b>Home</b>, <b>End</b>, <b>Backspace</b>, <b>Del</b> |
| 213 | : text editing <br> |
| 214 | <b>ctrl-Y</b> : delete current line <br> |
| 215 | <b>Enter</b> : send current line </p> |
| 216 | </ul> |
| 217 | |
| 218 | <p>Some applications (e.g. mailer) can use the whole screen. Each channel |
| 219 | can run only one such application at a time. It's possible to switch |
| 220 | to this application using <b>Alt-<<i>channel_number</i>></b> (e.g. |
| 221 | Alt-5) and switch back to terminal using <b>F1</b> - <b>F10</b>. </p> |
| 222 | |
| 223 | <p><a name="POS3_2"></a> </p> |
| 224 | |
| 225 | <h3> 3.2 Entering commands</h3> |
| 226 | Each command is invoked using its name. Some commands can be abbreviated. |
| 227 | In this manual the mandatory part is always written in upper case. The |
| 228 | remainder of the command name is optional. Some commands require some extra |
| 229 | arguments. The arguments are written after the command and are separated by |
| 230 | one or more spaces. If you want to enter an argument containing more than |
| 231 | one word, that argument must be entered in quotation marks. |
| 232 | <p>Examples:</p> |
| 233 | <p> |
| 234 | <ul> |
| 235 | <code>:color red blue</code> - calls the 'color' command with two arguments |
| 236 | - 'red' and 'blue' <br> |
| 237 | <code>:color 'light red'</code> or <br> |
| 238 | <code>:color "light red"</code> - calls the 'color' command with one argument |
| 239 | 'light red' |
| 240 | </ul> |
| 241 | </p> |
| 242 | |
| 243 | <p>Most of the commands work on the currently selected channel. If you want |
| 244 | to execute the command on some other channel, you can enter the number of |
| 245 | the channel this way. For example, to make an OUTGOING connection to destination |
| 246 | OK0PAB on Linpac channel 5:</p> |
| 247 | |
| 248 | <p> |
| 249 | <ul> |
| 250 | <code>:connect@5 OK0PAB</code> |
| 251 | </ul> |
| 252 | </p> |
| 253 | |
| 254 | <p>In this case the 'connect' command is executed on channel 5. </p> |
| 255 | |
| 256 | <p>The complete list of commands with descriptions is available in Appendix |
| 257 | A. </p> |
| 258 | |
| 259 | <p><a name="POS3_3"></a> </p> |
| 260 | |
| 261 | <h3> 3.3 Initiating a connection</h3> |
| 262 | To initiate a connection the <code>:Connect </code>command is used. Just |
| 263 | switch to the channel you want to use by pressing <b>F1</b> - <b>F8 </b>and |
| 264 | enter the following command: |
| 265 | <p><code>:connect <i>CALLSIGN</i></code> </p> |
| 266 | |
| 267 | <p>Replace the <i>CALLSIGN</i> with the real callsign of the station you want |
| 268 | to connect. The command can be abbreviated to the first letter only. Example: |
| 269 | </p> |
| 270 | |
| 271 | <p><code>:c OK0PAB</code> </p> |
| 272 | |
| 273 | <p>This command will initiate the connecting sequence to OK0PAB. To close |
| 274 | the connection, you can use the <code>:Disconnect</code> command by entering<br> |
| 275 | </p> |
| 276 | <p><code>:d<br> |
| 277 | </code></p> |
| 278 | <p> When your system has multiple radio ports, you can specify its name |
| 279 | before the callsign like this: </p> |
| 280 | |
| 281 | <p><code>:c 2:OK0PAB</code> </p> |
| 282 | |
| 283 | <p>This command will try to connect OK0PAB via port 2. When no port name is |
| 284 | specified, the default one is used. Initially the default port is |
| 285 | the first port in <code>/etc/axports</code> (your system AX.25 port configuration |
| 286 | file). If you want to change the default port, just use the command <code>:port</code>. |
| 287 | </p> |
| 288 | |
| 289 | <p><code>:port 2</code> </p> |
| 290 | |
| 291 | <p>This will change the default port name to '2'. In some cases it is useful |
| 292 | to set another default port for some selected channels. For this the variable |
| 293 | <code>CHN_PORT</code> can be used (see <a href="#POS4">chapter 4</a>). When set, |
| 294 | the content of this variable overrides the default port selection for |
| 295 | the particular channel. For example, when you set the variable for channel |
| 296 | 4 using<br> |
| 297 | </p> |
| 298 | <p><code>:set CHN_PORT@4 1<br> |
| 299 | </code></p> |
| 300 | <p>the port '1' will be used as the default one for the channel 4. For other |
| 301 | channels, the previously set default port will be used.<br> |
| 302 | </p> |
| 303 | |
| 304 | <p><a name="POS3_4"></a> </p> |
| 305 | |
| 306 | <h3> 3.4 Receiving and sending files</h3> |
| 307 | The standard distribution can receive files using plain text or binary |
| 308 | transfer and using file transfer protocols YAPP and Autobin. LinPac will |
| 309 | automaticaly start to receive the file when the peer begins to send using |
| 310 | the YAPP or Autobin protocols. The 7+ files are automaticaly saved too. When |
| 311 | you want to save the incoming text you have to use the command |
| 312 | <p><code>:Write <<i>filename</i>></code> </p> |
| 313 | |
| 314 | <p>The incoming text will be saved until you stop the saving using </p> |
| 315 | |
| 316 | <p><code>:Write off</code> </p> |
| 317 | |
| 318 | <p>For receiving a plain binary file, the corresponding command <code>:WBin</code> |
| 319 | can be used. This way of transferring binary files is not recommended; use |
| 320 | the autobin or yapp protocol instead. </p> |
| 321 | |
| 322 | <p>The following commands are available for sending files: </p> |
| 323 | |
| 324 | <p> |
| 325 | <ul> |
| 326 | <code>:rprg <<i>filename</i>></code> - sends the file using the Autobin |
| 327 | protocol <br> |
| 328 | <code>:yput <<i>filename</i>></code> - sends the file using the YAPP |
| 329 | protocol <br> |
| 330 | <code>:rbin <<i>filename</i>></code> - sends the binary file (no protocol |
| 331 | - not recommended) <br> |
| 332 | <code>:read <<i>filename</i>></code> - semds the text file </p> |
| 333 | </ul> |
| 334 | </p> |
| 335 | |
| 336 | <p><a name="POS3_5"></a> </p> |
| 337 | |
| 338 | <h3> 3.5 Remote commands</h3> |
| 339 | LinPac allows the remote user to enter commands. For remote control, |
| 340 | all LinPac commands are available but there can be (and should be) some restrictions |
| 341 | for each user. |
| 342 | <p>The remote command must start with the <code>//</code> sequence. For example |
| 343 | if some connected user sends you the text '<code>//info</code>' your terminal |
| 344 | will send back the station information. </p> |
| 345 | |
| 346 | <p>The remote commands can be disabled using the command <code>:remote off</code> |
| 347 | and enabled by <code>:remote on</code>. You can also specify that only some commands |
| 348 | be available for remote users. The default list of available remote commands |
| 349 | is defined in the <b>init.mac</b> file (the DEF_RCMD line). It is also |
| 350 | possible to enable various commands for each user. This is described |
| 351 | in <a href="#POS5">chapter 5</a>. </p> |
| 352 | |
| 353 | <p><a name="POS3_6"></a> </p> |
| 354 | |
| 355 | <h3> 3.6 Character encoding</h3> |
| 356 | Some countries use different national character encodings |
| 357 | for some historical reasons. A user who has his Linux console configured |
| 358 | for example for some of the standard ISO encodings may be incompatible with another |
| 359 | one using a traditional encoding. To solve this LinPac allows the translation |
| 360 | of the input and output of each channel using a translation table. The translation |
| 361 | tables are stored in files <code>*.ctt</code> in the LinPac home directory. |
| 362 | |
| 363 | <p>All known encodings must be defined in the file called <code>encodings</code> |
| 364 | in the LinPac home directory. This file contains a single line for each encoding |
| 365 | that specifies its <i>alias</i> (name which will identify the encoding in |
| 366 | LinPac), <i>encoding name</i> (an official name such as iso-8859-1) and optionally |
| 367 | the name of the <i>translation table file</i> to be used (without the extension |
| 368 | <code>.ctt</code>). </p> |
| 369 | |
| 370 | <p>Note that LinPac does <em>not</em> support multi-byte encodings such as UTF-8 |
| 371 | or other Unicode encodings.</p> |
| 372 | |
| 373 | <p>The current encoding can be switched using the <b>:TRanslate</b> command separately |
| 374 | for each channel. To specify the default encoding for each user you can |
| 375 | add the line </p> |
| 376 | |
| 377 | <p><code>ENC=<alias></code> </p> |
| 378 | |
| 379 | <p>to the appropriate record in the station database. (The station database is described |
| 380 | in <a href="#POS5">chapter 5</a>.) When no encoding is specified for the |
| 381 | user, the default one is used. The default encoding alias is stored in the |
| 382 | DEF_ENC@0 variable which is set in the macro init.mac. </p> |
| 383 | |
| 384 | <p>When the conversion table is not specified in the encodings file LinPac |
| 385 | only changes the name of currently used encoding but doesn't provide any |
| 386 | conversion. However some applications (such as QLinPac which works in unicode) |
| 387 | are able to do their own conversions. </p> |
| 388 | |
| 389 | <p><a name="POS3_7"></a> </p> |
| 390 | |
| 391 | <h3> 3.7 Huffman compression</h3> |
| 392 | Some packet radio terminals and BBS software allows the compression of |
| 393 | transferred text. When switched on, the sender does the compression of all |
| 394 | data before sending them to the other station and the recipient has to decompress |
| 395 | the data after receiving them. This makes the communication more reliable |
| 396 | and reduces the load of the radio link. |
| 397 | <p>The line compression in LinPac is activated using the <code>:comp</code> command. |
| 398 | The compression is switched on using <code>:comp on</code> and switched off |
| 399 | using <code>:comp off</code>. To ensure that the compression is activated or |
| 400 | deactivated on both ends of the link simultaneously LinPac sends the remote |
| 401 | command <code>:comp 1</code> or <code>:comp 0</code> to the other station automatically. |
| 402 | The arguments 1 and 0 have the same effect as <code>on</code> and <code>off,</code> |
| 403 | but they don't cause sending any command to the other station. </p> |
| 404 | |
| 405 | <p>In the case in which the remote system doesn't support the <code>:comp</code> command |
| 406 | it's necessary to switch on the compression on the remote system manually |
| 407 | and then use the<code>:comp 1</code> command in LinPac. </p> |
| 408 | |
| 409 | <p><a name="POS4"></a> </p> |
| 410 | |
| 411 | <h2> 4 Variables</h2> |
| 412 | <p>Each channel has its own set of variables. Some of the variables are used |
| 413 | to store the configuration data. The user can create and remove variables |
| 414 | and change the values of existing variables using following commands:</p> |
| 415 | |
| 416 | <p><ul> |
| 417 | <code>:set <<i>variable</i>> <<i>value</i>></code> - sets the |
| 418 | value of the variable. If the variable doesn't exist, a new one is created. |
| 419 | <br> |
| 420 | <code>:get <<i>variable</i>></code> - prints the value of the variable |
| 421 | <br> |
| 422 | <code>:unset <<i>variable</i>></code> - removes the variable </p> |
| 423 | </ul> |
| 424 | </p> |
| 425 | |
| 426 | <p>Some examples:</p> |
| 427 | <p> |
| 428 | <ul> |
| 429 | <code>:set NAME John</code> <br> |
| 430 | <code>:set WHOLE_NAME 'John Big'</code> <br> |
| 431 | <code>:get NAME</code> <br> |
| 432 | <code>:unset NAME</code> |
| 433 | </ul> |
| 434 | </p> |
| 435 | |
| 436 | <p>The name of the variable can contain the specification of the channel. |
| 437 | For example the variable <code>NAME@5</code> is the variable '<code>NAME</code>' |
| 438 | defined on channel 5. </p> |
| 439 | |
| 440 | <p>When LinPac finds the character '<code>%</code>' followed by the name of variable, |
| 441 | it automatically replaces this text with the value of the variable. Considering the |
| 442 | previous example, the text <code>%NAME</code> will be replaced with John. </p> |
| 443 | |
| 444 | <p><a name="POS4_1"></a> </p> |
| 445 | |
| 446 | <h3> 4.1 Special variables</h3> |
| 447 | There are some special internal variables that don't allow changing their |
| 448 | value. Their value is set and changed directly by LinPac and these variables |
| 449 | can be used to add some actual information to the text. The list follows: |
| 450 | |
| 451 | <p> |
| 452 | <ul> |
| 453 | <code>%V</code> - LinPac version (e.g. 0.26) <br> |
| 454 | <code>%C</code> - The callsign of connected station <br> |
| 455 | <code>%N</code> - The name of connected station (when known), else replaced |
| 456 | by the contents of %U macro <br> |
| 457 | <code>%Y</code>- Channel callsign (mycall) <br> |
| 458 | <code>%K</code>- Current channel number <br> |
| 459 | <code>%T</code> - Current time <br> |
| 460 | <code>%D</code> - Current date <br> |
| 461 | <code>%B</code> - Audible bell <br> |
| 462 | <code>%Z</code> - Current time zone <br> |
| 463 | <code>%U</code> - The text used when the name is unknown. This can contain |
| 464 | other macros (typicaly %C). <br> |
| 465 | <code>%P</code>- The port number <br> |
| 466 | <code>%M</code>- The number of connected users <br> |
| 467 | <code>%A</code>- The time since the last operator activity <br> |
| 468 | <code>%_</code>- End of line (CR) <br> |
| 469 | <code>%<</code>- Contents of the last line received, this is cleared by |
| 470 | reading <br> |
| 471 | <code>%#<i>number</i></code> - Replaced by a character with an ASCII value |
| 472 | <number> (e.g. %#27 means ESC) <br> |
| 473 | <code>%(<i>command</i>)</code> - Replaced by the command result. <br> |
| 474 | <code>%[<i>expression</i>]</code> - Replaced by the result of mathematical |
| 475 | expression |
| 476 | </ul> |
| 477 | </p> |
| 478 | |
| 479 | <p>Variables for use in macros only: </p> |
| 480 | |
| 481 | <p> |
| 482 | <ul> |
| 483 | <code>%R</code> - the number of macro arguments (up to 9) <br> |
| 484 | <code>%0</code> - the name of the macro <br> |
| 485 | <code>%1</code> - <code>%9</code> - macro arguments |
| 486 | </ul> |
| 487 | </p> |
| 488 | |
| 489 | <p>For example try to write following text in the editor and press enter: |
| 490 | </p> |
| 491 | |
| 492 | <p><code>The time is %T and the date is %D.</code> </p> |
| 493 | |
| 494 | <p><a name="POS5"></a> </p> |
| 495 | |
| 496 | <h2> 5 Station database</h2> |
| 497 | The station database holds various information about known stations. All |
| 498 | the information is stored in the '<code>station.data</code>' file and can be |
| 499 | changed using the normal text editor or using the LinPac :<code>Name </code>command. |
| 500 | |
| 501 | <p><a name="POS5_1"></a> </p> |
| 502 | |
| 503 | <h3> 5.1 The station.data file format</h3> |
| 504 | The information about each station is written in a paragraph starting |
| 505 | with the station callsign in square brackets. Each line in the paragraph |
| 506 | contains one definition like: |
| 507 | <p><code><item_name>=<value></code> </p> |
| 508 | |
| 509 | <p>A typical station information paragraph might look like this: </p> |
| 510 | |
| 511 | <p> |
| 512 | <ul> |
| 513 | <code>[OK0NMA]</code> <br> |
| 514 | <code>NAME=PC/FlexNet Brno</code> <br> |
| 515 | <code>TYPE=FLEXNET</code> <br> |
| 516 | <code>LOC=JN89HE</code> <br> |
| 517 | <code>QRG=144.8125 MHz</code> <br> |
| 518 | <code>SYSNUM=85946</code> |
| 519 | </ul> |
| 520 | </p> |
| 521 | |
| 522 | <p>There are no mandatory items; the user can add various items depending |
| 523 | on what information he wants to store. The current LinPac distribution uses following |
| 524 | item names for standard information: </p> |
| 525 | |
| 526 | <p> |
| 527 | <ul> |
| 528 | <b>NAME</b> - Text information about the station, or the operator's name. |
| 529 | LinPac shows this information when connected to that station. LOC - QRA |
| 530 | locator of the station. Shown after connect too. </p> |
| 531 | |
| 532 | <p><b>TYPE</b> - The type of the station. For standard stations the types |
| 533 | FLEXNET, THENET, FBB, BAYBOX, DIEBOX, TNOS, JNOS, DXC and TERM for user terminals |
| 534 | are recomended, but you can add any other type. </p> |
| 535 | |
| 536 | <p><b>LANG</b> - The language to communicate with the station. This is currently |
| 537 | supported by macros only. When this item is set, LinPac will try to |
| 538 | find the macro in the directory <code>macro/<LANG>/</code>. </p> |
| 539 | |
| 540 | <p><b>NICKNAME</b> - The nickname of the operator. </p> |
| 541 | </ul> |
| 542 | |
| 543 | <p>The standard LinPac configuration also uses these item names: </p> |
| 544 | |
| 545 | <p> |
| 546 | <ul> |
| 547 | <b>TERM</b> - What type of terminal is used. If '<code>ansi</code>' is set, |
| 548 | LinPac switches to the ansi-color mode after connecting this station. <br> |
| 549 | <b>ENC</b> - The character encoding. Used to automaticaly switch to the |
| 550 | i/o character conversion. <br> |
| 551 | <b>RCMD</b> - The list of enabled remote commands for this station. <br> |
| 552 | <b>QRG</b> - The user frequency. Used by the logbook. <br> |
| 553 | <b>SYSNUM</b> and <b>PWD</b> - Sysop password for the station. See chapter |
| 554 | <a href="#POS8_2">8.2</a> for more information. |
| 555 | </ul> |
| 556 | </p> |
| 557 | |
| 558 | <p><a name="POS5_2"></a> </p> |
| 559 | |
| 560 | <h3> 5.2 The 'Name' command</h3> |
| 561 | <p>The <code>:Name</code> command is used to modify the station database. Running |
| 562 | the command without arguments results printing the name of currently connected |
| 563 | station. Arguments can be used to modify the data: </p> |
| 564 | <p> |
| 565 | <ul> |
| 566 | <code><name></code> - modify the NAME item <br> |
| 567 | <code>-l <locator></code> - modify the LOC item <br> |
| 568 | <code>-t <type></code> - TYPE <br> |
| 569 | <code>-L <language></code> - LANG <br> |
| 570 | <code>-n <nickname></code> - NICKNAME <br> |
| 571 | <code>-s <item>=<value></code> - modify other item |
| 572 | </ul> |
| 573 | </p> |
| 574 | |
| 575 | <p>The command '<code>Name -i</code>' prints all information about the station. |
| 576 | When you need to change the information about a station other than the connected |
| 577 | station, add the argument <code>-c <callsign></code>. </p> |
| 578 | |
| 579 | <p>Examples: </p> |
| 580 | <p> |
| 581 | <ul> |
| 582 | <code>:Name David</code> <br> |
| 583 | <code>:Name -c KI6ZHD -l CM97ai David</code> <br> |
| 584 | <code>:Name -i</code> |
| 585 | </ul> |
| 586 | </p> |
| 587 | |
| 588 | <p><a name="POS5_3"></a> </p> |
| 589 | |
| 590 | <h3> 5.3 Using the database</h3> |
| 591 | After any connection is established, LinPac reads the information about the |
| 592 | connected station from the database and creates the set of variables with |
| 593 | names <code>STN_<<i>database_item_name</i>></code> containing the values |
| 594 | of the items. These variables can be used in macros as described below. |
| 595 | |
| 596 | <p><a name="POS6"></a> </p> |
| 597 | |
| 598 | <h2> 6 About macros</h2> |
| 599 | <a name="POS6_1"></a> |
| 600 | <h3> 6.1 Creating macros</h3> |
| 601 | A macro is a LinPac command that is created using the macro language, |
| 602 | and uses other LinPac commands to perform some action. A macro can be defined |
| 603 | by creating the file <code>macro/<<i>command_name</i>>.mac</code>. It's |
| 604 | possible to define an abbreviated form of the command; this is described |
| 605 | in <a href="#POS7">chapter 7</a>. There are two ways to define a macro: |
| 606 | |
| 607 | <p><b><i>a) Text macros</i></b> <br> |
| 608 | This way is suitable for commands which are intended to produce a larger |
| 609 | text output (for example station information). When executing this macro, |
| 610 | each line that doesn't start with ':' is printed (sent out). All commands |
| 611 | must start with the colon. This is suitable for modifying the text output |
| 612 | using the IF ~ ELSE ~ ENDIF commands or for including some other commands. |
| 613 | </p> |
| 614 | |
| 615 | <p><b><i>b) Command macros</i></b> <br> |
| 616 | A command macro must start with the line <br> |
| 617 | <code>:MACRO <name></code> <br> |
| 618 | Each line of a command macro is interpreted as a command (doesn't start |
| 619 | with the colon and doesn't need to start at the begining of line). Text |
| 620 | output is provided by the 'echo' command. This way is more synoptical and |
| 621 | allows including comments that must start with the sequence '<code>;;</code>' |
| 622 | and end at the end of the line. </p> |
| 623 | |
| 624 | <p>A macro is called with its name. When the first arguments starts with |
| 625 | the '@' symbol the macro is executed from the specified label. For example |
| 626 | the command <code>:convers @SEND</code> will execute the macro '<b>convers.mac</b>' |
| 627 | from the label 'SEND' (see next chapter to see how to define the label). |
| 628 | </p> |
| 629 | |
| 630 | <p><a name="POS6_2"></a> </p> |
| 631 | |
| 632 | <h3> 6.2 Commands used in macros</h3> |
| 633 | A macro can contain all LinPac and user defined commands. There |
| 634 | are also some special commands that can be used in macros only: |
| 635 | <p><b>MACRO [name]</b> <br> |
| 636 | Start of the command script definition (see previous section). </p> |
| 637 | |
| 638 | <p><b>LABEL <label_name></b> <br> |
| 639 | Creates a label with specified name. In the command scripts the notation |
| 640 | :<label_name> can be used. </p> |
| 641 | |
| 642 | <p><b>GOTO <label_name></b> <br> |
| 643 | Jump to specified label. </p> |
| 644 | |
| 645 | <p><b>IF ~ ELSE ~ ENDIF</b> <br> |
| 646 | Conditional commands. There are two ways to specify a condition: </p> |
| 647 | |
| 648 | <ul> |
| 649 | <li> normal notation (for more than one command)</li> |
| 650 | |
| 651 | <p><b>IF</b> <condition> <br> |
| 652 | . <br> |
| 653 | . <br> |
| 654 | (commands to be executed when the condition is true) <br> |
| 655 | . <br> |
| 656 | . <br> |
| 657 | <b>ELSE</b> <br> |
| 658 | . <br> |
| 659 | . <br> |
| 660 | (commands to be executed when the condition is false) <br> |
| 661 | . <br> |
| 662 | . <br> |
| 663 | <b>ENDIF</b> </p> |
| 664 | |
| 665 | <p>The ELSE part is not necessary - the IF ~ ENDIF notation is possible. |
| 666 | <br> |
| 667 | </p> |
| 668 | <li> abbreviated notation (for one conditional command)</li> |
| 669 | |
| 670 | <p><b>IF</b> (<condition>) command </p> |
| 671 | |
| 672 | <p>The parentheses are necessary in this case.</p> |
| 673 | |
| 674 | </ul> |
| 675 | The following example shows how to use conditions and how to use the data |
| 676 | from the station database. We want to create a macro that will greet the |
| 677 | operator of the connected station with his nickname or with his name, if the |
| 678 | nickname is not defined. |
| 679 | <p><b><i>a) The solution using a text macro</i></b> (the comments are actually |
| 680 | not allowed in the text macros, they are here for explanation only) </p> |
| 681 | |
| 682 | <p> |
| 683 | <ul> |
| 684 | <code>:if %(exist STN_NICKNAME) == 1 ;; when NICKNAME is defined</code> <br> |
| 685 | <code>Hello %STN_NICKNAME |
| 686 | ;; greet with the nickname</code> <br> |
| 687 | <code>:else |
| 688 | ;; else (not defined)</code> <br> |
| 689 | <code>Hello %N ! |
| 690 | ;; greet with the name</code> <br> |
| 691 | <code>:endif |
| 692 | ;;(following commands are always executed)</code> <br> |
| 693 | <code>You have connected to %Y at %T. ;; Say your callsign and current time</code> |
| 694 | </ul> |
| 695 | </p> |
| 696 | |
| 697 | <p><b><i>b) The solution using a command macro</i></b> </p> |
| 698 | |
| 699 | <p> |
| 700 | <ul> |
| 701 | <code>:macro GREETING ;; start the command macro</code> <br> |
| 702 | <code>if %(exist STN_NICKNAME) == 1 ;; when NICKNAME is defined</code> <br> |
| 703 | <code>echo Hello %STN_NICKNAME ;; greet with the |
| 704 | nickname</code> <br> |
| 705 | <code>else |
| 706 | ;; else (not defined)</code> <br> |
| 707 | <code>echo Hello %N ! |
| 708 | ;; greet with the name</code> <br> |
| 709 | <code>endif |
| 710 | ;; (following commands are always executed)</code> <br> |
| 711 | <code>echo You have connected to %Y at %T. ;; Say your callsign and current |
| 712 | time</code> |
| 713 | </ul> |
| 714 | </p> |
| 715 | |
| 716 | <p><a name="POS6_3"></a> </p> |
| 717 | |
| 718 | <h3> 6.3 Special system macros</h3> |
| 719 | <p>There are some special macros that are executed automaticaly by LinPac |
| 720 | in some cases:</p> |
| 721 | |
| 722 | <p> |
| 723 | <ul> |
| 724 | <b>init.mac</b> - This is executed when LinPac is started and its function |
| 725 | is to set the callsigns, screen options, and some other parameters. </p> |
| 726 | |
| 727 | <p><b>cinit.mac</b> - This is always executed when a connection is established. |
| 728 | The distribution version of this macro sets the channel parameters in order |
| 729 | to configure station settings from the station database (allowed remote commands, i/o encoding, |
| 730 | terminal type) and executes the logbook command to sign the start of a connection. |
| 731 | LinPac always passes two arguments to this macro. The first (%1) argument |
| 732 | is the callsign of the connected station and the second (%2) argument is the |
| 733 | callsign of the previously connected station that provides the connection, |
| 734 | or empty in case of direct connection. </p> |
| 735 | |
| 736 | <p><b>ctext.mac</b> - This macro is executed when some station connects to |
| 737 | the terminal. It should print some greeting text. No arguments are passed. </p> |
| 738 | |
| 739 | <p><b>cexit.mac</b> - This is always executed when a connection closes. |
| 740 | The distribution version of this macro just executes the logbook command |
| 741 | to sign the end of the connection and clears the list of allowed remote commands. |
| 742 | There is always one argument passed by LinPac (%1), containing the callsign |
| 743 | of the disconnected station. </p> |
| 744 | </ul> |
| 745 | </p> |
| 746 | |
| 747 | <p><a name="POS7"></a> </p> |
| 748 | |
| 749 | <h2> 7 Creating new commands</h2> |
| 750 | <p>A new command can be represented by a macro or by an external program |
| 751 | (standard linux program or special LinPac application). Macros are placed |
| 752 | in the <code>$LINPACDIR/macro</code> directory and external programs are placed |
| 753 | in the <code>$LINPACDIR/bin</code> directory. In both of these directories is |
| 754 | the file '<code>commands</code>' that contains the list of commands in that directory. |
| 755 | You should specify here the name of the file, the name of the command in LinPac |
| 756 | (use upper case to specify the mandatory part of the command). It's |
| 757 | not necessary to include the macros here if you don't want to define the |
| 758 | abbreviation. </p> |
| 759 | <p>In case of external programs, it is also possibile to specify |
| 760 | program flags. Currently the following flags are supported:</p> |
| 761 | <p> |
| 762 | <ul> |
| 763 | A - Ascii mode program. LinPac provides CR <-> LF conversion |
| 764 | when communicating with this program. This is the default setting. <br> |
| 765 | B - Binary mode. Disables the text conversions. <br> |
| 766 | C - Leaves the stdout stream of the program on the console and reads its |
| 767 | stderr stream instead. <br> |
| 768 | D - DOS conversion - ignore LF characters. <br> |
| 769 | S - Reads both stdin and stderr streams of the program (shell mode). <br> |
| 770 | L - Local. This program is never available as a remote command. <br> |
| 771 | R - This program is always run as a remote command (its messages are |
| 772 | always sent out). <br> |
| 773 | P - LinPac removes the paths from filenames that are passed as the argument |
| 774 | of this command when the FIXPATH command is on. This is a security option. |
| 775 | </ul> |
| 776 | </p> |
| 777 | |
| 778 | <p><a name="POS8"></a> </p> |
| 779 | |
| 780 | <h2> 8 Standard applications</h2> |
| 781 | <a name="POS8_1"></a> |
| 782 | <h3> 8.1 File transfer protocols</h3> |
| 783 | <p>At present LinPac supports two protocols for transferring files:</p> |
| 784 | <ul> |
| 785 | <li> <b>Autobin</b> - a simple protocol suitable for short files</li> |
| 786 | <li> <b>YAPP</b> - a very sophisticated transfer protocol that provides |
| 787 | better error detection and is able to resume a previously interrupted transfer</li> |
| 788 | |
| 789 | </ul> |
| 790 | <p>Usage of these protocols is described in chapter <a href="#POS3_4">3.4</a>.</p> |
| 791 | |
| 792 | <p>LinPac can also automatically save incomming 7+ files. After saving all |
| 793 | parts of a file LinPac tries to call the '7plus' program to decode the file. |
| 794 | Received 7+ files are not removed automatically. </p> |
| 795 | |
| 796 | <p><a name="POS8_2"></a> </p> |
| 797 | |
| 798 | <h3> 8.2 Automatic password generation</h3> |
| 799 | |
| 800 | <h4> <a name="POS8_2_1"></a>8.2.1 Login passwords</h4> |
| 801 | <p>LinPac provides automatic replies to the login authorization requests |
| 802 | for the following systems: F6FBB BBS (VE2BLY C_FILTER), BAYBOX, TNOS (numeric |
| 803 | MD5). Each station which requests a login password must have an entry |
| 804 | in the station database containing at least following fields:</p>A |
| 805 | |
| 806 | <p> |
| 807 | <ul> |
| 808 | <code>TYPE=<<i>station_type</i>></code> (FBB, BAYBOX or TNOS) <br> |
| 809 | <code>LOGINPW=<<i>login_password</i>></code> <br> |
| 810 | <code>PWPROMPT=<<i>BBS_prompt</i>></code> |
| 811 | </ul> |
| 812 | </p> |
| 813 | |
| 814 | <p><i><code>BBS_prompt</code></i> is the text which the BBS sends when requesting |
| 815 | the authorization. Usually it looks like 'Password>' or 'OK0XYZ>'. |
| 816 | </p> |
| 817 | |
| 818 | <h4> <a name="POS8_2_2"></a>8.2.2 Sysop and general use passwords</h4> |
| 819 | <p>LinPac provides automatic authorization to the following systems: F6FBB BBS |
| 820 | (MD2 password), FLEXNET (older versions, the 'magic' numbers system and newer |
| 821 | TheNet-like system), THENET and BAYBOX. Each station you want to authenticate |
| 822 | with must have an entry in the station database. For password generation, the following |
| 823 | fields must be set:</p> |
| 824 | |
| 825 | <p> |
| 826 | <ul> |
| 827 | <code>TYPE=<<i>station_type</i>></code> <br> |
| 828 | <code>PWD=<<i>your_password</i>> or</code> <br> |
| 829 | <code>SYSNUM=<<i>magic_number</i>></code> |
| 830 | </ul> |
| 831 | </p> |
| 832 | |
| 833 | <p>Known station types are: </p> |
| 834 | |
| 835 | <ul> |
| 836 | <li> <b>FBB</b> - An F6FBB BBS. The PWD field must contain your password.</li> |
| 837 | <li> <b>THENET</b> - A TheNet node. Again the PWD must contain the password.</li> |
| 838 | <li> <b>BAYBOX</b> - The same system as TheNet.</li> |
| 839 | <li> <b>FPAC</b> - A FPAC node. Password must be stored in the PWD field.</li> |
| 840 | <li> <b>FLEXNET</b> - FlexNet node. If the magic number algorithm is |
| 841 | used (older versions of flexdigi) the SYSNUM field must contain your magic |
| 842 | number and the PWD field must not be set. When the TheNet algorithm is used |
| 843 | (newer versions of flexdigi), the PWD field must contain the password and |
| 844 | the SYSNUM field must not be used.</li> |
| 845 | |
| 846 | </ul> |
| 847 | <p>In case of <b>FBB</b> the authorization algorithm can be chosen by setting |
| 848 | the <b>MD</b> field in the station database: </p> |
| 849 | <p> |
| 850 | <ul> |
| 851 | <code>MD=5</code> - this value will select the MD5 algorithm <br> |
| 852 | <code>MD=2</code> - this value will select the MD2 algorithm |
| 853 | </ul> |
| 854 | </p> |
| 855 | |
| 856 | <p>When no value is set, MD2 algorithm is used. </p> |
| 857 | |
| 858 | <p>After connecting to the station you want to authenticate with, the authorization |
| 859 | sequence begins with the <code>:PW</code> command. LinPac will send the authorization |
| 860 | command to the station and tries to answer the authorization request using |
| 861 | your password. If the password is correct, authorization should finish successfully. |
| 862 | </p> |
| 863 | |
| 864 | <p>The PW command accepts the following parameters: </p> |
| 865 | |
| 866 | <p> |
| 867 | <ul> |
| 868 | <code>:PW [<<i>command</i>> [<<i>system</i>> [<<i>password</i>>]]]</code> |
| 869 | </ul> |
| 870 | </p> |
| 871 | |
| 872 | <p>where </p> |
| 873 | <ul> |
| 874 | <li><code><<i>command</i>></code> is the command to be sent to the remote |
| 875 | station to start the authorization sequence (<i>sys</i> by default)</li> |
| 876 | <li><code><<i>system</i>></code> is one of the above-mentioned supported |
| 877 | systems; this system is used instead of the one specified in station database</li> |
| 878 | <li><code><<i>password</i>></code> is the password that will be used instead |
| 879 | of the one specified in the station database</li> |
| 880 | </ul> |
| 881 | |
| 882 | <p>It's recommended that you create simple macros for frequently used authorizations |
| 883 | that require special arguments to the PW command. </p> |
| 884 | |
| 885 | <p><a name="POS8_3"></a> </p> |
| 886 | |
| 887 | <h3> 8.3 Utilities for mail exchange</h3> |
| 888 | <p>LinPac contains support for exchanging messages with remote Kantronics PBBSs as well |
| 889 | as F6FBB BBS systems. This support utilizies some tools from the ax25mail-utils so please |
| 890 | install that package first. THe next step would be to configure Linpac and ax25mail-utils's |
| 891 | configuration settings with the following variables either in Linpac's channel 0 or in |
| 892 | Linpac's init.mac file:</p> |
| 893 | <p> |
| 894 | Example #1: Kantronics KPC3: |
| 895 | </p> |
| 896 | <ul> |
| 897 | <li><b>HOME_TYPE</b> - This sets the type of remote system you're connecting to. |
| 898 | Supported options are either "PBBS" for Kantronics KPC3 type TNCs or "FBB" for F6FBB |
| 899 | BBSes. Only "PBBS" is well understood though the FBB support has been there for some time. |
| 900 | </li> |
| 901 | <li><b>HOME_BBS</b> - The AX.25 path to the home PBBS including the port name. |
| 902 | For example <code>d710:AA6WK-1</code> means use the <code>d710</code> AX.25 port as defined |
| 903 | in the <code>/etc/ax25/axports</code> configuration file and connect to the PBBS <code>AA6WK-1</code>. |
| 904 | It's important to note that the callsigns in Linpac are CaSe-SeNsItIvE so make sure these |
| 905 | two variables use the SAME case.</li> |
| 906 | <li><b>HOME_ADDR</b> - The full hierarchical address of the BBS (which technically isn't |
| 907 | required for PBBSes). For example |
| 908 | <code>AA6WK.#NCA.CA.USA.NOAM</code>.</li> |
| 909 | </ul> |
| 910 | <p>To set the variable while in Linpac, the <code>:SET</code> command can be used. You can also |
| 911 | put this same line (but without the colon) in Linpac's init.mac file: |
| 912 | </p> |
| 913 | |
| 914 | <p> |
| 915 | <ul> |
| 916 | <code>:set HOME_TYPE "PBBS"</code><br> |
| 917 | <code>:set HOME_BBS@0 "d710:AA6WK-1"</code><br> |
| 918 | <code>:set HOME_ADDR "AA6WK.#NCA.CA.USA.NOAM"</code><br> |
| 919 | </ul> |
| 920 | </p> |
| 921 | |
| 922 | <p>The recommended place to set this variables is in the startup macro <code>init.mac</code>. |
| 923 | The default version of this macro contains an example of setting these variables. |
| 924 | After setting these variables, the following commands are available: </p> |
| 925 | |
| 926 | <p> |
| 927 | Example #2: |
| 928 | </p> |
| 929 | <ul> |
| 930 | <li><b>HOME_TYPE</b> - This sets the type of remote system you're connecting to. |
| 931 | Supported options are either "PBBS" for Kantronics KPC3 type TNCs or "FBB" for F6FBB |
| 932 | BBSes. Only "PBBS" is well understood though the FBB support has been there for some time. |
| 933 | </li> |
| 934 | <li><b>HOME_BBS</b> - The AX.25 path to the home BBS including the port name. |
| 935 | For example <code>kiss:OK0PAB OK0NMA</code> means use the <code>kiss</code> AX.25 port |
| 936 | as defined in the <code>/etc/ax25/axports</code> configuration file and connec to the BBS |
| 937 | <code>OK0PAB</code> via the digipeater <code>OK0NMA</code>. It's important to note that the |
| 938 | callsigns are CaSe-SeNsItIvE in Linpac so make sure these two variables use the SAME case.</li> |
| 939 | <li><b>HOME_ADDR</b> - The full hierarchical address of the BBS. For example |
| 940 | <code>OK0PAB.#MOR.CZE.EU</code>.</li> |
| 941 | </ul> |
| 942 | <p>To set the variable while in Linpac, the <code>:SET</code> command can be used. You can also |
| 943 | put this same line (but without the colon) in Linpac's init.mac file:</p> |
| 944 | |
| 945 | <p> |
| 946 | <ul> |
| 947 | <code>:set HOME_TYPE "FBB"</code> <br> |
| 948 | <code>:set HOME_BBS@0 "kiss:OK0PAB OK0NMA"</code> <br> |
| 949 | <code>:set HOME_ADDR "OK0PAB.#MOR.CZE.EU"</code> |
| 950 | </ul> |
| 951 | |
| 952 | <p>The recommended place to set this variables is in the startup macro <code>init.mac</code>. |
| 953 | The default version of this macro contains an example of setting these variables. |
| 954 | After setting these variables, the following commands are available: </p> |
| 955 | |
| 956 | <p>Now you need to configure the ax25mail-utils program by editing the </code>/etc/ax25/axgetlist.conf</code> |
| 957 | file. The following example is to support connecting to PBBSes in example #1 above:</p> |
| 958 | <ul> |
| 959 | <pre> |
| 960 | [AA6WK-1] |
| 961 | MYCALL N0CALL |
| 962 | BBSCALL AA6WK-1 |
| 963 | BBSPORT d710 |
| 964 | CMD_LIST LO +;L |
| 965 | CMD_LIST_FROM LO +;L $ |
| 966 | CMD_DISC B |
| 967 | HEADER_LINES 1 |
| 968 | FORMAT <NUM> <FLAGS> <SIZE> <TO> <FROM> <DATE> <TIME> <SUBJ> |
| 969 | DATEFMT mm/dd/yyyy |
| 970 | BPFPOS 1-- |
| 971 | </pre> |
| 972 | </ul> |
| 973 | |
| 974 | <p>Each remote BBS gets it's own section, unique callsign, and any other specific settings to support |
| 975 | the sending and receiving of messages.<p> |
| 976 | |
| 977 | <p> NOTE: the associated ax25mail-utils <code>/etc/ax25/axgetmail.conf</code> configuration file |
| 978 | NOT currently mentioned in this documentation is <b>only</b> used for remote "FBB" setups. That |
| 979 | support is currently not documented yet.</p> |
| 980 | |
| 981 | <p><b>Urgent:</b> Linpac's packet messaging support is still a work in progress so some quirks exist for now:</p> |
| 982 | <p> |
| 983 | <ul> |
| 984 | <li>All remote BBS systems that use SSID numbers will have their message index files "flattened" |
| 985 | aka written to the same base callsign name without the SSID in <code>/var/ax25/ulistd/</code>. In |
| 986 | the future, this filename should include the <code>-SSID#</code></li> |
| 987 | <li>All non-private messages will be stored in <code>/var/ax25/mail/<callsign-SSID></code></li> |
| 988 | <li>All private messages will be stored in <code>/var/ax25/mail/<callsign-SSID></code></li> |
| 989 | <li>There is a known bug in Linpac's message system due to the index "flattening" issue where |
| 990 | messages cannot be written to disk or found in the :mail interface. To work around this issue, do |
| 991 | the following in the directory of the Linux user who is running Linpac:</li> |
| 992 | <p> |
| 993 | <ul> |
| 994 | <code>mkdir LinPac/mail/<callsign-SSID></code><br> |
| 995 | <code>ln -s LinPac/mail/<callsign-SSID> LinPac/mail/<callsign></code> |
| 996 | </ul> |
| 997 | </p> |
| 998 | </ul> |
| 999 | </p> |
| 1000 | |
| 1001 | <p>Now that the basics (and workarounds) are setup, let's fetch any pending messages for you on your |
| 1002 | configured remote BBS system. Enter in the following command on the Linux prompt (this example |
| 1003 | is following example #1 above):</p> |
| 1004 | |
| 1005 | <p> |
| 1006 | <ul> |
| 1007 | <code>axgetlist -b AA6WK-1</code> |
| 1008 | </ul></p> |
| 1009 | |
| 1010 | <p>NOTE: The above Linux command <b>must be</b> run as the same Unix user that is running the Linpac |
| 1011 | program.</p> |
| 1012 | |
| 1013 | <p> The axgetlist utility will now fetch an index of all messages on the remote BBS system and |
| 1014 | store this list in <code>/var/ax25/ulistd/<bbs-name></code> (all SSIDs are currently stripped). |
| 1015 | While this Linux command line-based index capture occurs, the packet traffic will NOT show up in |
| 1016 | Linpac's main send/receive UI as this command is running outside of Linpac. You will see the AX.25 |
| 1017 | traffic if you have Linpac's AX.25 traffic monitor working. The resulting downloaded index file |
| 1018 | will then be used to manually download any messages with the <code>getmsg</code> command or interact |
| 1019 | with those remote messages them via Linpac's :mail interface</p> |
| 1020 | |
| 1021 | <p> |
| 1022 | <ul> |
| 1023 | <p><code>:GETMSG <<i>message_number</i>> [<<i>message_number</i>> |
| 1024 | ...]</code> <br> |
| 1025 | From the main Linpac interface, this command reads specified messages from the remote BBS and |
| 1026 | stores them into <code>/var/ax25/mail/<<i>BBS_callsign</i>>/<<i>message_number</i>></code>. |
| 1027 | The file system directory for the remote BBS must be created before using this command (use upper |
| 1028 | case for the BBS callsign). When the message number starts with the letter <b>'p'</b>, the message |
| 1029 | is considered a PERSONAL one and it's killed automatically after download. You can specify the kill |
| 1030 | command by setting the <code>KILLPERS</code> variable in channel 0 using the <b>#</b> character for |
| 1031 | the number of the message (e.g. <code>:set KILLPERS@0 "kill #"</code>). When this variable is not |
| 1032 | set, the default command <code>K #</code> is used. This can also be set in the init.mac file.<p> |
| 1033 | |
| 1034 | <p><code>:SP <<i>address</i>></code> or <code>:SB <<i>address</i>></code><br> |
| 1035 | These commands can be used for creating new private messages or bulletins. |
| 1036 | The usage is the same as for the FBB BBS. </p> |
| 1037 | |
| 1038 | <p><code>:FORWARD</code> <br> |
| 1039 | Transfers all new messages to the BBS. </p> |
| 1040 | |
| 1041 | <p><code>:DELMSG <<i>message_number</i>></code> <br> |
| 1042 | Marks the message for delete. </p> |
| 1043 | |
| 1044 | <p><code>:PACK</code> <br> |
| 1045 | Deletes all marked messages. </p> |
| 1046 | </ul> |
| 1047 | </p> |
| 1048 | |
| 1049 | <p><a name="POS8_4"></a> </p> |
| 1050 | |
| 1051 | <h3> 8.4 Mail client</h3> |
| 1052 | <p>This application allows full screen message editing and browsing. It provides |
| 1053 | a graphical (Ncurses) frontend to mail exchange utilities. The mail client is started |
| 1054 | by the <code>:MAIL</code> command from Linpac's Channel 0 (aka.. the F1-key view). If |
| 1055 | you run this command from any other Linpac channel, it won't display any messages!<p> |
| 1056 | |
| 1057 | <p>After the mail interface opens, the <b>H</b> key shows the operating instructions.</p> |
| 1058 | |
| 1059 | <p>In the INCOMING mail folder, you should see a list of messages available to download. |
| 1060 | Toggle the messages you want to fetch with the SPACEBAR and then use the "d" key to download |
| 1061 | those messages.</p> |
| 1062 | |
| 1063 | <p><a name="POS8_5"></a> </p> |
| 1064 | |
| 1065 | <h3> 8.5 Logbook</h3> |
| 1066 | Logbook is a simple application that is started from the cinit.mac and |
| 1067 | cexit.mac scripts (at the begining and at the end of each connection). It |
| 1068 | creates the file in the 'log' directory for each callsign and writes there |
| 1069 | the time when the connections were started and finished and the QRG. The QRG |
| 1070 | is taken from the <code>QRG</code> field of the station entry in station database. |
| 1071 | If the station has no QRG defined, the value from the <code>QRG@0</code> variable |
| 1072 | is taken. |
| 1073 | <p><a name="POS9"></a> </p> |
| 1074 | |
| 1075 | <h2> 9 Command line options</h2> |
| 1076 | <p>LinPac accepts following command line options:</p> |
| 1077 | <ul> |
| 1078 | <b>-m</b> : disable monitor. When this option is used, LinPac doesn't |
| 1079 | create it's internal monitor objects and saves memory. |
| 1080 | <p><b>-s</b> : disable <i>ax25spyd</i>. Linpac normally tries to connect |
| 1081 | <i>ax25spyd</i> to get monitor data and when the connection fails, the |
| 1082 | <i>listen</i> utility is used instead. When <b>-s</b> swicth is used, LinPac |
| 1083 | doesn't try to connect <i>ax25spyd</i> at all. </p> |
| 1084 | |
| 1085 | <p><b>-d</b> : daemon mode. LinPac doesn't initialize the screen and runs |
| 1086 | in the background. </p> |
| 1087 | |
| 1088 | <p><b>-p <string></b> : specify the arguments for the <i>listen</i> |
| 1089 | program. Default value is <code>ar8</code>.</p> |
| 1090 | |
| 1091 | </ul> |
| 1092 | <a name="POS10"></a> |
| 1093 | <h2> 10 Copying</h2> |
| 1094 | <p>LinPac is Copyright (c) 2002-2020 by David Ranch KI6ZHD and |
| 1095 | Copyright (c) 1998-2002 by Radek Burget, OK2JBG</p> |
| 1096 | |
| 1097 | <p>This program is free software; you can redistribute it and/or modify it |
| 1098 | under the terms of the GNU General Public License as published by the Free |
| 1099 | Software Foundation; </p> |
| 1100 | |
| 1101 | <p>This program is distributed in the hope that it will be useful, but WITHOUT |
| 1102 | ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS |
| 1103 | FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details |
| 1104 | (contained in file 'license'). </p> |
| 1105 | |
| 1106 | <p>You should have received a copy of the GNU General Public License along |
| 1107 | with this program; if not, see <a href="https://www.gnu.org/licenses/"><https://www.gnu.org/licenses/></a>.</p> |
| 1108 | |
| 1109 | <p> </p> |
| 1110 | |
| 1111 | <hr> |
| 1112 | <h2> <a name="POSAppendixA"></a></h2> |
| 1113 | |
| 1114 | <h2> Appendix A - LinPac commands</h2> |
| 1115 | |
| 1116 | <h3> Built-in commands</h3> |
| 1117 | <b><i>a) action commands</i></b> |
| 1118 | <p> |
| 1119 | <ul> |
| 1120 | |
| 1121 | <p> |
| 1122 | <ul> |
| 1123 | <p><b>ABort [address]</b> <br> |
| 1124 | Cancels an action. Some commands are cancelled without specifying any address |
| 1125 | (e.g. autobin). Addresses for some commands:</p> |
| 1126 | |
| 1127 | <ul> |
| 1128 | <table border="1" cellspacing="0" cellpadding="5"> |
| 1129 | <thead style="font-weight:bold; text-align: center;"> |
| 1130 | <tr> |
| 1131 | <td>Action</td> |
| 1132 | <td>Address for abort</td> |
| 1133 | </tr> |
| 1134 | </thead> |
| 1135 | <tbody> |
| 1136 | <tr> |
| 1137 | <td>autobin RX/TX</td> |
| 1138 | <td><b>autobin</b> (or none)</td> |
| 1139 | </tr> |
| 1140 | <tr> |
| 1141 | <td>yapp RX/TX</td> |
| 1142 | <td><b>yapp</b> (or none)</td> |
| 1143 | </tr> |
| 1144 | <tr> |
| 1145 | <td>7plus autosave</td> |
| 1146 | <td><b>7plus</b> (or none)</td> |
| 1147 | </tr> |
| 1148 | <tr> |
| 1149 | <td>read / RBin</td> |
| 1150 | <td><b>read</b> (or none)</td> |
| 1151 | </tr> |
| 1152 | <tr> |
| 1153 | <td>write / WBin</td> |
| 1154 | <td><b>write</b> (or none)</td> |
| 1155 | </tr> |
| 1156 | <tr> |
| 1157 | <td>forward</td> |
| 1158 | <td><b>forward</b> (mandatory)</td> |
| 1159 | </tr> |
| 1160 | </tbody> |
| 1161 | </table> |
| 1162 | </ul> |
| 1163 | </ul> |
| 1164 | |
| 1165 | <p>Most of the other commands don't need any address. </p> |
| 1166 | |
| 1167 | <p> |
| 1168 | <ul> |
| 1169 | <p><b>COMPress [on | off | 1 | 0]</b> <br> |
| 1170 | Switch the link compression on or off. The arguments 1 and 0 have the |
| 1171 | same meaning as on or off but the remote station is not synchronized. </p> |
| 1172 | |
| 1173 | <p><b>Connect [port:]call [digi [digi...]]</b> <br> |
| 1174 | Initiate a connection to the specified station. </p> |
| 1175 | |
| 1176 | <p><b>Disconnect</b> <br> |
| 1177 | Disconnect the channel. </p> |
| 1178 | |
| 1179 | <p><b>Echo <text></b> <br> |
| 1180 | Print (send) the specified text. </p> |
| 1181 | |
| 1182 | <p><b>FLUSH</b> <br> |
| 1183 | Flush an output buffer (for example in scripts before disconnect or before |
| 1184 | requesting input). </p> |
| 1185 | |
| 1186 | <p><b>SYstem</b> <br> |
| 1187 | End of LinPac, cancel all connections. </p> |
| 1188 | |
| 1189 | <p><b>UNproto <text></b> <br> |
| 1190 | Send specified text in a UI frame. </p> |
| 1191 | |
| 1192 | <p><b>VERsion</b> <br> |
| 1193 | Print version information. </p> |
| 1194 | </ul> |
| 1195 | <p> |
| 1196 | |
| 1197 | <p><b><i>b) Commands for variable handling</i></b> </p> |
| 1198 | <p> |
| 1199 | <ul> |
| 1200 | |
| 1201 | <p><b>SET <variable> <value></b> <br> |
| 1202 | Assign a value to the variable. If the variable doesn't exist, it is created. </p> |
| 1203 | |
| 1204 | <p><b>UNSET <variable></b> <br> |
| 1205 | Remove the variable. </p> |
| 1206 | |
| 1207 | <p><b>GET <variable></b> <br> |
| 1208 | Return the value of the variable. Usually is better to use macro %variable |
| 1209 | (see file macros.txt) </p> |
| 1210 | |
| 1211 | <p><b>EXISTs <variable></b> <br> |
| 1212 | Return 1 when variable exists, 0 when it doesn't exist. </p> |
| 1213 | </ul> |
| 1214 | <p> |
| 1215 | |
| 1216 | <p><b><i>c) information commands</i></b> </p> |
| 1217 | <p> |
| 1218 | <ul> |
| 1219 | <p><b>ENVINFO</b> <br> |
| 1220 | Display information about the variable environment. </p> |
| 1221 | |
| 1222 | <p><b>ISCONnected</b> <br> |
| 1223 | Return "1" when the channel is connected, "0" otherwise. </p> |
| 1224 | |
| 1225 | <p><b>MAXCHannels</b> <br> |
| 1226 | Return the number of LinPac channels (typically 8). </p> |
| 1227 | |
| 1228 | <p><b>PCALL</b> <br> |
| 1229 | Return the physical callsign of the connected station (first station connected)</p> |
| 1230 | |
| 1231 | <p><b>UTCTime</b> <br> |
| 1232 | Return current UTC time (operating system value). </p> |
| 1233 | </ul> |
| 1234 | </p> |
| 1235 | |
| 1236 | <p><b><i>d) setup commands</i></b> </p> |
| 1237 | |
| 1238 | <p> |
| 1239 | <ul> |
| 1240 | <p><b>CBell [on|off]</b> <br> |
| 1241 | When on, LinPac gives an audio signal when any station connects or |
| 1242 | disconnects. </p> |
| 1243 | |
| 1244 | <p><b>FIXPath [on|off]</b> <br> |
| 1245 | When FIXPath=ON then the paths to files mentioned in the parameters are |
| 1246 | ignored for external commands marked with a P flag. That means only the |
| 1247 | default paths are usable. </p> |
| 1248 | |
| 1249 | <p><b>INFOLEvel [0 | 1 | 2]</b> <br> |
| 1250 | Set the mode of information line: <br> |
| 1251 | 0 - off (no connection info) <br> |
| 1252 | 1 - show importatnt informations <br> |
| 1253 | 2 - show all available informations </p> |
| 1254 | |
| 1255 | <p><b>KNax [on|off]</b> <br> |
| 1256 | Enable/disable sound signal when data is received. </p> |
| 1257 | |
| 1258 | <p><b>Language [language]</b> <br> |
| 1259 | Sets the language used. Currently supported in scripts only. </p> |
| 1260 | |
| 1261 | <p><b>LIsten [on|off]</b> <br> |
| 1262 | When listen is off, all connect requests are ignored by LinPac. Default |
| 1263 | value is on. </p> |
| 1264 | |
| 1265 | <p><b>MBIN [on|off]</b> <br> |
| 1266 | When switched on, the monitor shows binary data. When switched off, the |
| 1267 | binary data is hidden and replaced with the <Binary data> information. |
| 1268 | </p> |
| 1269 | |
| 1270 | <p><b>MONitor [on|off]</b> <br> |
| 1271 | Enable/disable monitor function. This command is usually followed by STATLINE |
| 1272 | and CHNLINE commands to adjust the screen layout. </p> |
| 1273 | |
| 1274 | <p><b>MONPort <port_specification><br> |
| 1275 | </b>Monitor the specified port(s) only. Port specification is either a port name |
| 1276 | (as defined in /etc/ax25/axports) or <i>*</i> for monitoring all the ports.<br> |
| 1277 | </p> |
| 1278 | |
| 1279 | <p><b>MYcall <call></b> <br> |
| 1280 | Change the channel callsign. </p> |
| 1281 | |
| 1282 | <p><b>Port <port_name></b> <br> |
| 1283 | Set the default port for the Connect command. This is usually the first |
| 1284 | port defined in the /etc/ax25/axports file but can be overriden here. |
| 1285 | This can be overriden for particular channels by setting the <code>CHN_PORT</code> |
| 1286 | variable for the channel (see <a href="#POS3_3">chapter 3.3</a>).</p> |
| 1287 | |
| 1288 | <p><b>PRIVate [on|off]</b> <br> |
| 1289 | Mark the channel as private. No stations are allowed to connect on this |
| 1290 | channel. </p> |
| 1291 | |
| 1292 | <p><b>RCMD [<command list>]</b> <br> |
| 1293 | Specify the list of available external commands. Only commands |
| 1294 | from this list are available to a remote user. It's possible to include abbreviated |
| 1295 | commands. The remote commands can be executed only on a channel which provides |
| 1296 | a connection. Adding the @ character just after the command name in |
| 1297 | the list (e.g. GET@) means that the remote user is allowed to specify the |
| 1298 | channel on which the command should be executed (e.g. //GET@5 NAME). </p> |
| 1299 | |
| 1300 | <p><b>REMote [on|off]</b> <br> |
| 1301 | Enable or disable remote commands. </p> |
| 1302 | |
| 1303 | <p><b>RXFlow [on|off]</b> <br> |
| 1304 | Enable or disable data RX. The data is received only when <b>RXFlow</b> |
| 1305 | is enabled on <b><u>all</u></b> channels. </p> |
| 1306 | |
| 1307 | <p><b>TIMEZone [zone]</b> <br> |
| 1308 | Set the time zone. Used for information only, doesn't affect time. </p> |
| 1309 | |
| 1310 | <p><b>UNDest [call]</b> <br> |
| 1311 | The destination address for UI / unconnected frames. You can use up to a maximum |
| 1312 | of seven digipeaters by by including the remote digis in a space delinated list. Here |
| 1313 | is an example where you MUST include the double quotes to complete the proper syntax:<br> |
| 1314 | undest "DAVID KLPRC3 KBETH KBANN KBULN"</p> |
| 1315 | |
| 1316 | <p><b>UNPort <port_name></b> <br> |
| 1317 | Set the default port for the UI frames / unproto traffic command or F10 |
| 1318 | unproto traffic area. This is usually the first port defined in the |
| 1319 | /etc/ax25/axports file but can be overriden here. This can be overriden |
| 1320 | for particular channels by setting the unport variable for the channel.</p> |
| 1321 | |
| 1322 | <p><b>UNSrc [call]</b> <br> |
| 1323 | The source callsign for UI frames. </p> |
| 1324 | |
| 1325 | <p><b>WAtch <port | 0> <pattern> <command/text></b> <br> |
| 1326 | Start to watch the specified port (0 for all ports). When the specified pattern |
| 1327 | is received then the specified command is executed or text is sent. (Commands |
| 1328 | must start with a colon.) </p> |
| 1329 | </ul> |
| 1330 | </p> |
| 1331 | |
| 1332 | <p><b><i>e) Screen control commands</i></b> </p> |
| 1333 | |
| 1334 | <p> |
| 1335 | <ul> |
| 1336 | <p><b>STATLINE <n></b> <br> |
| 1337 | Place the status line at the n-th line of the screen. </p> |
| 1338 | |
| 1339 | <p><b>CHNLINE <n></b> <br> |
| 1340 | Place the channel line at the n-th line of the screen. </p> |
| 1341 | |
| 1342 | <p><b>SWAPEDit</b> <br> |
| 1343 | Replace the editor window with the QSO window and vice versa. </p> |
| 1344 | |
| 1345 | <p><b>INFOLine <nm> <text></b> <br> |
| 1346 | Change the specified info line text. If the info line doesn't exist, it's |
| 1347 | created. </p> |
| 1348 | |
| 1349 | <p><b>REMOVEINFO <nm></b> <br> |
| 1350 | Remove the specified info line. </p> |
| 1351 | |
| 1352 | <p><b>TRanslate <alias></b> <br> |
| 1353 | Switch I/O character translation (see <a href="#POS3_6">chapter 3.6</a>). |
| 1354 | Running this command on channel 0 (unproto channel) switches the translation |
| 1355 | table in all channels including the unproto channel and the monitor window. </p> |
| 1356 | |
| 1357 | <p><b>TErm <type></b> <br> |
| 1358 | Set the terminal type. If 'ansi' is entered then ANSI-color control sequences |
| 1359 | are interpreted. </p> |
| 1360 | |
| 1361 | <p><b>SCRLimit <low-limit> <high-limit></b> <br> |
| 1362 | When the size of the window buffer exceeds the high limit, then the size |
| 1363 | of the buffer is truncated to low-limit. The values are in bytes; default is |
| 1364 | 356352 and 524288 (384 and 512 kB). </p> |
| 1365 | |
| 1366 | <p><b>DEFColor <color_name> <foreground_color> <background_color></b> |
| 1367 | <br> |
| 1368 | Change the color of some part of screen. The color_name parameter specifies |
| 1369 | which part of screen to change. The following values can be used: <br> |
| 1370 | QSO_RX - received text in QSO window <br> |
| 1371 | QSO_TX - sent text in QSO window <br> |
| 1372 | QSO_INFO - local information in QSO window <br> |
| 1373 | QSO_CTRL - control characters in QSO window <br> |
| 1374 | ED_TEXT - normal text in editor <br> |
| 1375 | ED_INFO - command results in editor <br> |
| 1376 | ED_CTRL - control characters in editor <br> |
| 1377 | CI_NORM - channel info line - channel numbers <br> |
| 1378 | CI_SLCT - selected channel <br> |
| 1379 | CI_NCHN - normal channel <br> |
| 1380 | CI_PRVT - private channel <br> |
| 1381 | IL_TEXT - status lines </p> |
| 1382 | |
| 1383 | <p>For specifying foreground and background colors, these values can be used: |
| 1384 | <br> |
| 1385 | BLACK, RED, GREEN, BROWN, BLUE, MAGENTA, CYAN, LIGHTGRAY <br> |
| 1386 | These additional colors can be used for foreground only: <br> |
| 1387 | DARKGRAY, LIGHTRED, LIGHTGREEN, YELLOW, LIGHTBLUE, LIGHTMAGENTA, LIGHTCYAN, |
| 1388 | WHITE </p> |
| 1389 | </ul> |
| 1390 | </p> |
| 1391 | |
| 1392 | <p><b><i>f) system commands</i></b> </p> |
| 1393 | <p> |
| 1394 | <ul> |
| 1395 | <p><b>RESULT <text></b> <br> |
| 1396 | Return the text as the result of a script. </p> |
| 1397 | </ul> |
| 1398 | </p> |
| 1399 | |
| 1400 | <p><b><i>g) string commands</i></b> </p> |
| 1401 | <p> |
| 1402 | <ul> |
| 1403 | <p><b>STRMid <start> <length> <string></b> <br> |
| 1404 | Return the substring starting at <start> position and <length> |
| 1405 | characters long. </p> |
| 1406 | |
| 1407 | <p><b>STRLeft <length> <string></b> <br> |
| 1408 | Return the left substring of specified length. </p> |
| 1409 | |
| 1410 | <p><b>STRRight <length> <string></b> <br> |
| 1411 | Return the right substring of specified length. </p> |
| 1412 | |
| 1413 | <p><b>STRLen <string></b> <br> |
| 1414 | Return the length of the string. </p> |
| 1415 | |
| 1416 | <p><b>STRPos <substring> <string></b> <br> |
| 1417 | Return the position of the substring in the string or -1 when the string |
| 1418 | doesn't contain the substring. </p> |
| 1419 | |
| 1420 | <p><b>UPCASE <string></b> <br> |
| 1421 | Return the string converted into upper case. </p> |
| 1422 | </ul> |
| 1423 | </p> |
| 1424 | </ul> |
| 1425 | </p> |
| 1426 | |
| 1427 | <h3> External commands</h3> |
| 1428 | <p> |
| 1429 | <ul> |
| 1430 | <b>Bell</b> <br> |
| 1431 | Call the operator using an acoustic signal.<br> |
| 1432 | |
| 1433 | <p><b>Compose [p|b] <address> [<subject>] [<filename>]</b> |
| 1434 | Create either a Private message or a Bulletin packet message for the specified |
| 1435 | callsign or fully formatted packet BBS address. When no subject is specified, the |
| 1436 | user is prompted for the subject. When filename is specified, the message is |
| 1437 | created from the file, otherwise the text is read from the LinPac console. </p> |
| 1438 | |
| 1439 | <p><b>CATCH -iol <pattern> <command/text></b> <br> |
| 1440 | Catch is the extended version of <b>WAtch</b> command. It scans one or |
| 1441 | more data streams (-i = input stream, -o = output stream, -l = local info |
| 1442 | stream) for the configured pattern. The pattern can contain <b>*</b> and <b>?</b> wildcards. |
| 1443 | The command can contain string <code>$1</code> .. <code>$n</code> which are replaced |
| 1444 | with the string corresponding to the n-th wildcard in the pattern. The <code>$0</code> |
| 1445 | string is replaced with the whole string that matches the pattern. See <code>catch |
| 1446 | -h</code> for extended parameters. </p> |
| 1447 | |
| 1448 | <p><b>DELMSG <message_number></b> <br> |
| 1449 | Mark the packet message for deletion </p> |
| 1450 | |
| 1451 | <p><b>FORWARD</b> <br> |
| 1452 | Transmit all new packet messages to a BBS</p> |
| 1453 | |
| 1454 | <p><b>GETMsg <numers></b> <br> |
| 1455 | Fetch packet messages from the configured BBS</p> |
| 1456 | |
| 1457 | <p><b>JOIN <channel_number></b> <br> |
| 1458 | This is a form of a group chat feature where you can join the specified Linpac |
| 1459 | channel to current Linpac channel. All data received on any of these channels is |
| 1460 | automatically redirected to the other channel. Stop with <b>:ABort join</b>. </p> |
| 1461 | |
| 1462 | <p><b>MAIL</b> <br> |
| 1463 | Simple full-screen packet message client</p> |
| 1464 | |
| 1465 | <p><b>MHeard</b> <br> |
| 1466 | List of heard stations. </p> |
| 1467 | |
| 1468 | <p><b>Name</b> <br> |
| 1469 | Store station name or change a station database entry. (see Name -h) </p> |
| 1470 | |
| 1471 | <p><b>PACK</b> <br> |
| 1472 | Delete all packet messages marked for deletion </p> |
| 1473 | |
| 1474 | <p><b>Read <filename></b> <br> |
| 1475 | Send the specified text file (see Wbin / Rbin commands for BINARY files)</p> |
| 1476 | |
| 1477 | <p><b>RPRg <filename></b> <br> |
| 1478 | Transmit the specified file using Autobin protocol</p> |
| 1479 | |
| 1480 | <p><b>RTt</b> <br> |
| 1481 | Measure the round trip time to the other connected Linpac station. Think of this |
| 1482 | as a "ping" time but results can be highly variable due to on-frequency packet |
| 1483 | collisions, poor packet decodes, RF propogation, etc.</p> |
| 1484 | |
| 1485 | <p><b>SENDFile [p|b] <file> <address> [<num_messages>]</b> |
| 1486 | <br> |
| 1487 | This command takes a binary file, splits the file into <i>num_messages</i> |
| 1488 | parts using <b>7plus</b> and creates a separate packet message for each part. |
| 1489 | When <i>num_messages</i> is not specified, the command tries to use <br> |
| 1490 | the variable <code>BLOCK7P@0</code> which should contain the maximum size of |
| 1491 | one block. If this variable is not set, blocks of 5 KB are created.</p> |
| 1492 | |
| 1493 | <p><b>WBin / RBin</b> <br> |
| 1494 | The same as Read / Write file transfers but to be used with BINARY files. |
| 1495 | (See Read / Write commands for TEXT files)</p> |
| 1496 | |
| 1497 | <p><b>Write <filename></b> <br> |
| 1498 | Start to write received TEXT to the file. (see Wbin / Rbin commands for |
| 1499 | BINARY files)</p> |
| 1500 | |
| 1501 | <p><b>YPUT <filename></b> <br> |
| 1502 | Transmit the file using the YAPP protocol. </p> |
| 1503 | </ul> |
| 1504 | </p> |
| 1505 | |
| 1506 | <h3> Macros</h3> |
| 1507 | <p> |
| 1508 | <ul> |
| 1509 | <p><b>Activity</b> <br> |
| 1510 | Show the time since the last operator activity. This is also posted when |
| 1511 | users first log into the Linpac system</p> |
| 1512 | |
| 1513 | <p><b>Conv</b> <br> |
| 1514 | Enter the conference. </p> |
| 1515 | |
| 1516 | <p><b>Info</b> <br> |
| 1517 | Print local station information. </p> |
| 1518 | |
| 1519 | <p><b>Help</b> <br> |
| 1520 | Print brief help information. </p> |
| 1521 | |
| 1522 | <p><b>PW [<command> [<system> [<password>] ] ]</b> <br> |
| 1523 | Start the authorization to the BBS or the node. See <a |
| 1524 | href="#POS8_2_2">chapter 8.2.2</a> . </p> |
| 1525 | |
| 1526 | <p><b>Quit</b> <br> |
| 1527 | Send the quit text and disconnect. </p> |
| 1528 | |
| 1529 | <p><b>Users / CStatus</b> <br> |
| 1530 | Print list of connected users. </p> |
| 1531 | </ul> |
| 1532 | </p> |
| 1533 | |
| 1534 | <h3> Commands for creating scripts</h3> |
| 1535 | <p> |
| 1536 | <ul> |
| 1537 | <p><b>MACRO [name]</b> <br> |
| 1538 | Start of the command script definition (see below).</p> |
| 1539 | |
| 1540 | <p><b>LABEL <label_name></b> <br> |
| 1541 | Create a label with specified name. In the command scripts the notation |
| 1542 | :<label_name> can be used. </p> |
| 1543 | |
| 1544 | <p><b>GOTO <label_name></b> <br> |
| 1545 | Jump to specified label. </p> |
| 1546 | |
| 1547 | <p><b>IF ~ ELSE ~ ENDIF</b> <br> |
| 1548 | Conditional commands. There are two ways to specify a condition: </p> |
| 1549 | |
| 1550 | <ul> |
| 1551 | <li> normal notation (for more than one command)</li> |
| 1552 | |
| 1553 | <p><b>IF</b> <condition> <br> |
| 1554 | . <br> |
| 1555 | . <br> |
| 1556 | (commands to be done when the condition is true) <br> |
| 1557 | . <br> |
| 1558 | . <br> |
| 1559 | <b>ELSE</b> <br> |
| 1560 | . <br> |
| 1561 | . <br> |
| 1562 | (commands to be done when the condition is false) <br> |
| 1563 | . <br> |
| 1564 | . <br> |
| 1565 | <b>ENDIF</b> </p> |
| 1566 | |
| 1567 | <p>The ELSE part is not necessary - the IF ~ ENDIF notation is possible. |
| 1568 | </p> |
| 1569 | |
| 1570 | <p>abbreviated notation (for one conditional command) </p> |
| 1571 | |
| 1572 | <p><b>IF</b> (<condition>) command </p> |
| 1573 | |
| 1574 | <p>The parentheses are necessary in this case.</p> |
| 1575 | </ul> |
| 1576 | |
| 1577 | <p><b>RETURN [<data>]</b> <br> |
| 1578 | Abort the macro execution and return the data as a result.</p> |
| 1579 | |
| 1580 | <p><b>SLEEP <seconds></b> <br> |
| 1581 | Pause the macro for specified time in seconds. </p> |
| 1582 | |
| 1583 | <p><b>WAITFOR <condition></b> <br> |
| 1584 | Pause the macro until the condition is true. </p> |
| 1585 | </ul> |
| 1586 | </p> |
| 1587 | |
| 1588 | <p> </p> |
| 1589 | <hr> |
| 1590 | |
| 1591 | <h2> <a name="POSFAQ"></a></h2> |
| 1592 | <h2>Appendix B - Linpac FAQ / Questions and Answers / Getting more help</h2> |
| 1593 | <p> |
| 1594 | <ol> |
| 1595 | <li><b>Q: X doesn't work right in Linpact. Why?</b><br> |
| 1596 | <b>A:</b> Have you looked in the errors.txt file found in the main LinPac directory? It can provide a lot of clues.</li> |
| 1597 | <p></p> |
| 1598 | |
| 1599 | <li><b>Q: When I start Linpac, I get "Segmentation fault". What is the fix?</b><br> |
| 1600 | <b>A:</b> You are probably running an old version of Linpac. Please try the newest release |
| 1601 | version available at <a href="https://sourceforge.net/projects/linpac/">https://sourceforge.net/projects/linpac/</a> |
| 1602 | or possibly the newest DEVELOP branch. This will most likely require you to |
| 1603 | compile Linpac to get it running</li> |
| 1604 | <p></p> |
| 1605 | |
| 1606 | <li><b>Q: When I start Linpac, all of the text in the AX.25 monitor is indented |
| 1607 | to the right. How do I fix this?</b><br> |
| 1608 | <b>A:</b> Exit Linpac, go into the directory where Linpac is installed, and delete the file: |
| 1609 | <p></p> |
| 1610 | <ul> |
| 1611 | <code>monitor.screen</code> |
| 1612 | </ul> |
| 1613 | <p></p> |
| 1614 | Now restart Linpac. Did that solve your issue? No? Also try deleting the files <code>window*.screen</code> and restart Linpac</li> |
| 1615 | <p></p> |
| 1616 | |
| 1617 | <li><b>Q: My question isn't addressed in this document, where else can I get help?</b><br> |
| 1618 | <b>A:</b> Consider reviewing these other URLS: |
| 1619 | <ul> |
| 1620 | <li><a href="https://sourceforge.net/p/linpac/linpac/ci/develop/tree/linpac-todo.txt">Review Linpac's known bugs and enhancement requests</a><br> |
| 1621 | <li><a href="http://www.trinityos.com/HAM/CentosDigitalModes/hampacketizing-centos.html#11.linpac">KI6ZHD's HamPacket documentation</a><br> |
| 1622 | <li><a href="http://www.trinityos.com/HAM/CentosDigitalModes/RPi/rpi4-setup.html#28.install-linpac">KI6ZHD's Raspberry Pi documentation</a><br> |
| 1623 | <li><a href="https://sourceforge.net/projects/linpac/support">Linpac's SourceForge Discussion area</a><br> |
| 1624 | <li><a href="https://sourceforge.net/p/linpac/_list/tickets">Submit a bug / enhancement request via Linpac's SourceForge ticketing system</a><br> |
| 1625 | </ul></li> |
| 1626 | </ol> |
| 1627 | |
| 1628 | </p> |
| 1629 | |
| 1630 | <p> </p> |
| 1631 | <hr> |
| 1632 | |
| 1633 | <h2> <a name="POSErrata"></a></h2> |
| 1634 | <h2>Appendix c - Errata</h2> |
| 1635 | <p> |
| 1636 | 03/30/2020 - dranch |
| 1637 | <ul> |
| 1638 | <li>Expanded packet mail section on how to configure message system for PBBS |
| 1639 | and FBB remote systems</li> |
| 1640 | <li>Added a FAQ section and added this errata section</li> |
| 1641 | <li>Improved formatting and added this errata section</li> |
| 1642 | </ul> |
| 1643 | </p> |
| 1644 | |
| 1645 | <p> |
| 1646 | 04/01/2019 - dranch |
| 1647 | <ul> |
| 1648 | <li>Minor improvements |
| 1649 | </ul> |
| 1650 | </p> |
| 1651 | |
| 1652 | <p> |
| 1653 | <hr> |
| 1654 | </p> |
| 1655 | |
| 1656 | <p style="font-style:italic; font-size: -1;">Last update: March 30 2020<br/> |
| 1657 | Please report any errors to <a |
| 1658 | href="mailto:[email protected]">[email protected]</a></p> |
| 1659 | |
| 1660 | </body> |
| 1661 | </html> |