Areeb Posted July 21, 2020 Report Posted July 21, 2020 Hi, I wanted to know how do I check my interrupt input signal whether it coming or not. Basically I have a program which consists of I401 & I 501 interrupts as externally connected in X4 & X5 of PLC input and this signals belong to proximity sensor and photo mark sensor. But now it is not working properly as it is not cutting the product with the desired location. below I have attached the snapshot. I
AndreasW Posted July 21, 2020 Report Posted July 21, 2020 hi Areeb, your code should run on the rising edge of X4 and X5, check out if interrupt handling is enabled ( EI instruction inside the normal scan program) and that the interrupt disable commands (M8050...M8055) are not set within the scan program. to see if the code get called you can temporarily add a line inside the interrupt program that increment a word register on each call If the interrupt get called the register should be counting up. e.g. for register D1 insert: ----| M8000 | ------------------------------ [INC D1] , be sure to use a free register that isn't used inside the program! also check out if/when M30 is set inside the scan program. the calculation only will be executed if M30 is set. You should use an extra 'calculated' flag to be sure that D60 got calculated. I don't see if the cutting is started inside the X4 interrupt, in this case be aware that X4 interrupt has higher priority than X5 interrupt. Just in case that both signals turn on at the same time. In this case X5 interrupt can be interrupted by X4 interrupt. maybe you should also check out the input filter time in the IO parameters, i think the default setting for X4 and X5 is 10ms, maybe this is too long for short input pulse
Areeb Posted July 22, 2020 Author Report Posted July 22, 2020 Thanks buddy I will try to check it out with the given information above. Hope it will workout and solve my problem.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now