Bug 638 - Windows: Multiple ols acquisitions in a row (or any acquisitions) usually don't work
Summary: Windows: Multiple ols acquisitions in a row (or any acquisitions) usually don...
Status: CONFIRMED
Alias: None
Product: libsigrok
Classification: Unclassified
Component: Driver: openbench-logic-sniffer (show other bugs)
Version: unreleased development snapshot
Hardware: All Windows
: Normal normal
Target Milestone: ---
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-08-28 18:09 CEST by Uwe Hermann
Modified: 2023-05-06 09:08 CEST (History)
2 users (show)



Attachments
ols logs (7.49 KB, application/x-gtar-compressed)
2015-12-20 21:04 CET, Uwe Hermann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Uwe Hermann 2015-08-28 18:09:40 CEST
In PulseView, scanning for an OLS works (e.g. on port COM168), but when pressing Run most of the time there's no data being shown, and pressing Run again will yield an error.

In the error case, the second click will be due to "sr: ols: serial: Wrote 0/5 bytes." which then yields SR_ERR ("generic/unspecified error"). This may be just a follow-up error, something else probably goes wrong before that failing write.

Also incorrect is that these runs never send a SR_DF_END (but there are lots of "ols: Received byte ..." lines in the log, so the driver does get data from the hardware.

With "sigrok-cli -d ols:conn=COM168 -c samplerate=100mhz --samples 6144" you get errors from time to time as well:

  sr: ols: Port COM168 not writable.
  sr: ols: Could not use port COM168. Quitting.

(This is due to "sr: serial: Wrote 0/1 bytes.").

Sometimes the above errors don't appear, but no data either.

Sometimes the acquisition seems to work though.

Add "-l 5" for sigrok-cli *seems* to make it work more often than not, so I suspect something timing-related (delay that's too short or something like that), among potentially other issues.
Comment 1 Uwe Hermann 2015-08-28 18:13:33 CEST
Doing the same (sigrok-cli and PulseView) on Linux doesn't seem to have any issues, so I'm guessing this is Windows related and/or timing/box related.
Comment 2 Uwe Hermann 2015-12-20 21:04:48 CET
Created attachment 201 [details]
ols logs
Comment 3 Uwe Hermann 2017-06-15 18:17:11 CEST
I just rechecked this via "sigrok-cli -d ols:conn=... -c samplerate=100mhz --samples 6144 -O hex" with git as of today.

There's no problem on Linux or Mac OS X, it is reproducible on Windows, though.
Comment 4 vanecvit 2020-02-21 18:05:31 CET
I've had this problem on every Windows 10 machine i tried. I've managed to find a janky solution where I closed and reopened serial device before every acquisition from OLS device.

In detail I added 2 lines at the start of dev_acquisition_start in file libsigrok\src\hardware\openbench-logic-sniffer\api.c

devc = sdi->priv;
serial = sdi->conn;

serial_close(serial); //Added
serial_open(serial, SERIAL_RDWR); //Added
	
ols_channel_mask(sdi);
Comment 5 jack 2023-05-06 09:08:34 CEST
GPS is also used for intelligence gathering in the military. It allows for the tracking of enemy movements and the gathering of data on enemy positions, which is essential for planning and executing missions. GPS technology can also be used to detect and track the movements of submarines and other underwater vessels. https://routefinderhq.com/best-marine-gps-chartplotter/