home    builders    Search

TARPN Command -- List of commands/parameters

This document describes the commands available from the Raspberry PI under Linux using the tarpn command. These commands are used to start, stop, test, configure, connect to and listen for connects from your TARPN node.

This document is evolving as the TARPN programs on the Raspberry PI evolve.
You can do a tarpn update command to retrieve the lastest code for your version.
Keep an eye out for TARPN groups-io email reflector emails for significant changes and new releases.
Post any questions, suggestions, observations, bug reports, complaints, etc.. as well.

tarpn sysinfo

Obtains version numbers and system configuration info for display. This is a good place to start if trying to see if your system has the proper software and USB provisioning.

tarpn ps

Process list. Does ps auf and shows any processes associated with a tty. Shows the process hierarchy using ASCII art.

tarpn update

This goes out to the Internet and pulls down the latest copies of the tarpn command program, and several functions called out by the tarpn command. A side effect of this command is that the G8BPQ node is kicked. If it is set to auto it will start up again. If it was run using tarpn test, it will count-down and then quit. This command takes a few seconds to run.

tarpn updateapps

This goes out to the Internet and pulls down the latest copies of System resources, Applications (including G8BPQ node software) and some utilities. This command cannot be run if the G8BPQ node software is running. This command takes a few minutes to execute.

tarpn shutdown

Puts the Raspberry PI to sleep. This is the first step in turning off your node hardware. Once this command is complete the node is still powered up but it is in a lock-up state waiting for power to be removed.
After doing this command the Raspberry PI will close all SSH and Telnet links, close all open files, disconnect from Ethernet, shutdown the G8BPQ node. You should wait a minute after issuing this command before removing power. Removing power while the software is still shutting down can corrupt the file system on the SDcard. If the lights are still blinking on the Reaspberry PI, then it is definitely not safe to power it off.

tarpn reboot

This does the same thing as shutdown except it then performs a file system repair, and then brings the Raspberry PI back on-line. If the G8BPQ node is set for auto-start, it will come back on-line.

tarpn url

This reports the current URL and then prompts you for a new URL. This URL is the source for TARPN updates. The URL is tested after you enter it and you will be prompted again if tarpn script files are not present at the new URL. The URL for released TARPN code at time of this publication is http://tarpn.net/2017aug. Watch for updates on the TARPN groups-io email reflector.

tarpn config

Prompts you for configuration details needed for your node/station. This function will let you keep the existing values, or will change them. For each value you are prompted with the old value. Hitting ‹ENTER› will leave your existing value. You can control-C out of this function and no changes will be saved.

Note that this feature is not available if the node is already running. You must quit the node or stopauto and reboot, whichever is applicable, before running this command. The reason this is so is to make sure you don't introduce destructive changes that could cause the node to be unstable, possibly breaking your access to the Raspberry PI. By forcing you to quit the node before making changes, you are given the opportunity to run the node as an application using tarpn test before committing to automatic operation.

tarpn tx

Use this command to connect to your G8BPQ node for exploration or to connect to another station.
This starts a local telnet session from your terminal window to the G8BPQ node on your Raspberry PI. You could also telnet directly from your workstation to the Raspberry PI's TCP/IP address. Please do not use telnet to connect to the Raspberry PI over the Internet. That sort of defies the whole TARPN idea.
In a real emergency this could be used but please make sure to have a ham-in-the-middle and to move text-only into the network. Beware of overflowing the TARPN.

After issuing the tarpn tx command, you will be prompted to type your callsign to log in. After you type your callsign and hit ‹ENTER› you will be prompted for your telnet password. Your telnet password will always be p ‹ENTER› (lower case p). Finally you be connected to the node and can type r r ‹ENTER› to see your routes list.

tarpn host

Use this command to start an inbound HOST session. This command launches Minicom with a connection to a virtual port established by the G8BBPQ node. When Minicom is launched a script is run to configure the virtual port to accept inbound HOST requests.
Note, if the G8BPQ program is reset, this Minicom session is corrupted but left connected. You should exit Minicom and run tarpn host again, to reconnect.
To exit from Minicom, press control A followed by capital X.

Here is some documentation G8BPQ wrote on the subject: G8BPQ TNC2 Emulation

tarpn test

This command configures and launches G8BPQ node application. The application runs until the Raspberry PI is shutdown, the terminal window is quit, control C is given to the terminal window, or until an error occurs that the G8BPQ node can't deal with.
You should run the tarpn test command to verify that there are NOT any issues that the node can't deal with. The reason to run it in test before making it auto is that it is much easier to see the STDOUT messages from G8BPQ and from the scripting when running it from this command.
Once the G8BPQ node is seen to be stable and you are happy with its execution, you can control C out, and do the tarpn makeauto command to start the node automatically when the Raspberry PI launches.
During the test you should launch more terminal window sessions, then connect with tarpn tx and tarpn host and make sure the node responds to commands, that the TxDelays are set appropriately, and that your links behave correctly and are properly named.

tarpn home

This command starts, stops, updates, and inspects Linux SERVICE for the TARPN-HOME web app.
Commands are: tarpn home, tarpn home start, tarpn home stop, tarpn home update.

TNC-PI I2C setup utilities

tarpn i2c

Read the I2C bus and find out what TNC-PI addresses are currently attached to the top of the Raspberry PI. Note that the address readout is in HEXADECIMAL.
See FAQ Hexadecimal
to convert the HEX addresses to decimal, one at a time. for your convenience. Sorry.
Note: I2C commands will not work if the G8BPQ node software is running.
See Configure TNC-PI for examples.

tarpn i2c-assign

Assign an I2C address to an async TNC-PI. This is an initialization procedure usually done once to each TNC-PI and is performed with only one TNC-PI attached. Note: I2C commands will not work if the G8BPQ node software is running.
See Configure TNC-PI for examples.

tarpn i2c-get

Read all parameters from a TNC-PI at a particular address
Use with TNC address in decimal. Reads all parameters.
See Configure TNC-PI for examples.

tarpn i2c-set

Write a parameter change to a TNC-PI at a particular I2C address use with address in decimal, parameter number, and new value
See Configure TNC-PI for examples.

Automatic G8BPQ node startup

tarpn service

This command starts or stops the automatic background (service) execution of the G8BPQ node software. When enabled as a service, the node will automatically be run every time it is found to not be running. This is a good thing if the configuration is all set. Before running the node as a background service, you should test the node and verify that the print output from the execution is stable. The dead giveaway that it is not is that it will either give you really obvious ERROR output, or it will spew interesting messages faster than you can read them. Use tarpn test.

After verifying that the software works ok, use tarpn service start to run the node in the background.

Use tarpn service stop to discontinue background operation.

Please note that background operation is only prosecuted periodically. It may take a minute for the node to start running in the background, or to stop running, after you have issued the tarpn service start or stop commands.

You can verify that the node is running (but not that it is running error free) at any time just by typing
tarpn ‹ENTER›
The tarpn program will respond with
BPQ node is running or
BPQ node is NOT running
followed by
BPQ node background Service is (AUTO), or with
BPQ node is not set to run as a Service (!AUTO)

If the node crashes or is KILLed after having been launched from the service, the node will automatically re-launch.
Each time the node re-launches it will attempt to rebuild its configuration and will integrate Internet supplied data. If the Internet data is not supplied, the re-launch will continue and the configuration will be rebuilt using locally available information.

The tarpn service start command edits a token in /usr/local/etc/background.ini directory to tell /usr/local/sbin/tarpn_background.sh to start G8BPQ node automatically when the Raspberry PI boots up.

tarpn kill

This kills an existing node process. This will cause a node running as an application from a shell to be quit, just like control C would. It also will cause a node running as a service to be quit after which it will restart.

tarpn conspy

This launches an application, conspy, which monitors the console output for BPQ node background process. This is useful when doing a stop command and the BPQ node is set to run automatically. Note: Run this command from a 2nd ssh. To exit conspy, hit ESCAPE 3 times in a row..
© Tadd Torborg, 2014↝2019 -- all rights reserved