I've taken the liberty of converting that to ASP code and making it available at http://www.piclist.com/techref/default.asp?url=microchip/rs232 under "SPBRG Calc" I made a quick job of it and haven't really checked the results, please let me know.... --- James Newton (PICList Admin #3) mailto:jamesnewton@piclist.com 1-619-652-0593 PIC/PICList FAQ: http://www.piclist.com or .org -----Original Message----- From: pic microcontroller discussion list [mailto:PICLIST@MITVMA.MIT.EDU]On Behalf Of Andrew Kunz Sent: Wednesday, August 16, 2000 13:52 To: PICLIST@MITVMA.MIT.EDU Subject: [PIC]: Handy Utility I know it's usually "bad" to attach source to a posting, but I think you'll like this one. Besides, it's only a small file. It's a handy-dandy tool to tell you the correct SPBRG value(s) for your PIC application. It supports both BRGH values, and should run with any C compiler. Instructions - compile & run. Do what it tells you. Print out the results. It isn't the most efficient way to check if something is valid, but it was easy to do and I'm pretty lazy. If you need it in .EXE (for DOS) send me a private note (I'll ignore public ones ). If you need the MSVC .MAK file, I have that handy too. Andy (See attached file: baudrate.c) -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu