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

Case structure with comparison returning random numbers

$
0
0

I have written a VI for a syringe pump that controls aspiration and dispense.

Along with the control, I would also like to record total aspiration and dispense volume and I got that done using a while loop. 

My problem is in the case of error, in which dispense volume is larger than aspiration volume. 

The hardware is programmed that if the dispense volume (V_dis) is bigger than aspiration volume (V_asp), it does nothing. 

I want to reflect that on my VI as well that if V_dis is larger than V_asp, the total dispense volume does not change. 

The case structure (under "dispense" case and outside the subVI for dispense) for this particular condition works well, but there is some case in which it does not work and return some random value. 

 

It is in this scenario that it does not work:

1) Aspirate 1mL.

2) Dispense 0.2mL for 5 times. 

3) Dispense 0.2mL for 6th time and the number does not change (functioning well as I intended). 

4) Aspirate 0.2mL.

5) Dispense 0.1mL for twice. <- Problem in second dispense. 

 

It works well until the first dispense of 0.1mL in step #5, but not for the second dispense. 

After the first dispense, V_asp = 1.2mL and V_disp = -1.1mL. So V_asp > V_disp and the case should let the syringe dispense 0.1mL. 

However, it does not dispense and stay at that status. 

I set up the probes to see where it was going wrong and found that after going through comparison, it give a random number. 

 

I am attaching my VI, so please take a look at it and leave a comment if any of my explanations does not make sense, for I know this is a weird case where it works fine except for one particular set of numbers. 

 

Thanks. 


Create new Excel workbook

$
0
0

Hello,

 

How do you go about creating a new excel workbook if one does not exist within LabVIEW.  Currently, I have to manually create an excel file then copy that path into LabVIEW for the program to run.  I wanted to generate a new Excel file within LabVIEW.

 

Thanks.

Unable to move key focus onto newly added cluster in array

$
0
0

Hi everyone,

 

I have been trying to develop a COM port serial number vi for batch tests. I want this interface to continually scan for new COM ports, and when it finds a new one, add it to the array on the front panel and move key focus to the Serial Number member in the cluster. This way the tester can plug in a COM port and then scan the board serial number with a barcode scanner to automatically fill out the Serial Number (without having to click the Serial number box).

I have the first part mostly working, but I am unable to set keyfocus onto the Serial number of the last cluster in the array. I have tried resizing the array to 1, setting the index to the last member and then setting the Keyfocus, but the keyfocus is lost when I resize the array back to what it was before.

Does anybody have any advice on how I can do this?

Get the last row using the Cells object in Excel

$
0
0

All,

I am trying to recreate the VBA code here in LabVIEW '16 to tell me what the last row is without hard-coding anything (like the cell address). Right now, I am calling a VBA function that tells me what the last row is in a particular column (A).

 

Sub LastRowInOneColumn()
'Find the last used row in a Column: column A in this example
Dim LastRow As Long
With ActiveSheet
LastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
End With
MsgBox LastRow
End Sub

 

When I try to recreate the code in LabVIEW, I don't see the optional parameters  for the Cell object that you get when you code this with VBA. I am sure it is something that I am missing but maybe I just need another set of eyes to look at it. You'll see that I have tried to use the Range object, but that only results in an error. Any ideas?

Cannot Find NI_Word.lvclass

$
0
0

I have a program that runs in development mode but fails after I build the executable and try and run it.

 

I have attached a screenshot of the error and details as well a screenshots of the vi itself

Stop concatinating strings when string length is reached

$
0
0

Hello, 

I would like to Stop concatenating strings when a certain string length is reached.

Here is my trial on the VI.

Could you assist?

Regards,

 

Problem with 3D picture in Labview

$
0
0

hello everybody ... please i have problem when i try to create 3D picture in front panel

28-2017-2.png

 

I got this error and LabVIEW close after that 

28-2017.png

I have LabVIEW 2016 full and i installed openGL Extensions viewer 

.NET web browser clicking button doesn´t work all the time

$
0
0

Hey guys,

I´m currently working on an application that gives the user the opportunity to select images from google and download them. My idea is that the user types in an object he wants to search for. The application searches for that object. Then all the google images are displayed one after another and the user can click to download the image or not.

So, my first step was to create a .NET web browser and navigate to google image, type in the object name which the user likes to search for and click the search button. After that, I get the URL of the first image shown by google and navigate to it. Afterwards I programmatically click the "next" button every time the user clicks "download" or "not download". In the current version of the application, the images are switched every second just to test the functionality.

 

Now the problem is that clicking the search button after typing in the object name does not work all the time. My guess: When clicking the search button, I use the same document reference then before writing to the search field. So I´m searching for an empty string. But like mentioned - sometimes it works. I furthermore could not find any .NET event or property to wait until the document is updated before I click the button. Has anyone any idea what I´m doing wrong? I´m absolutely new to .NET. I´ll attach a snipped of my VI. I know I should close all the references and so on but this is just a test VI.

 


Real Time data acquisition on cRIO FPGA

$
0
0

Hello,

 

I am trying to write my first FPGA program that simply displays an input signal from a function generator in real time using the NI 9223 on a cRIO.

 

I followed the setup in the 9223 manual and cannot seem to get it working. Nothing displays at all on the graph and I've probed everywhere to try to find the problem however nothing is executable.

 

Looking forward to any help. 

 

 

NI-DAQmx 9.1.7 installer hangs

$
0
0

Hi.

 

I'm trying install NI-DAQmx 9.1.7. At first time, the installer hanged at 57%. I was unable to terminate the installer by clicking Cancel, so I kill the process in Task Manager. I tried to uninstall the product through Control Panel, but the uninstallation also hanged. I followed this steps (http://digital.ni.com/public.nsf/allkb/F4B8D92A304E4A7B862577460072002F) and manually uninstalled the product. After this, I runned two registry cleaners and restarted the computer. I runned the installer again, but it hanged at 4%, with a Command Prompt window with the message: "CertMgr Succeeded". I canceled the installer and runned it again, but it hanged at 0%, with the same message.

 

My computer is running Windows 7 Home Basic 32 bits.

Probe watch window scrollbar

$
0
0

hi..

Why probe scrollbar disappear??
Could let it visible?

That's LV version different?? I use LV2016..

I remember previous version that can scale object while resizing ,but now scale object after resizing ...

 

未命名.png

 

How to view block diagram in multiple window

$
0
0

Since I have so many states (3x) I do not want to swtich between states to view the block diagram so frequently.

How can I have multiple windows/views on the same block diagram?

Yokogawa ykwt500 Analyzer

$
0
0

 Hi Guys,

 

I have requirement to interface the Yokogawa ykwt500 Analyzer to a labview VI and write measurements to an excel file. I have downloaded the library files. How can I interface it with a labview vi? It's not an actual device. I just need to plug and play the driver and take measurements.

reversing the order of data written to variable

$
0
0

Hi,

i am making a small test vi to test the way to write data to a buffer. I am writing a string in a while loop with the time and send the data saved from loop to a local variable. But i found the data is saved in reverse order than how I want it to be. I have attached the image and the vi i made. As seen in the image, the time 11:00:34 should be at the end of the data but not at the top. Is there anyway this can be reversed. 

 

Thanks

Data acquisition with labview on odroid c2 board

$
0
0

Hello, this is the first time, I do not know if it's okay. Basically what I want to do is to install the labview on a board (ODROID-C2) which by what I see exceeds the raspberry pi 3 and from what I saw, have what it takes and more to be able to install the labview program By the way I have Version 15) this board (the odroid) has an ADC converter that RP3 does not have What I want to do is take the corresponding port (adc) of the data plate and then, after processing them, send them to Other ports on the board. I want to know if this can be done. How do I tell the program (labview) that x port is an adc and that it has to take the data that comes from that port and then sends them to me by another port? Can it be done Or am I wrong? Micro is an ARM by the way. Thank you very much


calling a piece of code based on event

$
0
0

Hi,

Looking for some help with my project.

I have a code that receives data continuously. But i want to call another piece of code once in a while based on an event (maybe a boolean event for now). I was wondering what would be the best way to do that. Any sample vi or example would be helpful.

 

Thanks

Change File Path to excel file

$
0
0

So I have changed this previously, but I have gone back to change it and I cant remember and Labview is far form intuitive.

 

Attached image - I want to change the file path

Live Sensor data from Labview to MATLAB

$
0
0

LabVIEW is obtaining 16 temperature values from 16 sensors continuously, I want to send this data to MATLAB so I can perform the same calculation on 16 temperature values and perform some live plots.

 

Is this possible, any examples? Google search has failed to find what I am looking for.

 

Kind Regards

 

Issues with Channel Wires on Larger Projects

$
0
0

I've been developing a mid-sized Project containing about 250 VIs and about 70 TypeDefs, all organized in a single LabVIEW Project.  There is a Main VI that does all of the Data Acquisition and Control, three Support Routines that create and manage some of the Configuration Files, and some Test Routines for trying out particular algorithms.

 

When running, the Main routine "spawns" (Start Asynchronous Call) up to 24 "Clones" that consist of four parallel loops -- a "Station" that communicates with the Main routine, a Balance routine that acquires data from a Balance using a VISA protocol at 10 weighing/sec, a Camera routine that acquires video images at 30 frames/second, and a Video routine that creates AVIs from the video images when the Balance signals "something happened".

 

All of the parallel loops are tied together and controlled using Asynchronous Channel Wires.  There are two Event Messengers, 11 Messengers, one Stream, and one Tag (if my count is accurate).

 

The code is being developed in LabVIEW 2016 (32-bit) on three PCs -- one Windows 7 Pro (64-bit) and two Windows 10 Enterprise (64-bit, Creator).  The code is maintained on Subversion, and I do an Update before starting work.

 

To facilitate development and find errors quickly when I make changes to, say, a TypeDef, I've created several "Tree" VIs that allow me to quickly load into memory sections of my Project, e.g. all of the Balance VIs, or all of the Support VIs.  Last night, I committed what I hoped was a near-final version of the code from my Laptop Windows 10 machine, verifying that there were no Broken Arrows in any of the VIs in the Project.

 

This morning, I updated the code on my desktop Windows 10 machine, which hadn't "seen" any code development on this Project for a few weeks.  In particular, there had been changes made to several of the TypeDefs underlying some of the Channel Wires used in the Project.  Thus it was no big surprise when multiple VIs showed broken arrows, and missing Channel dependencies, when the Project was opened and the VIs were loaded.

 

Channel Wires have a peculiarity that the LabVIEW code that supports their features lives neither in the Project nor in vi.lib, but rather in the User's LabVIEW Data Folder in a folder called ChannelInstances that is a sub-Folder of ExtraVILib.  When a Channel Wire is first encountered in Development, "magic happens" and the appropriate support code is created and place in this Folder.  A consequence of this is that springing a "change" to a Channel (for example, by doing an SVN Update of LabVIEW code) can lead to "lost" Channel support routines and broken wires.

 

The solution is normally simple -- simply close LabVIEW, delete the ChannelInstances folder, reopen the Project, reload the VIs, and wait while LabVIEW rebuilds the Channels.

 

But today, this didn't happen.  Instead, after several rounds of "Compiling ..." notifications, LabVIEW "got stuck" -- the spinning "Wait, I'm busy ..." signal appeared (for > 1 minute), and when I tried to close LabVIEW, red X's appeared on the Close button, a few seconds went by, and I got the message "LabVIEW appears to not be responding ..."  I chose to close LabVIEW and try again.

 

So that's the problem.  I tried multiple times to fix this by closing LabVIEW, deleting ChannelInstances, and restarting, largely getting the same result.  Any suggestions?

 

Bob Schor

LabVIEW Applications Updates

$
0
0

Hello everyone

 

I am working on an LabVIEW application that runs over more than 20 PC, I would like to know how could I code a "service" or background applications that each PC detects an update and install new versions if the user want it?, just like a regular windows application

 

And how could I send those updates?

 

I am using LabVIEW 2016

 

Thanks

Viewing all 66935 articles
Browse latest View live


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