Hi, On Thu, Sep 11, 2014 at 12:50:07AM +0200, Uffe Jakobsen wrote: > * PROBLEM: > open logic sniffer (ols) driver does not work on FreeBSD (10.0) > > sigrok-cli is unable to detect the ols device. > > Example: the following command does not work (on FreeBSD): > # sigrok-cli -d ols:conn=/dev/ttyU0 --scan
Hm, can you open an issue at sigrok.org/bugzilla for this? Please post the output of the following command there: $ LIBSERIALPORT_DEBUG=1 sigrok-cli -d ols:conn=/dev/ttyU0 --scan -l 5 It would be interesting to see what exactly happens there (and compare it to other runs on Linux/Mac/Windows). > * FIX: > send_shortcommand() and send_longcommand() did not ensure that the commands > were actually sent. Hence the initial 5 times reset followed by identify > never left the buffer. > > The attached patch (against HEAD) fixes above described problem on FreeBSD > (10.0) Great, thanks! I'll give this is a test-run on Linux and Windows as well soonish, I'm guessing it'll be an issue that also happens on other OSes (?) Quick patch review below. > diff --git a/src/hardware/openbench-logic-sniffer/protocol.c > b/src/hardware/openbench-logic-sniffer/protocol.c > index 1c94b7f..ebdcb4a 100644 > --- a/src/hardware/openbench-logic-sniffer/protocol.c > +++ b/src/hardware/openbench-logic-sniffer/protocol.c > @@ -2,6 +2,7 @@ > * This file is part of the libsigrok project. > * > * Copyright (C) 2013 Bert Vermeulen <[email protected]> > + * Copyright (C) 2014 Uffe Jakobsen <[email protected]> Please only add (C) lines to files where you do a non-trivial amount of non-trivial code changes or additions. We're trying not to clutter the files too much with (C) lines when only minor changes are made. Thanks! > +SR_PRIV int serial_drain(struct sr_serial_dev_inst *serial) If the sp_drain() is indeed required, please add them in the ols driver directly. We're planning the reduce the amount of serial wrappers in serial.c over time (in favor of direct libserialport calls), we'd rather not add new wrappers like serial_drain() at this point. Cheers, Uwe. -- http://hermann-uwe.de | http://randomprojects.org | http://sigrok.org ------------------------------------------------------------------------------ Want excitement? Manually upgrade your production database. When you want reliability, choose Perforce Perforce version control. Predictably reliable. http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk _______________________________________________ sigrok-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/sigrok-devel

