LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Failed to create files with write to measure.vi

Hello,

 

First I apologize for not seeing that network streams are new feature of LabVIEW 2010. I found link regarding sending array of strings throught TCP: https://decibel.ni.com/content/docs/DOC-6641

To be able to use this in your system you need to convert you array of doubles to array of strings, and then send/recieve it like it is described is the link.

 

The connection of error wire i correct. To fix please try few thing: set timeout of the stop variable in cRIO.vi (the one you write false) to 3000 milliseconds, change of Variable1 few times bigger and change buffer size of Variable1 to few times bigger number. If after this still does not work, try enabling RT FIFO on stop variable to single-element

 

The control of sampling rate in the computer VI needs to be in while loop, so it is updating data each iritation. The variable must not be buffered and RT FIFO need to be single-element.

 

Input node sets the settings on the start of the timed loop; with right data node you can change setting between the timed loop in running.

 

Best Regards,

Gregor Cerne

 

National Instruments

 

 

0 Kudos
Message 51 of 77
(989 Views)

Right,

 

This should work, it is completely untested though, and I have never down converted files before so I have no idea how far this will get us!!!!

 

The files you will want to use are in the 2k9 folder.

 

Dom

0 Kudos
Message 52 of 77
(986 Views)

Sorry how come when i right click on the Stop variable, there's no option saying "show timeout" ?

0 Kudos
Message 53 of 77
(983 Views)

Is this aimed at me or Gregor?

0 Kudos
Message 54 of 77
(979 Views)

Sorry that message was to Gregor regarding one of the suggestion he has made previously.

 

Thanks for your code!! Because I have close to 0 knowledge about TCP, I shall go check out Gregor's link about TCP first and build some basic knowledge before I can understand the VI you provided. Thanks a lot ! I really appreciated your help!!

0 Kudos
Message 55 of 77
(976 Views)

I have also just realised that on my PC VI, I haven't wired a proper stop, you will need to do this or kill the program.

 

The VI's I have sent to you are a kind of proof of concept, they should work, if they do then we can build in the rest of the functionality as we go.

0 Kudos
Message 56 of 77
(974 Views)

Hello,

 

I deeply apologize, I mixed up few things together - there is no way to set the timeout for writing into variable. Please skip this step.

 

Best Regards,

Gregor Cerne

 

National Instruments

0 Kudos
Message 57 of 77
(973 Views)

@ Gregor,

 

Because I previously set variable1 to be a single process variable, it does not enable buffering, if I change it to a network variable and enable buffering, it still doesnt solve the problem, plus it creates another problem where the display of the timestamp on the computer.vi doesnt go smoothly. Maybe I should implement your previously suggested approach for the stop button but can yours be modified in such a way that the stop button displays on the computer.vi rather than cRIO.vi? Thanks!

 

@Dom I 'll start looking at the VI now and hopefully I can get back to you soon! Once again thanks a lot!!

0 Kudos
Message 58 of 77
(962 Views)

@ Dom, I have just tried to run your provided VIs on my project and I have got an error message, which reads :

 

Error 74 occurred at Unflatten From String in PC VI.vi

 

Possible reason(s):

LabVIEW:  Memory or data structure corrupt.

 

And for the cRIO TCP VI.vi, was I supposed to perform the instructions given about removing the code disabled structure code?

0 Kudos
Message 59 of 77
(956 Views)

The instruction to remove the disable structure was purely so you could test it on your cRIO with your data once we have sorted the streaming out....

 

I'll have another look, unfortunately my cRIO's are otherwise occupied at the moment, but I'll get back to you ASAP.

 

Dom

0 Kudos
Message 60 of 77
(954 Views)