* You may add additional uplinks for different locations by repeating the previous step
* Happy traveling ...
+The buttons at the bottom of the LuCI overview page behave as follows:
+
+| Button | Description |
+| :------------------- | :----------------------------------------------------------------------------------------------------------------- |
+| **Stop** | Stops the travelmate service. Greyed out while the service is not running |
+| **Interface Wizard** | One-time setup of the uplink interface, firewall zone and metric |
+| **Interface Restart** | Restarts the travelmate uplink interface without touching the configuration |
+| **AP QR-Codes** | Displays a QR code per AP to transfer the wireless credentials to your mobile devices |
+| **Save & Restart** | Applies pending configuration changes and restarts the service, this also brings a stopped service back up |
+
+While a run cycle is in progress (status `processing`), all buttons except **Stop** are temporarily locked to avoid overlapping actions. **Stop** always stays available, so an unwanted or long running cycle can be interrupted at any time - e.g. right after the **Interface Wizard** on a fresh setup, when no uplink station has been configured yet.
+
<a id="travelmate-cli-interface"></a>
## Travelmate CLI interface
* All important travelmate functions are accessible via CLI, too. If you're going to configure travelmate via CLI, edit the config file `/etc/config/travelmate` and enable the service, see the options reference tables below.
+ system_info : cores: 2, fetch: curl, Cudy TR3000 v1, mediatek/filogic, OpenWrt SNAPSHOT (r32287-1c7ec8ab19)
```
+The `travelmate_status` field reports one of the following states:
+
+| State | Description |
+| :-------------- | :-------------------------------------------------------------------------------------------------------------- |
+| `connected` | An uplink is connected, followed by the connection details, e.g. `connected, net ok/100` |
+| `processing` | A run cycle is currently in progress, e.g. scanning the radios or waiting for an uplink to come up |
+| `not connected` | No uplink is connected and no run cycle is active, i.e. travelmate is idle and waiting for the next trigger |
+| `program error` | A fatal error occurred, the daemon has stopped, please check the syslog |
+
+A stopped service does not report a state at all, it truncates the runtime file instead - LuCI shows this as `stopped`.
+
<a id="travelmate-config-options"></a>
## Travelmate config options
* Usually the pre-configured travelmate setup works quite well and no manual config overrides are needed. All options listed below apply to the 'global' section:
trm_useragent="Mozilla/5.0 (X11; Linux x86_64; rv:144.0) Gecko/20100101 Firefox/144.0"
trm_action="${1}"
trm_runmode=""
+trm_active="0"
# ensure runtime directory exists
#
status="program error"
else
trm_connection=""
- status="processing"
+ if [ "${trm_active}" = "1" ]; then
+ status="processing"
+ else
+ status="not connected"
+ fi
runtime="-"
fi
local radio cnt retrycnt scan_list scan_essid scan_bssid scan_rsn scan_wpa scan_quality scan_open station_id retry_display
local section sta sta_essid sta_bssid sta_radio sta_mac open_sta open_essid config_radio config_essid config_bssid
+ # mark the run cycle as active, e.g. to distinguish 'processing' from an
+ # idle daemon in f_genstatus
+ #
+ trm_active="1"
+
# initial check
#
f_check "initial" "false"
done
done
fi
+
+ # the run cycle is over, settle the status file for the idle phase, e.g.
+ # to turn a leftover 'processing' into 'not connected'
+ #
+ trm_active="0"
+ if [ "${trm_ifstatus}" != "true" ] && [ "${trm_ifstatus}" != "error" ]; then
+ f_genstatus
+ fi
}
# reference required system utilities