Saturday 14 December 2019

Timer

Date of completion: 2018-19

Design

Having bought a small solar powered cascade for the pond in 2018, I soon discovered that it had a very limited range of settings for the length of time for which it could be switched on each day. So I bought some more solar panels to boost the charging rate and then set about designing my own daily timer for it. The timer is based around a Microchip PIC16F628 (programmed in assembler) with an LCD display and three push buttons to set current time, time for switch-on and time for switch-off. The pump current is switched on and off by an n-MOSFET. There is also a reset button, which is useful to recover from glitches and also to switch the pump off permanently without unplugging everything. In addition it has a means of overriding the current settings, so that the cascade can be switched on during an off-period, and vice versa. The display switches itself off via a p-MOSFET after a certain time (about 2 minutes) during an off-period in order to save the battery charge (the display current, however, is fairly small compared to that of the pond pump, so it makes sense to leave the display on during those times.)
Later I added a comparator to ensure the whole thing switches off if the battery voltage falls below 4V (the cascade controller has a 6V SLA cell.) Later still I added a solid state relay, so that the timer could be used for other circuits, e.g. Christmas lights.

Photos



Circuit Diagram

Tiny CAD (.dsn) files: Timer


Source code and other files

Timer.asm - All files (zipped)

No comments:

Post a Comment