Closed p1ngb4ck closed 1 year ago
Some more information would be helpful:
-l 5
does the right value appear in the log? If so, please attach this portion of the log (with maybe 10 lines before and after the interesting part)@knarfS Ubuntu 22.04, latest git version (compiled everything regarding sigrok from git, no ubuntu packages used). Expected value (as seen in log and being shown in the graphs of smuviewk : resistor with 4700 Ohms). Smuview gets the correct value (uses it for graphs etc) but rounds it for the main display.
Shown on "main" display : 5k Ohms ("exactly" - problem is just the rounded value in display. smuview gets the correct values but displays them rounded)
Screenshot :
Unfortunately I couldn`t screen the correct bar graph value. Yesterday it was shown correctly, today it messes up the scaling somehow, dont know why
I think I've found the problem. SmuView is using the encoding.digits
/spec.spec_digits
information, provided in each individual analog data payload by the libsigrok drivers. This information is used to get a representation of the measured value as close as possible to the display of the DMM.
It looks like the fs9922 protocol decoder used for the UT61C is setting the exponent rather the number of decimal places. From the docstring in libsigrok.h
:
Number of significant digits after the decimal point if positive, or number of non-significant digits before the decimal point if negative [...]
I've fixed that issue in my libsigrok branch fs9922_digits
, but of course couldn't test it. Give it a try if you like. Would be great, if you could test also for other decimal places and prefixes (µ, m, k, M)- Let me know, if this works for you, then I'll open a PR in the next days.
This works absolutely perfect so far, thank you soo much. I get exactly whats on the display of my UT-61C now. I tested any resistors I had handy (k / M works fine), as well as some defined voltages (160mV, -12V, 3.3V, 5V ,12V, 40V) Signed ( - ) numbers/decimals also work just fine. Will test some caps over the weekend to check µF & nF.
Thanks sooooo much for your work, this is just incredible =) It allows me to integrate my multimeter (and hopefully psu too soon) in my videos/streams via OBS in linux with a nice display !! Just great.
I can confirm now, that all modes and decimal places and units work just fine.
The wrong value inside the main display is fixed with commit https://github.com/knarfS/smuview/commit/1be2c391ecef3073e8613ecb4cc31a8dfd73941c and the latest continuous build.
I use a UT61C multimeter connected via RS232. When I test a resistor of 4.7k, I get a display of 5k in the main display, while the graphs and sigrok-cli clearly show the correct values. There is some unwanted rounding active on the display routine ..