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

Deadband Zone in tank control

$
0
0

I am trying to create a deadband zone(maybe stability zone is correct terminology) that the output will enter into the zone and hold the valve(keep it from moving) until the PV goes either above or below the zone. Once the PV goes beyond the zone, either above or below, I want the valve to kick back on to bring it back into the zone, and hold again. Basically, I do not want to wear the valve out by constantly keeping it adjusting to the SP. By holding the valve in this zone, I want to be able to extend the life of the valve over time.


DAQMX task ID with local variables?

$
0
0

Hi folks,

 

Long time Labview programmer (although I don't do consumer/producer)... new to DAQMX.

 

I've been able to test out my new myDAQ by writing a vi that sets up AO (transmit a frequency pulse out to a speaker); and AI (receive the reflection of the pulse thru a microphone). And, I can use a while loop to repeat the AO & AI without having to reconfigure the AO & AI each time (the two Task IDs are looped through shift registers).

 

But, I'd like to now build my application with labview "states" (cases within a while loop). So, I'd like the AO/AI config in one state and the AO/AI start/execution/stop in a different state. It's hanging up in the very first wait for AO completion (start/execute/stop state)... I don't why or how to resolve this... can you help? I'm suspecting that I'm not handling the Task IDs correctly.

 

I've tried putting the TASK ID OUT into an indicator in the config state and using it's local variable in the start/execute/stop state. That doesn't work.

 

So, I just tried putting shift registers in all of my states and passing the Task IDs through those shift registers. Same problem. Stumped!

 

Richard

 

What am I missing here???

Organization of Variant Attributes

$
0
0

LV2013, Win7

 

I'm using a VARIANT to represent a function call from a script engine to an add-on.

In other words, you write an add-on in a certain format and put it into a certain folder.

My host program can see it, and attach it, and then there are certain facilities available.

Your addon can register a function, with parameters, and the host's script engine can call that function, supplying parameters, and your addon will execute your function and return a value.

 

The VARIANT seems a perfect fit for this: it has a TYPE, and can carry parameters as attributes, each having a separate type.

 

I've discovered that attributes seem to have TWO names.  The External name, supplied separately when you SET ATTRIBUTE, and an internal name, taken from the label of the value you supply to SET ATTRIBUTE.

This pic shows this:

Case 1.PNG

 

The NAME VI above uses the TYPE DESCRIPTOR of a variant and extracts the name embedded in that.  As you can see, each attribute has TWO names.  

My scheme needs to use the internals, because I need to deliver the parameters in the expected data type: u8, I32, Enum, whatever.  If your addon specifies a U16, then you get a U16 - no conversions necessary.

 

All of that works OK.

What I don't understand though, is this:

Case 2.PNG

 

Notice the EXTERNAL name of the first attribute is changed to "BAttr 1".

Also notice that the names come out in REVERSE ORDER!

I assume that LV or Windows or somebody is alphabetizing the attributes.

 

It would be easier and more efficient for me if the attributes came back in the order that I put them in, regardless of alphabetic order.

 

1... Is that possible?

2... Why are there TWO names for each attribute?

3... What is the purpose of alphabetizing the attributes?  Maybe a dictionary search?

 

Architecture for running VI's based on a method "script" file

$
0
0

My goal is to load text files that basically contain what amounts to a stepwise script (step 1, step 2, etc...) and have my application essentially perform each operation accordingly. I've done some brief preliminary thinking on how to implement this and while I'm confident I can pull it off, I'm not happy with the "elegance" of it and I'm positive someone (or many people) has already come up with something better. I can't come up with the right search terms to find this myself.

 

Can anyone point me in the direction of a good example or discussion on this sort of implementation?

 

5105 Multiple Sessions possible in one application?

$
0
0

Is it possible to group the channels on a PCIe-5105 so one group has one trigger and the other group has a separate independent trigger? Looking at IVI in MAX, it appears possible to create separate logical driver sessions with different groups of channels and different triggers, but I don't know if both logical driver sessions can be opened at the same time on one card in one application, and have them operate independently.

Zoom factor property in picture indicators

$
0
0

Hi everyone,

 

Does increasing image size (in pixels) using the zoom factor property note affect the clarity of the image. I was just yesterday acquainted with Raster and Vector Graphic Images and effect of image scaling on them.

 

I need to rescale images in my application without affecting clarity, and also being reasonably fast (image size 2592 * 1944 pixels (2 MB approx.)) like 3-4 seconds maximum. Is it possible to do that in labview. I am currently displaying images using simple picture indicators.

 

Is it worth giving a try? Any suggestions would be helpful. I am currently using labview 8.5 evaluation without any image processing toolbox.

 

 

 

 

 

 

 

 

 

 

Remainder

$
0
0

Hey Everyone! Can you please tell me what is the purpose of a remainder. Like, why do we use it? What do we get from it?

 

Thanks

 

Data logging of multiple standalone usb instruments

$
0
0

Hi All,

 

I'm new to LabView and looking for example code for data logging of multiple standalone usb instruments. There are examples for single instruments but I can't seem to find example code where multiple instruments are used. For my application I was envisaging logging data from multiple instruments in a test environment (e.g. Lake Shore 336, Agilent N8731A, Keysight 34461A, Tektronix PA3000 etc) at say 1 sec intervals. I was thinking of connecting the standalone instruments via a USB hub into a PC running labview. Most instruments we're using appear to have LV VIs available. If anyone has developed a similar application or can point me to some examples to assist me that would be great!

 

Thanks in advance.


Hiding the curve on XY plot

$
0
0

Hi all,

 

I have drawn a simple XY plot (positive portion of the function y=x^2) on LabView2014. I have attached a screenshot of the graph here.

 

I wanted to add a checkbox in the graph area so that as the program is running and the curve is being plotted, when I tick the box, the curve disappears (but continues drawing in the background). Unticking it should show the curve again. 

 

Any help (ASAP) would be greatly appreciated. Many Thanks in advance.

Closing windows command line using libraries

$
0
0

Hi there!

Im making a project that runs a executable using the windows command line. I have managed to open the command line from LabView and im able to run the executable correctly. The problem is that I want to close the command line automatically after a time when it opens. So Im trying to use "call library function node" with user32.dll library and FindWindow() and DestroyWindow() functions, because I think that I have to use this functions. Does someone know how to close the command line after a time? is it posible? am I using the correct functions?

Help please!

Labview 16.0 sudden slow down

$
0
0

Hi, I am currently running a co-simulation for control of a microgrid using Labview 16.0. 

I am experiencing sudden slow down of the labview software. It basically takes way too much time to edit anything and to run co-simulations. 

It takes about 30mins to run a 0.05s co-simulation atm. The frustrating thing here that it was working fine until yesterday and I have not changed anything.  I have to admit that my VI is very large in size and it takes a lot of time anyways, but I have also tried running other VIs that usually take no time at all, but they also took very long time. 

I figured it would be some sort of computer issue, so I checked for virus and tried optimizing the memory, but still no luck. 

Is it possible that some settings might have changed on labview? any suggestions on making it a little fatser? 

date 10days missing

$
0
0

Hello,

in the attached after convering the date are 10 days missing, but anything else is right. See attached.

Thanks!

OpalRT's OP5600 with LabVIEW.

$
0
0

Hello,

Has anybody tried to connect OpalRT system with LabVIEW? RT-Lab does not support clusters.!! I am trying to deploy a LabVIEW executable on OP5600 which runs on Redhat Real time. OP5600 system is programmed with simulink modelling. How to exchange data between LabVIEW & OP5600 ? I am stuck. Smiley Sad

 

Many thanks,

-Amith

Notifier communication, exit program

$
0
0

Perphaps more an item for in the feature request section.

What I like about notifiers is that you don't have to connect wires. Making the program less cluttered. But it seems that you do have to connect the error wire to the second notifier to stop the loop. In the example below both 'wait on notification' blocks receive the updated number. But when the notifier is released only the left loop is stopped. Why does the right loop generate any error?

 

 

notifier.png

OpenVPN Startup is killed by CRIO

$
0
0

Hi,

I'm turning arround for few day now, and I don't now why my Crio 9067 kills my startupscript.

I'm using Labview 2015 and I define to start  openvpn at the startup with:
update-rc.d openvpn defaults

It's working nice. But seconds after my connection with the server is lost?!?

If I launch openvpn manually with:

openvpn --config ****.conf

it's not working in background, but my connection with the server is maintained.

 

It seems that the rtstartup.exe or another script is killing my connection.. someone can help me?

(I already format my CRIO.. 2 times)


define coordinate of receiving data - display the position -intensity graph

$
0
0

Hi Everyone, 

 

i'm just wondering how i can define the correct position of streaming data over intensity graph. 

 

i have a hardware design contain from shift register and  Multiplexer (2x2). wired to 10 rows and 16 columns sensor sheet (force sensors) 

 

the 16 columns connected to shift registers and the rows connected to Multiplexers. 

 

i defined the pins of each of them, connected  to the sensor sheet and started streaming data from analogue pin (P0) arduino uno

 

i programmed my Arduino UNO to receive all the data from those sensor from only one pin. 

 

i'm displaying all this data over intensity graph, using serial visa. 

 

when i'm displaying the data, the intensity graph display it in the whole range of it, i'm trying to make those data display in similar location of the sensor (assuming if i pressed over those sensor in location Row3 Column2), I'd like to display on intensity in same location/coordinates. but that's not happening with me. 

 

you can see that there's something over intensity graph, but you can't detect the location. 

 

more general, I'm placing my hand over the force sensors, and I'm trying to display my hand over the intensity graph, but till now i couldn't manage that. 

 

i really want help with this. i did Core1 and Core2 courses, and still need more to learn but i'm trying my best. 

 

please check the data that i received over arduino serial monitor.

 

i attached two pictures, the one called Hand, is what i'm looking for

and the second one is what i'm receiving Smiley Sad 

 

looking forward any help

 

 

 

 

Regards,

 

any suggesting !!!!!!! 

2D, 1 column array to a 1D array?

$
0
0

Is there any easy way to do this? I can envision a way to do it by using loops, but that seems unnecessary. Maybe a way to transpose 2D array and convert?

 

Thanks

eeg trigger through usb ttl module

$
0
0

I need to send a trigger during eeg data acquisition. The eeg PC is connected to a laptop where LabView is installed. The laptop does not have a parallel port, therefore I am using a USB TTL Module to connect the two PCs.

I am wondering whether there is a way of sending a trigger from LabView through the USB module, as I do not have any DAQ devices...I have also tried using the VISA VI but it does not work (or maybe I am not writing correctly the buffer). Is there anybody able to help?

thanks in advance!

 

Flavia 

Problem with Shared Variable Engine after Windows Update from June 13th 2017

$
0
0

We are running an OPC-Client/Server set-up on our lab computer using the NI-OPC-Client VI and Beckhoff PLC as OPC server on LabVIEW 2014 SP1 and latest patch. This had been working without issues till the Windows 10 Update from 13th June.  After the update of windows 10 (KB4022725) the computer in the lab is facing issues namely:

  1. Local shared variables are not being displayed under the process names in the distributed system manager. Even though the NI Tagging Service is running.
  2. NI-OPC-UA-Client.lvlib: Connect.vi is giving an error within our LabVIEW program. The error – 356629 is being shown with comment “an operating system resource is not available” (Hex0xFFFA8EEB). We are noticing that the VI is not executing properly and hence our code to communicate with the OPC server (Beckhoff PLC) is not executing either.

Another point we have noted is that the same code is working properly when run from a laptop also running windows 10 with same updates.

Following are the characteristics of the desktop in the lab and the laptop:

Desktop:

  • Intel Xeon, W3550 @ 3.07 hz 3.06 Ghz
  • RAM 8 GB
  • 64 bit OS with x64 Processor
  • Data Acquisition Devices connected: PXIe -4357,6363
  • Windows 10 enterprise with update KB4022725

 

Laptop:

  • Intel Core, 15-6300 2.4 Ghz
  • RAM GB
  • 64 bit OS with x64 Processor
  • Windows 10 Home

 

Anyone having similar issues after the updates or has tips to solve the problem ??

 

Thanks and best wishes from Offenburg, Germany

Using System Configuration API to Differentiate Network Cards?

$
0
0

I've got a PXI chassis with 3 network cards in it.  I want to configure their IP addresses using the System Configuration API.  My problem is that I can't seem to find a property that I can use to distinguish between them.  I can pull their MAC Addresses, but that won't help because I'm deploying to several PXI and each set of cards gets different addresses.  I was hoping to pull Serial Number, Product Name, or even slot number so I could tell which card was which (I have an 8110 controller, 6682 timing card, and an 8231), but that property doesn't seem to be supported for Network Adapters.

 

Anyone have an idea what property I could pull instead?  Or another method would be fine too, I just need to set their IP addresses to the card in the right slot.  I've tried doing this with RAD too, but it doesn't seem to be able to tell the cards apart either, and sometimes switches the static IP addresses on deployment.

Viewing all 69515 articles
Browse latest View live