Difference between revisions of "Repeater Controller SSH Commands"

From BATC Wiki
Jump to navigation Jump to search
Line 1: Line 1:
In normal operation, the repeater controller is set to start itself on boot-up.  There is aan SSH Console menu for basic configuration; some of the more advanced commands are also listed on this page.  
+
In normal operation, the repeater controller is set to start itself on boot-up.  There is an SSH Console Menu for basic configuration; some of the more advanced commands are also listed on this page.  
  
 
===Changing Basic Settings===
 
===Changing Basic Settings===

Revision as of 16:28, 5 March 2022

In normal operation, the repeater controller is set to start itself on boot-up. There is an SSH Console Menu for basic configuration; some of the more advanced commands are also listed on this page.

Changing Basic Settings

You can change most of the basic settings with the Controller Menu. Just type

menu

Controller ssh menu.jpg


The additional commands that can be used from the SSH command line need to you to be working from the home directory. You can ensure this by typing

cd /home/pi

Stopping the Controller

The controller can be stopped by entering

stop

at the command line. This tells all the repeater processes to stop and should show a "Controller Software Not Running" caption on the HDMI output.

Editing the Configuration File

You can also hand-edit the configuration file with the command

nano atv-rptr/config/repeater_config.txt

Use the arrow keys to move about (not the mouse) and save by pressing ctrl-x, y and then enter. Discard changes by simply pressing ctrl-x and then n.

If it has all gone wrong, you can start again with a factory-fresh configuration file using the command

cp atv-rptr/config/repeater_config.txt atv-rptr/config/repeater_config.txt.factory

Note that you will lose all if your previous edits.

Restarting the Controller for Testing

You can restart the controller for testing by entering

rptr

You will see a running commentary of what the repeater is doing in the console window. However, if you close the window, the repeater will stop. You can also stop it and get back to the command prompt by pressing ctrl-c.

You can start the repeater so that it runs and keeps a log of what it is doing (even if you close the controller window) by entering this command:

nohup atv-rptr/utils/run_rptr_nohup_with_log.sh &

Then press ctrl-c to get back to the command prompt.

If you see behaviour that you want to investigate, enter

stop

to force the last bit of the log to be written to the file, and then enter

tail -25 log.txt

to see the last 25 lines of the log.

Do not run the repeater for normal use using these test modes. The log file will grow over time and eventually fill the SD Card, causing the repeater to fail.

Getting Back to Normal Use

At the end of a maintenance session, you should always reboot the repeater to check that it is working properly and put it in its normal mode. Do this by typing

sudo reboot now

Close the SSH window, watch the repeater output and if all is well, walk away.

Advanced Commands

If you need to edit the C code, you can recompile it and run the repeater software with the command

urptr

This will also show you any errors if the compilation fails.

If you need to troubleshoot the output display settings, use

tvservice -s