> I've got a program, that should when it's finished receive a character in > the range A-G from the UART, and depending on the character received perform > an AD Conversion of one of the pins, and transfer the result back to a PC I've got a template UART command processor project at http://www.embedinc.com/pic/hos.htm. It uses a jump table to dispatch to different code for each command byte received from the UART. The dispatch code is in the HOS_CMD.ASPIC module. The UART read and write routines are in the HOS_UART.ASPIC module. > loop > call ser_in ; Call ser_in, > call doconverstion ; when finished in ser_in > goto transmit w > goto loop ; when finished transmitted, start > ago. > > ser_in This is apparently a subroutine entry point. It should have a clear comment saying so! > btfsc rcsta,oerr ; does rcsta indicate an overflow I don't see anything to guarantee the correct bank setting here. In fact, you seem to have completely ignored both banking and paging. You can ignore paging if the PIC has 2K code space or less, but all PICs with a USART have at least two banks that I know of. > error > goto overerror ; if so goto overerr > btfsc rcsta,ferr ; does rcsta indicate an frameing > error > goto frameerror ; if so goto frameing error. > > uart_ready > > btfss pir1,rcif ; Check If Data Received. > goto ser_in ; If Not goback and recheck. > > uart_gotit > bcf intcon,gie ; Clear This Pin > btfsc intcon,gie ; Check If Cleared. > goto uart_gotit ; If Not Clear reset. Why are you disabling interrupts around reading RCREG? I don't see any reason to do so. Again, address the banking and try again. Persuing anything else until banking is fixed would be pointless. ***************************************************************** Embed Inc, embedded system specialists in Littleton Massachusetts (978) 742-9014, http://www.embedinc.com -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads