Registry / devops / msmart-ng

msmart-ng

JSON →
library2026.4.1pypypi✓ verified 80d ago

A Python library for local control of Midea and associated brands (e.g., ProElec, Tornado, Carrier) smart air conditioners. Version 2026.4.1 requires Python >=3.10. Community-maintained, receives regular updates for protocol changes.

pip install msmart-ng
INSTALL
IMPORT
SIG · MSMART-NG
M
msmart-ng
devopspythonv2026.4.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

metadata
from msmart import metadata
from msmart import MideaClient

Quick example to control a Midea AC locally.

import asyncio from msmart import MideaClient from msmart.device import AirConditioner async def main(): client = MideaClient('192.168.1.100') # Replace with IP device = await client.get_device() if isinstance(device, AirConditioner): device.power = True device.target_temperature = 24 await device.apply() print("AC set") asyncio.run(main())
Debug
Known issues
breakingmsmart-ng v2022.5.1+ changed the package name from 'msmart' to 'msmart-ng', breaking imports like 'from msmart import *'.
fix
Uninstall the old 'msmart' package and install 'msmart-ng'. Update imports: from msmart import MideaClient
affects: >=2022.5.1
gotchaLocal control requires the device token. Without it, communication will fail with a crypto error.
fix
Run 'msmart-ng token' CLI command while the device is in pairing mode to generate a token.
affects: all
deprecatedThe 'discover' function using UDP broadcast can be unreliable on some networks; consider using the new 'MideaClient.search' method.
fix
Use msmart.discovery.search() with the IP instead of broadcast discovery.
affects: <2023.5
Upgrade
Version history
2026.4.1latest on PyPI · released Apr 2, 2026
Audit
Dependencies
cryptographyrequiredRequired for device communication encryption
requestsrequiredHTTP requests for token generation
Agent activity
2 hits · last 30 days
node
2
Resources
msmart-ng — pip install msmart-ng · libregistry