Can't catch the Rising Edge

O

Thread Starter

Ozi

Hi everybody,

I have a problem. I am using "Positive Transition Contact Detector" in my logic to catch the rising edge of a bit.

The positive transition contact is triggered when its coil is energized and if I put the contact in a different section, the processor can't catch it. But, if I put the contact right after the coil then it catches it. But still it does not operate very smoothly. Once in while I find my logic get locked up and I believe that the processor misses the positive transition and the rest of the logic does not work...

Has anybody encountered a similar problem with Premium PLC?

I appreciate any comments.

Best regards,

Ozi
 
Hi

In PL7 Reference Manual you can find:
"Do not perform SET or RESET on a object whose rising or falling edge is being tested."
So if you test coils which are triggered with SET and RESET instruction the program don't work corectly.

Regards
Andrzej
www.modbus.pl
 
A

A PLC Programmer

Dear Ozi

I have encountered the same problem while programing. What I usually do is either use a Set-Reset latch. Set the latch witht he raising edge. Rest it when your desire logic is satisfied. Or use a temporaray timer to have the positive edge remain alive for a few seconds.

Best of luck for u.

Regards

A PLC Programmer
PAKISTAN
 
I don't know about Schneider stuff, but most PLC instructions from many vendors only work if the pulse that generates the rising edge takes longer than the worst case scan time of your system. If you sometimes get 50us pulses or something like that (Like from a high speed photo sensor detecting a small part flying by at high speed , and with no off delay), your PLC will miss it most of the time unless it has a high speed latch function on some dedicated inputs (some vendors have this on option boards, etc).

Best of luck,
~KEJR
 
Thank you all.

I will try to put some delay and see how it works out since I cant see the result right away. sometimes it doesn`t happen for couple of days. but sometimes it happens couple of times a day.

anyway, thanks for commenting.

regards,
Ozi
 
A

Arun Kataria

Dear Ozi,

Can't say about Premum PLC but there must be some intrrupt function for which you have to configure your rising edge input as an interrupt so that it will have the highest priority, i.e. as and when the input comes (irrespective of scan cycle) the plc will execute the subroutine written for this interrupt.

OR

there must be some function which can elongate the rising edge to be readable for PLC. In my PLC Brand (FATEK) this function is called Capture input. Look for the similar function, this will solve your problem.

OR

If your PLC have high speed counter function then configure your input as high speed input and then make your logic.

Hope this will help you.

Arun Kataria
 
Normally the edge information of an I/O or internal bit (%Mx) is updated after each modification affecting it (writing operation in the application for internal bits and outputs, system cycle for inputs). So if you have somewhere two consecutive operations writing the same state for internal bits (%Mx), the edge information is lost for the tests following.

Read carefully your program by thinking that and you will find probably the origin of your problem. About input bits, the cycle time of the PLC must be short considering a pulse duration to be able to detect edges.

Regards.
 
If your have a RESET coil on the eboolean value you wish to catch it deletes the edge inforation in the ebool structure. This may be the problem.
 
Top