Introduction

Documentation Status Discord Build Status Code Style: Black

CircuitPython Wrapper for BloomSky API

Dependencies

This driver depends on:

Please ensure all dependencies are available on the CircuitPython filesystem. This is easily achieved by downloading the Adafruit library and driver bundle.

BloomSky Account

This library is only useful to owners of BloomSky Weather Stations. Get your Bloomsky API Key from your Bloomsky Dashboard. https://dashboard.bloomsky.com/

Usage Example

See full working example in the examples folder. The basic structure looks like this,

## Join Network
wifi.radio.connect(secrets["ssid"], secrets["password"])

# Setup Requests
radio = wifi.radio
pool = socketpool.SocketPool(radio)
requests = adafruit_requests.Session(pool,
ssl.create_default_context())

# Create Bloomsky client.
bloomsky_client = circuitpython_bloomsky.BloomSkyAPIClient(
    requests, api_key=secrets["bloomsky_key"]
)

# Get data and utilize it in your application.
# This is the section you would put in your While loop if running
# repeatedly.
bloomsky_report = bloomsky_client.get_data()

print(bloomsky_report.device)
print(bloomsky_report.indoor)
print(bloomsky_report.sky)
print(bloomsky_report.storm)

Contributing

Contributions are welcome! Please read our Code of Conduct before contributing to help this project stay welcoming.

Documentation

Pretty documentation available https://circuitpython-bloomsky.readthedocs.io/en/latest/

Installing from PyPI

Note

This library is not available on PyPI yet. Stay tuned for PyPI availability, when or if CircuitPython libraries are supported from there.

Acknowledgements

The basic idea for this library and the concept to rename attributes came from https://github.com/tylerdave/bloomsky-api and was heavily reworked for this library.

Indices and tables