Skip to content
/ haanna Public
forked from laetificat/haanna

Plugwise Anna API to use in conjunction with Home Assistant.

License

Notifications You must be signed in to change notification settings

fritsvp/haanna

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Haanna (HA Anna)

A Python API made for use in conjunction with the Home Assistant Anna component, but this API can also be used in other projects.

Installation

pip install haanna

Usage

from haanna import haanna

# Create the API
api = haanna.Haanna('smile', 'short_id', '192.168.1.60')

# Fetch the domain objects
domain_objects = api.get_domain_objects()

# Set the temperature
temperature = api.set_temperature(domain_objects, 22.50)
print(temperature)

# Get the temperature
temperature = api.get_temperature(domain_objects)
print(temperature)

# Get the outdoor temperature
temperature = api.get_outdoor_temperature(domain_objects)
print(temperature)

# Get the target temperature
temperature = api.get_target_temperature(domain_objects)
print(temperature)

# Get the available presets
presets = api.get_presets(domain_objects)
print(presets)

# Get the current active preset
current_preset = api.get_current_preset(domain_objects)
print(current_preset)

# Set a preset
preset = api.set_preset(domain_objects, 'away')
print(preset)

To do:

  • Optimize fetching of domain objects
  • Add support for custom port mapping

About

Plugwise Anna API to use in conjunction with Home Assistant.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 100.0%