--- id: ppk2-api version: "0.9.2" license: unclear license_treatment: copyleft maintenance: active --- # ppk2-api — API for Nordic Semiconductor's Power Profiler Kit II (PPK 2). License: copyleft · Maintenance: active · Downloads: 85.2K/mo ## What it is and what it does ppk2-api is a Python wrapper around Nordic Semiconductor's Power Profiler Kit II hardware, enabling automated power consumption measurement and logging without the GUI. It communicates with the PPK 2 device over a serial port and provides methods to configure measurement modes, set voltage levels, and stream power samples in real time. The package offers two usage patterns: a basic synchronous API that reads samples on demand, and a multiprocessing variant that runs a background polling process to buffer up to 10 seconds of data, reducing the frequency of manual polling. It is cross-platform and requires only pyserial as a runtime dependency, making it suitable for embedded test automation, power profiling in CI/CD pipelines, and long-term power monitoring applications. Use it for: - Automated power consumption testing in embedded device development workflows and CI/CD pipelines - Long-term power monitoring and data logging for battery-powered device optimization - Real-time power measurement during firmware development without manual GUI interaction - Batch power profiling across multiple device configurations or firmware variants - Integration of power metrics into test reports and performance dashboards ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Provides a Python API to automate power consumption measurement and data logging with Nordic Semiconductor's Power Profiler Kit II (PPK 2) over a serial connection. Yes, if you own a PPK 2 and need automated power measurement. The package is actively maintained, has low install friction, and fills a genuine gap (no official automation support). The GPLv2 license is a consideration for proprietary projects. The 1162-day gap since first release and over a year since the last release suggest the core API is stable but may not be under active feature development. ## Install pip install ppk2-api uv add ppk2-api poetry add ppk2-api ## Installing ppk2-api Before you install: Low install friction with a single runtime dependency (pyserial). Package is actively maintained with recent commits and a modest but engaged user base, though last release was over a year ago. License in practice: Licensed under GPLv2 (copyleft). Any derivative work or modifications must be shared under the same license terms. Suitable for open-source projects; proprietary software integration requires careful review. Quickstart: from ppk2_api import PPK2_API import time ppk2 = PPK2_API("/dev/ttyACM0") # adjust serial port ppk2.use_source_meter() ppk2.set_source_voltage(3300) ppk2.start_measuring() for i in range(10): data = ppk2.get_data() if data: samples = ppk2.get_samples(data) print(f"Avg: {sum(samples)/len(samples)}uA") time.sleep(0.1) ppk2.stop_measuring() Requires a PPK 2 device connected to a serial port; the serial port path must be known and accessible to the Python process. Verify before relying: - Whether Python version support is truly unspecified or if there is a practical minimum (e.g., Python 3.6+) - Current state of 'in progress' features (data logging formats, full GUI parity) and their timeline - Whether multiprocessing mode is production-ready or still experimental ## Package facts - License: not declared (copyleft) - Python support: unspecified - Install friction: low - Maintenance: active - Downloads: 85.2K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags power profiler kit ii python, ppk2 automated measurement, device power consumption monitoring, nordic semiconductor power profiling, serial power measurement api, automated power logging python, real-time power consumption data, hardware-profiling, power-measurement, embedded-testing [View on SkillFed](https://skillfed.io/packages/ppk2-api) · [View on PyPI](https://pypi.org/project/ppk2-api/)