Re: [newbie] trying socket as a replacement for nc

2013-12-18 Thread 88888 Dihedral
> 8 Dihedral wrote: > > > > > It is trivial to use UDP with > > > forward error correction such as > > > the CD in 1982. > > > > CD uses Reed-Solomon coding, which is great for correcting the types of > > errors expected on a CD. Namely, bursts of bit errors caused by > > loca

Re: [newbie] trying socket as a replacement for nc

2013-12-18 Thread Jean Dubois
Op woensdag 18 december 2013 15:48:43 UTC+1 schreef Jean Dubois: > Op woensdag 18 december 2013 14:04:08 UTC+1 schreef Jean Dubois: > > Op dinsdag 17 december 2013 10:37:37 UTC+1 schreef Jean-Michel Pichavant: > > > > I'm a newbie in Python programming that is very much true, and > > > > contrary t

Re: [newbie] trying socket as a replacement for nc

2013-12-18 Thread Jean Dubois
Op woensdag 18 december 2013 14:04:08 UTC+1 schreef Jean Dubois: > Op dinsdag 17 december 2013 10:37:37 UTC+1 schreef Jean-Michel Pichavant: > > > I'm a newbie in Python programming that is very much true, and > > > contrary to what you seem to suggest I did my homework > > At no point that was my

Re: [newbie] trying socket as a replacement for nc

2013-12-18 Thread Jean Dubois
Op dinsdag 17 december 2013 10:37:37 UTC+1 schreef Jean-Michel Pichavant: > > I'm a newbie in Python programming that is very much true, and > > contrary to what you seem to suggest I did my homework > At no point that was my intention, my apologies. OK, no problem > If you fixed the syntax error,

Re: [newbie] trying socket as a replacement for nc

2013-12-17 Thread Jean-Michel Pichavant
> I'm a newbie in Python programming that is very much true, and > contrary to what you seem to suggest I did my homework At no point that was my intention, my apologies. If you fixed the syntax error, you should be pretty close to the solution though. JM -- IMPORTANT NOTICE: The contents of

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean Dubois
Op maandag 16 december 2013 20:21:15 UTC+1 schreef Jean-Michel Pichavant: > - Original Message - > > On Tue, Dec 17, 2013 at 5:26 AM, Jean Dubois > > wrote: > > >> Try something simple first: > > >> import telnetlib > > >> host = '10.128.59.63' > > >> port = 7000 > > >> t = Telnet(host, po

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean-Michel Pichavant
- Original Message - > On Tue, Dec 17, 2013 at 5:26 AM, Jean Dubois > wrote: > >> Try something simple first: > >> import telnetlib > >> host = '10.128.59.63' > >> port = 7000 > >> t = Telnet(host, port) > >> def flush() > >> t.read_very_eager() > >> def sendCmd(cmd) > >> t.write('%s

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Dave Angel
On Mon, 16 Dec 2013 10:26:14 -0800 (PST), Jean Dubois wrote: File "./test.py", line 7 def flush() ^ SyntaxError: invalid syntax A definition line needs to end with a colon (fix the other as well) -- DaveA -- https://mail.python.org/mailman/listinfo/python-list

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Chris Angelico
On Tue, Dec 17, 2013 at 5:26 AM, Jean Dubois wrote: >> Try something simple first: >> import telnetlib >> host = '10.128.59.63' >> port = 7000 >> t = Telnet(host, port) >> def flush() >> t.read_very_eager() >> def sendCmd(cmd) >> t.write('%s\n' % cmd) >> return flush() >> flush() >> print se

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean Dubois
Op maandag 16 december 2013 17:44:31 UTC+1 schreef Jean-Michel Pichavant: > > This is what I got using telnet: > > [jean:~] $ telnet 10.128.59.63 7000 > > Trying 10.128.59.63... > > Connected to 10.128.59.63. > > Escape character is '^]'. > > *IDN? > > KEITHLEY INSTRUMENTS INC.,MODEL 2425,1078209,C

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean-Michel Pichavant
> This is what I got using telnet: > [jean:~] $ telnet 10.128.59.63 7000 > Trying 10.128.59.63... > Connected to 10.128.59.63. > Escape character is '^]'. > *IDN? > KEITHLEY INSTRUMENTS INC.,MODEL 2425,1078209,C32 Oct 4 2010 > 14:20:11/A02 /E/ >

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean Dubois
Op maandag 16 december 2013 15:16:17 UTC+1 schreef Jean-Michel Pichavant: > - Original Message - > > Op maandag 16 december 2013 13:05:41 UTC+1 schreef Jean-Michel > > Pichavant: > > > > Here is the code: > > > > #!/usr/bin/env python > > > > import telnetlib > > > > host = '10.128.59.63' >

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean-Michel Pichavant
- Original Message - > Op maandag 16 december 2013 13:05:41 UTC+1 schreef Jean-Michel > Pichavant: > > > Here is the code: > > > #!/usr/bin/env python > > > import telnetlib > > > host = '10.128.59.63' > > > port = 7000 > > > t = Telnet(host, port) > > > t.write('*IDN?\n') > > > print t.r

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Roy Smith
On Friday, December 13, 2013 5:58:49 AM UTC+8, Chris Angelico wrote: > > Now, if you want reliability AND datagrams, it's a lot easier to add > > boundaries to a TCP stream (sentinel or length prefixes) than to add > > reliability to UDP... In article <11cb8cd3-7a12-46b2-abc6-53fbc2a54...@googlegr

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean Dubois
Op maandag 16 december 2013 13:05:41 UTC+1 schreef Jean-Michel Pichavant: > > Here is the code: > > #!/usr/bin/env python > > import telnetlib > > host = '10.128.59.63' > > port = 7000 > > t = Telnet(host, port) > > t.write('*IDN?\n') > > print t.read_until('Whateverprompt') > > # you can use read_

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Chris Angelico
On Mon, Dec 16, 2013 at 11:38 PM, 8 Dihedral wrote: > It is trivial to use UDP with > forward error correction such as > the CD in 1982. This is another reason for moving to IPv6. With IPv4, the size of a datagram is limited to 64KB, but with IPv6, you could carry an entire CD's contents in a

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread 88888 Dihedral
On Friday, December 13, 2013 5:58:49 AM UTC+8, Chris Angelico wrote: > On Fri, Dec 13, 2013 at 8:27 AM, Dan Stromberg wrote: > > > On Thu, Dec 12, 2013 at 6:16 AM, Grant Edwards > > wrote: > > > > > >>> Sockets reserve the right to split one socket.send() into multiple > > >>> socket.recv()'

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean-Michel Pichavant
> Here is the code: > #!/usr/bin/env python > import telnetlib > host = '10.128.59.63' > port = 7000 > t = Telnet(host, port) > t.write('*IDN?\n') > print t.read_until('Whateverprompt') > # you can use read_very_eager also > > and this is the result of executing the code(from which I deduce I > ha

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean Dubois
Op maandag 16 december 2013 11:29:12 UTC+1 schreef Jean-Michel Pichavant: > > > Such equipment often implements a telnet protocol. Have use try > > > using the telnetlib module ? > > > http://docs.python.org/2/library/telnetlib.html > > > > > > t = Telnet(host, port) > > > t.write('*IDN?') > > > pr

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean-Michel Pichavant
> Did you try > > import telnetlib > > ? > > Note that in the code above I forgot the EOF, which is very much > dependent of the equipment itself. > > You may have to write > t.write('*IDN?\n') > or > t.write('IDN?\n\r') > > JM Additionally, here's the code we're using for our signal generat

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean-Michel Pichavant
> > Such equipment often implements a telnet protocol. Have use try > > using the telnetlib module ? > > http://docs.python.org/2/library/telnetlib.html > > > > t = Telnet(host, port) > > t.write('*IDN?') > > print t.read_until('Whateverprompt') > > # you can use read_very_eager also > > > > JM > >

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Ervin Hegedüs
hello, > #!/usr/bin/env python > > """ > A simple echo client > """ > import socket as socket_mod > import bufsock as bufsock_mod [...] > Traceback (most recent call last): > File "./buftest.py", line 11, in > socket = socket_mod.socket(socket.AF_INET, socket.SOCK_STREAM) > NameError: name

Re: [newbie] trying socket as a replacement for nc

2013-12-16 Thread Jean Dubois
Op donderdag 12 december 2013 22:23:22 UTC+1 schreef Dan Stromberg: > On Thu, Dec 12, 2013 at 12:28 AM, Jean Dubois wrote: > > On Thursday, December 12, 2013 12:20:36 AM UTC+1, Dan Stromberg wrote: > >> On Wed, Dec 11, 2013 at 3:08 PM, Jean Dubois wrote: > >> > >> I have an ethernet-rs232 adapter

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Chris Angelico
On Mon, Dec 16, 2013 at 9:42 AM, Grant Edwards wrote: > Good point -- I meant send(). I keep forgetting that the libc socket > write() operation is missing in Python and only the send() call has > been made visible. In C write() and send() are effectively the same > thing (the parameters are arra

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Grant Edwards
On 2013-12-15, Roy Smith wrote: > In article , > Grant Edwards wrote: > >> UDP is a a _datagram_ service. Either all the bytes in a write() >> should get sent or none of them. Sending a paritial datagram is _not_ >> a valid option. > > I would agree with the above if you said send() instead of

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Dan Stromberg
On Sun, Dec 15, 2013 at 7:35 AM, Jean Dubois wrote: >> You can "svn checkout ". You might try Sliksvn if you're on >> Windows, or if you're on Linux it's in synaptic or yum or whatever. >> You can "wget ". >> You can bring up the URL in a web browser and cut and paste. > I'm using Linux, I did t

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Roy Smith
In article , Chris Angelico wrote: > On Mon, Dec 16, 2013 at 2:51 AM, Roy Smith wrote: > > In article , > > Grant Edwards wrote: > > > >> UDP is a a _datagram_ service. Either all the bytes in a write() > >> should get sent or none of them. Sending a paritial datagram is _not_ > >> a valid op

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Chris Angelico
On Mon, Dec 16, 2013 at 2:51 AM, Roy Smith wrote: > In article , > Grant Edwards wrote: > >> UDP is a a _datagram_ service. Either all the bytes in a write() >> should get sent or none of them. Sending a paritial datagram is _not_ >> a valid option. > > I would agree with the above if you said s

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Roy Smith
In article , Grant Edwards wrote: > UDP is a a _datagram_ service. Either all the bytes in a write() > should get sent or none of them. Sending a paritial datagram is _not_ > a valid option. I would agree with the above if you said send() instead of write(). Python socket objects don't have

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Chris Angelico
On Mon, Dec 16, 2013 at 2:35 AM, Jean Dubois wrote: > I'm using Linux, I did the following: > svn checkout http://stromberg.dnsalias.org/svn/bufsock/ > which resulted in a directory 'bufsock' being added to my home-directory, > Do I have to run further commands on the files in this directory? > Ho

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Jean Dubois
Op zondag 15 december 2013 02:03:14 UTC+1 schreef Dan Stromberg: > On Sat, Dec 14, 2013 at 5:33 AM, Jean Dubois wrote: > > Op vrijdag 13 december 2013 16:35:31 UTC+1 schreef Jean-Michel Pichavant: > >> - Original Message - > >> > I have an ethernet-rs232 adapter which allows me to connect

Re: [newbie] trying socket as a replacement for nc

2013-12-15 Thread Grant Edwards
On 2013-12-15, Dan Stromberg wrote: > On Fri, Dec 13, 2013 at 8:06 AM, Grant Edwards > wrote: >> On 2013-12-12, Dan Stromberg wrote: Just to be pedantic: _TCP_ sockets reserve that right. UDP sockets do not, and do in fact guarantee that each message is discrete. [It appears t

Re: [newbie] trying socket as a replacement for nc

2013-12-14 Thread Dan Stromberg
On Fri, Dec 13, 2013 at 8:06 AM, Grant Edwards wrote: > On 2013-12-12, Dan Stromberg wrote: >> On Thu, Dec 12, 2013 at 6:16 AM, Grant Edwards >> wrote: >> Sockets reserve the right to split one socket.send() into multiple socket.recv()'s on the other end of the communication, or to ag

Re: [newbie] trying socket as a replacement for nc

2013-12-14 Thread Dan Stromberg
On Sat, Dec 14, 2013 at 5:33 AM, Jean Dubois wrote: > Op vrijdag 13 december 2013 16:35:31 UTC+1 schreef Jean-Michel Pichavant: >> - Original Message - >> > I have an ethernet-rs232 adapter which allows me to connect to a >> > measurement instrument by means of netcat on a linux system. >>

Re: [newbie] trying socket as a replacement for nc

2013-12-14 Thread Jean Dubois
Op vrijdag 13 december 2013 16:35:31 UTC+1 schreef Jean-Michel Pichavant: > - Original Message - > > I have an ethernet-rs232 adapter which allows me to connect to a > > measurement instrument by means of netcat on a linux system. > > e.g. entering nc 10.128.59.63 7000 > > allows me to ente

Re: [newbie] trying socket as a replacement for nc

2013-12-14 Thread Mark Lawrence
On 14/12/2013 13:14, Jean Dubois wrote: Op vrijdag 13 december 2013 09:35:18 UTC+1 schreef Mark Lawrence: On 13/12/2013 03:23, Jean Dubois wrote: kind regards, jean p.s. I'm using Linux/Kubuntu 11.04 Would you please read and action this https://wiki.python.org/moin/GoogleGroupsPython to pre

Re: [newbie] trying socket as a replacement for nc

2013-12-14 Thread Jean Dubois
Op vrijdag 13 december 2013 09:35:18 UTC+1 schreef Mark Lawrence: > On 13/12/2013 03:23, Jean Dubois wrote: > > > > kind regards, > > jean > > p.s. I'm using Linux/Kubuntu 11.04 > > > Would you please read and action this > https://wiki.python.org/moin/GoogleGroupsPython to prevent us seeing the

Re: [newbie] trying socket as a replacement for nc

2013-12-14 Thread Jean Dubois
Op vrijdag 13 december 2013 18:09:50 UTC+1 schreef rusi: > On Friday, December 13, 2013 5:50:03 PM UTC+5:30, Jean Dubois wrote: > > to make the script check itself whether pyhon2 or python3 should be used? > As far as I know both (2 and 3) worked > Do you have some reason to suspect one works and o

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread rusi
On Friday, December 13, 2013 5:50:03 PM UTC+5:30, Jean Dubois wrote: > to make the script check itself whether pyhon2 or python3 should be used? As far as I know both (2 and 3) worked Do you have some reason to suspect one works and other not? -- https://mail.python.org/mailman/listinfo/python-li

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Chris Angelico
On Sat, Dec 14, 2013 at 3:57 AM, Grant Edwards wrote: > On 2013-12-13, Chris Angelico wrote: >> On Sat, Dec 14, 2013 at 3:10 AM, Grant Edwards >> wrote: >>> Adding boundaries to a TCP stream achieves the same goal (and isn't >>> that hard to do), but since there's no standard for it, people kee

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread rusi
On Friday, December 13, 2013 5:50:03 PM UTC+5:30, Jean Dubois wrote: > Op vrijdag 13 december 2013 09:35:18 UTC+1 schreef Mark Lawrence: > > Would you please read and action this > > https://wiki.python.org/moin/GoogleGroupsPython to prevent us seeing the > > double line spacing that accompanied

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Grant Edwards
On 2013-12-13, Chris Angelico wrote: > On Sat, Dec 14, 2013 at 3:10 AM, Grant Edwards > wrote: >> Adding boundaries to a TCP stream achieves the same goal (and isn't >> that hard to do), but since there's no standard for it, people keep >> having to reinvent it (often badly and always incompaibl

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Chris Angelico
On Sat, Dec 14, 2013 at 3:10 AM, Grant Edwards wrote: > Adding boundaries to a TCP stream achieves the same goal (and isn't > that hard to do), but since there's no standard for it, people keep > having to reinvent it (often badly and always incompaibly). Nearest to a standard would be the way he

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Grant Edwards
On 2013-12-12, Chris Angelico wrote: > Now, if you want reliability AND datagrams, it's a lot easier to add > boundaries to a TCP stream (sentinel or length prefixes) than to add > reliability to UDP... It's unfortunate that there's no standardized reliable connection-oriented datagram protocol.

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Grant Edwards
On 2013-12-12, Dan Stromberg wrote: > On Thu, Dec 12, 2013 at 6:16 AM, Grant Edwards > wrote: > >>> Sockets reserve the right to split one socket.send() into multiple >>> socket.recv()'s on the other end of the communication, or to aggregate >>> multiple socket.send()'s into a single socket.recv

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Jean-Michel Pichavant
- Original Message - > I have an ethernet-rs232 adapter which allows me to connect to a > measurement instrument by means of netcat on a linux system. > e.g. entering nc 10.128.59.63 7000 > allows me to enter e.g. > *IDN? > after which I get an identification string of the measurement > ins

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Jean Dubois
Op vrijdag 13 december 2013 09:35:18 UTC+1 schreef Mark Lawrence: > Would you please read and action this > https://wiki.python.org/moin/GoogleGroupsPython to prevent us seeing the > double line spacing that accompanied the above, thanks. > > -- > > Mark Lawrence Dear Mark, I'm sorry for the

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Jean Dubois
Op vrijdag 13 december 2013 04:32:30 UTC+1 schreef Dan Stromberg: > On Thu, Dec 12, 2013 at 7:23 PM, Jean Dubois wrote: > > > Op donderdag 12 december 2013 22:23:22 UTC+1 schreef Dan Stromberg: > > >> On Thu, Dec 12, 2013 at 12:28 AM, Jean Dubois > >> wrote: > > >> > > >> > On Thursday, Dece

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Jean Dubois
Op vrijdag 13 december 2013 04:32:30 UTC+1 schreef Dan Stromberg: > On Thu, Dec 12, 2013 at 7:23 PM, Jean Dubois wrote: > > > Op donderdag 12 december 2013 22:23:22 UTC+1 schreef Dan Stromberg: > > >> On Thu, Dec 12, 2013 at 12:28 AM, Jean Dubois > >> wrote: > > >> > > >> > On Thursday, Dece

Re: [newbie] trying socket as a replacement for nc

2013-12-13 Thread Mark Lawrence
On 13/12/2013 03:23, Jean Dubois wrote: kind regards, jean p.s. I'm using Linux/Kubuntu 11.04 Would you please read and action this https://wiki.python.org/moin/GoogleGroupsPython to prevent us seeing the double line spacing that accompanied the above, thanks. -- My fellow Pythonistas, as

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Dan Stromberg
On Thu, Dec 12, 2013 at 7:23 PM, Jean Dubois wrote: > Op donderdag 12 december 2013 22:23:22 UTC+1 schreef Dan Stromberg: >> On Thu, Dec 12, 2013 at 12:28 AM, Jean Dubois >> wrote: >> >> > On Thursday, December 12, 2013 12:20:36 AM UTC+1, Dan Stromberg wrote: >> >> >> On Wed, Dec 11, 2013 at 3:0

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Jean Dubois
Op donderdag 12 december 2013 22:23:22 UTC+1 schreef Dan Stromberg: > On Thu, Dec 12, 2013 at 12:28 AM, Jean Dubois wrote: > > > On Thursday, December 12, 2013 12:20:36 AM UTC+1, Dan Stromberg wrote: > > >> On Wed, Dec 11, 2013 at 3:08 PM, Jean Dubois wrote: > > >> > > >> I have an ethernet-r

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Dave Angel
On Thu, 12 Dec 2013 13:27:16 -0800, Dan Stromberg wrote: On Thu, Dec 12, 2013 at 6:16 AM, Grant Edwards wrote: I haven't done a lot of UDP, but are you pretty sure UDP can't at least fragment large packets? What's a router or switch to do if the Path MTU isn't large enough for an original

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Christian Gollwitzer
Am 12.12.13 00:08, schrieb Jean Dubois: I have an ethernet-rs232 adapter which allows me to connect to a measurement instrument by means of netcat on a linux system. e.g. entering nc 10.128.59.63 7000 allows me to enter e.g. *IDN? after which I get an identification string of the measurement ins

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Chris Angelico
On Fri, Dec 13, 2013 at 8:27 AM, Dan Stromberg wrote: > On Thu, Dec 12, 2013 at 6:16 AM, Grant Edwards > wrote: > >>> Sockets reserve the right to split one socket.send() into multiple >>> socket.recv()'s on the other end of the communication, or to aggregate >>> multiple socket.send()'s into a

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Dan Stromberg
On Thu, Dec 12, 2013 at 6:16 AM, Grant Edwards wrote: >> Sockets reserve the right to split one socket.send() into multiple >> socket.recv()'s on the other end of the communication, or to aggregate >> multiple socket.send()'s into a single socket.recv() - pretty much any way >> the relevant IP st

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Dan Stromberg
On Thu, Dec 12, 2013 at 12:28 AM, Jean Dubois wrote: > On Thursday, December 12, 2013 12:20:36 AM UTC+1, Dan Stromberg wrote: >> On Wed, Dec 11, 2013 at 3:08 PM, Jean Dubois wrote: >> >> I have an ethernet-rs232 adapter which allows me to connect to a measurement >> instrument by means of netcat

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Mark Lawrence
On 12/12/2013 14:05, Alister wrote: you probably need to use something like wireshark to see what is actually happening and compare it to a good connection in the normal way. You've sent this twice old chap, you've a configuration issue somewhere I'd guess :) -- My fellow Pythonistas, ask

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Chris Angelico
On Fri, Dec 13, 2013 at 1:16 AM, Grant Edwards wrote: > And it _will_ fail someday in some odd circumstance when, for example, > some customer is be using it via a dial-up PPP connection, or there is > a satellite link in the path, or there's a flakey router somewhere, > or... Or you write, write

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Grant Edwards
On 2013-12-11, Dan Stromberg wrote: > On Wed, Dec 11, 2013 at 3:08 PM, Jean Dubois wrote: > >> I have an ethernet-rs232 adapter which allows me to connect to a >> measurement instrument by means of netcat on a linux system. >> e.g. entering nc 10.128.59.63 7000 >> allows me to enter e.g. >> *IDN?

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Alister
On Thu, 12 Dec 2013 01:21:27 -0800, Jean Dubois wrote: > On Thursday, December 12, 2013 9:21:32 AM UTC+1, Chris Angelico wrote: >> On Thu, Dec 12, 2013 at 7:08 PM, Jean Dubois >> wrote: >> >> > Thanks for the reply, I changed the line you mentioned to >> >> > s.send('*IDN?\n') >> >> >> >> Se

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Alister
On Thu, 12 Dec 2013 01:21:27 -0800, Jean Dubois wrote: > On Thursday, December 12, 2013 9:21:32 AM UTC+1, Chris Angelico wrote: >> On Thu, Dec 12, 2013 at 7:08 PM, Jean Dubois >> wrote: >> >> > Thanks for the reply, I changed the line you mentioned to >> >> > s.send('*IDN?\n') >> >> >> >> Se

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Jean Dubois
On Thursday, December 12, 2013 9:21:32 AM UTC+1, Chris Angelico wrote: > On Thu, Dec 12, 2013 at 7:08 PM, Jean Dubois wrote: > > > Thanks for the reply, I changed the line you mentioned to > > > s.send('*IDN?\n') > > > > See if there's a newline issue - you might need \r\n here. > > > > Ch

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Jean Dubois
On Thursday, December 12, 2013 12:20:36 AM UTC+1, Dan Stromberg wrote: > On Wed, Dec 11, 2013 at 3:08 PM, Jean Dubois wrote: > > I have an ethernet-rs232 adapter which allows me to connect to a measurement > instrument by means of netcat on a linux system. > > > e.g. entering nc 10.128.59.63 7

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Chris Angelico
On Thu, Dec 12, 2013 at 7:08 PM, Jean Dubois wrote: > Thanks for the reply, I changed the line you mentioned to > s.send('*IDN?\n') See if there's a newline issue - you might need \r\n here. ChrisA -- https://mail.python.org/mailman/listinfo/python-list

Re: [newbie] trying socket as a replacement for nc

2013-12-12 Thread Jean Dubois
On Thursday, December 12, 2013 12:38:12 AM UTC+1, Conor Hughes wrote: > Jean Dubois writes: > > > > > I have an ethernet-rs232 adapter which allows me to connect to a > > > measurement instrument by means of netcat on a linux system. > > > e.g. entering nc 10.128.59.63 7000 > > > allows me t

Re: [newbie] trying socket as a replacement for nc

2013-12-11 Thread Conor Hughes
Jean Dubois writes: > I have an ethernet-rs232 adapter which allows me to connect to a > measurement instrument by means of netcat on a linux system. > e.g. entering nc 10.128.59.63 7000 > allows me to enter e.g. > *IDN? > after which I get an identification string of the measurement > instrument

Re: [newbie] trying socket as a replacement for nc

2013-12-11 Thread Dan Stromberg
On Wed, Dec 11, 2013 at 3:08 PM, Jean Dubois wrote: > I have an ethernet-rs232 adapter which allows me to connect to a > measurement instrument by means of netcat on a linux system. > e.g. entering nc 10.128.59.63 7000 > allows me to enter e.g. > *IDN? > after which I get an identification string