Hello Sanjay ,
One option would be to close the device by deleting the refereence to the object and then when you would want to start the pipeline, you would reconnect to it. Another option would be to use Script node to discard all input frames (from the color/mono camera) when pipeline is stopped, or to pass them to the pipeline when pipeline is "running". Example of such functionality can be found here. Thoughts?
Thanks, Erik