This is a software package to be used with the Homelab-pH module. After the installation of the package a web browser is used for visualization of the module readings, for its calibration, for setting periodic/continuous unassisted measurements (PUM), and for logging and plotting data.

The package installation may be done under various OS. Raspberry Pi OS (Raspbian), Ubuntu, Armbian OS, as well as DietPi are available at Raspberry Pi Imager. All are in fact based on a Debian/GNU-Linux. The imager can be downloaded at the Raspberry Pi web site.

The operating system should have Apache web-server installed to send the module readings to the browser. If it is not found the installation script will try to install the Apache package. Other modules and packages to be installed if not present are: i2c_bcm2708, i2c_dev, i2c-tools, w1-gpio, w1-therm and bc.

An active internet connection has to be available during the installation.

INSTALLATION
------------
1.	Start the RPi console and create a new directory (installation directory).
2.	Go to the site's Downloads section, get the HomeLab-pH installation file and place it in the installation directory.

OR,
alternatively:

go to the installation directory and at the command line execute the following to download the installation file:

curl https://homelab.link/ph/meter/software/rpi/get/ -OJ

3.	Unpack the installation file:

   tar -xvf hl_install_xxxxxx.tar.gz --overwrite
   
   "xxxxxx" to correspond to the version number (see the name of the installation file).


4.	Run the package installation like this:
    sudo bash homelab_install.sh

    or to enable PUM:
    sudo bash homelab_install.sh --enable-pum

    or to disable PUM:
    sudo bash homelab_install.sh --disable-pum

5.	Wait for the script to finish.

If successful:

6.	Take a note of the printed IP-address at the end of the installation. 
	This is where the HomeLab-pH module may be found.

7.	Restart the system if asked to do so.

A log file is created which may be useful in case something went wrong with the 
installation.

USAGE
-----
Be sure the device the HomeLab-pH module resides on (e.g. RPi mini-computer) is 
connected to the local net. Start a web-browser on a whatever connected device 
and point it to the IP-address printed at the end of the installation 
procedure. You should see the HomeLab-pH meter readings.

Have in mind though that it would be better the mini-computer to be assigned to 
a static IP-address. Otherwise varying IP-address may be assigned to it by the 
router. In this case you should find yourself what its IP-address is.

HELP
----
Visit HomeLab site at 
http://homelab.link/ph/meter/software/rpi/

DISCLAIMER
----------
Although the authors has attempted to find and correct any bugs in this free
package of software code, the authors are not responsible for any damage or 
losses of any kind caused by the use or misuse of the code. 