WIP: Refactor fintic source code #1

Draft
c0de wants to merge 7 commits from begin-refactor into main
Showing only changes of commit 8d2467cdbc - Show all commits

View File

@ -18,14 +18,16 @@
1. Reboot the pi: `sudo reboot now` 1. Reboot the pi: `sudo reboot now`
## Install the hotspot ## Install the hotspot
```console
```shell
cd ~ cd ~
curl "https://www.raspberryconnect.com/images/hsinstaller/AutoHotspot-Setup.tar.gz" -o AutoHotspot-Setup.tar.gz curl "https://www.raspberryconnect.com/images/hsinstaller/AutoHotspot-Setup.tar.gz" -o AutoHotspot-Setup.tar.gz
tar -xzvf AutoHotspot-Setup.tar.gz tar -xzvf AutoHotspot-Setup.tar.gz
cd Autohotspot cd Autohotspot
sudo ./autohotspot-setup.sh sudo ./autohotspot-setup.sh
``` ```
Choose option 2, then option 7 to change the SSID and password (for some reason it didnt work with the default SSID and password).
Choose option 2, then option 7 to change the SSID and password (for some reason it didn't work with the default SSID and password).
Then you can connect to the network and go to http://fintic.local:1024 or http://10.0.0.5:1024 and enter wifi information, then reboot Then you can connect to the network and go to http://fintic.local:1024 or http://10.0.0.5:1024 and enter wifi information, then reboot
@ -33,29 +35,26 @@ Then you can connect to the network and go to http://fintic.local:1024 or http:/
## Change the hostname ## Change the hostname
To change the hostname (URL used to access the server) first open config To change the hostname (URL used to access the server) first open config
```console ```console
sudo raspi-config sudo raspi-config
``` ```
Then go to system options -> hostname and change it to e.g. fintic Then go to system options -> hostname and change it to e.g. fintic
You then connect to the server using the url fintic.local:1024 You then connect to the server using the url fintic.local:1024
## Run instructions ## Run instructions
```console ```console
sudo -E python3 server.py sudo -E python3 server.py
``` ```
in browser go to url http://raspberrypi.local:1024 in browser go to url http://raspberrypi.local:1024
If it doesnt work because of a missing package try running setup.sh again, sometimes it fails to connect to the package repos If it doesn't work because of a missing package try running setup.sh again, sometimes it fails to connect to the package repos
## Notes ## Notes
To convert bdf font to pil format do `pilfont.py <font filename>`
To conver bdf font to pil format do pilfont.py <font filename>
pillow v 5.4.1 works, but version 8.2.0 breaks. pillow v 5.4.1 works, but version 8.2.0 breaks.