News:

PROTON pic BASIC Compilers for PIC, PIC24, dsPIC33

Main Menu

help rs485 usart

Started by krizpin, Aug 09, 2022, 07:21 AM

Previous topic - Next topic

krizpin

I hadn't thought of that, thanks. can be an option. I will look at it . however, buy the rs485 with hardware flow control on aliexpress. When I have them I will also try them to see if they are a better option. thank you

RGV250

Hi,
If you only have one master you should not need arbitration as the master will know when it has received the data from the slave. If it is not high speed just send a request to the first, small delay and the the second etc.

Bob

John Drew

@krizpin,
The forum has a mix of professional and hobbyists. I'm one of the hobbyists, completely self taught and I'm mostly in it for fun and self improvement. Never feel bad about asking questions or feeling embarrassed about your knowledge. All of us have been there at some time. Enjoy using Positron, the occassional struggle is how we all learn.
Cheers
John

tumbleweed

The MAX485 has separate RE and DE pins to enable the receiver and transmitter. Many people tie them together, but one trick I've used before is to "permanently" enable RE and just control DE when you go to transmit.

Since you will see the data you transmit this allows you a "poor man's" collision detection scheme. It's not 100% reliable since it doesn't account for the delay down the wire, but it usually works out fine.

This also has the benefit of not having to poll/monitor the uart TRMT flag to know when you can disable the transmitter... you just disable it after receiving the last char you send.

krizpin

Thanks, I have the pins together, all the schematics I saw were like this. is another option to look at. I think I'm going crazy :-). Thanks a lot

krizpin

Quote from: John Drew on Aug 10, 2022, 12:15 PM@krizpin,
The forum has a mix of professional and hobbyists. I'm one of the hobbyists, completely self taught and I'm mostly in it for fun and self improvement. Never feel bad about asking questions or feeling embarrassed about your knowledge. All of us have been there at some time. Enjoy using Positron, the occassional struggle is how we all learn.
Cheers
John
thank you very much john. They are nice words. I program and manufacture pcb for myself as a hobby. I am glad to have met positron and to be part of this community where people help you selflessly and where you can also breathe such a healthy environment with people from all over. thanks to all

krizpin

Good morning again. Today I have received some circuits that were recommended to me for RS485 communication where the integrated itself manages the data flow. I have one, does anyone know if these circuits act as a hardware buffer?

RGV250

Hi,
Not sure what you mean by buffer, they just convert the TTL signal to RS485 levels.

Bob

tumbleweed

QuoteToday I have received some circuits that were recommended to me for RS485 communication where the integrated itself manages the data flow.
Do you have a datasheet for it?

It appears to be just a regular MAX485 + hex inverter, so it's difficult to see how it manages much of anything.