Moxa Technologies CP-118U user manual Addc

Page 70

CP-118U User’s Manual

Serial Programming Tools

ADDC™

ADDC™ is the best method for switching between transmission and receiving when using 2-wire RS-485.

When using ADDC™, additional code is not required to switch between data transmitting and receiving, since the switching mechanism is managed automatically by the board’s built-in intelligent hardware mechanism. This means that RS-485 programming using ADDC™ mode is just as simple and straightforward as RS-232 or RS-422 programming.

RTS

To ensure precise timing control when using 2-wire RS-485 transmission, we recommend that you configure your CP-118U Series ports as described below.

There are 2 methods for controlling 2-wire RS-485 transmission.

Method 1

The following method is commonly used for 2-wire RS-485 transmission:

sio_SetWriteTimeouts(port, 0);

/* Set sio_write() into block mode if for Windows NT and

 

Windows 95/98 */

sio_RTS(port, 1);

/* Turn on RTS signal. The RS-485 port is ready for

 

transmitting data. */

sio_write(port, buff, 10);

/* Write 10 byte characters in "buff". The function blocks

 

until the last character is transmitted */

sio_RTS(port, 0);

/* Turn off RTS signal. The RS-485 port is ready for

 

receiving data. */

sio_read(port, buff, 10);

/* Read 10 bytes */

Method 2

The PComm or API-232 library includes a dedicated RS-485 function that integrates the functions described in Method 1 above into one function:

sio_putb_x(port, buff, tick );

/* 1. Turn on RTS and ready for transmitting data.

 

2. Send data.

 

3. Wait for tick time.

 

4. Turn off RTS and ready for receiving data. */

To see more detailed information about these functions, refer to the PComm library’s on-line Help file for Windows 95/98/NT/2000/XP/2003.

4-6

Image 70
Contents CP-118U User’s Manual Trademarks Copyright NoticeDisclaimer Table of Contents Appendix a Technical Reference Introduction Smartio-The Smart Multiport Async Solution OverviewPackage Checklist FeaturesApplications Installation Flowchart Hardware Installation CP-118U Block Diagram DIP Switch SettingsPlugging the Board into an Expansion Slot Page Software Installation Windows Drivers CPCI Boards CT-114IInstalling the Driver Windows 2003/XPCP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation Configuring the Ports CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation Using Moxa PComm Utility Using Event LogRemoving the Driver Installing the Driver for the First Time WindowsCP-118U User’s Manual Software Installation Select Specify a location and then click on Next to continue CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation Configuring the Ports CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation Using Moxa PComm Utility Removing the Driver Windows 95/98 CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation Configuring the Ports CP-118U User’s Manual Software Installation Updating the Driver CP-118U User’s Manual Software Installation Click on Next CP-118U User’s Manual Software Installation Removing the Driver Windows NT Continue from in the next section, Configuring the Ports CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation Removing a CP-118U Board Click on Remove Click on Close, and then restart the system Non-Windows Drivers DOSSetting up the Driver Run BIN\SETUP.EXETxD buffer size Loading the Driver LinuxUnloading the Driver Use the Moxa terminal utility to test the tty ports SCO CP-118U User’s Manual Software Installation CP-118U User’s Manual Software Installation Serial Programming Tools UtilitiesMoxa PComm Installing PCommPComm Programming Library Diagnostic for Moxa boards only UtilitiesMonitor for Moxa boards under Windows NT/2000/XP/2003 Wire RS-485 Programming Terminal EmulatorAddc Pin Assignments Board Side Pin Assignments-Female DB62 RS-422 and 4-wire RS-485RS-232 Device Side Pin Assignments Wire RS-485Male DB9 Opt8-D/Opt8-M9 Male DB25 Opt8B/C Female DB25 Opt8A/SRJ45 Opt8-RJ45 Page Troubleshooting General TroubleshootingWindows NT Windows 95/98Product Specifications Technical ReferencePCI Service Information Moxa Internet Services Following services are providedProblem Report Form Moxa CP-118U SeriesProduct Return Procedure
Related manuals
Manual 2 pages 63.12 Kb