Hola, pero si utilizas CCS por ejemplo es fácil configurar el módulo USART, o si es assembler una rutina de comunicación es igualmente simple.
este es un ejemplo del conversor AD a PC
TITLE" CONVERSOR AD DE 0 A 999 "
LIST P=12f675
;REGISTROS DE USO ESPECIFICO
dir_ind equ 00 ;direccionamiento indirecto de la RAM
rtcc equ 01 ;reloj de tiempo real
pcl equ 02 ;contador de programa
status equ 03 ;registro de estado de la ALU
fsr equ 04 ;datos de la RAM
gpio equ 05 ;dato del puerto a
intcon equ 0b ;registro de interrupciones
pie1 equ 0c ;registro de interrupciones perifericas
tmr1l equ 0e ;parte baja del tmr1
tmr1h equ 0f ;parte alta del tmr1
t1con equ 10 ;configuracion del tmr1
adresl equ 1e
adresh equ 1e
adcon0 equ 1f
ansel equ 1f
cmcon equ 19
;REGISTROS EN LA PAGINA 1
p_option equ 1 ;registro de config. del rtcc
trisio equ 05 ;registro de config. del puerto a
pir1 equ 0c ;registro de interrupciones perifericas
;REGISTROS DE USO GENERAL
conta equ 20
conta1 equ 21
unidades equ 22
decenas equ 23
centenas equ 24
uni_mil equ 25
dec_mil equ 26
bandera equ 27
registro1_l equ 28
registro1_h equ 29
conta2 equ 2a
res_w equ 2b
con_tiem equ 2c
respaldo equ 2d
;===========================================================================
;BANDERAS UTILIZADAS DEL REGISTRO STATUS
c equ 0x00 ;carry
z equ 0x02 ;cero
rp0 equ 0x05 ;seleccion de pagina uno
;CONSTANTES DE PROGRAMACION
w equ 00
f equ 01
;============================================================================
;PUERTO A
;GPO ENTRADA ANALOGA
;GP1 SALIDA LED PILOTO
;GP2 SALIDA PARA TRANSMICION TX
;GP3 PIN LIBRE
;GP4 PIN LIBRE
;GP5 PIN LIBRE
;===========================================================================
org 0x00
goto inicio
;==============================================================================
org 0x04 ;VECTOR DE LA INTERRUPCION
;POR RTCC 1 Sgdo
movwf res_w
nop ;INSTRUCCIONES NO OPERE PARA AJUSTAR
nop ;UN TIEMPO EXACTO
nop
movlw 0x0b
movwf tmr1h
movlw 0xdd ;SE CARGA NUEVAMENTE EL TMR1
movwf tmr1l
bsf bandera,0 ;BANDERA QUE INDICA 0.5 SEG
incf con_tiem,f
movlw d'2'
xorwf con_tiem,w
btfss status,z
goto fin_int
movlw 0x02
movwf con_tiem
bsf bandera,1 ;BANDERA QUE INDICA 1Sgd
;===============
fin_int movf res_w,w
bcf pir1,0
retfie
;===========================================================================
conversion bsf adcon0,1 ;RUTINA GENERAL DE CONVERSION A/D
btfsc adcon0,1 ;INICIO DE LA CONVERSION
goto $-1
bsf status,rp0
movf adresl,w
bcf status,rp0
movwf registro1_l
movf adresh,w
movwf registro1_h
;==================
clrf dec_mil
clrf uni_mil ;RUTINA QUE CONVIERTE UN NUMERO BINARIO
clrf centenas ;DE 16 BIT A BCD (CUATRO DIGITOS)
clrf decenas
clrf unidades ;TIEMPO APROXIMADO 440 Ms
;==================
res_dec_mil movlw b'00010000' ;AL NUMERO BINARIO SE LE RESTA 10000
subwf registro1_l,f ;LUEGO SE LE RESTA 1000
btfsc status,c ;LUEGO SE LE RESTA 100
goto $+5 ;LUEGO SE LE RESTA 10
movlw b'00000001' ;EL NUMERO RESTANTE SON LAS UNIDADES
subwf registro1_h,f
btfss status,c
goto res_uni_mil
bsf bandera,2
movlw b'00100111'
subwf registro1_h,f
btfss status,c
goto res_uni_mil
bcf bandera,2
incf dec_mil,f
goto res_dec_mil
;==================
res_uni_mil movlw b'00010000'
addwf registro1_l,f
btfsc status,c
incf registro1_h,f
btfss bandera,2
goto $+3
movlw b'00100111'
addwf registro1_h,f
bcf bandera,2
res_ot_uni_mil movlw b'11101000'
subwf registro1_l,f
btfsc status,c
goto $+5
movlw b'00000001'
subwf registro1_h,f
btfss status,c
goto res_centenas
bsf bandera,2
movlw b'00000011'
subwf registro1_h,f
btfss status,c
goto res_centenas
bcf bandera,2
incf uni_mil,f
goto res_ot_uni_mil
;==================
res_centenas movlw b'11101000'
addwf registro1_l,f
btfsc status,c
incf registro1_h,f
btfss bandera,2
goto $+3
movlw b'00000011'
addwf registro1_h,f
res_otra_cent movlw d'100'
subwf registro1_l,f
btfsc status,c
goto $+5
movlw d'1'
subwf registro1_h,f
btfss status,c
goto res_decenas
incf centenas,f
goto res_otra_cent
res_decenas movlw d'100'
addwf registro1_l,f
btfsc status,c
incf registro1_h,f
;==================
res_otra_dec movlw d'10'
subwf registro1_l,f
btfss status,c
goto $+3
incf decenas,f
goto res_otra_dec
movlw d'10'
addwf registro1_l,f
movf registro1_l,w
movwf unidades
;==================
return
;===========================================================================
osc_led btfss gpio,1 ;LED PILOTO QUE INDICA QUE ESTA
goto $+3 ;REALIZANDO LA OPERACION
bcf gpio,1
return
bsf gpio,1
return
;===========================================================================
;==============================================================================
t_208Ms movlw d'50' ;RETARDO DE 208 Ms PARA LA COMUNICAION
movwf conta ;CON EL PC A 4800 BPS
nop
decfsz conta,f
goto $-2
nop
nop
return
;==============================================================================
enviar movwf respaldo ;RUTINA GENERAL DE COMUNICACION CON
;EL PC
movlw d'8'
movwf conta1 ;NUMERO DE BITS
bcf gpio,2 ;BIT DE INICIO
call t_208Ms
en_otro_bit rrf respaldo,f ;SE ROTAN LOS OCHO BIT DE DATO
btfss status,c
bcf gpio,2
btfsc status,c
bsf gpio,2
call t_208Ms
decfsz conta1,f
goto en_otro_bit
bsf gpio,2 ;BIT DE PARADA
call t_208Ms
return
;===========================================================================
transmite movlw h'30'
addwf uni_mil,w
call enviar
movlw h'30'
addwf centenas,w
call enviar
movlw h'30'
addwf decenas,w
call enviar
movlw h'30'
addwf unidades,w
call enviar
movlw h'0d'
call enviar
return
;===========================================================================
programa btfss bandera,0
goto programa
bcf bandera,0
call osc_led
call conversion
call transmite
goto programa
;===========================================================================
inicio bsf status,rp0 ;SE SELECCIONA LA PAGINA 1 DE LA RAM
;NECESARIA PARA LA CONFIGURACION GRAL.
movlw b'11111001'
movwf trisio
movlw b'00000001' ;SE SELEECIONA EL RA3 COMO ENTRADA
movwf ansel ;ANALOGA
bsf pie1,0 ;SE HABILITA INTERRUPCION POR SOBREFLUJO
;EN EL TMR1
movlw h'c0' ;SE HABILITA TODAS LAS INTERRUPCIONES
movwf intcon
bcf status,rp0 ;SE RETORNA A LA PAGINA 0 DE LA RAM
movlw b'00000111' ;EL MODULO DE COMPARACION SE CONFIGURA
movwf cmcon ;COMO PINES DIGITALES GENERALES
movlw b'10000001'
movwf adcon0
movlw b'00110101' ;SE HABILITA EL TMR1
movwf t1con
bcf gpio,1
bsf gpio,2
;===========================================================================
movlw 0x21 ;BORRADO DE LA MEMORIA RAM
movwf fsr ;DEL MICRO-CONTROLADOR
movlw 0x1f
movwf conta
borre clrf dir_ind
incf fsr,f
decfsz conta,f
goto borre
;===========================================================================
goto programa
;===========================================================================
end
Saludos