Dan H, Sudarshan K,
The ISS second loop automation is implemented in the IMC guardian. This included a slightly modified script from alog 15164.
We added ISS_ON as a requestable state and CLOSE_ISS and OPEN_ISS as intermediate state to move in and out of it. The sticky issue is setting the REF_SIGNAL voltage to get the OUTPUT to zero. We do that by looking at the sum of the in-loop-pd signal. This takes several seconds and occasionally will sets the initial ref signal little off from the optimal value because of the in-loop-pd transient. We need to find a better way of doing this for our future iterations.
There are some failure modes in the CLOSE_ISS mode which will trigger jump transitition to OPEN_ISS. This can result in a never ending loop if the script keeps trying and failing to close the loop. In this case you can change the requested state to LOCKED and it will return to LOCKED when it fails the next time.