How to ouput the value after A/D converstion (PIC16C71) ?

Status
Not open for further replies.

kseng2002

Member level 2
Joined
Aug 27, 2004
Messages
51
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Location
Malaysia
Activity points
467
Hi,

can anyone help me how to output the value after the A/D conversion ?

Code:
BSF STATUS, RP0           ;Select Bank 1
CLRF ADCON1                         ;Configure A/D inputs
BCF STATUS, RP0                    ;Select Bank 0
MOVLW 0xC1                          ;RC Clock, A/D is on, Channel 0 is selected
MOVWF ADCON0                     ;
BSF INTCON, ADIE                  ;Enable A/D Interrupt
BSF INTCON, GIE                    ;Enable all interrupts
;
; Ensure that the required sampling time for the selected input channel has elapsed.
; Then the conversion may be started.
;
BSF ADCON0, GO                     ;Start A/D Conversion
: ; The ADIF bit will be set and the GO/DONE bit
: ; is cleared upon completion of the A/D Conversion.
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…