misdoro / Electronic_load_px100

150W Electronic load / Battery discharge capacity tester PX-100 v2.70 protocol and control software. May be compatible with some DL24 versions.
GNU General Public License v3.0
107 stars 23 forks source link

Updated installation instructions for Linux (here Mint V22) #28

Open DittelHome opened 2 days ago

DittelHome commented 2 days ago

Since the installation instructions are no longer valid for newer Python versions, I'll describe my installation steps here, maybe it will help someone. Testet with Mint Linux V22 (Python 3.12.3) and DL24P It would be a shame if the great work of Misdoro could no longer be used..

Download: git clone https://github.com/misdoro/Electronic_load_px100.git

Corrections: Edit /gui/internatl_r.py line 26:

def append(self, row):
        self.beginInsertRows(QModelIndex(), self.rowCount(1), self.rowCount(1))
        self._data = self._data.append(row, ignore_index=True)
        self.endInsertRows()

to

def append(self, row):
        self.beginInsertRows(QModelIndex(), self.rowCount(1), self.rowCount(1))
        self._data = self._data._append(row, ignore_index=True)
        self.endInsertRows()

Edit requirements.txt: remove "< 2.0" behind pandas

Installation: Only pip install -r requirements.txt wont work, we have to create a new virtual enviroment: (@misdoro pipx would be nice)

python3 -m venv .venv 
source .venv/bin/activate 
pip install -r requirements.txt 

Program call:

source .venv/bin /activate
python3 main.py
deactivate

Bluetooth: Program does not work via Bleutooth, it does not search /dev/rfcomx... @misdoro Is it possible to add ?

@misdoro You may be able to adapt the instructions accordingly...

regards Klaus

ivanbistrovic commented 2 days ago

For use with DL24 there is already a fork made by Jay2k1. There are some modifications made to make it more compatible with DL24, I tested it and it works really good with Bluetooth. Would be great if this project continues as it would be nice to have some improvements.

DittelHome commented 1 day ago

I have tested fork made by Jay2k1. On my side Bluetooth is not working. In addition, the fields capacity and time are not readable (black letters on black background).

ivanbistrovic commented 22 hours ago

I don't think the problem is in the program but with the settings in your OS. For example, I needed to add my user in the bluetooth group, and restart. I also work on Linux Mint 22. I can't remember now all the steps but try with that one, Bluetooth on Linux is sometimes tricky to get working.

misdoro commented 14 hours ago

Working or not might depend on the hardware version/software revision of DL24 as well.

From my own experience, my version of DL24 doesn't react to PX100 commands for first couple of seconds, then somehow switches to this protocol, so re-starting this program once or twice made things working for me.