{"id":24598,"library":"smp","title":"smp: Simple Management Protocol","description":"smp is a Python implementation of the Simple Management Protocol (SMP) for remotely managing MCU firmware, commonly used with Zephyr and MCUboot. Version 4.0.2 is current, supporting Python >=3.9. The library provides client and server functionality for MCU management including image upload, shell, file system, and task statistics. Releases occur every few months.","status":"active","version":"4.0.2","language":"python","source_language":"en","source_url":"https://github.com/JPHutchins/smp","tags":["smp","mcumgr","zephyr","iot","firmware","management"],"install":[{"cmd":"pip install smp","lang":"bash","label":"Install from PyPI"}],"dependencies":[{"reason":"CBOR serialization/deserialization for SMP frames","package":"cbor2","optional":false},{"reason":"optional for persistent session storage","package":"lmdb","optional":true}],"imports":[{"wrong":"from smp import SMPClient","symbol":"SMPClient","correct":"import smp"}],"quickstart":{"code":"import asyncio\nfrom smp import SMPClient, Group\n\nasync def main():\n    client = SMPClient(\"tcp://localhost:6500\")\n    await client.connect()\n    # Get echo response\n    echo = await client.echo(data=b\"hello\")\n    print(\"Echo:\", echo)\n    # List groups\n    groups = await client.get_group_list()\n    print(\"Groups:\", groups)\n    await client.disconnect()\n\nasyncio.run(main())","lang":"python","description":"Connect to a remote MCU over TCP, send an echo request, and list management groups."},"warnings":[{"fix":"Ensure Python 3.9+ is installed.","message":"v4.0.0 dropped Python 3.8 support. Upgrade to Python >=3.9.","severity":"breaking","affected_versions":"<4.0"},{"fix":"Use `SMPClient.encode(data, fragment_size=8192)` if 8192 bytes is required.","message":"v4.0.0 changed default line length from 8192 to 127 bytes for encode(). Override if using larger frames.","severity":"breaking","affected_versions":">=4.0.0 <4.0.0"},{"fix":"Use 'from smp import SMPClient' instead.","message":"Top-level imports changed in v4; 'from smp.client import SMPClient' no longer works.","severity":"gotcha","affected_versions":">=4.0.0"},{"fix":"Migrate to SMPClient (import from smp).","message":"The 'session' module is deprecated in favor of the new client interface.","severity":"deprecated","affected_versions":">=3.0 <4.0"}],"env_vars":null,"search_vec":"'3.9':33 '4.0.2':28 'client':37 'common':21 'current':30 'everi':55 'file':48 'firmwar':20,62 'function':40 'imag':45 'implement':9 'includ':44 'iot':61 'librari':35 'manag':3,13,18,43,63 'mcu':19,42 'mcuboot':26 'mcumgr':59 'month':57 'occur':54 'protocol':4,14 'provid':36 'python':8,32 'releas':53 'remot':17 'server':39 'shell':47 'simpl':2,12 'smp':1,5,15,58 'statist':52 'support':31 'system':49 'task':51 'upload':46 'use':22 'version':27 'zephyr':24,60","created_at":"2026-05-01T08:13:56.040545+00:00","updated_at":"2026-05-01T08:13:56.040545+00:00","problems":null,"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":"4.1.0","cli_name":"smp","cli_version":"sh: 1: smp: not found","type":"library","homepage":null,"github":"https://github.com/JPHutchins/smp","docs":"https://jphutchins.github.io/smp/","changelog":null,"pypi":"https://pypi.org/project/smp/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["devops","communication","http-networking"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"passing","verified_at":"2026-07-03","last_verified":"2026-07-03","next_check":"2026-08-02","install_tag":null}}