Pic controlled fan

This construction is used to control a 120mm computer fan. The fan is mounted in a vent in the wall, and turns on and off depending of how hot it is in the room. There is a LDR to which can be used to stop the fan from running when it's dark (ie when you're sleeping), but it's not used in my firmware. The potentiometers are used to control at what temperature the fan will turn on and how long it will be running at each time.