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

System Exec VI and CANBus

$
0
0

Hi guys, 

I have a problem in System Exec vi and would be appreciated if anyone can suggest a solution. 

So I use SystemExec vi to load an application called CANopenshell.exe and send a command over a CAN a line. My problem is, the command gets repeatedly sent until I close the terminal manually! Is any  one able to tell why that happens? Command has been given as Standard Input. Please see attached images, as you'd see that, the output, "Write PDO......etc" section has been repeated many times. 

Also, how would I be able to send commands one by one ? 

(Sorry, I had to take some data/parameters off)

Thanks in advance.

 

Capture1.JPGCapture2.JPG

 


Drag and Drop Listbox

$
0
0

Hello

I have written a small vi that assembles text file which I use in other places in my application.

It works fine, but I would like to use drag and drop is this possible,  and if so how do I do it?

Once I have generated my string, - can be seen in upper panel I wold like to be able to drag that into my list box. Ideally I would like to replace the 'insert' 'append' and 'delete' buttons (for the delete button I would create a 'trash' icon that I could drag the list box entry to.

I have attached my vi and associated text support file.

Many thanks

Lee

 

Slow Front Panel update with Call Library Function Node (Pico USB TC-08) in Run in UI thread

$
0
0

Hello, good people!

 

This is my first post on this site.

I'm using LabView 2015. I have a Pico USB TC-08 which I use in LabVIEW to get 4 thermocouple temperature readings that I use to control a system. I have provided a minimal working example (MWE) which only does the temperature reading, and a snippet of the slow part below (It is not working without a Pico USB TC-08, i guess, but i cannot make an example that runs without it without removing the relevant stuff). The code was provided by Pico but has been commented and tidied up by me. My problem is that the front panel is lagging such that when I scroll or enter values in controls, it takes about half a second before the action is registered / shown on my screen. This incidentally coincides with the time taken by one iteration of the temperature measurement loop.

 

From what I have found on the internet so far, my hypothesis is that the temperature reading, which is done through a Call Library Function Node and the function usbtc08.dll:usb_tc08_get_single, is using all the capacity of the UI thread. This node takes about half a second to get temperatures and then starts over, and in the transition between each acquisition, I think the UI thread is free to update the front panel (adding a 10 second wait inside the while loop makes the front panel lag for half a second every 10 seconds and responding nicely in between).

 

Some people online suggest changing the node properties to "Run in any thread", but then i only get 0's in all the temperature measurements. I need the temperature measurements to run as quickly as possible. My question(s) is(are) therefore:

 

Can I make the front panel update run in another thread?

Can I make the node work with "Run in any thread"? I have seen something about calling a VI with an "Invoke Node" vs calling a VI with a "Call by Reference Node" which might be worth checking out but I know nothing about these threads and the DLL-stuff.

 

Can anyone help - it would be much appreciated!

 

Magnus

 

MWE.PNG

Waveform data length not correct

$
0
0

Dear All,

 

I need to develop an application that logs snippets of signal/waveform.
Meaning, for every y period of time, log signal/waveform during an x period of time.

For this end, I have developed an app that goes through the following steps:

  • Simulate and log a sine waveform with a specific dt, t0 and Number of Samples.
  • Compute and Monitor timing to detect multiples of period y.
  • When period y, start logging waveform. Stop when k*y+x period is achieved.
  • repeat until period Number of Samples*dt is achieved.

The problem is that when I check the TDMS Log file, I can clearly see that lengths of the channels (original signal, snippet signal) are not what I was expecting.

Though the Y components of the signals are correct, the waveforms logged yielded channels with lots of additional values..

 

Can you please explain why is that? and Should I log the Y component instead?

The VI is attached.

 

Thanks!

Writing a .fcs file

$
0
0

I am trying to convert a TDMS file to a .fcs file, which is used in flow cytometry.
I am having trouble implementing this in LabVIEW, my main confusion is due to data types:

I have a 2D array of DOUBLEs, which I get from the TDMS file. According to the specifications, data in a .fcs file can be stored in multiple ways, including as "unsigned binary integers" and doubles (see page 14).

I am writing the HEADER and TEXT segment to a binary file as strings, which should be fine.

But how do I  write the 2D array?

Ideally I want the datatype in the file to be DOUBLE, which I can specify by setting the keyword '$DATATYPE' to the value 'D'. Does this mean I can just wire the 2D array into the "data" port of the "Write to binary file"-subvi? Surely not, since the array will also write some array specific delimiters which will corrupt the bit stream of my data to give 'ghost values'.

In the attached vi, I rearrange the 2D array into a 1D array, by appending the rows of the array one after the other. Then I type cast this into a string, which gives me a pure ASCII qword (64 bits) for each number. Is this how it should be done? I've reached the llimit of my interpretation of the documentation (in the link above) and can still not get my files to be recognised by file readers (such as this one).

Kind Regards

Interfacing Logitech G920 dll

$
0
0

Hello guys,

I have been tring to interface the logitech dll by reading the sdk, but it has always been a challenge for me to adapt data types, can you help me for the 2 in the pictures for exemple ? 

At the end of the project I intend to post a full library to drive the logitech wheels.

 

Update : I tried the generation wizard, it is doing almost the same things as I do but still no result (I try the is connected at index 0, always false/0)

 

Regards

Can I do triggering and manual control simultaneously on one card?

$
0
0

I have a PCIe 6323 and can I generate triggering output on, say ao0, while setting up a GUI for, say ao1, for users to manually set a constant output on ao1?

Temperature control at a fixed point

$
0
0

Hi,

 

I am very new in Labview. I need to control temperature at a fixed point by Agilent 3436 series DC power source, and want to log the data using Agilent 34970 . 

 

I could see data and extract and average temperature using a Agilent 34970 Data recorder.

 

But I could not use PID controller from Average data to back to heater with PID tool kit.

 

I am attaching my data.

 

Could you pleas give me details that is helpful for us.

 

thanks,

Masuma


2nd, or 4th order filter

$
0
0

Hello!

 

I am attempting to low-pass filter some force data. I have set up what I believe to be 4th order, zero phase shift filter (via a 2nd order recursive filter). However, there seems to be much debate on the accuracy of my code. Some people seemingly believe that my code equates to a 2nd order filter. They believe that within the butterworth code in LabVIEW, it "controls" this somehow. 

 

Thoughts on my code and whether it is or is not a 4th order zero phase shift? Do you have sources for your thoughts? Trying to get this right, but I need sources to convince my boss (my PhD adviser). 

 

Thanks! 

 

ps  - my first post!!!  

Lab View DAQmx Calibration

$
0
0

Hi everyone, hope you all don't mind if I ask a quick question here.

 

I am conducting a project as part of my final year at university, and as part of the project I have to create code using LabVIEW wherein pressure will be displayed as an output on a chart from the pressure sensing equipment I have set up. I have written the code and created a task using the DAQ assist where a voltage is read from my pressure sensor and is automatically converted to Pascals through adjustments I have made to the scaling.

 

I am however having trouble with the calibration of my task. I have been using the tutorial shown in the link below to attempt to work my way through the process however I am finding that the explanations are too general for me to understand because this is my first experience using the software.

 

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P80ZSAS

 

Specifically the questions I have relating to the process are as follows:

 

The first question is in relation to part 5 of the tutorial linked above. Are the samples to be averaged and the rate just the same settings as those I have chosen in my timing settings? If not what do I base these figures off of?

 

My next question is in relation to part 7 of the linked tutorial. When selecting a reference value in relation to the uncalibrated value, should I be selecting reference values that coincide with the maximum and minimum readable values of the pressure sensor or base the reference values off of another baseline?

 

 

I can offer more information on my setup if it is needed. I do apologise for troubling you all with my questions and any help or pointers anyone can offer will be greatly appreciated.

 

Thanks,

 

Corey McPhail

web module in NXG requires new license

$
0
0

I just installed NXG 2.0 to get to know it and start with webVIs. However, I can't get the Web module activated with my pretty comprehensive license. Is it really a seperate option now that must be purchased seperately?? What a disappointment :-(

Building an Application involving the Database Connectivity Toolkit

$
0
0

Hello all,

 

I hope this is a really stupid question.  I've built an application that writes data to an access database that resides on the company network.  The .udl file sits in the same folder as the database (on the network).  The path reference for the .udl file, goes all the way back to the root server (ex. \\Servername\folder\subfolder\dbconnect.udl) so that path should work on any computer on the network (as long as the user has the proper permissions).  The .exe works on my development system, but when it has been installed on any other computer, the data is not written to the database.  Another odd behavior is that the application will not throw an error.  Any help at all would be appreciated.  I'm running windows 10 64bit, LabVIEW 2016 32bit. 

 

Regards,

Mike

Embedding Xilinx System Generator in Labview FPGA

$
0
0

Hi, 

 

There is an old paper titled "Integrating a Model from Xilinx SystemGenerator for DSP into LabVIEW FPGA". It says that Xilinx System Generator should be configured to produce an .ngc file. In Vivado System Generator this option is no longer available. How can it be done with the latest tools? Is there an updated version of the paper?

 

Kind regards, 

Ivan  

 

Load all website

$
0
0
Hello !
Tell me, please, how can I get the height of the columns?
If you open the chrome (PKM> look at the code (ctrl + shift + I)), then the height of the columns can be seen. (see 333.jpg)
But in labview I can not get this data.

Tried:
HTTP Client -> Get
DataSocket Read
But with the help of these two methods I get what in the chrome (PCM> view the page code (ctrl + U))

Thanks for any help!

Sending an external trigger to LabView

$
0
0

Dear all,

I'm quite new to LabView and I hope my question is not answered elsewhere, but I didn't find much.

 

I have a VI that does something in a loop, will receive an external (TTL) trigger and then breaks the loop. This is not a time-critical step and it doesn't matter whether it takes 10ms or 1s. Is there a (simple) way of implementing this on a PC without additional hardware required?

 

~


how to prevent automatic insertion of synchronization registers in LabVIEW FPGA?

$
0
0

Hi,

 

my hardware is a FlexRIO 7962R card and a NI6581B adapter module.

On the FPGA a custom made CLIP is running using 2 different clock domains (100MHz and 25MHz). The toplevel clock of the LabVIEW FPGA VI is 40MHz.

 

The I/O nodes of the CLIP shall have a straight connection to the I/O nodes of the adapter module. When synthesis is finished, I'm always getting timing violations and it looks like LabVIEW FPGA automatically inserts synchronization registers between the CLIP I/O nodes and the adapter module I/O nodes that are causing those violations. The connections between the CLIP and the adapter module are made in the wiring diagram of the LabVIEW FPGA VI (it's a wire from the adapter module I/O node to the CLIP I/O node, enclosed by a while loop).

 

How do I disable the timing between the CLIP and the adapter module (similar to set_false_path -from CLIP -to adapterModule)? The signals that are read/written from/to the adapter module are asynchronous. The CLIP is taking care of proper synchronization of those signals.

 

Thanks for any advice.

 

Regards,

 

Ralf

Labview 17

$
0
0

Hi I am trying to connect a TDK Lambda GEN150-10 power supply to my pc via LAN cable so I can control it through a Lab view program I have. I seem to be getting a -1074001908 error in the initialize sub VI and don't know how I can solve it...any suggestions?

Maxon motor Control using an ESCON 70/10 controller and an NI USB X

$
0
0

Hello,

 

I have a EC 60 motor and a motor controller ESCON 70/10. I want to control the speed and the direction of the motor using labview and a NI USB-6212. How can I do this?  I am new to LabView and also to motors.

 

I think that I can connect a potentiometer to NI USB in an Analog IN pin and if I rotate the potentiometer to right the motor will go to right and so the other way. I used a potentiometer to control the led's brightness and setted a minimum of 5V and a maximum of 5V voltage. How can I send this to the ESCON controller, also from analog pins? Like DAQ Analog output and ESCON to Analog input.

 

For speed control i thought that I can use an Encoder to produce a pulse in terms of Frequency and change the Duty Cycle.

 

Do you have any tips on how can I create the VI's? 

 

Thank you

Client for Network Published SharedVariable

$
0
0

I have a simple requirement where i need to share some variables across a WLAN.  One Host -PC on the WLAN will be deploying a few variables and another PC on the same WLAN needs to function as a Client and read the variables. 

 

Using the HELP topics i have been able to create the Project to deploy the Variables - but i have no idea how to refer to these variables in the Client so that it can read them. 

 

Would be thankful if this can be outlined or even if a simple example exists , a link to it ?? 

 

I have attached the basic Host which i created. 

number presentation

$
0
0

Hi everyone

currently i'm working on a project with a high measurement resolution , and i'm facing an issue that labview does not take in consideration all of the digits. i changed the indicator representation to extend precision but nothing changed. here's an exemple , when the measuremet is 512,0029875 the labview take only 512.003 , is there a solution to manipulate all of the digits?? thnks 

Viewing all 69213 articles
Browse latest View live


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