about the usart in PIC18

Started by Karlo Campos June 1, 2004

Is it possible to use the receive module of the USART in interrupt
mode and the transmit module in non-interrupt (polling)? Based on the
data sheets, (theoretically) is yes. How come when I tried it with my
pic it doesn't?

Any explanation guys? or work arounds? Reply is greatly appreciated!


Yes, of course you can. Set up everything on the TXREG and RCREG registers, as you want them to be.


Then, configure, atleast this bits:


PEIE = 1; // Peripheral interrupt enabled

RCIE = 1; // Reception interrupt enabled

TXIE = 0; // Transmition interrupts disabled

GIE = 1; // Global interrupts enabled


And thas about it. Perhaps the bits have different names, but I don’t have the datasheet near me right now, anyway, it works.




Mauricio D. Jancic

Janso Desarrollos - Microchip Consultant

(54) 011 - 4542 - 3519

Lugones 3238 "B" - C1430ECN



MSN: j...@hotmail.com