PIC16C782 Microchip Technology Inc., PIC16C782 Datasheet - Page 111
![no-image](/images/manufacturer_photos/0/4/440/microchip_technology_inc__sml.jpg)
PIC16C782
Manufacturer Part Number
PIC16C782
Description
8-bit Cmos Microcontrollers With A/d, D/a, Opamp, Comparators And Psmc
Manufacturer
Microchip Technology Inc.
Datasheet
1.PIC16C782.pdf
(186 pages)
Available stocks
Company
Part Number
Manufacturer
Quantity
Price
- Current page: 111 of 186
- Download datasheet (4Mb)
EXAMPLE 13-1:
;* This code block will configure the PSMC and
;*
;*
;*
;*
;*
;*
;*
;*
;*
;*
**********************************************************
;*
;**********************************************************************
;*
;*
;**********************************************************************
;*
;*
;*************************************************************************
;*
;*
;*
;************************************************************************
;*
;*
;*
2001 Microchip Technology Inc.
Order of configuration
1.
2.
3.
4.
5.
6.
This code block will configure all analog ports.
BANKSEL
MOVLW
MOVWF
MOVLW
MOVWF
MOVLW
MOVWF
This code block will configure the DAC for VDD as
DACREF, and RB1/AN5/VDAC as an output
BANKSEL
CLRF
MOVLW
MOVWF
MOVLW
MOVWF
This code block will configure the OPA module as an
Op Amp, with a 2MHz GBWP
MOVLW
MOVWF
This code block will configure Comparator C1
for normal speed and output polarity,
input on AN6, and Reference from the VREF1
MOVLW
MOVWF
This code block will configure the PSMC module
for PWM, FOSC/128, Single in, Single pulse out, slope comp out
Non-inverting out, DC min = 0%, DC max = 75%
MOVLW
MOVWF
MOVLW
MOVWF
BSF
all additional peripherals for a boost mode
switching power supply.
PORTA/B I/O and analog configured
DAC enabled, configured, and preset
Op Amp enabled and configured
Comparator C1 enabled and configured
PSMC configured
PSMC enabled
TRISA
B’00001011’
TRISA
B’11001110’
TRISB
B’11101011’
ANSEL
DACON0
DAC
B’11000000’
DACON0
OUTPUT_VALUE
DAC
B’10000001’
OPACON
B’10001010
CM1CON0
B’00001000’
PSMCCON0
B’00001010’
PSMCCON1
PSMCCON1,SMCON
PSMC CONFIGURATION EXAMPLE
; Select Bank 1
; Set RA0,1,& 3 as inputs
; Set RB1,2,3,6 & 7 as inputs
; Configure RA0, RA1, RA3,
; RB1, RB2, RB3 as analog
; Select Bank 2
; Set DAC to safe value
; Enable DAC, output
;
; Set DAC output level
; Set Op Amp mode and
;
; Set C1, no ext out, norm
;
; Set DCmin 0, DCmax 75, FOSC/128
; Set PWM Sngl in, Sngl out non-invert
; Slope comp
; Enable PSMC
2MHz GBWP
and set DACREF = VDD
speed & pol, VREF1, AN6
Preliminary
PIC16C781/782
DS41171A-page 109
Related parts for PIC16C782
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
![PIC-0903](/images/no-image3.png)
Part Number:
Description:
Photo IC(photodiode with signal processing)
Manufacturer:
KODENSHI KOREA CORP
Datasheet:
![PIC-1018SMB](/images/no-image3.png)
Part Number:
Description:
INFRARED RECEIVER MODULE
Manufacturer:
ETC
Datasheet:
![PIC-2058SMB](/images/no-image3.png)
Part Number:
Description:
INFRARED RECEIVER MODULE
Manufacturer:
ETC
Datasheet:
![PIC-2503](/images/no-image3.png)
Part Number:
Description:
Photo IC(photodiode with signal processing)
Manufacturer:
KODENSHI KOREA CORP
Datasheet:
![PIC12045S](/images/manufacturer_photos/0/3/374/kodenshi_tmb.jpg)
Part Number:
Description:
(PIC-1204x) OPTICAL-RECEIVER OUTPUT PHOTO IC
Manufacturer:
Kodenshi
Datasheet:
![TC1014-2.7VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1014-5.0VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-2.5VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-2.7VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-2.8VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-4.0VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet: