import isystem.connect as ic
import subprocess
import time
TIMEOUT_S = 15
POLL_INTERVAL_S = 0.5
def test_isConnected():
print("Connecting...")
cfg = ic.CConnectionConfig()
cfg.start_always()
conn_mgr = ic.ConnectionMgr()
conn_mgr.connect(cfg)
print(f"\tIs connected: {conn_mgr.isConnected()}")
print("Disconnecting...")
conn_mgr.disconnect_close(bSaveAll=False)
print(f"\tIs connected: {conn_mgr.isConnected()}")
if __name__ == "__main__":
test_isConnected()