INTRODUCTION
Isolating a problem is the first step in fixing it. Below is a series of tests that catch about 85% of the problems our users report. If you have trouble getting data into QC-Gage, perform these tests. Remember that if you can’t reliably get raw data into HyperTerminal, QC-Gage has nothing to work on!
STEPS
- Start Microsoft HyperTerminal. In HyperTerminal set the Baud Rate to the rate your gage is set to, set the flow control to none (even if your gage uses flow control), turn on local echo, and set the COM port to the port you want to use. Disconnect the gage and cables from the computer. Connect to the port - you must click the Connect button. If you get an error, the COM port you specified does not exist, is broken, or is used by another device. Likely candidates are internal modems, mice, and communications programs. Fix the port if it’s broken or use a different port. Note that even if you have 3 COM ports, you only have 2 COM interrupts, so a modem or mouse on COM3 will interfere with COM1.
- In HyperTerminal type "Hello". You should see "Hello" on the screen, indicating local Echo is working. Now jumper pins 2 and 3 of the COM port together. You can use a breakout box, pin jumpers, or just get a helper to hold a piece of wire or a penny against the 2 pins, being careful not to touch the wire to the sides of the connector. Now, with the jumper in place, type "World". You should see "WWoorrlldd" indicating you get both a local echo (the first of each character) and the loop back character. If you don’t get 2 of each character, you have the wrong COM port or the port is broken. Try a different COM number or a different socket on the back of the computer. If you can’t find a socket that works with the COM number, that COM port must be broken.
- Disconnect your jumper, connect the cable to the computer, and jumper pins 2 and 3 at the gage end of the cable. Type "cable". You should see the word "ccaabbllee" indicating you have local echo and the data can travel the cable in both directions. If you only see "cable" you have a faulty cable, replace or repair it.
- Disconnect the jumper from the cable and connect the gage. In HyperTerminal set the flow control to the type of flow control the gage uses. You may have to disconnect and reconnect for the change to take effect. Send data from the gage. There are several possible outcomes, you could get data, garbled characters, or nothing. If you get data, you have a connection but may have problems at higher data flow rates, we suggest you run test 5. If you get garbled data, you probably have a setting wrong. Verify your baud rate, parity, and stop bits on both HyperTerminal and the gage. If all the settings are correct and you still get garbled characters, run test 6. If you get nothing, run test 7.
- Test the gages high speed by choosing HyperTerminal's Capture to text file and sending data as fast as the gage can for several minutes. Then close the text file and open it in Notepad. Look for missing characters and sections of garbled characters. If you get good data sending one or two readings but have problems at high speed, there are several possible problems. If you use a baud rate higher than 2400 baud you must have a 16550 compatible UART chip. This is a Windows limitation and there is nothing you can do about it. Run Microsoft’s MSD.EXE utility to determine the type of UART you have. Note that MSD.EXE is included in all versions of Windows, but it does not automatically install. If you run Windows95 or NT, you may need to get your installation disks to run MSD.EXE. If the UART is not the problem, check for an electrical problem (see test 8 below) then contact the computer or gage manufacturer.
- If you get garbled characters even when sending just a few characters, and you are sure the settings on both the gage and HyperTerminal are correct, you may have a gage that does not output ASCII format. Check with the gage manufacturer to determine the output format. You may have an electrical problem, a defective gage, or a defective computer.
- If you get no data from the gage, the problem is probably either in the gage or is related to flow control. Check the settings again, and test the cable to make sure it has all pins correctly connected. If the cable is good, try turning everything off, then back on - all this testing could have locked up the gage. When you restart, turn the computer and HyperTerminal on first, some gages check for a live connection on startup and if they don’t find one will not communicate at all for that session. If you are using software flow control, go to HyperTerminal, hold down the "Ctrl" key and press "Q" to send an XOn character. If this still does not work, you will need an RS232 breakout box or a line monitor. A breakout box plugs in between the cable and the computer and displays the current value of all the different lines on the cable and lets you change some values by jumpering pins together. A line monitor is a more sophisticated breakout box, it also displays the characters sent, but many lack the ability to jumper pins. Use the breakout box (or the line monitor) to see if any handshaking lines are set. Even if your gage manual says your gage does not use flow control, you should try using hardware flow control in HyperTerminal if the gage won’t talk. The documentation may be in error. If the gage still won’t send data to HyperTerminal, you should contact the gage manufacturer for further assistance.
- If you suspect electrical problems, you may have a problem with interference, improper grounding, or a faulty gage. Make sure; all electrical outlets are properly grounded, all electrical outlets have filters and surge suppressers, the cable is shielded, the cable is far from strong electromagnetic fields. Check the cable for; loose pins in the connector, broken wires inside the insulation (if they break inside the insulation, bending the cable in one direction makes it work but stretching it or bending it the other way breaks it). Try; a different gage of the same model, a different cable, a different computer.
- A more rigorous test of serial port. This requires 2 computers with serial ports, or 2 serial ports on a single computer, and a text file about 50000 bytes long or larger. Connect the 2 computers (or 2 serial ports) with a Null Modem cable.
- Run HyperTerminal on both computers, using the baud rate and parity your gage uses and using XOn / XOff flow control. Send the text file from one computer to the other, using Capture Text File to save it to disk. When it finishes, read it to see if there are missing or garbled characters. If it has no errors, send it back and check it on the other side for errors. If you get errors, they could be caused by defective serial cards, interference from other programs (virus checkers, mice, and display drivers are common causes), or electrical problems (see above). This may be a difficult problem to isolate, and may require your MIS department, a computer consultant, or the computer manufacturer. You can repeat this test many times or with larger files to find errors that are very infrequent. If you send the file from computer A to computer B then send it back to computer A but give it a different name, you can use the DOS FileCompare command to check the file for errors without reading it. Just start a DOS shell, change to the directory with the original file (called Name1.txt) and the twice transmitted copy (called Name2.txt) and type FC Name1.txt Name2.TXT then press enter. If you get "No differences encountered" then there were no errors.