- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
Link copied. Please paste this link to share this article on your social media post.
Posted: 2024-03-04 11:02 PM . Last Modified: 2024-03-04 11:05 PM
M221 serial line stuck (stress test)
As part of the pre-commissioning testing, we validate ladder logic against different scenarios, one of them is related to testing the serial line adding noise, parity errors, drop of frames, insert/remove out extra characters to the frame, ignore requests, delay responses.
PLC/Ladder is properly able to handle the scenario when requests are ignored (sensor disconnected) and when the response is delayed. But when we test introducing parity errors (CRC) or any other simulation that actually corrupts the frame, after some time (5 min to 10 min) the READ_VAR blocks get stuck and the only way to properly get the communication back is to restart the PLC.
(Check attachments)
Image 1: Test using PLC connected to a Rs485 to USB adapter and using a simulator (ModRSim2 OpenSource)
Serial devices:
(Check attachments)
Image 2: List of READ_VARs
Comm port settings:
Image 3: (Check attachments)
How to replicate the issue:
1 - Setup the environment similarly to image 1.
2 - Configure the READ_VARs as in image 2.
3 - Add the READ_VARs on the ladder, sequentially after one finishes trigger the next. DONE or ERROR triggers EXECUTE of the next. (in our case we have a counter adding a small delay between each READ_VAR)
3 - Download and install ModRsSim2 https://sourceforge.net/projects/modrssim2/
4 - Under "Communication Fault Simulation" enable all options.
5 - Let it run for 10 min
6 - Monitor the errors on each READ_VAR
After getting "stuck" every new read attempt on any READ_VAR (EXECUTE to 1) fails (ERROR to 1) with the following error codes:
CommError: 255
OperError: 6
Is there any limitation or known issue on the serial port SL (READ_VAR communication block)?
- Labels:
-
Energy Efficiency
- Tags:
- english
Link copied. Please paste this link to share this article on your social media post.

