1 |
#include <16F88.h> |
1 |
#include <16F88.h> |
2 |
#device adc=8 |
2 |
#device adc=8 |
3 |
|
3 |
|
4 |
#FUSES NOWDT //Watch Dog Timer |
4 |
#FUSES NOWDT //Watch Dog Timer |
5 |
#FUSES INTRC_IO //Internal RC Osc, no CLKOUT |
5 |
#FUSES INTRC_IO //Internal RC Osc, no CLKOUT |
6 |
//#FUSES INTRC |
6 |
//#FUSES INTRC |
7 |
//#FUSES XT |
7 |
//#FUSES XT |
8 |
#FUSES PUT //Power Up Timer |
8 |
#FUSES PUT //Power Up Timer |
9 |
//#FUSES NOMCLR //Master Clear pin used for I/O |
9 |
#FUSES NOMCLR //Master Clear pin used for I/O |
10 |
#FUSES NOBROWNOUT //No brownout reset |
10 |
#FUSES NOBROWNOUT //No brownout reset |
11 |
#FUSES NOLVP //No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O |
11 |
#FUSES NOLVP //No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O |
12 |
#FUSES NOCPD //No EE protection |
12 |
#FUSES NOCPD //No EE protection |
13 |
#FUSES NOWRT //Program memory not write protected |
13 |
#FUSES NOWRT //Program memory not write protected |
14 |
#FUSES NODEBUG //No Debug mode for ICD |
14 |
#FUSES NODEBUG //No Debug mode for ICD |
15 |
#FUSES NOPROTECT //Code not protected from reading |
15 |
#FUSES NOPROTECT //Code not protected from reading |
16 |
#FUSES NOFCMEN //Fail-safe clock monitor disabled |
16 |
#FUSES NOFCMEN //Fail-safe clock monitor disabled |
17 |
#FUSES NOIESO //Internal External Switch Over mode disabled |
17 |
#FUSES NOIESO //Internal External Switch Over mode disabled |
18 |
|
18 |
|
19 |
#use delay(clock=4000000) |
19 |
#use delay(clock=4000000) |
20 |
//#use delay(clock=3686400) |
20 |
//#use delay(clock=3686400) |
21 |
#use rs232(baud=2400,parity=N,xmit=PIN_B5,rcv=PIN_B2,bits=8)//,FORCE_SW) |
21 |
#use rs232(baud=2400,parity=N,xmit=PIN_B5,rcv=PIN_B2,bits=8)//,FORCE_SW) |
22 |
#use i2c(MASTER,SLOW,sda=PIN_B1,scl=PIN_B4,SMBUS) |
22 |
#use i2c(MASTER,SLOW,sda=PIN_B1,scl=PIN_B4,SMBUS) |
23 |
|
23 |
|