On Sun, Sep 29, 2002 at 04:32:25PM -0500, Nick Veys wrote: > Hi all, planning on doing a little serial i/o and want to get a good > idea before writing code that may end up worthless due to a false > assumption. :) OK. > > I plan on using the 16F876's USART in Asynch mode to talk to a HAM TNC, > 9600 baud 8N1. Looking through the datasheet, I see the TRMT bit is set > once a transmission is complete, is it safe to assume I can being a new > transmission once that bit is set? I've used the SPI ports quite often, > and there is a transmit flag there which I use for the same purpose and > have no problems, but I'm wondering if since these commands might be > coming in too fast to be buffered by the slow TNC on the other end, if a > wait would be warranted after the transmission... > > I'm hoping I can just keep firing away on the port but I'd like some > words of wisdom just in case. I have a better idea. Take a good read of Fr. Thomas McGahee's PICUART turorial. It's a highly annotated PIC assembly source file that doubles as the best PIC UART tutorial around and as a drop in working program that'll get your USART right as rain. I cannot recommend the code or the comments highly enough. I have a copy of Fr. Tom's latest version online. Download here: http://www.finitesite.com/d3jsys/picuart.zip BAJ -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads