Open StefanMack opened 4 years ago
Hi,
Let us take a look and we will come back with a fix as soon as possible. We are working on a new release for some bug fixes, we will take a look at this and add this too.
-Alexandra
Hi,
This causes trouble only for Python3. One idea would be to change the return map(ord, data) to return bytearray(data). Would this work for you?
-Alexandra
Hi Alexandra,
I installed libsmu and the python bindings on Ubuntu 18.04. Where can I find the filelibsmu.pyx
to test the changes suggested by you?
-Stefan
Hi,
We are sorry for the delay. We added the fix for libsmu.pyx on master. We will prepare a new release soon. We're just working on fixing the nightly builds on Appveyor and migrating the linux builds. Here is the link to the commit that fixes the bindings: https://github.com/analogdevicesinc/libsmu/commit/aaad9af471647922baa306b4a424c6c713ccc41b
-Alexandra
Hi Alexandra, thank you for the great pysmu package. The ADC and DAC functions of the libsmu python examples work fine. The ADALM1000 is an ideal tool for university teaching electrical engineering labs. Especially nowadays during Corona we can give the ADALM1000 to the students for a take home lab!
Setting the PIO0-3 (e.g.
device.ctrl_transfer(0x40, 0x51, PIO_0, 0, 0, 0, 100)
) also works fine, by I do not manage to read the PIO0-3 state.The following code fails on Python 3.69, Ubuntu Linux 18.04 LTS with error:
print(list(state)) TypeError: ord() expected string of length 1, but int found
I guess it has something to to with the following statement in the
libsmu.pyx
function definition ofctrl_transfer()
:To me it seems that the
map()
function causes trouble for Python 3. Is there any work around? Or how and where can I change the implementation of thectrl_transfer()
function?