With a huge amount of help I can now offer
"The Ichbinbier Option" - a "scrolling" temperature display with a link to the temperature logger gui as an add-on to the RaspberryPints tap list display. You can see the latest temperature data for each One-Wire probe display in sequence for up to five channels right on the tap list page.
Overview:
Basically, this procedure will cause the RaspberryPints tap list web page to pull in a chunk of primarily JavaScript code that will take the latest entry in the temperature logger database, sort out the individual probe readings, and then display them in turn in a small bit of text next to a thermometer icon that links to the logger display gui.
Installation:
- Obviously, this add-on assumes one is using my temperature logger to begin with
If you're not currently running the logger, please start with the instructions found
here.
Get that running first, then you can add this on.
- Next, you
must install support for sqlite on php, by executing the following two commands from a terminal session:
$ sudo apt-get update
$ sudo apt-get install php5-sqlite
- Next, copy the file temp_insert.php from my Google Drive
here to /var/www/temp_insert.php. Be sure to set the ownership and permissions to match whatever is set for the RaspberryPints index.php file. I use WinSCP from my W7U workstation to view and change file properties, but you can use a terminal session as well.
Show ownership and permissions of index.php:
$ ls -l /var/www/index.php
-rwxrwxrwx 1 pi pi 13315 Oct 9 21:17 index.php
Index.php is owned by user 'pi' in group 'pi' with permissions set to 0777
If the same command used for temp_insert.php results in different owner and/or permissions, change them:
Change ownership to 'pi' in group 'pi':
$ sudo chown pi
i /var/www/temp_insert.php
Change permissions:
$ sudo chmod 777 /var/www/temp_insert.php
- Edit temp_insert.php and set the variables listed below.
Note that there is a "php" set and a "javascript" set of variables to configure.
The "php" set is at the top of temp_insert.php, the "javascript" set follows.
This is the php set.
//Enter all variables between the php tags
//Set database name. If you used the original logger installation, this could be temp_data1.db, temp_data2.db...to temp_data5.db.
$dbname = 'temp_data5.db';
//Set Fahrenheit(F) or Celcius(C). Note that this is just part of the label, it doesn't affect the numeric temperature readings.
$cf = "F";
//Channel labels go here. Terse works best if you want to support handheld displays. My 5 channel labels are shown.
$ch0 = "Ch0 Room";
$ch1 = "Ch1 Tower";
$ch2 = "Ch2 Upper";
$ch3 = "Ch3 Lower";
$ch4 = "Ch4 Keg";
//URL string to the RaspberryPints server. If your server listens to a non-standard port (ie: anything other than 80) be sure to include the port as shown in the example setting below. If you never changed the default listening port, omit the colon and the numbers that follow. If you do not intend to access the tap list from beyond the RaspberryPi console, you can use 'localhost' or '127.0.0.1'; if you want to access the RPi inside your LAN, you need to set this to the LAN addressfor the RPi; if you want to access from the internet, you need to use your WAN address. The example shown is a WAN address listening on port 84.
$url = "96.252.83.39:84";
//Name of webguiN.py file for the temperature logger gui. If you installed the temperature logger using the filenames in the original logger kit, 'N' could be 1 through 5 (hence webgui1.py, webgui2.py...webgui5.py) depending on the number of supported channels. Default is set to webgui5.py for five channels.
$gui_file = "webgui5.py";
The "javascript" variables start at line 28. The only critical setting is the variable "channels", the rest tune the appearance of the temperature display and aren't shown here.
var channels = 5; //valid setting is from 1 through 5, and defines the number of temperature channels to display
Now save the file.
- Next, make a back-up copy of the RaspberryPints /var/www/index.php file just in case, then edit index.php as follows:
Read the next steps carefully:
Look for this line (occurs at line 98 in the original v2.0.1 file):
<div class="HeaderRight">
Cut the (5) lines of code directly following the above tag, down to but not including the </div> tag.
Then type in this single line (still in between the <div class="HeaderRight"> tag and the following </div> tag):
<?php include'temp_insert.php'; ?>
Then, scroll down near the very bottom of the file, find the last occurrence of the </body> tag, and paste the cut lines directly
above that tag. This will move the RaspberryPints logo to the bottom of the tap list display, making room for the temperature display.
Save the file and exit the text editor.
And that's it. If you load your RaspberryPints tap list page, the thermometer icon that links to the logger gui should appear in the top right corner, with the "rolling" temperature channel data listed directly to the left.
Cheers!
[edited 10/10/14 to refine instructions]