Difference between revisions of "Online heating system control project"

From Wiki2
Line 43: Line 43:
:http://net.tutsplus.com/tutorials/php/managing-cron-jobs-with-php-2/
:http://net.tutsplus.com/tutorials/php/managing-cron-jobs-with-php-2/
:http://stackoverflow.com/questions/4421020/use-php-to-create-edit-and-delete-crontab-jobs
:http://stackoverflow.com/questions/4421020/use-php-to-create-edit-and-delete-crontab-jobs
====parts====
=====[http://www.maximintegrated.com/datasheet/index.mvp/id/2735 DS1620 Digital Thermometer and Thermostat]=====
In a [http://www.rentron.com/project01.htm thermostat circuit]
=====[http://datasheets.maximintegrated.com/en/ds/DS18B20.pdf DS18B20] Dallas 1-wire temperature sensors=====
::[http://www.practicalarduino.com/projects/online-thermometer online thermometer]for encased red=vcc,black=gnd,yellow=data
http://circuits.datasheetdir.com/101/DS18B20-pinout.jpg

Revision as of 23:01, 8 January 2013

back to electronics

online heating system control project

bits and pieces

version 3
php www-data program that creates a crontab and calls a C program that executes root commands to copy it into crontabs and install it
write a php file that PUTS some light on on the AVR
collect data from AVR and store it in mysql
view the saved data on a client using javascript

code working on arduino

version 2
Online thermometer creating web page in which you call for the data by clicking a button. Uses design from Practical Arduino in /tim/Documents/electronics/arduino/thermometerthermometer.ino and it runs at http://10.0.1.79
version 1
Take random readings from analog pins start an etehrnet client that sends them out to http://cosm.com (mcktimo 6j) every ten seconds :comtest.ino

final narrative

An Avr takes in temperature readings from multiple locations. At the control room the AVR hub polls temperature and for each zone knows the set temperature, the default temperature and whether or not a zone is ON and how long it has been on. If it doesn't hear from the (linux) scheduler then it falls back to act as a multi-zone thermostat set at the default temperatures. Through a rudimentary display it would allow you to set temperatures for each zone.

The scheduler would take temperature data from the AVR client and would know the schedule. Whenever a schedule change point would come up, it would notify the AVR and instruct it to change the set point. It would do this via chrontab maybe.

The controller would on the client probably an HTML5/javascript client. Here you can read the temperatures and view the schedule. You can override or change the schedule.

possible routes

A cheap circuit like http://www.craig.copperleife.com/tech/thermo/ or more complicated http://www.rentron.com/project01.htm using http://datasheets.maximintegrated.com/en/ds/DS1620.pdf which can be overridden by server program that controls multiple thermostats.

ReST

http://cosm.github.com/cosm-js/tutorial/
accessing-incoming-put-data-from-php
create-a-rest-api-with-php
http://rest.elkstein.org/2008/02/using-rest-in-php.html
http://blog.garethj.com/2009/02/17/building-a-restful-web-application-with-php/
get for my feed
making-reliable-connections-with-arduino
websockets
http://code.google.com/p/phpwebsocket/
start-using-html5-websockets-today
cosm javascript library docs

Cron Jobs

Hudsonvalley#cron_and_backups
http://net.tutsplus.com/tutorials/php/managing-cron-jobs-with-php-2/
http://stackoverflow.com/questions/4421020/use-php-to-create-edit-and-delete-crontab-jobs

parts

DS1620 Digital Thermometer and Thermostat

In a thermostat circuit

DS18B20 Dallas 1-wire temperature sensors
online thermometerfor encased red=vcc,black=gnd,yellow=data

DS18B20-pinout.jpg