Skip to content

richbeales/python-orvibo

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

python-orvibo

Control Orvibo devices with Python 3. Currently supports the S20 WiFi Smart Switch.

Usage

from orvibo.s20 import S20

s20 = S20("x.x.x.x") # Discover the IP on your own.
print(s20.on) # Current state (True = ON, False = OFF).
s20.on = True # Turn it on.
s20.on = False # Turn it off.

There is also a command line version to achieve the same, e.g.

python cmd.py --server 1.2.3.4 --switch off
python cmd.py --server 1.2.3.4 --switch on
python cmd.py --server 1.2.3.4 --status

There is also a HTTP Server version .

python3 OrviboHTTPServer.py <ip to bind to> <port to listen to>

Commands can then be given through HTTP GET requests in the openHAB http binding using the following IP Address and path:

<ip to bind to>:<port to listen to>/STATUS/<ip of plug>
<ip to bind to>:<port to listen to>/ON/<ip of plug>
<ip to bind to>:<port to listen to>/OFF/<ip of plug>

Contributions

Pull requests are welcome. Possible areas for improvement:

  • Discover configured devices (get IPs).
  • Additional Orvibo devices.
  • Expand S20 functions: Timers, configuration, etc

Disclaimer

Not affiliated with Shenzhen Orvibo Electronics Co., Ltd.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%