Note: I just forked this to adjust the voltage multiplier factor for my (clone?) tester. I have the one from this image:
I had some trouble getting it to work, but I could pair the tester (passcode: 1234) using blueman Bluetooth Manager on Elementary OS Hera (5.1.3). When disconnecting and reconnecting it created a new /dev/rfcommX interface, but the app tried to connect to the one described in ~/.local/share/rd-usb/config.json.
All the kudos go to kollinger (https://github.com/kolinger/rd-usb) and the work of sebastianha (https://github.com/sebastianha/um34c).
==
Simple web GUI written in Python 3. Measurements are stored in sqlite database. Tables and graphs are supported. Live preview and graphing is also available.
Tested on UM34C/UM24C/UM25C/TC66C.
Based on https://github.com/sebastianha/um34c
- UM34C/UM24C/UM25C - meter needs to be connected as serial port
- Pairing with Windows Settings works fine. Pin is 1234. After successful pairing some serial ports are installed. In my case two. One of them works.
- On Linux
rfcomm
andhcitool
can be used (both provided by bluez package)- Retrieve bluetooth address with
hcitool scan
- Bind retrieved address to serial port with
rfcomm bind 0 aa:bb:cc:dd:ee:ff
. This step is not persistent. Serial port will disappear after reboot. Also rd-usb needs to have permissions to use /dev/rfcommX.
- Retrieve bluetooth address with
- TC66C - meter is using BLE instead of regular bluetooth so pairing will not work nor RFCOMM will.
- BLE has very limited support on desktop devices, see used library for supported platforms and versions: https://github.com/hbldh/bleak#features
- TC66C USB - meter connected with USB
- Meter connected with USB exposes itself as serial port
- Download from releases
- Run executable and web server will be shortly spawned on address http://127.0.0.1:5000
- Application will be probably blocked by Microsoft SmartScreen. For unblock click
More info
andRun anyway
. I don't have certificate for signing and application does not have any reputation so Microsoft will block by default.
- Python 3.4 or newer is required
- Download from github or
git clone https://github.com/kolinger/rd-usb.git
- Install requirements
pip install -r requirements.txt
- Run with
python web.py
- this will spawn web server on http://127.0.0.1:5000, port can be changed with first argument:python web.py 5555
On Windows python
can be found in Python's installation folder.
For example replace python
with C:\Python37\python.exe web.py
and pip
with C:\Python37\python.exe -m pip install -r requirements.txt
.
On Linux use python3
and pip3
.
UM34C/UM24C/UM25C Bluetooth or TC66C USB
- Select your device version.
- Name your session. For example 'testing some power bank'. This is used to separate multiple measurements from each other.
- Select sample rate. Faster sample rate will result in more accurate data but also will create a lot more data. For short measurements use faster sample rate. For longer use slower rate. Choose carefully.
- Follow Setup link to find your serial port or click Connect if you already have port selected.
- Connection will be hopefully successful and you will see live measurements in graph. Otherwise read log for error messages.
TC66C Bluetooth
- Make sure your OS is supported and has bluetooth with BLE support (Bluetooth Low Energy)
- Select TC66C from devices and follow with Setup link.
- Scan for devices and select your device from list by clicking on it
- After this you can connect simply by using Connect button. Setup is required only for new/different device.
- Rest is same as other devices. See above.
- Install pyinstaller:
pip install pyinstaller
- Generate binary with provided spec file:
pyinstaller pyinstaller.spec
- Binaries will be saved in
dist
directory