Re: Working with secondary addresses
John via Linux-gpib-general <[email protected]> Wed, 25 Mar 2026 15:34:39 +0000
| Newsgroups | gmane.linux.hardware.gpib.general |
|---|---|
| Message-ID | <[email protected]> |
This is a multi-part message in MIME format. --===============4624049412960425030== Content-Type: multipart/alternative; boundary="------------igM4OoVecSM2PYUffNyWOSRQ" Content-Language: en-US This is a multi-part message in MIME format. --------------igM4OoVecSM2PYUffNyWOSRQ Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable On 25/03/2026 10:28, dave penkler wrote: > > > On Wed, 25 Mar 2026 at 01:12, John <[email protected]> wrote: > > > I get the following error: > > $ ./test_storage.py > Traceback (most recent call last): > =C2=A0 File "/home/johnc/Test/linux-gpib/./test_storage.py", line 27= , > in <module> > =C2=A0 =C2=A0 gpib.write(cmd_find, b'\x31\x0D') > =C2=A0 =C2=A0 ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^ > gpib.GpibError: write() failed: You have attempted to write data > or command bytes, but there are no listeners currently addressed. > > The script uses the same technique that worked in Perl so not sure > what I am doing wrong at this point: > > > Your code looks fine. This is not a python issue, it is hardware=20 > related. The problem with the device you are talking to is in one or=20 > more of: > 1) Not plugged into the bus > 2) Not powered on > 3) Device is hung > cheers, > -Dave > > > _______________________________________________ > Linux-gpib-general mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/linux-gpib-general 1) Not plugged into the bus The device is plugged in and the Perl script works so its not connectivity= . 2) Not powered on Again, the Perl script works on the same device. 3) Device is hung There is no change after power cycling the device and computer. I am fairly certain its a software issue, but would need to dig into the= =20 library code and maybe attach a logic analyser to understand what's=20 happening behind the scenes so to speak. What does it mean by "but there are no listeners currently addressed." ? The gpib.dev() addressing command is presumably opening a listen or talk= =20 communication handle? Could be an issue with how the device is responding I suppose, but why=20 would Perl work and Python not when its supposedly doing the same thing? I do at least have the option to run with Perl for now, but it would be=20 nice to have Python. --------------igM4OoVecSM2PYUffNyWOSRQ Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <!DOCTYPE html> <html> <head> <meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3DUTF-= 8"> </head> <body> <p><br> </p> <div class=3D"moz-cite-prefix">On 25/03/2026 10:28, dave penkler wrote:<br> </div> <blockquote type=3D"cite" cite=3D"mid:[email protected]= mail.com"> <meta http-equiv=3D"content-type" content=3D"text/html; charset=3DUT= F-8"> <div dir=3D"ltr"> <div dir=3D"ltr"><br> </div> <br> <div class=3D"gmail_quote gmail_quote_container"> <div dir=3D"ltr" class=3D"gmail_attr">On Wed, 25 Mar 2026 at 01:12, John <<a href=3D"mailto:[email protected]" moz-do-not-send=3D"true" class=3D"moz-txt-link-freetext">sub= [email protected]</a>> wrote:<br> </div> <blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);p= adding-left:1ex"> <div> <p><br> </p> <p>I get the following error:</p> <p>$ ./test_storage.py<br> Traceback (most recent call last):<br> =C2=A0 File "/home/johnc/Test/linux-gpib/./test_storage.py= ", line 27, in <module><br> =C2=A0 =C2=A0 gpib.write(cmd_find, b'\x31\x0D')<br> =C2=A0 =C2=A0 ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^<br> gpib.GpibError: write() failed: You have attempted to write data or command bytes, but there are no listeners currently addressed.<br> <br> </p> <p>The script uses the same technique that worked in Perl so not sure what I am doing wrong at this point:</p> </div> </blockquote> <div><br> </div> <div>Your code looks fine. This is not a python issue, it is hardware related. The problem with the device you are talking to is in one or more of:</div> <div>1) Not plugged into the bus</div> <div>2) Not powered on</div> <div>3) Device is hung</div> <div>cheers,</div> <div>-Dave</div> </div> </div> <br> <fieldset class=3D"moz-mime-attachment-header"></fieldset> <br> <fieldset class=3D"moz-mime-attachment-header"></fieldset> <pre wrap=3D"" class=3D"moz-quote-pre">_____________________________= __________________ Linux-gpib-general mailing list <a class=3D"moz-txt-link-abbreviated" href=3D"mailto:Linux-gpib-general@li= sts.sourceforge.net">[email protected]</a> <a class=3D"moz-txt-link-freetext" href=3D"https://lists.sourceforge.net/l= ists/listinfo/linux-gpib-general">https://lists.sourceforge.net/lists/list= info/linux-gpib-general</a></pre> </blockquote> <p><br> </p> <div>1) Not plugged into the bus</div> <div><br> </div> <div>The device is plugged in and the Perl script works so its not connectivity.</div> <div><br> </div> <div> <div>2) Not powered on</div> <div><br> </div> <div>Again, the Perl script works on the same device.</div> <div><br> </div> <div> <div>3) Device is hung</div> <div><br> </div> <div>There is no change after power cycling the device and computer.</div> <div><br> </div> <div>I am fairly certain its a software issue, but would need to dig into the library code and maybe attach a logic analyser to understand what's happening behind the scenes so to speak.</div> <div><br> </div> What does it mean by "but there are no listeners currently addressed." ?</div> </div> <div>The gpib.dev() addressing command is presumably opening a listen or talk communication handle?</div> <p>Could be an issue with how the device is responding I suppose, but why would Perl work and Python not when its supposedly doing the same thing?</p> <p>I do at least have the option to run with Perl for now, but it would be nice to have Python.</p> <blockquote type=3D"cite" cite=3D"mid:[email protected]= mail.com"> <pre wrap=3D"" class=3D"moz-quote-pre"> </pre> </blockquote> </body> </html> --------------igM4OoVecSM2PYUffNyWOSRQ-- --===============4624049412960425030== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline --===============4624049412960425030== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Linux-gpib-general mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linux-gpib-general --===============4624049412960425030==--