92
RabbitCore RCM3305/RCM3315
B.4.6.2 RS-485
The Prototyping Board has one RS-485 serial channel, which is connected to the Rabbit
3000 Serial Port C through an RS-485 transceiver. The half-duplex communication uses
an output from PD7 on the Rabbit 3000 to control the transmit enable on the communica-
tion line. Using this scheme a strict master/slave relationship must exist between devices
to insure that no two devices attempt to drive the bus simultaneously.
Serial Port C is configured in software for RS-485 as follows.
#define ser485open serCopen
#define ser485close serCclose
#define ser485wrFlush serCwrFlush
#define ser485rdFlush serCrdFlush
#define ser485putc serCputc
#define ser485getc serCgetc
#define CINBUFSIZE 15
#define COUTBUFSIZE 15
#ifndef _485BAUD
#define _485BAUD 115200
#endif
The configuration shown above is based on circular buffers. RS-485 configuration may
also be done using functions from the
PACKET.LIB
library.
The Prototyping Boards with RCM3305/RCM3315 modules installed can be used in an
RS-485 multidrop network spanning up to 1200 m (4000 ft), and there can be as many as
32 attached devices. Connect the 485+ to 485+ and 485– to 485– using single twisted-pair
wires as shown in Figure B-8. Note that a common ground is recommended.
Figure B-8. Multidrop Network
RS-485
RS485+
GND
RS-485
RS485+
GND
RS-485
RS485+
GND
Содержание RCM3305
Страница 6: ...RabbitCore RCM3305 RCM3315...
Страница 14: ...8 RabbitCore RCM3305 RCM3315...
Страница 22: ...16 RabbitCore RCM3305 RCM3315...
Страница 28: ...22 RabbitCore RCM3305 RCM3315...
Страница 70: ...64 RabbitCore RCM3305 RCM3315...
Страница 106: ...100 RabbitCore RCM3305 RCM3315...
Страница 144: ...138 RabbitCore RCM3305 RCM3315...
Страница 160: ......