Skip to main content
Python Software Foundation 20th Year Anniversary Fundraiser  Donate today!

No project description provided

Project description

This is a python library to access iot website
IOT-JOKE(https://iot-joker.firebaseapp.com)
https://img.shields.io/pypi/status/pyiotjokepi.svg https://img.shields.io/pypi/dw/pyiotjokepi.svg?style=plastic https://img.shields.io/pypi/v/pyiotjokepi.svg https://img.shields.io/pypi/format/pyiotjokepi.svg https://img.shields.io/badge/author-Dhanush-orange.svg

Functions:

  • Control devices using switches
  • Plot your sensor data

Installation :

Python3

pip3 install pyiotjoke

or

pip install pyiotjoke

Implementing :

from iotjokepi import JokePi

ApiKey = 'Your API Key'
Link = 'http://iot-joke-pi.herokuapp.com'

# Instance to get swtich states
getOb = JokePi('Button', ApiKey, Link + '/api/getdata/')


data1 = getOb.getSwitchState('Switch Name')
data = data1

if data == 'ON':
    print('Switch is ON')
elif data == 'OFF':
    print('Switch is OFF')
else:
    print('Invalid Device')

Project details


Download files

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

Files for pyiotjokepi, version 0.2.4
Filename, size File type Python version Upload date Hashes
Filename, size pyiotjokepi-0.2.4-py3-none-any.whl (4.0 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size pyiotjokepi-0.2.4.tar.gz (2.1 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page