LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Datasocket vi crashes labview

I'm learning Labview and currently only have the evaluation version of 8.6 available.

 

Now I use the following vi's to establish a datasocket connection, but labview crashes when I executed these vi's:

Vi sender      vi receiver

 

 

For both I set the datasocket to dstp://localhost/temp as displayed here for the server (receiver is read-only, but for the rest the same):

datasocket-settings

 

I added the path via browsing to the datasocket.

The original vi - which I downloaded from hxxp://www.hs-weingarten.de/~georgi/LabVIEW/public_html//Examples/VI_Lessons/Part%2010/ - had it already set, but since the temp path was not available in the Datasocket Server Manager I first assumed that was the error. But after setting the path up myself and browsing to it in the property box Labview still crashes.

 

Does anybody know what is wrong?

0 Kudos
Message 1 of 4
(3,019 Views)

Nemelis wrote:

Now I use the following vi's to establish a datasocket connection, but labview crashes when I executed these vi's:


Your images in the post screwed up since it points out to your local drive in your system. Also don't use preview post after adding the attachments, then you will loss the attachments. Post back with full details again.

 

thanks,

Mathan

0 Kudos
Message 2 of 4
(3,015 Views)

The images should not point to my local drive, since I added them from photobucket.

 

But I did indeed preview before I posted.

 

Anyway the images are:

vi's:

sender-vi        receiver-vi

 

(URL's:

http://i2.photobucket.com/albums/y48/Nemelis/sender-vi.png

http://i2.photobucket.com/albums/y48/Nemelis/receiver-vi.png)

 

And settings:

 

server-datasocket settings

 

(URL: http://i2.photobucket.com/albums/y48/Nemelis/Datasocket-settings-sender.png)

 

Again: The settings for the receiver are almost identical, exept that it is read-only. And I created the temp-path and used browse to select it, i.s.o. using the settings that were provided in the example-vi's.

0 Kudos
Message 3 of 4
(3,009 Views)

Hi Nemelis,

 

I have been troubleshooting your VI's and probably found two solutions.


I assume that you get the followin error, when running this program:

"Error 1181 occurred at DataSocket Write in V"

 

There are two ways to  implement a DataSocket connection:

 

Control

The first, and most simple option is to bind a control to a DataSocket connection (dstp://localhost/test in your case); 1 control writes, 1 control reads.

Enclosed you will find a .ZIP file (DS Basic.ZIP) containing a Read and Write VI. You will see that you do not need the DataSocket Read/Write function in this case.

 

Output Data

The second, more advanced option is to open a DataSocket connection (with which you create the channel), wire the output of a control to a  DataSocket Write function and then close the DataSocket connection. Enclosed you will find another .ZIP file (DS Advanced.ZIP) containing a Read and Write VI based on this way of programming. This option allows you to implement some additional features with DataSocket, whereas the Control Binding option does not.

 

Alternatively, you might consider using the Shared Variable. More information regarding the shared variable can be found using the following weblink:

http://zone.ni.com/devzone/cda/tut/p/id/4679

 

I hope this will help you with creating your program!

 

Regards,

 

PeterS

 

 

 

Message Edited by Peter S on 04-07-2009 12:15 PM
Message Edited by Peter S on 04-07-2009 12:16 PM
Download All
0 Kudos
Message 4 of 4
(2,984 Views)