Quantcast
Channel: LabVIEW topics
Viewing all 69090 articles
Browse latest View live

Do LabVIEW upgrades include security patches

$
0
0

Am looking into whether to renew the standard service program. From a programming standpoint, don't need to, but from a security standpoint am wondering if the updates in software ever patch security issues. Know in general LV is pretty secure, so wasn't sure if the updates ever include this or if those patches would be released without the standard service agreement (I assume they would).

 

Thanks for your help!


Liaison série RS232 problème de pilotage

$
0
0

Bonjour,

Je voudrais commander une imprimante 3D en utilisant une liaison série RS232 entre l'imprimante et mon pc.

Dans le cas où j'utilise Termite, j'envoie une commande Gcode à l'imprimante. Et, comme réponse, l'axe se déplace. (vous trouviez en pièce jointe) la commande envoyée via termite.

Dans le cas où j'utilise Labview, la commande est envoyée car le programme me retourne le nombre de bits envoyé et l'imprimante fait un bip une fois elle reçoit la commande. Cependant, l'axe ne se déplace pas.

Problème: pourrie-vous me dire où est-il le problème car je n'arrive pas à le voir?

En pièce jointe, vous trouvez le programme Labview que j'ai utilisé et la commande Gcode que j'ai envoyé.

Merci pour votre aide,

Liaison série RS232 problème de pilotage

Handling a state machine using a single button

$
0
0

Hi all,

 

I would like to implement a process which runs like a state machine with a certain functionality that I can't seem to make work just yet.

Basically, the user will first choose a number of processes (and the state machine will only run the process they select), and the following steps should occur after pressing start:

(Each process corresponds to a state in the state machine)

 

1) Process 1 is run for as long until user clicks an OK Boolean

2) After OK Boolean is clicked the state goes to Process 2 

3) Process 2 runs as long until user clicks the OK Boolean once again

4) And so on and so forth until all processes are done

 

The problem I'm having is with the OK Button. Accomplishing the above tasks is relatively simple if there are multiple OK Buttons for each process/state OR if the Boolean operation of a single OK Button is changed to Switch and is Reinitialized to Defalt after each process.

 

However I find both methods inelegant, especially when the number of possible processes is high hence the amount of local variables that need to be polled each time to see if it's been clicked and ensuring the button is reinitialized to false each time clutters the block diagram unnecessarily methinks).

 

I'm thinking of making just one single OK button and making it a latch, which runs into the problem of local variables not being possible to be inserted into each state. I feel an Event structure is needed *somewhere* so that the state (which is a loop that does a bunch of things) stays the same until OK is triggered (which effectively stops the loop in the current state, and then it springs to the next state and the same thing happens until OK is triggered again but my rudimentary attempts has only resulted in endless looping and hard aborts.

 

Bonus problem: when the user clicks the OK button, there should be an awareness they have done so and not press again because it might skip one/more states ahead than it should... (Dialog boxes are useless bc they just cause more unnecessary clicking; I've mulled over a kind of maybe showing a loading button but then the question comes up of how long enough should it stay up to make the user aware but short enough to not give the feeling that the program is lagging, etc....so other suggestions for this are welcome too.)

ModBus/TCP

$
0
0

Hello! 

We use Codesys to write data in the address range 0x3000...0x5fff to the non-volatile memory of the Wago 750-881 controller. There is a task to read this data from the controller's non-volatile memory using Labview. We have to read this data by ModBus/TCP.

Please tell me how to do this.

Using text file to initialize front panel controls

$
0
0

I'm new to LabVIEW and am stuck on something that I thought should be pretty easy to accomplish. I have a form wtih about 50 controls on it. I can loop through these controls and write their values to a text file without a problem. This is done in a way that I can add or remove controls and the code to generate the text file doesn't need to change.

 

I can also read this file in and parse it up without any problems. However, nothing I have tried gets the controls populated. I've attached my current code and the text file I'm reading from. Does anybody have any suggestions on how to accomplish this?

 

My code to read and write the text file is attached. Thank you.

Saving LabVIEW Temperature Data Through Excel

$
0
0

I am trying to save some temperature sensor data into a LabVIEW file. In my code, It is under the "Pico Temp" tab. 

The current way I have it saving it does not work correctly. It either doesn't save any data or it saves only one data (so one temperature,not a set of temperatures taken over a period of time).

I am fairly new to labVIEW and I got the  code I have now from the PICO temp github, and then I tried to use a friend's code to do the saving process. 

Questions regrading labview.

$
0
0

I have a few problems on LabVIEW  that I am trying to solve but I get stuck on some steps because I'm new and just learning it, would be possible to describe the steps in videos or pictures of the problems so I can know which code or thing that i have to use in order to solve the questions.

 

3. Create a VI that takes a 2D array of numbers and returns a 1D array that contains the average of each of the rows. Make a control for the 2D array input by placing an empty array on the front panel and placing a Numeric Control inside (see Section 2.1). Add a dimension to the array (since the default is a 1D array) and then populate a few rows and columns of the array with numbers in order to test your code. Make an indicator on the front panel consisting of a 1D array that will show the results of the averaging (place a Numeric Indicator inside another empty array). You can use a “for” loop in your block diagram to perform calculations on the rows of the array one at a time: when a 2D array enters such a loop through an auto-indexing tunnel (see Section 2.1.2), each iteration of the loop will use one row of the array (and the number of iterations will be the number of rows).
• Modify your code so that it can average either the rows or columns of the given array. Add a
Boolean control (switch or button) to the front panel which controls whether the 2D array is
transposed before its rows are averaged. Test your program by making sure that the averaging is
successful in both “row” and “column” configurations.
• Configure this VI for use as a subVI by connecting both controls and the indicator to terminals
on the “connector” diagram, then save the VI with an appropriate name.

 

4. Select “VI Properties” (under the File menu, or using Ctrl-I), choose the “Executive” category, and check the “Clear indicators when called” checkbox. Now, whenever you run the code, all indicators and charts will be cleared and show the values from the new run.

 


5. Write a VI that creates a sinusoidal signal contaminated by noise and then averages multiple instances of the signal to remove the noise. You can use the “Simulate Signal” Express VI, described in Section 2.4.2, to create the signal, placed within a “for loop” structure so that the signal is created many times. You’ll need to check the “Add noise” box in the configuration popup window to add noise contamination to the signal. Configure the “Simulate Signal” Express VI so that there are at least 2 or 3 oscillations of the sinusoid during the signal’s duration (you may wish to adjust the signal’s frequency, the number of samples per rate, and/or the number of samples). Also, select the “Reset phase, seed, and time stamps” option so that each time the signal is created, the sinusoid will start at the same point in its cycle.

In addition to the “Simulate Signal” Express VI in a “for” loop, your front panel should feature:
• Controls for the signal’s amplitude, the amplitude of the noise, and the number of averages used
to suppress the noise (the number of times to run the “for” loop).
• Indicators including:
– one graph displaying a single instance of the signal, which will change each time through the
loop
– a second graph that displays the current averaged signal (updated each time through the loop,
it should look less and less noisy because more and more measurements are being averaged)
– an indication of how many averages have taken place so far
Helpful Hints
• The output of the “Simulate Signal” VI is a wire of type “Dynamic Data.” The Convert From
Dynamic Data express VI will allow you to convert this directly to a 1D array of numbers, or to
convert it to a waveform, from which you can then extract the array of numbers you need to work
as well as the timing information using the “Get Waveform Components” function.
• You can use Shift Registers to assemble the 1D arrays generated by the “Simulate Signal” VI into larger and larger 2D arrays as the loop repeats.
• Call the subVI you created in problem 4 to perform the averaging calculation.
• Make sure the labels on your graphs are correct. Plot amplitude vs. time if you can, otherwise,
be sure to indicate the plots are amplitude vs. sample number.


Front panel objects not responsive

$
0
0

Hi All,

 

I have a VI that has some front panel objects that are no longer responsive. Front panel objects are enabled and never get disabled. I am not sure why and everything seems to check out on the block diagram. I know the program is operating because my task states are triggered. Any thoughts or insights would be greatly appreciated.

 

Thanks in advance,

 

Anton

Labview Source Control for Package Manager

$
0
0

Hi,

I use Gitbucket and Sourcetree for source control. I have a cloned online folder on my desktop where I save all my files. When creating a new program I always make sure to include it in this folder so I can keep track of changes. Now, when I use third party LabVIEW drivers that I downloaded with LV Package Manager I am no longer certain how to integrate these into source control. The drivers automatically download onto my desktop. This means they are not included in my source control, so if I were to pull a code from source tree on a different computer the drivers would not be included. If I move the drivers out of their original download location and put them into the online folder this solves the problem, but they no longer show up on the functions pallet. This was the best solution I could think of, any suggestions? I am self taught in programming so my knowledge on correct protocol is sparse 😞

DAQmx terminal to JSON - has unsupported data type - "Tag"

$
0
0

DAQmx terminal control type fails conversion to JSON with at least 4 different libraries:

JDP Science, JKI JSON, G Craftsman and LabVIEW builtin "Flatten to JSON"

 

The error code is 1 with a note "Unsupported Data Type: Tag". This is slightly difficult to document as it requires the libraries which I download with VIPM from JKI. But I have the screen dumps below.

Documentation for the builtin "Flatten to JSON" is confirming that this data type is not supported, but I included it to illustrate the general problem.

Failing librariesFailing libraries4 failing libraries4 failing libraries

 

A workaround could be to convert the DAQmx terminal to a string, but then the builtin browsing and filter option is lost.

Any logical reason why the Tag type is not supported by any of these libraries?

Labview steps to be described.

Labview licencia de estudiante

$
0
0
Moved to Spanish board under Regional Communities

Error -1073807194 VISA: (Hex 0xBFFF00A6) The connection for the given session has been lost. Ethernet and windows 10

$
0
0

We have been changing all of our testers to LabVIEW 2018 and Windows 10.  We have been seeing an issue where after a while they will throw the "VISA: (Hex 0xBFFF00A6) The connection for the given session has been lost." Error.  This LabVIEW code has been running for years on windows 7 pro on versions of LabVIEW at least back to 2012 and up to 2017 with no problems.  We only see it with Ethernet connected instruments, Primarily Keysight 33512 ARBS, N6700 series power supplies, and DSOX3014 scopes.  GPIB instruments work fine.  We had some LabVIEW 2018 windows 7 installations, but I do not know if any of them had Ethernet instruments.  I have not seen an issue with Ethernet/IP connected PLCs, but those are hard coded static IP addresses rather than a VISA Alias session.  That being said, the PLCs will attempt to automatically re-establish the connection, so we may not even see a drop out if the LabVIEW side doesn't throw an error.

 

Flow looks like this:

On product select use MAX visa alias name to initialize instruments.

Run product for several hours.

Close Visa sessions with product end routine.

 

Production tells me that it happens intermittently, but I suspect it is after a period of idle time.  Does windows 10 automatically close out ethernet VISA sessions for inactivity that Windows 7 was more tolerant of?

 

If I close the visa sessions at the end of each DUT and reopen for the next, it adds a significant amount of cycle time.

WebDAV error 353629 when transferring files from cRIO to PC

$
0
0

Hi,

 

I'm building an application that transfer files from a HDD connected to a cRIO (9040) to a PC. Tranfser is done using WebDAV Asynchonous VIs.

The HDD is always mounted as /u.

It happens sometimes, if the file size is greater than 900MB, that the transfert ends with the error code 353529 and saying that the server closed prematurarly the connection.

 

So I'm pretty far from the 2GB barrier using WebDAV, it shouldn't be the issue.

The PC running my application can have a Win7 or Win10 OS. Error happens on both OS.

I already tried to modify some registry keys to extend the file size limit as found on some other threads... But it has no effect.

 

Can you help me with this issue ?


.VI 2013 to 7.1

Access shared memory in racing game

$
0
0

Hi,

 

I want to access shared memory in racing game "Assetto Corsa"

 

I know that Assetto Corsa share game data(speed,rpm, etc.) by shared memory section.

 

How to access this section by labview?

 

I can't see any shared memory dll file in Assetto Corsa install folder.

 

Regards.

Do I need a license to install NI-DAQmx solely simulated instruments in NI-MAX and Python test script development?

$
0
0

Do I need a license for

- installing NI-DAQmx on a work laptop solely for simulated instruments in NI-MAX - not LabView or TestStand

- developing Python code against the Python NIDAQmx API and NIDAQmx drivers to run against the simulated devices

- aim is to develop Python test scripts on a development machine, then run on a DAQ once the scripts are finalized, to reserve time on the DAQ for actual testing.

 

Note: there are some similar-ish questions out on the forum, but nothing more recent than 2010.

Is there a way to use a text file or spreadsheet instead of the GUI to initialize variables in LabVIEW

$
0
0

Hello,

I am new to LabVIEW and have a question. Is there a way to completely skip the GUI altogether and just drive a LabVIEW program with a "settings" file/spreadsheet that initializes variables and such?

Thanks in advance!

Using an encoder to read RPM

$
0
0

Hey everyone. 

I'm running 2017 (I should probably update)

I have a 100 pulse TTL shaft encoder. Standard stuff, 5v. 

I've check my output with and Oscope and it works fine. 
I've changed my digital I/O card to read input. 

I do NOT know how to actually read the data in a VI. 
I know this is probably first day stuff, but I cannot seem to figure it out. 
I have thermocouples in the VI, DC current readings, but I can't seem to figure this one out. 
When I drag the channel from the project screen it gives me the Green icon and I don't know what to do with it from there. 

 

My end goal is to have two speed sensors, one will be the motor speed of the driver and one and will be the shaft speed of the driven. If the two don't match X amount of times over a period of time, something broke and an alarm will go off. 

 

Anyway, thanks for any tips or help! 

Ryan 

 

Viewing all 69090 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>