Accessing DataSocket Server with Python

Dan Stromberg drsalists at gmail.com
Thu May 28 18:17:49 EDT 2015


I have no idea about the protocol used by NI DataSockets, but you
might be able to reverse engineer the protocol by using the official
client with a sniffer.

Also, be aware that TCP/IP guarantees that you get the correct data in
the correct order, but it doesn't guarantee anything about the sizes
of the chunks in which that data arrives.  So you could send 100
bytes, 100 bytes, 100 bytes, but on the other end receive 100 bytes,
50 bytes, 75 bytes, 75 bytes.  When you catenate them all together,
it's still the same data though.

HTH.

On Wed, May 27, 2015 at 4:30 AM, Garrone, Corrado
<corrado.garrone at roche.com> wrote:
> Dear Python Team,
>
> currently I am working on a research project for my bachelor degree. A
> LabVIEW application is used for current and power measurements, whereas the
> measured data are sent to DataSocket Server, a technology by National
> Instruments used for data exchange between computers and applications.
> DataSocket is based on TCP/IP and thus requesting data from DataSocket
> should be similar to an internet request.
> I know with the socket library in Python it is possible with to establish
> sockets, send internet requests and communicate between clients and servers.
> Is there a possibility to access NI DataSocket and get measurement data with
> Python on the same computer where Python is installed and the codes are
> executed? Can you maybe send me an example code where such a connection with
> DataSocket is established?
>
> If you got any queries, please do not hesitate to contact me.
>
> Thank you very much for your efforts.
>
> Kind regards,
>
> Corrado Garrone
> DH-Student Fachrichtung Elektrotechnik / Co-op Student B.Eng. Electrical
> Engineering
>
> Roche Diagnostics GmbH
> DFGHMV8Y6164
> Sandhofer Strasse 116
> 68305 Mannheim / Germany
>
> Phone: apprentice
> mailto:corrado.garrone at roche.com
>
> Roche Diagnostics GmbH
> Sandhofer Straße 116; D‑68305 Mannheim; Telefon +49‑621‑759‑0; Telefax
> +49‑621‑759‑2890
> Sitz der Gesellschaft: Mannheim - Registergericht: AG Mannheim HRB 3962 -
> Geschäftsführung: Dr. Ursula Redeker, Sprecherin; Edgar Vieth -
> Aufsichtsratsvorsitzender: Dr. Severin Schwan
>
> Confidentiality Note
> This message is intended only for the use of the named recipient(s) and may
> contain confidential and/or privileged information. If you are not the
> intended recipient, please contact the sender and delete the message. Any
> unauthorized use of the information contained in this message is prohibited.
>
>
> --
> https://mail.python.org/mailman/listinfo/python-list
>



More information about the Python-list mailing list