Skip to main content

A Python library for controlling Neo Smart Blinds via BlueLink Bluetooth connection

Project description

NeoSmartBlue Python Library

A Python library for controlling Neo Smart Blinds via BlueLink Bluetooth connection.

Installation

pip install neosmartblue.py

Usage

Scanning for devices and reading status from advertisements

import asyncio
from neosmartblue.py import scan_for_devices

async def main():
    # Scan for nearby Neo Smart Blinds devices
    devices = await scan_for_devices(timeout=15.0)
    if not devices:
        print("No devices found.")
        return
    
    for device in devices:
        print(f"Device Address: {device['address']}")
        print(f"Device Name: {device['name']}")
        print("Status:")
        for key, value in device['status'].items():
            print(f"  {key}: {value}")
        print()


asyncio.run(main())

Controlling a device

import asyncio
from neosmartblue.py import BlueLinkDevice

async def main():
    # Replace with your device's MAC address
    device = BlueLinkDevice("XX:XX:XX:XX:XX:XX")
    
    # Connect to the device
    await device.connect()
    
    try:
        # Move blinds to 50% closed position
        await device.move_to_position(50)
        
        # Stop movement if needed
        # await device.stop()
    
    finally:
        # Disconnect from device
        await device.disconnect()

asyncio.run(main())

Project details


Download files

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

Source Distribution

neosmartblue_py-0.1.4.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

neosmartblue_py-0.1.4-py3-none-any.whl (7.2 kB view details)

Uploaded Python 3

File details

Details for the file neosmartblue_py-0.1.4.tar.gz.

File metadata

  • Download URL: neosmartblue_py-0.1.4.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for neosmartblue_py-0.1.4.tar.gz
Algorithm Hash digest
SHA256 c13e3d8af3aed39466797d66497a1065edb4ad93296632db6c1ff8104b2cecce
MD5 863adb99de6855da9e8b431defa97636
BLAKE2b-256 ae787b3fc01a072a6713c6728b8791015d3bb21ea0ecee4b5d87c598a945dcdf

See more details on using hashes here.

Provenance

The following attestation bundles were made for neosmartblue_py-0.1.4.tar.gz:

Publisher: publish.yml on ikifar2012/neosmartblue.py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file neosmartblue_py-0.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for neosmartblue_py-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 e38d27fa168210d4314ac26011d0e3ea44bade220be2046a7eb2adfbe7061f8b
MD5 d835b9b58f3ad1f9b7ab4d200332dcab
BLAKE2b-256 7f81e64fb9db9757a0d90fbac1eda3f7e93cdd9feca335e6076e185700f3eb0a

See more details on using hashes here.

Provenance

The following attestation bundles were made for neosmartblue_py-0.1.4-py3-none-any.whl:

Publisher: publish.yml on ikifar2012/neosmartblue.py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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