Page 1 of 1

RS485 in 16F628A

Posted: 20 Jul 2005 04:05
by ful babu
i tried to compile this code for 16F628A ...

void main() {

Usart_Init(9600);
RS485Slave_Init(160);

}

which gives an error like "Redefined:Usart_Init, Redefined:Usart_Data_Ready, Redefined:Usart_Read, Redefined:Usart_Write"

where as for 16F877a / 16F76 it compiles successfully

thx

Re: RS485 in 16F628A

Posted: 20 Jul 2005 08:38
by pizon
Current RS485 library (Rs485_M_S.mcl) for PIC16's works only for devices that have PORTC; for those that are not so lucky it complains about lack of PORTC in this weird way :roll:. We will correct this (add up a library), in the meantime you can use Rs485 only with devices that use Usart_U_A library, such as 876 / 877A.

Posted: 20 Jul 2005 10:52
by ful babu
it wud be really helpful if rs485 feature can be used via software UART in mcu's tat dosents hav any hardware USART like 16F84A / 12F629 etc , wud tat be considered ?

thx

Posted: 20 Jul 2005 15:30
by pizon
We could give it a try, but RS485 protocols are generally highly time-dependent, meaning that this kind of approach would most likely generate more troubles than benefits.

RS485 and PIC16f628A

Posted: 03 Nov 2008 21:02
by Stan
[/pizon Posted: Wed Jul 20, 2005 7:38 am Post subject: Re: RS485 in 16F628A

--------------------------------------------------------------------------------

Current RS485 library (Rs485_M_S.mcl) for PIC16's works only for devices that have PORTC; for those that are not so lucky it complains about lack of PORTC in this weird way . We will correct this (add up a library), in the meantime you can use Rs485 only with devices that use Usart_U_A library, such as 876 / 877A.
]

I found this post from Pizon in a forum search after trying for ages to get the RS485 running on the 16f628A.

After all this time (since 20/07/2005) has there been an upgrade in the Mikro RS485 library to allow us to use the smaller PICs such as 16f628A that dont have a port C. I have used the Mikro RS485 library and it works well in a limited way however, in my latest project I need to use much smaller PICS to keep down the size and cost of the RS485 slaves. I would appreciate an early answer so that I can consider my options with the project.

Stan

Posted: 07 Nov 2008 21:43
by Stan
It's been a few days now since I sent the first post, any chance of an answer from the Mikro team? they are simple enough questions:

Apart from upgrades due to new compiler versions and new PICs have you;

1. Upgraded the RS485 library in any way and how?

2. Changed the RS485 library to work with the smaller PICs without PortC such as the 16F628A and similar.

3. If not, any real plans for doing so soon or ever?

4. You have implied in the past that you would improve this library (as in Pizons post for instance) do you now consider it to be dead issue as far as further development is concerned? if so, why not open the library up so that members of the forums can develop it after all there is a lot of interest in RS485.

I'm not implying criticism of Mikro here, it's just the frustration of myself and others of the limited nature of the library. I would be grateful for any meaningful answers from the Mikro team.

Stan

Posted: 20 Nov 2008 17:07
by filip
We will consider adding this feature to some future versions of mikroC compiler. Sorry for the inconvenience.

Re: RS485 in 16F628A

Posted: 27 Jul 2010 08:07
by Lajbis
Hi. Is here something new about this feature?
I want to use 16F628A for RS485 communication (no PORTC) and want to know if it is already possible or still not.
If not, please tell when it will be.
Thank you for your answer.

Re: RS485 in 16F628A

Posted: 28 Jul 2010 14:06
by filip
Hi Lajbis,

Since your last post, we have released a new compiler for PIC MCU's, mikroC PRO for PIC.

It includes an improved RS-485 library, which works on any port.

We strongly encourage users to switch to PRO version because non-PRO version is an ancestor of PRO compiler, which is no longer being developed.
Every new feature, improvement and bug fix will only affect new versions of PRO compilers.
Therefore, even if you have come across some compiler bug in older compilers, we won't be able to fix it, nor help you, because that's just natural order of things.

If you're a registered user you'll receive PRO license key free of charge!

P.S.
Also, we have released many new development systems and accessory boards.
Examples for them are written in the PRO compilers.

Best regards,
Filip.

Re: RS485 in 16F628A

Posted: 07 Aug 2010 19:44
by Lajbis
Yes, it works.
Thanks.