Strategy and chart running but logic not executing

Hi all,

I am new to Opto 22 PAC software development (liked the flow of it, makes it easy to understand actual process) and on this forum.

We are using SNAP-PAC-R1 controller and PAC control professional version R9.6e.

I am currently facing following issue:
I can see that strategy and chart is running but logic is not getting executed (as if chart is suspended) after certain point (I have set flags at every step of the logic to track where the logic stops executing).

Now, this problem occurs only in certain case (Lets say case A). In other case (Case B) logic seems to perform correctly (Both strategy and chart running with logic getting executed).

I am not able to narrow down where the problem could be, any pointers in the direction of trouble shooting will be appreciated.

In case A and B both, it is closing a valve using serial communication RS232 (and some additional tasks), in case B valve is already closed but in case A valve which is open actually performs the closing operation. Action of closing valve is performed in another chart.

BR,
Akshay

Welcome to the forums!

Hard to say for sure, but it sounds to me that your RS232 comm handle is timing out, or more likely waiting for a response from the valve. That’s why the chart appears to suspend, its not suspended, its waiting for a response.
This is where I would be focusing my attention, on the comm handle. Check if it is open or closed at the point where the logic stops responding.
Also it can be a bit tricky to have two charts accessing the one comm handle, getting the two charts synchronized is very difficult to do and this may be another reason why one chart appears to suspend, it might be waiting for the other chart.
Can you move all the comm handle logic into the one chart so it flows cleanly?

Beno,

Thanks for the reply and pointers, they were helpful.

Found the problem, it’s related to not knowing the exact position of the valve and it is getting stuck in a loop waiting for a response to determine valve position.

BR,
Akshay

Searched on the forums and this post was about the closest I could find to my error…

Strategy and chart have been in use on other EPICs for a long time now with no issues. One of the first things that happens in the strategy is the communication with a scale using RS232. You can see that I am not able to get the comm status = 0 (true). Instead, I never get the “true” (I seem to get -39). Any suggestions for where to go next on troubleshooting this? AFAIK, everything on the RS232 output stream is the same as in prior installations. FYI, I do have two scales in use here, each with their own comm handle, and each feeding into different inputs of the CSERI module on a single EPIC.



CSERI

-39 is timeout on receive. I would check the cable / connection / issue with the scale - swap the two serial cables and see if the problem moves to the other port to confirm it isn’t the PR1 / CSERI / logic.

Thanks Philip. It turned out to be a wiring issue. Me and the person who connected the scale to the CSERI did not perfectly communicate the wiring.

To restate the obvious…
Transmit (Tx) from the RS232 output of the scale goes to Receive (Rx) on the CSERI.
Receive (Rx) from the RS232 output of the scale goes to Transmit (Tx) on the CSERI.

1 Like