Fixes bug with robot not halting, which caused connections, adaptors and...

... devices to not disconnect.