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

Keysight 34465A - set aperture in NPLC instead of seconds?

$
0
0

There is a function on Keysight 34465A multimeters front panel that allows setting aperture by time (s) or number of Power Line Cycles.

There is a VI in the Agilent 3446X Series library that allows to do the same from Labview, however it only works for the time in seconds. Is it possible to programatically (from Labview) set the aperture by number of PLC instead?     


Serial communication with generator and NI USB 6008

$
0
0

Hello,

I would do serial communication between NI USB 6008 and power generator; Its name is EA-PS 3150-04 B. This is my programm. Can you help me please?

module with digital and analog channel

$
0
0

Is there any module available with Digital and analog channels both. application is similar to NI 9401.

USB :timeout expired before operation competed

$
0
0

Hello all,

 

I have written one program in labview which sends 201 bytes of hex data to the hardware using USB Communication. Hardware is a third party hardware.i.e PSoC board of cypress. I have implemented Psoc board in bulk transfer mode with two end points EP1(IN) and EP2(OUT).  

But when i send data bytes from labview to PSoC.,labview shows timeout error.saying timeout expired before operation completed.

on the other side to test whether  bytes at hardware received or not, i have written a program  in such a way that received bytes will get displayed on LCD. Here, about 40-50 bytes showing  properly but after that it shows garbage values.

i have attached the vi. along with message. please help me.

Deployment Real Time + FPGAs without Labview

$
0
0

Hello!

 

I have a system consisting of PXIe 8101, PXIe 7971R and PXIe 7846R - that is one real time computer and two FPGAs. The development is done in the office and the target machine is in the lab. On the target machine's host computer, there is no Labview development environment installed. In the end, I would like to deploy my project to the target system using a few clicks; in the future, there will be even more target systems.

 

So far, I read that deployment is possible using MAX,  the System Configuration VIs and RAD.

 

Somehow, I am a bit confused about how to do it properly.

 

1) When building on my local machine, the CDF file for MAX is created in some National Instruments folder. How to bring everything properly to the host computer in the lab?

2) When using RAD, an image is created from an existing hardware and somehow temp files, log files and whatnot is included (unless I use a blacklist). In this scenario, I cannot simply hit the build button in Labview and have new files. First, I would need to bring it onto my development RT system and can then create a new image using RAD.

 

The best would be to have a build specification for something in Labview that creates an Updater Exe (with Installer) for Windows. This I would distribute to all host machines out there and somebody hits the install button, selects the RT machine (and FPGAs) and everything is updated there.

 

Can you help me out with ideas here?


Thanks,

 

Florian

Webcam lagging + DashBoard app

$
0
0

Hi, my name is Travor and i would like to ask you for help. 

I conneted my webcam (microsoft lifecam HD-3000) to myRio. Camera works fine, but after i´ll put it into block diagram and run it, it will start lagging. Maybe with some really small resolution, like 160x120 it works +/-  fine.
I´m running this program (see picture below) and i´m not sure if i did some mistake in it , or where is the problem. Because in MAX, when i´ll run a test, camera works without lagging even in higher resolutions like 640x480 etc. And my rio is showing CPU use about 20-30%..I´m not sure if its ok that this webcam can work only on that small resolution or i did´t do something to make it work properly. And, power supply is normal, from NI adapter. 

 

Second question if i may, is there any way how to put this live-stream video from webcam into DashBoard app?. I could´t find any manuals for that. 

 

Thank you for any help, I appreciate it,  Trevor. 

Multiple (separate) call of non-reentrant VI's

$
0
0

Hi

I have made a VISCA camera driver that automatically tracks objects. This driver uses TCP/IP and it all i based on writing a command, and waiting for a reply. Initially the system was designed to track only one object, but it now expanded to 7 cameras.

 

Since the system is waiting for a reply for each camera, i had to make all the vI's "preallocated clone for reentrant execution" since each camera has to send commands as fast as possible and not wait for the VI to be available for the next camera driver.

 

Below is a simple setup of my VI's:

 

TCP driver
	if Auto{	
		while(no error){
			// Get current position
			Write request position
			Read position, wait for data to arrive
			// Controller
			Control system
			// Update Position
			Write new position
			Read reply
			}
	}
	else if Manual{
		Write request position
		Read position, wait for data to arrive
		Write new manual position
		Read reply
	}

My question is: Is it possible to run the system without setting all the VI's to reentrant? and still run them without sharing the code? I want the main driver VI to allocate only one memory space for the subVI's, not a memory space for all of my calls.

 

The problem with setting all of the VI's to reentrant is first that i call them many more times than in my example and it will generate a lot of extra memory allocation. Also, i sometimes forget *blush* to set some new VI's to be reentrant, which of course makes my system run slower...

Set Zero

$
0
0

Hello,

 

At the moment i am putting values of a force sensor in a graph.

When i am going to use the sensor the start value should be set to zero so that i know how much force is applied.

Does anybody know a function for setting the current value to zero?

 

 

kind regards,

Jan


LIFA 2 or more analog inputs.

$
0
0

Hello!

I want to make an interface in LabView using Arduino. I am using LIFA but i heard that is no longer supported since 2014 or something like that and LINX now is used. 

If a test a single analog sensor (LM35-for temperature) is all good. When i add another one (in my case, pulse sensor) the interface is showing me the results but not the way i wanted. The temperature is constant, real but jumps 20 degrees then return to the real value, all real quickly. In my project, which is in 2 months i would like to have another one. (3 analog sensors). Is it possible to work, in the end with LIFA? And if not LIFA, with LINX can i read all 3 sensors in real time?

Thank you!

 

Labview random serial port Error -1073807339 VISA Read Timeout ARDUINO communication

$
0
0

Hi there,

 

this is my first post in this forum, as I looked to find a solution but reached a point where I really dont know what to try next. I attached three different files.

  • Arduino_code.txt            The code running on the Arduino and printing to the serial port
  • Arduino_standalone.vi     Arduino serial read VI as a standalone (works perfectly fine)
  • Arduino_as_subVI.vi        Arduino serial read VI as a subVI (crashes after 2-5 minutes)

Setup description:

I use LabVIEW and a cDAQ device to capture some data. I also control various pieces of hardware through LabVIEW via serial connection. That all works fine via LabVIEW using a single main VI and multiple subVIs. Additionally I want to capture some data with some sensors powered and controlled by an Arduino. The Arduino then prints to the serial port and I use LabVIEW to read the data from the serial Port.

 

Problem description:

The Arduino prints to the serial port the data (basically every 56microseconds). Every time the loop finishes printing the data ("X1,Y1,Z1, ... , \r\n) a linefeed (\r\n) is send at the end. First I made a VI to just test the functionality of reading in the data independent of the main VI. This VI works perfectly fine (even though its running a bit slow (4ms execution time for the while loop) and I let it run for a few hours capturing data with no problems. I then ammended this VI to work in the main VI. This requiered the following changes:

  • An error in/out is wired in
  • The data is not written directly to a file but put in a queue to process somewhere else

When I start the main VI everything starts fine in the subVI (COM port is initialized and the VISA Read function starts reading in the data correctly and adding it to the queue, the loop also executes every 4ms). However, after 2-5 minutes (this seems to be random) an error occurs at the VISA Read function (Error -1073807339 VISA Read Timeout) and it stops reading in data. I tried to reinitilaze the serial port once this error occurs automatically... then it will work fine again for a couple of minutes, but I loose some data as the reinitilazation takes place and eventually the error happens again. I removed the queue in this version to see whether this has any effect but the failure occurs as well. I slowed down the loop to 100ms to investigate if the failure still occurs and it does (though maybe a bit later). I referred to the error description here: https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019L3mSAE&l=en-GB but I could not find a solution as my connection works in the beginning and then the error occurs at some point randomly. But as I mentioned before, this only happens if I use it as a subVI. The rest of the main Vi and subVIs continues to work perfectly fine. I wonder what it could be, as this problem only occurs if running this as a subVI in combination with the main VI? Is this maybe a problem with not having enough memory (but windows Task manager shows only 20% of CPU is used)? Or could it be that a buffer overflows?

 

Also, this is another question, but is there a solution to let the LabVIEW while loop run faster so I could capture the data at a higher rate?

 

Kind regards and thank you for your help in advance

myRIO FPGA LUTs resources

$
0
0

Hi,

 

I had some code and I run out of resources when I tried to flash it in a myRIO 1900. After that, I literally flashed an empty .vi and these are the compilation results:

 

image.png

 

Anybody knows why is this happening? 47,5% of Slice LUTs seems a lot for an empty .vi.

Is there any extra functionality that I can deactivate to reduce this utilization? 

How to find the index of a changed array control

$
0
0

Hello, I have a array control on my front panel containing switches. Once one of the switches is flipped I would like to find the array index of said switch, along with the value. ( I am using an event structure to coordinate this)

I am using this to send on/off events to my GOOP "DAQ object".

Any insight or examples would be greatly appreciated.

Open and display XML contents

$
0
0

Hello!

I've attached a simple VI which I expect to open a display the contents of an XML file. I put a probe on the output of Build Path Icon, and a second probe on the output of Read From XML File. The VI runs, but, within the probe watch window, the value is just "" . I read the detailed help on Read From XML File, and I see that the XML file must be formatted in the LabVIEW XML schema. I'm sure my file does not conform to the schema. The test.xml file is an ouput from a different, separate VI. I cannot alter the schema of test.xml as it has been in use for a very long time. What do I need to do to read the test.xml?  Thank you for assisting me!!  -  John

 

The test xml file is a Word doc, but has an XML format. This XML format has been altered by the conversion process; converting it from an XML to a word doc.

LabVIEW FULL 2016

Locate "Standard" LabView VIs?

$
0
0

I have a legacy project that I am trying to debug, and I am new to LabVIEW. The project contains a number of custom VIs, but also uses a few VIs that I believe are "standard" library VIs. When I open the project, its asking me for the location of these standard VIs. However, a search of my hard drive doesn't locate these. One example is "niSwitch Send Software Trigger.vi". Is there an additional library or something I need to download for these?

GUI LED or boolean indicator design

$
0
0

Are there any LED or boolean indicator design besides those come with the system? I just don't like the highlight on provided LED design. Are there any plugin with additional LED design such as some color gradient design or some transition of color. I am trying to find a LED with more bright on the edge and darker in the middle.

Just something like the attached PNG file. 


Combo Box Mouse Wheel Scoll

$
0
0

Hello Community,

 

I am using Labview 2016 32-bit

 

When I scroll the mouse wheel on the combo box, it scrolls through all the values. When I click the dropdown arrow and my populated values appear, the mouse wheel scroll does not work. How can I scroll through the values in the dropdown list?

 

Any help would be greatly appreciated.

 

Thank you

Array, signal post processing

$
0
0

Hi Everyone

i have 3 signals

1) GMR SENSOR signal (white colour pulse in image below)

2) encoder A pulse (720 ppr) (green colour)

3) encoder z index                 (red colour)

i have attached image of my signals below,

my problem is how to count number of encoder A (green color)signal pulses from 1st rising edge of GMR sensor signal(white color) to next rising edge?

one solution might be

as Encoder A and GMR sensor output maximum value = 4

so i moved data from excel to array in labview (file is attached below)

 then GMR sensor signal( array) value greater than 2 or 3 gives boolean indicator 

same for  Encoder A signal( array) value greater than 2 or 3 gives boolean indicator 

then how can i use this T/F boolean indicator to count number of encoder A signal pulses from 1st rising edge of GMR sensor signal to next rising edge?

Converting measurement in current to other units in LabVIEW NXG

$
0
0

Please I have a challenge on how to convert unit in current to other units such as pH, psi, uS, and gpm in LabVIEW NXG. Please how can I go about it.

Database Connectivity Toolkit 32-Bit only?

$
0
0

I get this message when attempting to install the Database connectivity toolkit which is "included" in LabVIEW professional.  Do I really have to switch over to 32-bit just for this one toolkit?

 

Thanks folks!

 

Window listener

$
0
0

I am launching and controlling an app through keyboard commands, and I need to wait until a window appears, to repeat the process.

I know I can wait until a process ends, but I need to launch windows without closing the previous.

Can anyone please help me?

Any help will be greatly appreciated.

Viewing all 66881 articles
Browse latest View live


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