Mikroelektronika d.o.o.
RS485 5V Click Board
RS485 5V Click Board
Couldn't load pickup availability
The RS485 5 Click Board™ is equipped with the MAX485, low-power, slew-rate-limited transceiver for RS-485 and RS-422 communication, from Maxim Integrated. This device supports half-duplex RS-485 communication and can be used as an interface between the TTL level UART and the RS485 communication bus. Thanks to the low power consumption and reduced slew-rate drivers that minimize EMI and reduce reflections caused by improperly terminated cables, error-free data transmission up to 250kbps is supported.
The RS485 5 Click Board™ is perfectly suitable for EMI-Sensitive Applications, such as industrial-control local area networks, building automation, HVAC systems, and many more.
![Mikroelektronika d.o.o. MIKROE-925 RS485 5V Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-rs485-click-board-5v-30228662124733.jpg?v=1685053738&width=1445)
![Mikroelektronika d.o.o. MIKROE-925 RS485 5V Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-rs485-click-board-5v-30228661633213.jpg?v=1685053741&width=1445)
![Mikroelektronika d.o.o. MIKROE-925 RS485 5V Click Board - The Debug Store UK](http://thedebugstore.com/cdn/shop/products/mikroelektronika-d-o-o-click-board-rs485-click-board-5v-29668482318525.jpg?v=1685126445&width=1445)
The RS485 5V Click Board™ is an RS422/485 transceiver Click board™, which can be used as an interface between the TTL level UART and the RS422/485 communication bus. It features a half-duplex communication capability, bus Idle, open, and short-circuit detection, thermal shutdown, and more. It is well suited for transmitting data packets over long distances and noisy areas, using the twisted wire bus, which offers good electromagnetic interferences (EMI) immunity.
Due to its robustness and reliability, the RS485 click 5V can be used in various applications that require reliable data transfer in various noisy environments, or over a substantial distance, when data rate transfer up to 1 Mbps is sufficient. RS485 5V click can be used for controlling various building automation systems, intelligent lighting systems (DMX), Point-of-Sale (POS) networks, and various other devices that need to establish a reliable communication over the RS422/485 bus.
How Does The RS485 5V Click Board™ Work?
The RS485 5V Click Board™ uses the ADM485, an RS-422/485, half-duplex, tristate differential line driver and differential input line receiver, from Analog Devices. This click is intended to be used as a physical layer device, often referred to as PHY, providing physical interfacing of the MCU TTL level UART lines with the RS422/485 bus. It is well suited for transmitting smaller blocks of data over long distances, using a twisted differential signal pair, for both TX and RX signals, allowing for half-duplex asynchronous communication. The ADM485 transceiver consists of a separate driver and receiver sections, with Driver Enable and Receiver Enable pins (#RE and DE), used to enable the appropriate sections. Driver section is used to drive the RS422/485 bus with the signal received on the UART RX line labeled as DI on the IC, while the receiver section returns data from the bus back to the MCU via the UART TX line, labeled as RO on the IC in the schematics.
RS422/485 standard only specifies the electrical characteristics of the transmitter and the receiver. It does not specify or recommend any communications protocol, only the physical layer. The top layer communication protocol of choice can be used, such as the MODBUS or similar protocols. Therefore RS485 click 5V offers UART RX and TX pins, routed to the appropriate mikroBUS™ TX and RX UART pins. These pins are used by the MCU to send data to the RS485 bus, in a form determined by the user protocol. Additional DE and #RE pins are joined together and routed to the mikroBUS™ PWM pin. This pin is labeled as R/T on the Click board™. A pull-down resistor is used to determine states on these pins when they are left floating. Note that DE and RE pins use the opposite signal polarities for the active state, making it possible to drive them with a single MCU pin. When a HIGH logic level is applied to the R/T pin, transmitter becomes activated, while the receiver is deactivated at the same time - and vice versa. The R/T pin acts as a communication direction pin, in this configuration.
The ADM485 IC allows communication with data rates up to 5 Mbps. However, the maximal transfer speed is determined by the bus length: longer bus lines will result in less transfer speed. The RS422/RS485 bus needs to be terminated with the resistor on both ends (so-called parallel termination), which is equal to the characteristic impedance of the used cable, in order to prevent line reflections. The RS485 standard prescribes using a twisted pair cable as the data bus. Twisted pair cable tends to cancel common-mode noise and causes cancellation of the magnetic fields generated by the current flowing through each wire, thereby reducing the effective inductance of the pair.
The RS485 5V Click Board™ is equipped with a jumper, that can be used to route the termination resistor of 120 Ω between the bus lines. The Click board™ is equipped with two more jumpers, labeled as BIAS ENABLE. These jumpers are used to enable biasing of the bus by using pull-up and pull-down resistors between the bus differential lines and VCC/GND, respectively, preventing certain faulty conditions when no drivers are enabled on the bus, in addition to existing IC protection.
The RS-485 standard specifies that a compliant driver must be able to drive 32 unit loads (UL), where 1 unit load represents a load impedance of approximately 12 kΩ. This means that one driver can drive up to 32 ADM485 receivers.
The ADM485 receiver input hysteresis of about 70 mV to enhance the noise immunity. The ADM485 IC also features a true fail-safe receiver input, which guarantees a logic HIGH receiver output in cases when the receiver inputs are left unconnected or open.
There are two 2-pole screw terminals on board (VCC, +, -, GND) for connecting RS422/485 bus twisted pair cable, along with the GND and VCC. The terminal inputs labeled as "+" and "-" are used to connect the bus wires. GND and VCC rails can be used to provide the power supply for another node. Note that the VCC terminal is directly routed to the 5V rail of the mikroBUS™.
MikroElektronika provides a library that contains functions compatible with the MikroElektronika compilers, which can be used for working with the RS485 click 5V. The library also contains an example application, which demonstrates its use. This example application can be used as a reference for custom designs.
Specifications
Type | RS485 |
Applications | Board is suitable for Low power RS-485 systems, DTE/DCE interface Packet switching, Local area networks (LNAs), Data concentration, Data multiplexers, Integrated services digital network (ISDN) and more. |
On-board modules | ADM485 differential line transceiver |
Key Features | Meets EIA RS-485 standard; 5 Mbps data rate; Short-circuit protection |
Interface | GPIO,UART |
Compatibility | mikroBUS |
Click board size | M (42.9 x 25.4 mm) |
Input Voltage | 5V |
Pinout diagram
This table shows how the pinout on the RS485 5V Click Board™ corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Notes | Pin | ![]() |
Pin | Notes | |||
---|---|---|---|---|---|---|---|
NC | 1 | AN | PWM | 16 | R/W | Receive/Transmit | |
NC | 2 | RST | INT | 15 | NC | ||
NC | 3 | CS | RX | 14 | TX | UART transmit data | |
NC | 4 | SCK | TX | 13 | RX | UART receive data | |
NC | 5 | MISO | SCL | 12 | NC | ||
NC | 6 | MOSI | SDA | 11 | NC | ||
NC | 7 | 3.3V | 5V | 10 | 5V | Power supply | |
Ground | GND | 8 | GND | GND | 9 | GND | Ground |
RS485 Click 5V electrical specifications
Description | Min | Typ | Max | Unit |
---|---|---|---|---|
Bus common mode range | -7 | - | 12 | V |
Output Short-Circuit Current | -250 | - | 250 | mA |
Onboard settings and indicators
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | - | Power LED indicator |
JP2 | BIAS ENABLE | - | Pull-up resistor enables the positive bus line (non-inverted line) |
JP3 | BIAS ENABLE | - | Pull-down resistor enables the negative bus line (inverted line) |
JP4 | TERM | - | Termination resistor enable |
Software Support
We provide a demo application for the RS485 5V Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
Library initializes and defines a GPIO driver and performs control of device voltage.
For more details check the documentation.
Key Functions
void rs485_writeByte(uint8_t input)
- Write Single Byte.uint8_t rs485_readByte()
- Read Single Byte.uint8_t ras485_byteReady()
- Check for new byte received.
Example Description
The application is composed of three sections:
- System Initialization - Initializes UART module.
- Application Initialization - Driver intialization.
- Application Task - (code snippet) - Checks if new data byte has been received in the RX buffer (ready for reading), and if it has then it reads one byte from the RX buffer. Otherwise, the application task writes the message data via UART.
void applicationTask() { char tmp; uint8_t rdyFlag; // RECEIVER - UART polling rdyFlag = rs485_byteReady(); if (1 == rdyFlag) { tmp = rs485_readByte(); mikrobus_logWrite( &tmp, _LOG_BYTE ); } // TRANSMITER - TX each 2 sec for (tmp = 0; tmp < 9; tmp++) { rs485_writeByte( MESSAGE_DATA[tmp] ); mikrobus_logWrite( "MESSAGE SENT", _LOG_LINE ); } Delay_ms(2000); }
The full application code and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in this example:
- UART
Additional Notes and Information
Depending on the development board you are using, you may need USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
RS485 5V Click Board
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.