Temp Controller with Data logging and Web Interface

I have built a temp controller using an Arduino Leonardo and a series of DS18B20 sensors. I have the controller up and working. The next step for the project is data logging, and a web page interface.

So for now the Arduino is connected to my laptop and run from there. I want to use the USB serial port to collect data in a database of some form such as mySQL or maybe as a CSV file.

The laptop is connected to the internet via Wifi, however the connection isn’t the greatest. So my idea would be to log the data locally on the laptop and then have that push to the internet when it has a connection. With this in mind which approach would work best? Or is there a better option?

Also looking at what language to use to collect the data from the arduino. PHP or Python. Most examples I have found online use Python and the PySerial library. But then if I am going to build an Web Interface for it, that will require PHP? Again which option works best? Or is a combination of the two the way to go?

I want the web page interface to show real time data from the sensor, and be able to display graphs of historical data. As well as be able to change the setpoints on the various tanks the controller is monitoring. This will mean not just collecting data from the arduino, but pushing data back to it.

Any help or advice would be much appreciated.

I can't quite see what the parts are here:

What do you mean by "push to the internet"? Are you planning to use some service such as Xively?

Where is your web page going to be hosted?

Sorry if I am not being clear.

The Arduino is permanently connected to my laptop. What I want to be able to do is create an interface that lets me see real time data, logged historical data and change variables on the arduino.

The idea is I can run this from the laptop locally or access it via the internet. I hadn’t thought about using Xively or got as far as working out where I will host my web page. These are all still up for debate. I do have my own domain with HostGator, which I could use to host it.

You'll need to build something in your language of choice that runs on the laptop. It'll talk to the arduino over serial, store data locally and when wifi is available, push it to the web server using a GET request. The web server will store the data and other pages will render graphs/charts of that data. Look at the google charts api - might suit your needs. The response to the GET request will be the settings for the arduino that were entered via another page on the web server. Your laptop program will parse them and pass them on to the arduino.

Given all that though, your laptop is just acting as a middle man between the arduino and the web server (unless the laptop is going to be the web server) so I'd be inclined to use an arduino with wifi or ethernet connectivity and cut the laptop out of the picture - you won't have to run it all the time then either.

I can understand the benifit of going straight from the Arduino to the Internet. But it would have to be via WiFi due to the location of the controller. I am using the Laptop for that connection. I realize this is overkill, and I do eventually plan to swap the laptop over to a Rasberry Pi I have.

But for now I am happy to have the laptop handle that side of the connection.