# dp100_manipulator **Repository Path**: bbindong/dp100_manipulator ## Basic Information - **Project Name**: dp100_manipulator - **Description**: No description available - **Primary Language**: Unknown - **License**: GPL-3.0 - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-10-12 - **Last Updated**: 2026-10-12 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Alientek DP100 manipulator ![DP100 manipulator](png/DP100_manipulator_800.png "DP100 manipulator") ## All infos on: ## Some infos I love Linux, but mostly software is only written for Windows and Mac. Unfortunately the USB data transfer protocols of products are often proprietary and so it's hard to write software for Linux. But with the USB sniffer Cynthion from Great Scott Gadgets it's getting easier. I sniffed the protocol of an Alientek DP100 power supply. The result is on: . With this information I was able to write a first version of a Python program doing the most important things needed. It uses `hidapi` under Linux and Python Tkinter GUI. Unfortunately it must be run as root. Even with udev rules and all rights set it was not possible to use it without `sudo`. ## Platform support All the code is pure Python (dependencies: `hidapi`, `matplotlib`); the same files run on Linux **and** Windows. There are **no start-up scripts** - everything is started with `python`, and the few platform differences are handled inside the Python code: | Topic | Linux | Windows | |-------|-------|---------| | HID write | the 64-byte frame is sent as it is | a `0x00` report id byte is prepended (Windows takes the first byte of a write as the report id, and the DP100 declares none) | | virtualenv interpreter | `.venv/bin/python` | `.venv\Scripts\python.exe` | | Tk button background | whatever theme is used | the theme is switched to `clam`, because the Windows theme ignores `-background` and the ON/OFF colours would not show | | device access | needs the udev rule below | nothing to install | > The `*.sh`, `*.bat` and `*.ps1` files in this repository are legacy and no longer used. > Use the `python` commands below instead. ### Setup (both platforms, once) Python 3.9 or newer. `hidapi` and `matplotlib` are the only packages to install; `tkinter` ships with CPython (on Windows keep "tcl/tk and IDLE" checked in the python.org installer). ```bash cd Python python -m venv .venv .venv/bin/pip install -r requirements.txt # Windows: .venv\Scripts\pip ``` Both `dp100.py` and `dp100_cli.py` re-run themselves with the interpreter of that virtualenv, so you never have to activate it. Without a virtualenv the current interpreter is used. ### CLI ```bash python dp100_cli.py info # device name, firmware versions, serial number python dp100_cli.py basic # Vin, Vout, Iout, temperatures, state python dp100_cli.py active # active profile and its set values python dp100_cli.py profiles # list the 10 stored profiles python dp100_cli.py on | off # switch the output python dp100_cli.py use 3 # activate profile 3 (output ends up off) python dp100_cli.py set 0 3.3 0.5 --use # write profile 0 and activate it python dp100_cli.py watch # print Vin/Vout/Iout once python dp100_cli.py watch 0.5 # poll Vin/Vout/Iout every 0.5 s until Ctrl-C python dp100_cli.py plot # render the CSV log to PNG (no device needed) ``` Add `-j`/`--json` to any command for machine readable output. Run it from any directory: the CSV log and the PNG are always written next to the scripts. ### GUI ```bash python dp100.py ``` Pick a profile number (or press one of the `P0`..`P9` buttons) and the voltage/current fields are filled with what that profile currently stores. `Change Profile` writes the values into the device; press the profile button afterwards to activate them, because activating a profile always switches the output off. ### Linux only Install the udev rule once so that the USB device can be opened without root, then unplug and replug the DP100: ```bash sudo ./setup_udev_rules.sh ``` Windows needs no driver, no udev rule and no administrator rights - the DP100 is a plain USB HID device.