„README.md“ ändern

This commit is contained in:
Michael Clemens 2021-12-08 20:56:19 +01:00
parent 49ec5b36e2
commit 0f8f5336e5
1 changed files with 16 additions and 1 deletions

View File

@ -57,6 +57,14 @@ String api_base_url = "http://192.168.1.100:5000";
Add the files to your Arduino IDE, install all necessary libraries, configure the board and USB/serial port, compile the sketch and then upload it.
## Usage
Execute the server (see below) and power up the ESP board. The following user interaction is possible:
* short press of the upper button: executes a shell script / system command / program (Server config parameter 'shell_cmd')
* long press of the upper button: sends a serial commannd to the HR50. The default command will initiate the tuning cycle during the next transmission (Server config parameter 'serial_cmd')
* the lower button reboots the device
## Error handling
* If wifi is unavailable or misconfigured, the device will show "No Wifi!" on the screen
@ -72,13 +80,20 @@ You need a computer connected to the Hardrock-50 via USB, e.g. a Raspberry Pi. T
# Configuration
Open the file _hr50_rd_server.py_ and adapt the following lines to your environment:
Open the file _hr50_rd_server.py_ and adapt the following lines to your environment regarding the USB connection to the HR50:
```
serial_port = '/dev/ttyUSB0'
baud = 19200
```
Edit the following lines if you want to customize the actions performed when pressing the upper button:
```
shell_cmd = "./scripts/toggle_antenna.sh"
serial_cmd = "hrtu1"
```
# Execution
Executing this script will spawn a web server running on port 5000. This is not meant for production use and/or public exposure. Anyone able to access this server via the network can alter any settings on your HR50.