16F818 Temperature Controller
The PIC 16F818 is a replacement part for the 16F84A. It has a compatible pin-out (Figure 13.8), and additional features at a lower cost. Sixteen I/O pins are available, including five analogue inputs. It has 1k words of program memory; if extra memory is needed, the 16F819 has the same features but 2k program memory. As usual, each pin has multiple functions, other than the two supply pins. Analogue inputs can be selected on RA0eRA4, or external reference voltages. There is a capture, compare and PWM (CCP) module and a synchronous serial port offering serial peripheral interface (SPI) or inter-integrated circuit (I2C) modes. Other special features are a variety of power-saving modes in addition to the usual ‘sleep’, an internal oscillator which obviates the need for external clock components, and in-circuit programming and debugging.
This chip can be used in the temperature controller if the keyboard is eliminated, and the set temperature is input from a pot via one of the analogue inputs (Figure 13.9). A fixed control range might be acceptable, or other analogue inputs assigned for setting maximum and
minimum temperatures. The display digit selection can be reconfigured to use only one output, or binary coded decimal (BCD) displays used which need only four outputs each. The application then only needs 16 I/O pins. Operating data could be transferred via the serial interface if the display is omitted (RB1, RB2 and RB4).