Is there a sizeof() vi in labview?

I would like to get the size (in bytes) of various labview data types. Is there i vi which will do this? I can't find one. It seems flatten to string followed by string length does the job, but its a of shame having to create a string just for this...
Ian

pawel wrote:
I think, that the proper way is to use "TypeCast" function, located in "advanced->datamanipulation". That will not add any extra elements to the flattened structure.
Hi Pawel !
That works...except if you try to wire a cluster containing a string !
CC
Chilly Charly    (aka CC)
         E-List Master - Kudos glutton - Press the yellow button on the left...        

Similar Messages

  • How to take the screen shot of my computer page by using Labview.... is there any funtions available in Labview?

    How to take the screen shot of my computer page by using Labview.... is there any funtions available in Labview?

    Another thread about this theme.
    Waldemar
    Using 7.1.1, 8.5.1, 8.6.1, 2009 on XP and RT
    Don't forget to give Kudos to good answers and/or questions

  • Is there compatible motion driver for LabVIEW 8.6?

    Is there compatible motion driver for LabVIEW 8.6? The latest motion driver seems to be 7.6 and it only support up to LabVIEW 8.5...

    If you buy LabVIEW 8.6, you will also get 2008 August Driver CD.
    NI-Motion 7.7 driver should be included in it.
    Or you can wait for a while.
    I guess NI will put on Web these days.

  • Is there a way to interface Labview Web GUI with Fusion Charts?

    Is there a way to interface Labview Web GUI with Fusion Charts for dynamic web presentation?
    http://www.fusioncharts.com/

    I have a ballistics program which our clients can use (see attached).  Basically there is a series of Cascading Combo boxes that the user must select for Bullet Manufacturer, Caliber, and Bullet ID.  The program then goes out to the relevant data file (.CSV) and provides ballistic inputs for the selected projectile.  The user is also required to enter in additional data, such as Sight Height, LOS Range, Temp, etc..  Once all data is input, the user either hits the Calculate Button or the Tab (I'm using Event Structures and I now realize this is an issue for Web UI Builder), and the data gets passed to a MathScript which then crunches numbers and spits output to fill a table and a series of Graphs based upon the tablulated data (if so desired).
    I was hoping to use Labivew for the first two parts ( Data Collection and Number Crunching) and use something like Fusion Charts for the presentation.  I tried learning Ruby on Rails.  I was successful with the Ruby part (basically the Mathscript portion) but really got hung up on the Rails section and the need for something like JSON to interface with it.  Could not find a useful source of information which really showed you how to combine the two effectively. 
    Attachments:
    Ballistics1.JPG ‏144 KB
    Ballistics2.JPG ‏265 KB

  • Getting the Sizeof Clusters in LabVIEW

    I need to fill a series of different clusters with data from a byte array.   Ideally, I would like one function that would work for different cluster typedefs.   To do that, I created a VI that takes in a general cluster reference and loops thru the cluster elements, getting the size of each element and reading that number of bytes from the byte array, then using those bytes to set the cluster element's value.  To make this work, I need to know the sizeof each cluster element.
    Other discussion forum threads on sizeof said to flatten the control's value (which is a variant) to a string, then get the flattened string's length to get the sizeof the control. The problem is that the string created by flattening a variant contains a bunch of header info whose length and complexity depends on the data type of the control.  I have figured out how long the flattened string header info is for numeric types and array types, but not for other data types.
    I have data types such as strings, arrays, clusters, and arrays of clusters within the cluster I am trying to fill from the byte array.  These data types make the flattened string so complex that I cannot decipher the sizeof the control from the length of the flattened string.  Clearly LabVIEW knows the length of any data type.  I really like LabVIEW, much more than any text based language, but this problem is frustrating because getting the size of any data structure in C is as simple as calling the sizeof function.  How can I get LabVIEW to tell me the length of any data type?
    Thanks,
    Hans 

    Hi NathanD,
    Thanks for the reply and for your patience.  I looked at how LabVIEW stores data,  it was informative but didn't indicate to me how to programmatically determine the sizeof cluster elements.
    I'm not seeing how array to cluster will work for my situation because while I do have control of the cluster definitions, I do not have control of the C data structures that are used to create the byte array which I need to decode into the clusters.  The C data structures are of mixed types - 8 bit uints, 16 bit uints, 32 bit uints,  arrays of 8 bit uints, etc. and I can't change them.  If the first element of the C data structure is a 16 bit uint, its value will be in the first two bytes of the byte array.  If the next element is a 32 bit uint, its value will be stored in the next 4 bytes.  If the next element is a string defined as a 12 byte array, its value will be stored in the next 12 bytes of the byte array...  
    I am trying to download some applicable VIs from OpenG per Mike's suggestion, but it is a bit of a process since I am a OpenG newbie and needed to register, download and install VI Package Manager, and then try to guess which package might have a VI that might return the size of a cluster.  There's probably an easy way to search, but I haven't found it yet.  Also, when I try to install selected packages using VIPM, it acts like it is installing them, but then no packages show up in VIPM as installed and no new VIs show up on my functions palette.  Not sure what is up with that.  I'm approaching six degrees of separation from what I want to accomplish
    I tried to attach an example VI and a couple cluster typedefs, but the NI web site said "An unexplained error has occurred".  Now I am six degrees separated!  Will try to attach in subsequent posts.
    Hans 

  • Is there a way to make labview messages always appear on top of all windows?

    I have a main VI running and a user selects a non-Labview window to work on. Is there a way make the user prompt or user input express VI messages appear on top of all windows? I have experimented with the "make window always on top.vi" from the NI website. That brings the VI that is running to the top but not the prompt for the express VI message. I have also used the "make window always on top.vi" in a sub-VI and called that sub-VI to be always on top and it works. I was just wondering if there was a way to do it with the express VIs that NI already has written instead of making a custom message the way I have mentioned.
    Thanks,
    Troy

    If you only need to display a prompt and can get by with a limited set of canned buttons (OK, Cancel, Retry, Continue, etc.), you can try a VI that calls the Windows API MessageBox function. You can display a message box with user-defined title, text and buttons. There is an option to use the system modality which is what you want in this case. I use my own version of this all the time for that very reason.
    Message Box

  • Is there a .sld file for LabView runtime engine when creating Embedded XP image

    I'm looking for a .sld file to aid inclusion of LabView runtime engine in my embedded XP image. Has anyone already written one?

    Hi,
    unfortunately, National Instruments doesn't have any sld files for embedded OS'es, however, please checkout the links from the Lookout discussion forum, where someone was trying to do something similar.
    http://exchange.ni.com/servlet/ProcessRequest?RHIV​EID=101&RNAME=ViewQuestion&HOID=506500000008000000​AD5C0000&ECategory=Lookout
    Although there's no definitive resolution to this thread, the person who answered has said he could be contacted.
    Hope that helps
    Sacha Emery
    National Instruments (UK)
    // it takes almost no time to rate an answer

  • Are there any packages compatable with LabVIEW to make the program CFR21 part 11

    Hello All,
    Are there any packages that are compatable with a LabVIEW program, which creates a .csv file, that would make the program CFR 21 Part 11 compliant?

    A quick search of Google for " cfr 21part 11 labview" returns several links.
    http://www.ni.com/white-paper/4570/en
    http://www.ni.com/white-paper/8751/en
    Now is the right time to use %^<%Y-%m-%dT%H:%M:%S%3uZ>T
    If you don't hate time zones, you're not a real programmer.
    "You are what you don't automate"
    Inplaceness is synonymous with insidiousness

  • Is there still a list of LabVIEW tips and tricks on NI's site?

    There was such a list there a couple of years ago, but I can't seem to find it on NI's site.
    Anybody know where it went?

    The LabVIEW documentation team tried to collect information about how people used the Quick Tips in another discussion forum earlier this year.  I believe they took the information they got back and decided to incorporate the Quick Tips into other LabVIEW help topics.  However, the Quick Tips still exist for LabVIEW 8.0, and most tips are generic enough to transcend versions of LabVIEW.  
    If the Quick Tips are something that you would like LabVIEW to include in future versions, please make a product suggestion, so that they can be aware of the interest for this feature.
    Lorielle P.
    Applications Engineer
    National Instruments

  • Are there large performance gains in labview with a dual processor?

    I have an application that is very cpu intensive using 4 ni6052e's with lots of data aquisition going on. Does anyone have experience with dual processors and labview? What processors? What OS? What are the complications to switching?

    You might be interested in the following documents:
    Using LabVIEW to Create Multithreaded Applications for Maximum Performance and Reliability
    Optimizing Test with Multiprocessor Machines
    LabVIEW and Hyperthreading
    You'll want to look at multithreading along with multiprocessing. On multiple processor systems, multithreading is almost always beneficial, because it allows for each multiple i
    ntensive threads to run simultaneously. However, it is the operating system's responsibility to schedule threads on the processors, and may not always schedule the threads of your application on separate processors.
    On either single or multiple processor systems, there is often a benefit if you are sharing time between CPU-intensive threads and I/O-intensive threads. While one thread is reading or writing to the network (or GPIB, or hard drive, or DAQ device) other CPU-intensive threads can keep running. In a single-threaded system, the CPU would sit idle at times, waiting for the I/O to complete.
    Hope this helps.

  • Is there a BodePlotte​r on LabView?

    Hello,
    I use LabView 6.1.
    I want to measure a Lowpass with the analog input.
    Can I indicate the whole frequency spectrum (for example from 1khz to 10khz) in dependence of the amplitude? Is there something like a Bode Plotter?
    Thanks

    try these links
    http://sine.ni.com/apps/we/niepd_web_display.DISPL​AY_EPD4?p_guid=B123AE0CBBF6111EE034080020E74861&p_​node=DZ53045&p_submitted=N&p_rank=&p_answer=&p_sou​rce=External
    http://sine.ni.com/apps/we/niepd_web_display.DISPL​AY_EPD4?p_guid=B123AE0CBBFF111EE034080020E74861&p_​node=DZ52000&p_submitted=N&p_rank=&p_answer=&p_sou​rce=External
    hope it helps
    Alipio
    "Qod natura non dat, Salmantica non praestat"

  • Is there a way to use Labview for Linux for IBM AIX 5.1.

    I think any application built for linux can run on the AIX 5.1 if the application is recompiled on the AIX 5.1. So theoretically NI can just recompile there Linux version of Labview on the AIX 5.1 and it will work. Is there a possibility that NI will port Labview for AIX 5.1.

    I think that the use of LabVIEW for linux is platform independent as far as hardware. I believe that as long as you are running a compatible GUI (I believe XWindows and KPT??? are two that are recommended - check ni.com/linux for more information. So, for your purposes, as long as you can install the proper GUI, and then LabVIEW for Linux, you can then run, code, compile, and deploy applications on the AIX 5.1.
    I am personally VERY interested in knowing about your success (or failure, should that unlikelyhood occur) on Linux. If you browse the topics, there is actually one on non-windows useage of LabVIEW. I am currently setting up my first Linux machine at my home office, and am very curious to know how other people do with this 'adventure into unc
    harted territory'. The only documented useage I have seen is in Gary Johnson's newest edition of Power Programming.
    Good luck, and please keep us posted. I sense that I am the only LabVIEW for Linux fan besides yourself. But please feel free to post to this thread, and to the topic.

  • Are there any issues regarding running Labview on Windows Vista

    I am a cognitive psychology graduate student, and I am considering switching to LabView to display stimuli and gather RT data. I have previously used E-Prime for this task, but E-Prime doesn't seem to run well with Windows Vista. Are there any known issues regarding running LabView with Windows Vista?
    Thanks
    Chris 

    I've had no problems on Vista*. Only issue I've had was concerning how Vista uses fonts, but if you start on Vista and don't switch between XP and Vista, etc., then you'll be OK.
    *no problems with LabVIEW's compatibility with Vista. Now, Vista in general, that's another story and not for this thread/forum.
    Richard

  • Why are there no advantech drivers for labview by ni ?

    the advantech drivers do not integrate well in labview. The VIs provided by advantech are not direct equivalents and neither do they have the same features. I need some help on this.

    Hi PC
    I am using an Advantech PCI-1713 card and I was just wandering how your program is going because I am having difficulty with mine and was wandering if you would like to help each other out.
    I am trying to measure 16 channels using one of there sample VI, I think it must be the same as your Multi Channel Interrupt VI you described in your message.
    I have a question, how do you get it to save more than one cycle because mine is only saving one cycle and I do not know how to fix it.
    For example if I enter COUNT = 100 then it will only save 100 samples. How did you get your VI to continue saving samples???? I also am using Cyclic.
    I am new to DAQ and would like any help if possible
    I have attached the Vi and an example o
    f what I am getting.
    Cheers mate
    lp19
    Attachments:
    multichannel.vi ‏89 KB
    typical_results.xls ‏1 KB

  • Does there exist a .mat-to-LabVIEW converter?

    I need to be able to read from and write to .mat files from within LabVIEW. The .mat file format is what Matlab uses to store arrays. I have found that The Math Works offers a C library with functions for accessing .mat files. I suppose I can use this library to create a .dll (or use CINs). Is there a software utility currently available to do this?

    > I need to be able to read from and write to .mat files from within
    > LabVIEW. The .mat file format is what Matlab uses to store arrays. I
    > have found that The Math Works offers a C library with functions for
    > accessing .mat files. I suppose I can use this library to create a
    > dll (or use CINs). Is there a software utility currently available
    > to do this?
    This isn't a convertor, but you can reuse Matlab from within LV. LV5.1
    I think, added the script node. You can type in or popup and import
    matlab scripts. At runtime, the script contacts a Matlab EXE to have
    the computations performed and to return the results into LV.
    Greg McKaskle

Maybe you are looking for

  • Double buffering

    I was searching through posts to find an answer to my problem of getting double buffering working without flickering when I came across this response: Upgrade your SDK, early 1.4 implementations had this problem on Windows2k (It's a bug). Pretty much

  • Web Service error deserialisation failed.

    Hi Guru's, I have set up a Web Service, generated via a Z-Bapi. When posting to the webservice I am getting an error message saying: deserialisation failed So i did a search and found 2 SAP notes: - SAP Note 892944 Deserialisation failed - SAP Note 8

  • Are there any  best practice templates available to load Customer Master data into ECC using data services?

    Hi, As far as I remember there are best practices templates (AIO). I am not able to find the location to download these atl files though. Thanks, Pramod

  • Stress Test using em console in 11g results in lesser number of instances

    Hi All, We are doing Stress/Load testing using em console in SOA Suite 11g. The problem we are encountering is, em fails to create as many instances as it should. Under "Additional Test Options", we check the "Enable Stress Test" checkbox and give di

  • Manually  migrating to new Mac: how to move iOS Apps

    I am doing a manual migration from my old Mac to my new Air. I understand (I think) how to move my itunes Music Library). However, I don't know how to move all of my iOS apps  (some of which are installed on my iPad and iPhone and some of which aren'