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 CCS Technical Support

Using Both Usart Problem With "modbus.c"

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



Joined: 12 Jun 2012
Posts: 1

View user's profile Send private message

Using Both Usart Problem With "modbus.c"
PostPosted: Tue Jun 12, 2012 12:35 am     Reply with quote

We use "modbus.c" driver for PIC1867J10 with single usart(only RDA). Now we want to communicate double uart(RDA-RDA2 both) with "modbus.c" driver. Is it possible, how?
RF_Developer



Joined: 07 Feb 2011
Posts: 839

View user's profile Send private message

Tricky....
PostPosted: Tue Jun 12, 2012 2:25 am     Reply with quote

Modbus.c ues more than one resource. The problem is not just the UARTs, its the timer(s?) modbus.c uses in RTU mode. I strongly suspect that modbus.c was written to be a highlander - there can only ever be one.

I assume your application has two or more Modbi, on one of which this code will be a slave, while on the other it is the master. Maybe some kind of Modbus repeater/extender? If so I think you are going to have to delve deep into modbus.c and sort it out for yourself. You'll have to make two versions of its control/data structures, and sort out the timer usage. Its certainly not a case of setting a natty flag and away you go.

RF Developer
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