| Author |
Message |
|
|
Posted: Jan 15, 2008 - 04:55 AM |
|

Joined: Sep 05, 2003
Posts: 7
|
|
Is there a standard (dare I say best?) Uart library out there for GCC? I'm guessing there are a few, but is there one that is more common/better/more 'standard' then the rest?
I'm updating an old project of mine, and need some RS232 comms. I have some old code that used Artur Lipowski uart library v2.0, but I'm having trouble integrating it into some new code. Does he have an updated version? I searched around, but couldn't find any.
Thanks for any help!
Regards,
-Moses |
|
|
| |
|
|
|
|
|
Posted: Jan 15, 2008 - 05:16 AM |
|

Joined: Apr 01, 2004
Posts: 3812
Location: New Mexico
|
|
| Probably the "best" UART library is the one that you write for your specific application. OTOH, if you want to save time writing and debugging code, Pascal's avrlib has a fairly wide-spectrum of AVR's supported by its UART library. |
_________________ Kevin Rosenberg
http://b9.com
http://kevin.hypershots.com
|
| |
|
|
|
|
|
Posted: Jan 15, 2008 - 08:11 PM |
|

Joined: Oct 01, 2001
Posts: 38
|
|
|
|
|
|
|
Posted: Jan 15, 2008 - 08:54 PM |
|

Joined: Apr 01, 2004
Posts: 3812
Location: New Mexico
|
|
|
|
|
|
|
Posted: Jan 20, 2008 - 10:09 PM |
|

Joined: Sep 05, 2003
Posts: 7
|
|
Thanks Peter!
I got your library working.
It initially wasn't working, I didn't find out why until I hooked up a scope to the TX line, it looked like the output was 10 times (or more) slower then the actual baud rate I wanted. I had the mcu go into sleep mode with the ASYNC counter on, and removing the sleep command made it work.
I think I have to check the ring buffers to make sure they are clear before sleeping. I will dig into the code and see what I can do.
Any comments on making it work with a sleeping uc?
Thank again!
Regards,
-Moses |
|
|
| |
|
|
|
|
|
Posted: Jan 22, 2008 - 09:24 AM |
|


Joined: Oct 08, 2007
Posts: 86
Location: Merced, California
|
|
|
pfleury wrote:
You can use my UART library, a lot of people are using it:
http://homepage.hispeed.ch/peterfleury/
Awesome I just got UART working for the first time with your library on my intel-Mac thank you very much for the excellent code. by the way do you have any good examples of sending strings to the AVR ? I see the uart_getc() but how could I use this to receive a string? do I just create a char Array and poll the getc() function for each entry? maybe a quick example?
thanks anyway
Rob |
|
|
| |
|
|
|
|
|
Posted: Jun 25, 2008 - 04:12 AM |
|

Joined: Apr 25, 2008
Posts: 44
Location: Dexter MO
|
|
| i second rbackman's modest request |
|
|
| |
|
|
|
|
|