CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

Multiple serial ports on one PIC18F8722

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
dk-info



Joined: 13 Apr 2009
Posts: 5
Location: Melbourne, Florida

View user's profile Send private message Send e-mail

Multiple serial ports on one PIC18F8722
PostPosted: Fri Oct 16, 2009 12:45 pm     Reply with quote

I have an application where I need to control five low bandwidth devices using an RS-232 interface.

I haven't tried it, but how many "soft" UARTS can be programmed on a '8722? I only have to access the serial devices every second or so, at a very low bandwidth (1200 Baud).

Is it reasonable to invoke the "#use rs232() five times? What are the resource consequences?


Thanks
David
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Fri Oct 16, 2009 12:50 pm     Reply with quote

See this recent thread:
http://www.ccsinfo.com/forum/viewtopic.php?t=39583
bkamen



Joined: 07 Jan 2004
Posts: 1611
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Fri Oct 16, 2009 11:47 pm     Reply with quote

As mentioned in the other thread, multiple software uarts is a no-win situation.

PIC24's come with up to 4 uarts.. then you'd have to add an external 4th.

I hooked an octal uart up to a 18F97J60 recently and got it to work - but it needs a lot of optimization.

A PIC24 would have been better for that too.. the customer wanted to try the 97J60 first though..


It can be done - but it's not pretty. :D

-ben
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
asmallri



Joined: 12 Aug 2004
Posts: 1634
Location: Perth, Australia

View user's profile Send private message Send e-mail Visit poster's website

PostPosted: Sun Oct 18, 2009 4:04 am     Reply with quote

bkamen wrote:
As mentioned in the other thread, multiple software uarts is a no-win situation.


I disagree. 5 low speed software UARTS all at a constant baud rate is a walk in the park but not using the #use RS232 mechanism.

5 serial ports at 1200 baud could be implemented using high priority interrupts and a single timer. High priority to leave low priority to other functions.
_________________
Regards, Andrew

http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!!
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group