Hi,
I’m having difficulty finding an efficient way to read V/A/W values using a Joulescope JS110 (S/N 002973) in Python.
I’ve been using the Joulescope Python package (version 1.1.5) and have had some success with reading statistics. However, I ran into a limitation with the reduction frequency, which maxes out at 100 Hz—unfortunately, that’s not sufficient for my use case. I should mention that I’m not an advanced Python user, and I find the drivers somewhat challenging to navigate.
I attempted to use the read
function, but frequently encountered timeout errors, although not every time. Is there a reliable and efficient way to read out values every 0.5–1 ms in a Python script and store them in an array? Also, is there any additional documentation beyond the API instructions? Would you recommend using a different driver or approach for this purpose?
Thanks for your help!
Errors when I use the read example :
Traceback (most recent call last):
File “/home/dominik/Documents/ina/test_joulescope_raw.py”, line 7, in
js.close(timeout=1 )
File “/home/dominik/.local/lib/python3.10/site-packages/joulescope/v1/device.py”, line 395, in close
return self._driver.close(self._path, timeout)
File “pyjoulescope_driver/binding.pyx”, line 879, in pyjoulescope_driver.binding.Driver.close
File “pyjoulescope_driver/binding.pyx”, line 593, in pyjoulescope_driver.binding._handle_rc
TimeoutError: jsdrv_close timed out | u/js110/002973
OR:
_on_cmd_publish_cbk(u/js110/002973/s/v/!data)
Traceback (most recent call last):
File “pyjoulescope_driver/binding.pyx”, line 893, in pyjoulescope_driver.binding._on_cmd_publish_cbk
File “/home/dominik/.local/lib/python3.10/site-packages/joulescope/v1/device.py”, line 445, in _on_stream
_, e1 = b.sample_id_range
AttributeError: ‘NoneType’ object has no attribute ‘sample_id_range’
_on_cmd_publish_cbk(u/js110/002973/s/p/!data)
Traceback (most recent call last):
File “pyjoulescope_driver/binding.pyx”, line 893, in pyjoulescope_driver.binding._on_cmd_publish_cbk
File “/home/dominik/.local/lib/python3.10/site-packages/joulescope/v1/device.py”, line 445, in _on_stream