PDA

View Full Version : Benefits of hardware usart over software?



sccoupe
- 18th March 2009, 20:49
I was using a 12f675 in a project and after realizing i needed a max232 chip to get to rs232 voltage levels I decided to get some 16f688's that have a hardware usart. Much to my suprise, it also needs a max232 chip as it also is at TTL levels. So what are the advantages of a hardware usart over just using serin and serout software commands?

Thanks

Jason

BobK
- 18th March 2009, 21:54
Hi sccoupe,

I'm not a big serial comm user although I'm working on a project using serial now, but from reading alot of posts over the past few years, I think the big feature of using a usart over serin/serout is that the usart runs in the background and you can use interupts and polling to let you know when data is present in the usarts registers. Take some time and search the forums for more information.

HTH,

BobK

Jerson
- 19th March 2009, 01:16
Main advantage of a Hardware Usart is the speed of receiver operations. Due to the fact that you don't have to sit around waiting for bits/bytes, you can do more work while the USART is receiving bytes. 2nd advantage, less missed characters. Max232 is just a level changer, you will need it even with a soft usart if you want to stick with the RS232 voltages.