|Thermostat Project - six years in the making|
In December of 2009 one of the forum members on the PicBASIC Pro forum offered to assist me in developing a multi-channel pulse proportional thermostat. The concept was a simple unit that had 4 independent pulse proportional thermostats in one unit with an LCD display showing the set temperatures and the actual temperatures. Well once Darrel had given me the base code, I started adding other functions and with the help of other forum members managed to get the project to a point where it is now, a fully programmable environmental controller.
First off, it uses digital sensors. These are accurate to within +/- half a degree C (I could of used the more sensitive ones that are +/- one tenth a degree but don't need that degree of precision). The four thermostats control the heaters buy reading the sensors and comparing the read temperature with that set by the device, and then apply a pulse of power to the heater. The length of the pulse is calculated by the maths in a PID routine, thus as the temperature nears the set point the pulse gets shorter and shorter until it is applied just long enough to maintain the temperature. In trials it maintained temperatures to with in +/- 0.2 C of the target temperature.
However I then added a real time clock chip (DS1307) and have used this to provide the timing for two independent lighting circuits and four independent programmable night time settings which can allow a temperature drop at night. This can be set to drop the temperature by as little as one degree or down to 15C.
I then added an alarm function, so that in the rare event of a heater becoming locked on, or (more probable) the heater fails and the temperature falls outside of the high and low limits then the alarm sounds. Again, the high and low points are set individually for each thermostat. There are also safety functions built in should one of the sensors develop a fault, in that if the unit doesn't receive the digital data stream from the sensor it turns off the heater and the alarm will sound.
The guys on the Reptile Forum have been very supportive, and most have said they would buy one if it ever went into production. I don't really have the resources to take this to market, but I have designed a PCB and hoping to receive the prototype very shortly. Once the prototype PCB has been proven I might have a small batch made and offer them for sale through this web site, but a word of warning, the final product won't be cheap as the PCB alone works out at around £70 each !
The final option I'm looking at is communications between the device and a computer. So far I've managed to track down a sample VB.net example on the web which communicates to the device via an serial port, and I've had a generous offer from a chap in Canada to write an application in Liberty Basic which should also allow the device to be programmed from a PC - however we are just at the early stages in getting it to receive and display data - our 1st draft can be seen on the right
Well the prototype PCB arrived from the company in Cambridge, and to say I was disappointed was an understatement. The board had been milled rather than etched, and the clearances meant that it was impractical to solder. The upshot was that I slightly re-designed the PCB and had a batch of 6 made in Hong Kong by a company called PCBWing - for around £120 inc FedEX shipping I got 6 fully finished PCB's - that's £20 a board rather than £70 ! and these were fully solder masked and silk screened.
Working with a chap based in Canada (thanks Charles) we now have the option of programming the controller via a PC. In fact when connected it will log the temperatures whilst the application is open, so it can be used as a simple data logger too. So that about completed the project.... Er NO !
As there was so much interest I started looking at recovering my costs by offering these to the guys on the reptile forum. However I soon discovered that anything that is sold in the UK / EU has to be CE marked and to get to that point I need to have the device tested under several directives - net result is that I could be looking at a bill of between £5000 and £10,000 depending on what directives I have to comply with. Thinking that was that... I contacted several consultants who specialize in this field, and one guy called Alex has taken a keen interest in the project and is looking at various options, one includes a partnership in which the costs are recovered through the sales... so now I'm steaming ahead with the development of the MKII prototype, which will in effect be built to the same standard as a production unit. I'm also contacting local companies to get panels or a case fabricated to make production a lot less time consuming, especially as I have a full time job.
******* UPDATE ******
MKIII version now installed - details here