Tom Kazakoff
Member
The following is the way I call a bunch of routines from the top level routine.
It works fine, however I discovered that I can not restart the subroutine, since
the done bit turned off the JSR call so the done bit in the subroutine is still on
(It is not being scanned anymore). I want to avoid using latches and unlatches, i.e.,
I could latch the done bit in the subroutine and unlatch it at the top level. I
also tried shifting a 1 into an array with BSL, then if it is set start goes off.
I could also move a 1 to a tag (for done), then clear it at the top level routine.
Does anyone know of a method that will cause (start) to be false when done is true,
without having to latch and unlatch the done bit?
---[hmi on]----|--------[not done]-----------(start)
|
---[start ]----|
---[Start]-------------------------[JSR routine Home]
Sub: Routine Home
close valve
turn off motor
-----[all OK]-----------------------------(done) ->not latched
RET
It works fine, however I discovered that I can not restart the subroutine, since
the done bit turned off the JSR call so the done bit in the subroutine is still on
(It is not being scanned anymore). I want to avoid using latches and unlatches, i.e.,
I could latch the done bit in the subroutine and unlatch it at the top level. I
also tried shifting a 1 into an array with BSL, then if it is set start goes off.
I could also move a 1 to a tag (for done), then clear it at the top level routine.
Does anyone know of a method that will cause (start) to be false when done is true,
without having to latch and unlatch the done bit?
---[hmi on]----|--------[not done]-----------(start)
|
---[start ]----|
---[Start]-------------------------[JSR routine Home]
Sub: Routine Home
close valve
turn off motor
-----[all OK]-----------------------------(done) ->not latched
RET