I have a robot which uses interrupts stop a LIN motion when an input from loadcell circuit is turned on. This has worked fine for me when. program was Applying load in 1 direction (Input 1 On) and back to centre (Input 1 off) and then other direction (Input 2 on) and back to 0 (Input 2 off). The problem I'm having with this project is whenever initial load is applied and first interrupt routine is played. the load doesn't to back to 0. The load is applied in another direction. during this move input may go on or off, if it goes off and back on the interrupt routine is triggered again and robot stop which isn't what I want to do. I want robot to move in other direction regardless on input status. Hope this makes sense.
Interupts
-
Ruddock984 -
March 11, 2022 at 11:32 AM -
Thread is Unresolved
-
-
Hope this makes sense.
Not really. Also, post actual code, not screenshots.
-
Hope this makes sense.
nope...
if one cannot communicate well with humans, of course robots will understand even less.
i am guessing that "center" and "0" in your case are supposed to mean the same thing. i do not see inputs 1 and 2, i see inputs 1 and 4. it is unclear what is the "first interrupt routine", your program routines have names - use them. also if your interrupts are called, they are never turned off etc.
for example if robot is executing line 19 (instruction LIN P28) whn input 4 becomes true, line 20 is never reached. RESUME command aborts the MOVEMENTFWD1()