LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Open datasocket connection error 42

Solved!
Go to solution

Yes wiebe@CARYA, for me, it sounded like DCOM in OPC but I think Pataclaque is not using an OPC server.

As you may see in this White Paper http://www.ni.com/white-paper/12402/en/; the datasocket uses TCP port 3015 (for DSTP) and it should be opened in the firewall of both server and client.

If this is already so, then, I would try to use an example of LabVIEW. Are you using an example as Simple DataSocket.lvproj that is in the LabVIEW example finder

0 Kudos
Message 11 of 24
(2,517 Views)

Yes I did.

 

Computer A:  I had to re-installed Windows 8 and LabVIEW 2012.

Computer B: It stays the same and run the executable that we are talking about.  It tries to "Open Datasocket Connection" to a shared variable located on the Computer A.

 

Michel

0 Kudos
Message 12 of 24
(2,517 Views)

No, I'm using the same code that was working like a charm prior the re-installation of Windows 8 on Computer A.

Message 13 of 24
(2,511 Views)

@eaguero wrote:

Yes wiebe@CARYA, for me, it sounded like DCOM in OPC but I think @Pataclaque is not using an OPC server.

As you may see in this White Paper http://www.ni.com/white-paper/12402/en/; the datasocket uses TCP port 3015 (for DSTP) and it should be opened in the firewall of both server and client.

If this is already so, then, I would try to use an example of LabVIEW. Are you using an example as Simple DataSocket.lvproj that is in the LabVIEW example finder


But the application works when run in LabVIEW. It's only the executable of the application that does not work.

 

On the remote computer, it's a shared variable. So he's trying to read a shared variable (OPC) with datasocket. It seems to be the DCOM interface of the remote computer blocks the executable, but not LabVIEW.

0 Kudos
Message 14 of 24
(2,506 Views)

Yes, this is currently the situation I have.  To make it clear, prior the re-installation of Windows LabVIEW and the executable was working fine.

0 Kudos
Message 15 of 24
(2,501 Views)

If you have time, try a simple VI that access the shared variable as:

 

shared variable,

with Open shared Variable funciton,

and datasocket.

 

When it works, try to make an executable. I'm guessing the Open Shared Variable gives a lot less problems then the OpenDatasocket.

 

I'm off now, good luck.

0 Kudos
Message 16 of 24
(2,498 Views)

Ok, I will try that.

 

Thanks,

 

Michel

0 Kudos
Message 17 of 24
(2,494 Views)
Solution
Accepted by Pataclaque

Hello everyone,

 

I checked back my antivirus "Norton 360" on computer B, which has always run perfectly, by launching it from the tray icon.  I had an error related to Norton software, so I decided to uninstall completely from the computer B.  Guest what, everything is now running as before.

 

Thanks,

 

Michel

0 Kudos
Message 18 of 24
(2,484 Views)

Those are great news Patacle!

0 Kudos
Message 19 of 24
(2,471 Views)

Hi,

 

I have a problem about DataSocket Read Function . I want to read some data from OPC server. I read data and its value 100  as seen in picture dOPCexplorer . But when I give a start Labview .exe as seen Santral Veri Kayıt.vi, I get error 42 about DataSocket Read. Can anyone help me when solving this problem?

 

 

OPC SERVER.PNGLABWIEW.PNGLABWIEW.PNG

0 Kudos
Message 20 of 24
(2,441 Views)