def ping():
    conn = __proxy__['junos.conn']()
    ret = dict()
    ret['message'] = conn.probe()
    if ret['message']:
        ret['out'] = True
    else:
        ret['out'] = False
    return ret
To check the connection with the device
dataset/ETHPy150Open saltstack/salt/salt/modules/junos.py/ping