Wiki source code of LabviewDOOCS (no longer supported)
Last modified by sndueste on 2025/02/05 11:23
Hide last authors
author | version | line-number | content |
---|---|---|---|
![]() |
8.2 | 1 | \\ |
2 | |||
3 | * How to read and write DOOCS properties with LABVIEW | ||
4 | ** [[General>>doc:||anchor="General"]] | ||
5 | ** [[Labview 64 bit>>doc:||anchor="Labview 64 bit"]] | ||
6 | ** [[Labview 32 bit>>doc:||anchor="Labview 32 bit"]] | ||
7 | |||
8 | === General === | ||
9 | |||
10 | Within the DESY network any computer and user can **read** DOOCS information via LabView. But in order to **write** DOOCS properties from Labview (or Windows in general) the computer //and// the user have to registered (so same computer and different login does not work). ( (Registration will be done by FLASH IT stuff together with MCS4 (Anna Petrosian). | ||
11 | |||
12 | For this to work the computer must have either the ENSHOST environment variable set correctly (cumbersome) or [[desy.de>>url:http://desy.de||shape="rect"]] added to the auto DNS suffixes. | ||
13 | |||
14 | [[image:attach:network_settings.png.jpeg||height="400"]] | ||
15 | |||
16 | \\ | ||
17 | |||
18 | === Labview 64 bit === | ||
19 | |||
20 | For Labview 64 bit a completely new dll has been written (doocslv.dll) based on the newer **//windoocs//**. This supports all the basic property types (float, int, string, ...) and some array types (int array, spectrum (TD), ...). More complex types like IFFF are not included but can be added if need be. Writing to DOOCS is only implemented for basic types, but other are also easy to add. | ||
21 | |||
22 | Based on this dll you get the Labview user.lib or instrument.lib here. Just copy and extract the archive into your user.lib or instr.lib directory. All functions and an example is then available on your Labview palettes. See picture below. | ||
23 | |||
24 | Find it as single hopefully up to date archive here:[[attach:doocslv_64.zip]] | ||
25 | |||
26 | You need to have //MS Visual C++ Redistributable for Visual Studio 2015// installed, a.k.a. {{code language="none"}}msvcp140.dll{{/code}}. Maybe you will still find it [[here>>url:https://www.microsoft.com/en-US/download/details.aspx?id=48145||shape="rect"]]. | ||
27 | |||
28 | [[image:attach:user.lib.png.jpeg||height="400"]] | ||
29 | |||
30 | \\ | ||
31 | |||
32 | === Labview 32 bit === | ||
33 | |||
34 | Using the modern **//windoocs//** thru doocslv.dll (see explanations for 64 bit version above), you find the library on the SVN server [[https:~~/~~/svnsrv.desy.de/desy/GMD/LabView/doocslv_32/>>url:https://svnsrv.desy.de/k5websvn/wsvn/General.GMD/LabView/doocslv_32/||shape="rect"]] or as single hopefully up to date archive here:[[attach:doocslv_32.zip]] | ||
35 | |||
36 | There is also the older **//wdoocs//** based library; all text below discusses just that solution. | ||
37 | |||
38 | >Using the dlls (lv_client2011) sub .vi s for reading and writing DOOCS properties are available. This is based on the **wdoocs** library (a.d. 2005). Data transfer is done via strings. If you need better performance (reading spectra etc) transfer in the real type (i.e. float) is available with the newer windoocs based library for Labview 64. Please read the notes there.In the attachments the dlls and some sample files can be downloaded (lv_client2011.zip).(Last test was working with Labview2014 and Windows 7)(The dlls have to be in the same folder as the program (or the path has to be defined in Labview). No environment variables have to be set for DESY windows computers additionally (because they usually have the correct suffix set, imho (Fini)). Just extract and run ...)[[attach:DOOCS_USB_analog_output.zip]]: This is a collection of Labview programs (programmed March 2015 by MPK Heidelberg) that read DOOCS variables and sends them to a National Instruments DAC ADC USB device (NI USB 6009) to provide analog signals. The programs are specially made for the delayline and streak camera readouts but can be used for any DOOCS slow parameter. The USB6009 is in Soerens and Erlands office. |