Complete Example Programs
LCD
A/D
PWM
Comparator
PSP
Serial Interrupts
Magnetic Card Reader
Frequency counter
7 Seg LED
Data Logger
Pattern Generator
Stepper Motors
Tone Generation
Temperature Sensor
Fixed Point
TCP/IP
Floating Point
ICD Debugging
Advanced Macros
Memory Management
I2C
DTMF Tones
CRC Calculator
CCP
Watchdog Timer
Analog Comparator
Optical Encoder
USB
Boot Loader
CAN Bus
I/O for 8-in Parts
Sleep
Timers
Included C Driver:
Serial EEPROM/Flash
2041
24xx
25xx
93xx
AT2421
AT25256
AT29C1024
AT45DB021
A/D & D/A Converters
AD7705AD7715
ADS8320
LTC1298
MAX517
MCP4921
MCP3204
MCP3208
TLC545N
Real-Time Clock
DS1302
NJU6355
DS1305
ISL1209
Sounds
WTS701
TONES
LCD
GLCD
KS0108
LCD
LCD420
SED1335
HDM64GS12
Temperature
Expanded Input/Output
74165
74595
MAX7300
SC28L19x
Serial RAM
68HC68R1
68HC68R2
Other
Digital Compass
Keypad
Mag Card REader
PLL Inteface
Dallas One Wire
IR Decoder
Line Tracker
Servo Control
CE51x
CE62x
Digital Pots
ISD4003
DS1621
DS162M
M68AF031
PCF8570
X10
Cyclic Redundancy Code
CE67x
9512
MMC/SD
DS2??  (1-wire EEPROM)
AD8400
DS1868
MCP41010
RFID
EM4095
EM4402
EM4150
DS1631
DS1624
LM75CIM3
D41256
MT4264
Networking/Internet
RS485
N9085UD
PNI11096
LMX2326
USB
CAN Functionality
TCP
Robotics
GP2D12
Line Tracking Sensors
USBN960x
PIC_USB
PIC18_USB
Accelerometer
ADXL210
MCP251x
8xxx8
18F4580
PPP
S7600
RTL8019
ENC28J60
Seconds Counter
#include <18F4520.h>
#fuses HS,NOWDT,NOPROTECT,NOLVP
#use_delay(clock=20000000)
#use rs232(baud=9600, xmit=PIN_C6, rcv=PIN_C7)
Simple A/D
#include<16F877a.h>
#fuses HS,NOLVP,NOWDT,PUT
#use delay(clock=20000000)
#use rs232(baud=9600,xmit=PIN_C6,rcv=PIN_C7)
#define INTS_PER_SECOND 76
BYTE seconds;
BYTE int_count:
// (20000000/(4*256*256))
// A running seconds counter
// Number of interrupts left before a
// second has elapsed
void main() {
int i, value, min, max;
printf(“Sampling:”);
setup_adc_ports(RA0_ANALOG);
setup_adc(ADC_CLOCK_INTERNAL);
#int_rtcc
//
This function is called every time
set_adc_channel(0);
void clock_isr() {
//
//
the RTCC (timer0) overflows (255->0).
For this program this is
do {
min=255;
//Takes 30 samples from
//pin A0 and displays the min and
if(--int_count=0) {
//
apx 76 times per second.
max=0;
//max values for that 100ms peroid
++seconds;
int_count=INTS_PER_SECOND;
}
}
void main() {
BYTE start:
int_count=INTS_PER_SECOND;
set_timer0(0);
setup_coutner(RTCC_INTERNAL, RTCC_DIV_256 | RTCC_*BIT);
enable_interrupts(INT_RTCC);
enable_interrupts(GLOBAL);
{
printf(“Press any key to begin.\n\r”);
getc();
start=seconds;
printf(“Press any key to stop.\n\r”);
getc();
printf(“%u seconds.\n\r”,seconds-start);
}while (TRUE);
}
}
for(i=0; I <= 30; ++i) {
delay_ms(100);
value=read_adc();
if(value < min)
min = value:
if(value > max)
max = value;
}
printf(“\n\rMin:%x MAX: %x”, min, max);
} while (TRUE);
相关PDF资料
ICL7667CBAZA-T IC MOSFET DRIVER DUAL 8-SOIC
ICL7667CPA+ IC DRIVER MOSFET DUAL PWR 8-DIP
ICM7243BIPLZ IC LED DRIVR WHITE BCKLGT 40-DIP
IDC5N INPUT MODULE DC 34MA 5VDC
IDS7 SHELF FIXED 14.1X20.3" BEIGE
IDT6116SA25TPGI IC SRAM 16KBIT 25NS 24DIP
IDT7005S35G IC SRAM 64KBIT 35NS 68PGA
IDT7006L55G IC SRAM 128KBIT 55NS 68PGA
相关代理商/技术参数
IC-DX 制造商:ICHAUS 制造商全称:ICHAUS 功能描述:UNIVERSAL DIGITAL SENSOR OUTPUT DRIVER
IC-DX_11 制造商:ICHAUS 制造商全称:ICHAUS 功能描述:UNIVERSAL DIGITAL SENSOR OUTPUT DRIVER
IC-DXC 制造商:ICHAUS 制造商全称:ICHAUS 功能描述:Digital Sensor Output Drivers
IC-DXC_11 制造商:ICHAUS 制造商全称:ICHAUS 功能描述:DIGITAL SENSOR I/O DRIVER
IC-DXDFN6 制造商:ICHAUS 制造商全称:ICHAUS 功能描述:UNIVERSAL DIGITAL SENSOR OUTPUT DRIVER
ICE-063-S-TG 功能描述:IC 与器件插座 6P OPN BDY SCRW MCH RoHS:否 制造商:Molex 产品:LGA Sockets 节距:1.02 mm 排数: 位置/触点数量:2011 触点电镀:Gold 安装风格:SMD/SMT 端接类型:Solder 插座/封装类型:LGA 2011 工作温度范围:- 40 C to + 100 C
ICE-063-S-TG30 功能描述:IC 与器件插座 6P OPN BDY SCRW MCH DISC-BY-MFG-6/05 RoHS:否 制造商:Molex 产品:LGA Sockets 节距:1.02 mm 排数: 位置/触点数量:2011 触点电镀:Gold 安装风格:SMD/SMT 端接类型:Solder 插座/封装类型:LGA 2011 工作温度范围:- 40 C to + 100 C
ICE083STG 制造商:3M Electronic Products Division 功能描述: