Skip to main content

A lightweight ping module returning boolean

Project description

PingDevice Class

The PingDevice class is a Python class that allows you to check if a device is online by pinging its IP address.

Installation

The PingDevice class requires Python 3.6 or later. There are no additional dependencies required.

Usage

First, import the PingDevice class:

In [7]: from ping_module import PingDevice

Create object and call ping() method.

In [8]: a = PingDevice(host="192.168.178.1")

In [9]: a.ping()
Out[9]: True

In [10]: a = PingDevice(host="www.ciscoscsdfsdfdsfsfds.com")

In [11]: a.ping()
Out[11]: False

Project details


Release history Release notifications | RSS feed

This version

1.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ping-module-1.0.tar.gz (2.4 kB view hashes)

Uploaded Source

Built Distribution

ping_module-1.0-py3-none-any.whl (2.8 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page