1. Cx-Programmer V5.0 and PLC communication are unstable:

Computer and PLC connection: computer USB port (the computer does not have RS232 serial port) ←→[USB to RS232 cable USB plug ←→USB to RS232 cable (the computer has installed the driver, and the default COM4 port has been set to COM1) The middle part ←→USB to RS232 cable RS232 male head]←→[[The computer and PLC connection cable RS232 female ←→ computer and PLC connection cable middle part ←→ computer and PLC connection cable RS232 public Head]]←→PLC RS232 female.

The above single brackets are USB to RS232 cable, and the double brackets are the connection cable between the computer and the PLC. The connection cable between the computer and the PLC is as follows: (1). The males (used to connect the PLC) 2, 3, 9 and the female 2, 3, 5 (for connecting the computer or USB to RS232 cable) are short. This is the official connection method of Omron; (2). The male and female 2-2, 3-3, and 5-5 are shorted respectively, which is the conventional connection method of the RS232 cable. Later, it was proved by practice that the above two kinds of computer and PLC connection cables can be used. The first type of cable communication is stable and reliable. For the second type of cable, when the computer and the PLC communicate with each other through the VC application, the effect is not good, and it is easy to drop frames (can be seen by the serial debugging assistant), and only when the computer and the PLC share the power supply (common ground) problem found. Therefore, please use the first type of connecting cable as much as possible.

There is time for the computer and PLC to communicate normally, but there is time but it is not possible – display “Modem has been selected, continue code?” Fault (actually “code” should be “?”), once the fault message appears, it will definitely The following fault message appears:

When the communication is not on, the author has used the method of cloning back to the previous normal operating system, reinstalling Cx-Programmer V5.0 programming software, etc., and can communicate normally, but once the line is disconnected, communication may not be possible. On several occasions, I found that some programs can communicate with the PLC, while others can’t! Therefore, the author will back up the PLC program that can communicate, then delete all the instructions in the program, and finally copy all the instructions of the target program (the comments can be copied automatically when copying), so that the computer can communicate with the PLC normally. Now! But – the next time this program may not be able to communicate properly! Depressed…

According to the communication error message “Modem has been selected, continue code?”, I found a solution: right click on “My Computer” on the desktop, then click on “Properties” – “Hardware” – “Device Manager” , double-click “Modem”, then right-click on the expanded modem model and click “Deactivate”.

In addition, the correct connection method is as follows: the computer is not turned on or (and) the PLC is not powered (otherwise, the plugging and unplugging communication port may cause the communication port to be damaged (although this probability is not large, but you are better not to try your luck)) Connect the USB to RS232 cable, the connection cable between the computer and the PLC, and then connect the computer to the PLC through Cx-Programmer.

Please note that the USB port is not free to plug in. The key is to ensure that the RS232 port in the device manager is COM1. In the author’s computer, this situation: Initially, the default RS232 port has been changed from COM4 port to COM1 port, but the USB port inserted below corresponds to the COM4 port of RS232 (COM1, COM3 are being used), and the computer and PLC cannot be connected; Plug the USB port above to correspond to the COM1 port of RS232 (COM2, COM4 are in use), you can connect the computer to the PLC.

2.Cx-ProgrammerV5.0 and PLC communication interference:

If the Cx-Programmer is online, the computer and the PLC are connected and in communication state. When the device is stopped (nearly 20 AC contactors are disconnected at the same time), the Cx-Programmer will have a communication error and the computer and PLC connection will be interrupted. And each time the power is turned on (nearly 20 AC contactors are simultaneously attracted), there is no communication error.

Solution: Reconnect the PLC. If you are a perfectionist, you can add a RC resistor-capacitor module to each contactor coil (about 60 oceans per RC module), and there may be no communication errors (but I have not tried it.) .).

3. Computer and PLC connection cable test:

Because I think that the connection cable between the computer and the PLC (the first conventional connection cable) is 2-2 short, 3-3 short, 5-5 short, consider connecting the computer and PLC directly with a USB←→RS232 cable. Get up, if this is okay, would you save a connection cable? The following is the test result of connecting the computer and PLC directly with USB ←→RS232 cable:

When there is time for the first communication, the following error occurs: “The selected port is occupied by another application”; the following error occurred during the second communication:

Why is there no problem connecting the computer to the PLC through the above two connection cables, but the USB to RS232 cable is directly connected to the PLC but not? The following is the analysis process:

The first possibility: the cause of the impedance. Although the above two connecting cables are straight wires, there is impedance, and this impedance can be connected normally. But this reason seems to be far-fetched, even the author can not believe.

The second possibility: the USB to RS232 male head and the PLC’s female head are in poor contact, but a cable can be connected normally – the USB to RS232 male head and the connecting line’s female head are in good contact, the connection line is public. The head is in good contact with the female of the PLC. The guess comes from a computer failure that I have encountered: the mouse of one computer cannot be used, and the other mouse is normal, and the faulty mouse can be used for other computers. Finally, I suspect that the mouse connector is not in good contact with the motherboard socket. I will break the mouse plug and apply a layer of solder. The result is normal! However, for the guess that the male of the USB to RS232 is in poor contact with the female of the PLC, the author thinks that the possibility is not great – because he can’t explain the fault that the selected port is occupied by another application.

Finally, I thought of another possibility: USB to RS232 directly connected to the PLC is equivalent to USB to RS232 serial port and PLC serial port 1-1, 2-2, 3-3, 4-4, 5-5, 6-6, 7-7, 8-8, 9-9 are connected one by one, but only two pairs of terminals 2-2, 3-3, 5-5 are connected through the connecting line, which means 1-1, 4-4, 7- 7, 8-8, 9-9 at least one pair can not be connected, otherwise there will be problems, and this may also damage the communication port between the PLC and the computer.

Leave a Reply

Your email address will not be published. Required fields are marked *