N
N
Nikita Nikita2018-05-04 22:04:42
Arduino
Nikita Nikita, 2018-05-04 22:04:42

Connecting max485 to arduino?

I connect the hall sensor to the arduino and I want to connect it to the computer via RS485, the question arose of connecting the DE and RE pins.5aecaec53de3c180518932.jpeg

Answer the question

In order to leave comments, you need to log in

1 answer(s)
O
Ocelot, 2018-05-05
@Nikita425

We continue the educational program =)
Most likely, you will use the hardware USART. This means that the legs DI and RO must be connected to TX and RX, respectively. In the picture you have them mixed up - correct. The DE/RE legs are responsible for selecting the flow direction, 1=transmit, 0=receive. Since USART does not have hardware flow control in atmega, this leg will have to be pulled programmatically. Feel free to hang DE / RE on any free exit, where it is more convenient. At the start of the transfer, you will need to raise this output to 1, and after the end of the transfer (via the USART Tx Complete interrupt) - reset to 0

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question