]> sigrok.org Git - libsigrok.git/commit - src/scpi/scpi_libgpib.c
scpi/libgpib: Place device in local mode before closing handle
authorAlexandru Gagniuc <redacted>
Sun, 28 Feb 2016 18:32:19 +0000 (10:32 -0800)
committerUwe Hermann <redacted>
Wed, 30 Mar 2016 10:39:20 +0000 (12:39 +0200)
commit8b0ad3a55977fe90942d761ae4a075399b323f08
treefc5434eb5130175af6f8c4f551853a04cc9ed9fc
parentdaf13c570f3532a702401363a35195970600c046
scpi/libgpib: Place device in local mode before closing handle

Devices connected on a real GPIB bus are placed in remote mode when
opening them. libgpib does not automatically place devices back in
local mode when closing the handle. It is thus possible to lock out a
GPIB device by probing it with libsigrok.

This happens on the HP 3457A meter, which does not have a "LOCAL"
command, and must be put back in local mode via GPIB handshake.
ibloc() takes care of this, and it does it on a per-device basis,
such that other devices on the GPIB bus are not affected.
src/scpi/scpi_libgpib.c