----------------------------------- Using minicom to Test Comtrol Ports ----------------------------------- This document discusses how to use minicom in Linux to test ports using a null-modem cable connected between two ports. If necessary, cabling information is available in each product’s User Guide or hardware installation document. Note: This document uses ports ttyRP0 and ttyRP1 in the examples. You will need to substitute the port numbers that you will be testing, where appropriate, for your environment. Hardware Type Port Nomenclature -------------- ----------------- DeviceMaster AIR ttySIx DeviceMaster PRO ttySIx DeviceMaster RTS ttySIx DeviceMaster Serial Hub ttySIx DeviceMaster2 ttySIx RocketModem III ttyRx RocketModem IV ttyRx RocketPort Express ttyRPx RocketPort Infinity ttyRPx RocketPort ISA ttyRx RocketPort uPCI ttyRx Where x is the port number, which begins at 0 (zero) and continues sequentially. Note: Linux is case-sensitive, be sure to use the proper case. tty is lowercase, R, RP, and SI are in uppercase. See "Testing a RocketModem" later in this document for instructions on testing modem ports. -------------------- Testing Serial Ports -------------------- Use this procedure to test serial ports. 1. Verify that the driver has been installed and loaded using the driver installation README file. 2. Connect a null-modem cable from the first port to the second port on the device. If it is a 1-port device, connect Port 1 to a native serial port or connect the loopback plug, which means that there is only one minicom session. 3. If you have not already done so, log in to your Linux system. 4. Open a terminal window (GNOME, xterm, gterm, etc.) In GNOME select, Accessories-->Terminal. 5. Type su and enter the root password. 6. List the Comtrol ports. [root@localhost/dev]# ls /dev/ttyRP* This should show the tty ports that have been installed beginning at 0 (zero) and sequentially numbered to the highest port on the device. For example, a RocketPort Infinity 16-port has ttyRP0 through ttyRP15 displays as: ttyRP0 ttyRP10 ttyRP12 ttyRP14 ttyRP2 ttyRP4 ttyRP6 ttyRP8 ttyRP1 ttyRP11 ttyRP13 ttyRP15 ttyRP3 ttyRP5 ttyRP7 ttyRP9 7. Start minicom with the setup option. [root@localhost/root]# minicom -s The following warning message may appear: minicom: Warning: Configuration file not found, using defaults The following menu should appear: [Configuration] Filenames and paths File transfer protocols Serial port setup Modem and dialing Screen and keyboard Save setup as dfl Save setup as... Exit Exit from minicom 8. Using the up and down arrow keys select Serial port setup. The following menu should appear: A - Serial Device : /dev/modem B - Lockfile Location : /var/lock C - Callin Program D - Callout Program E - Bps/Par/Bits : 38400 8N1 F - Hardware Flow Control : Yes G - Software Flow Control : No Change which setting? 9. Enter a and the cursor should move to the end of A - Serial Device : /dev/modem. 10. Using the backspace key, change modem to ttyRPx where x is a number of the port to test. This example uses Ports 0 for the first minicom window, so the line should read, A - Serial Device : /dev/ttyRP0 Note: Linux is case-sensitive. 11. With the cursor at the "Change which setting?" option, press the Enter key to close this screen and return to the Configuration screen. 12. At the [Configuration] menu, use the Up and Down Arrow keys to select Exit. This exits the Configuration utility and starts minicom. A screen should appear "Initializing Modem" and then a Welcome window with a cursor. 13. Open a second minicom session and repeat the steps to open another port (ttyRP1). You will now have two minicom sessions active. 14. Type in some letters, numbers, and so forth. 15. Go to the first minicom session. Look for the characters that you had just typed in. If these characters are present, you have successfully transmitted data from the second port to the first port. 16. Type in something in the first minicom session. 17. Go to the second minicom session. Look for the characters that you had just typed in. If these characters are present, you have successfully transmitted data from the first port to the second port. You have successfully tested the Comtrol device and are ready to begin use. --------------------- Testing a RocketModem --------------------- If you are using a RocketModem and have live telephone lines connected to the modems you can do this test through the modems with only a couple of modifications. 1. Use the previous procedure to set up two minicom sessions. 2. Go to the first minicom session and type in ats0=1 to cause the modem to answer after one ring. A response of OK should be seen on the monitor. 3. Go to the second minicom session and enter atdt and the phone number of the first modem. For example, atdt5551234. The modems should connect and the connection statistics should be seen. Once the connection is made, typing in characters in one session should display the same characters in the other session. 4. To hang up, enter +++ath. 5. Go to the second minicom session. 6. Exit minicom using the Ctrl key then press the Z key and the Help screen should open. 7. Enter X to exit. 8. Log out. 9. Return to the first minicom session. 10. Exit minicom by pressing Ctrl then the Z key and the Help screen should open. 11. Enter X to exit. ----------------- Trademark Notices ----------------- DeviceMaster, RocketModem, and RocketPort are registered trademarks of Comtrol Corporation. Other product names mentioned herein may be trademarks and/or registered trademarks of their respective owners. Third Edition, July 20, 2007 Copyright © 2000 - 2007. Comtrol Corporation. All Rights Reserved. Comtrol Corporation makes no representations or warranties with regard to the contents of this document or to the suitability of the Comtrol product for any particular purpose. Specifications subject to change without notice. Some software or features may not be available at the time of publication. Contact your reseller for current product information. ------------------------------ Document Number: 2000176 Rev C