Loading Instrument settings from file

Hi there
I am developing a new app that uses quite a few possible instrument configurations and needs to be able to support multiple instruments models. I have written a little GUI that lets users select a config from various settings on different tables. I now want to save this config to a file and maybe read in the settings when they want to edit it again. Can any body suggest and tried and tested formats for doing this. I was going to use configuration files with a section for each instrument type and then keys for model number and GPIB addr but am open to any other suggestions as I need to do this quickly (whats new eh !) and it needs to be scalable.
Instrument settings will be loaded from file into Globals by each test sequence so that globals can be re-used etc
Cheers in advance.
Chris R

Chris,
Option 1 - HDF5
I have found HDF5 the best method for saving configuration data. You can get low-level HDF5 utilities for LabVIEW by searching for sfpFile or HDF5 on the main NI website, or try this link.
http://digital.ni.com/public.nsf/3efedde4322fef19862567740067f3cc/cb8a7f8090900f6c86256cc700033816?O...
HDF5 is a binary, hierarchical file format, with a lot of built-in features such as compression and 64-bit file pointers. As such, it is fast, allows for easy backwards compatibility, and you can put anything into it. It also allows circular references (it is actually a directed graph, not a tree), so, for example, you can reference data from configurations and configurations from data. I maintained the NI-SCOPE Soft Front Panel configuration file with this method through many years and configuration changes.
Now for the bad news. HDF5 is very low level. Expect to take a week to get comfortable with it. HDF5 is not threadsafe, so you must ensure that you never call the DLL from more than one place at once. The posted code uses version 1.4.4 of HDF5, while the latest version is 1.6.3.
Option 2 - Configuration file VIs
If your configurations are fairly simple and have no real hierarchy, consider the configuration file VIs found on the file palette. These store your data in a Windows style INI file, so it is easily human readable. They are not as fast as the HDF5 solution, and have only a single layer of hierarchy, but they are written in pure G, so are very portable.
Good luck. Let us know how you make out.
This account is no longer active. Contact ShadesOfGray for current posts and information.

Similar Messages

  • Can't load Network Settings from System Preferences

    For some reason I can't load Network Settings from System Preferences anymore - it just stalls with the bar showing "Loading Network" and doing nothing. This is happening in conjunction with a new inability to connect to a network printer - it won't show up on the list of printers, even when I manually enter the IP address. Something is obviously mucked up - can anyone tell me what it might be & how I can fix it? Thanks!

    I was able to fix this myself by using one of the techniques suggested here for a different problem. Basically I went into Library/Preferences/System Configuration and deleted networkinterfaces.plist, preferences.plist & com.apple.nat.plist. All were rebuilt when I restarted and went to System Preferences/Network and I was able to load the Network Settings. This didn't fix the problem with my printer, but at least it got the settings up.

  • Path Problem: Can't Load Database Settings From  A File

    <b>I am writing a swing application with the following functionality:</b><br>
    (1) There is a base class that supports things like changing the look and feel &ndash; this is done via a JDialog that loads all the installed lafs from which the user selects a choice.<br>
    (2) Enables the user to set/change the physical database properties &ndash; location, password usernames and the like. -<br>
    The idea is that when the application starts up for the first time the user will be asked to provide the database settings and then they will be stored in a file and then every time the application starts the settings will be loaded from this file. This works out fine!!!!!!!!!<br>
    <br>
    <b>Now here is the problem:</b><br>
    All the above is supported by an abstract class that extends JFrame (I&rsquo;ve put abstract after testing) - MySuperFrame. After testing, I packaged this class together with other utility classes into a jar file.<br>
    So my application which inherits from MySuperFrame fails on start-up with an exception that the database settings file cannot be found &ndash; And I know that it is in the jar file.<br>
    +<br>
    I think that my problem is the path and nothing but the path &ndash; or relative path.+<br>
    <br>
    This is the structure of my project:<br>
    There is the src and the bin directories and then there is an external folder (not a package inside these two folders) called files (this is where my database settings file is stored).<br>
    How do I solve this problem?<br>
    How do I make sure my application loads the settings file regardless of where it is? I thought of passing the database settings file to a constructor of a database settings dialog class. But I don&rsquo;t know how to sort out the path issue.<br>
    <br>
    Please give me advice on how to implement that?

    Apologies for the bad formatting on the original posting. Here is the formmatted posting:
    Hi All,
    I am writing a swing application with the following functionality:
    (1) There is a base class that supports things like changing the look and feel &ndash; this is done via a JDialog that loads all the installed lafs from which the user selects a choice.
    (2) Enables the user to set/change the physical database properties &ndash; location, password usernames and the like. -
    The idea is that when the application starts up for the first time the user will be asked to provide the database settings and then they will be stored in a file and then every time the application starts the settings will be loaded from this file. This works out fine!!!!!!!!!
    Now here is the problem:
    All the above is supported by an abstract class that extends JFrame (I&rsquo;ve put abstract after testing) - MySuperFrame. After testing, I packaged this class together with other utility classes into a jar file.
    So my application which inherits from MySuperFrame fails on start-up with an exception that the database settings file cannot be found &ndash; And I know that it is in the jar file.
    +
    I think that my problem is the path and nothing but the path &ndash; or relative path.+
    This is the structure of my project:
    There is the src and the bin directories and then there is an external folder (not a package inside these two folders) called files (this is where my database settings file is stored).
    How do I solve this problem?
    How do I make sure my application loads the settings file regardless of where it is? I thought of passing the database settings file to a constructor of a database settings dialog class.*{color:#ff0000} But I don&rsquo;t know how to sort out the path issue.{color}*
    Please give me advice on how to implement that?

  • Can't load thumbnail photo from file 'BBThumbs.dat'

    Hi everybody,
    I'm developing an application on BB to take and view photo. My problem is can't load the thumbnail photos from file 'BBThumbs.dat'. I'm using code as below:
    public byte[] getThumb(String fileName) {
    String DB = fileName.substring(0, fileName.lastIndexOf('/'))
    + "/BBThumbs.dat";
    fileName = fileName.substring(fileName.lastIndexOf('/') + 1, fileName
    .length());
    if (thumbsMap == null) {
    thumbsMap = new Hashtable();
    byte b[] = null;
    FileConnection fc = null;
    InputStream in = null;
    try {
    fc = (FileConnection) Connector.open(DB, Connector.READ);
    if (!fc.exists()) {
    return null;
    byte[] temp=new byte[(int)fc.fileSize()];
    in = fc.openInputStream();
    DataInputStream is=new DataInputStream(in);
    // b = getThumbNail(first, thumbsMap, fileName, in);
    is.readFully(temp);
    b=readThumbs(temp, fileName);
    } catch (Exception e) {
    } finally {
    if (fc != null) {
    try {
    fc.close();
    } catch (Exception e) {
    if (in != null) {
    try {
    in.close();
    } catch (Exception e) {
    return b;
    please give my any idea or suggestions. Thanks 

    Try:
    !Section=Dimensions
    'Name;DimensionClass;DimensionAlias;CustomDimensionID
    SKU;Generic;;
    !Members=SKU
    'Name;DataType
    Brand1;Unspecified
    Brand2;Unspecified
    !Hierarchies=SKU
    'Parent;Child;DataStorage
    #root;Brand1;StoreData
    #root;Brand2;StoreData
    Tho I would add MemberValidForPlan#;Plan#Aggregation, where # is a number of your application which this member is valid for or even has a specific aggregation, as well
    example:
    !Hierarchies=SKU
    'Parent;Child;DataStorage;MemberValidForPlan1;MemberValidForPlan2;MemberValidForPlan3;Plan1Aggregation;Plan2Aggregation;Plan3Aggregation;UDA
    #root;Brand1;StoreData;Y;Y;Y;+;+;+;
    #root;Brand2;StoreData;Y;Y;Y;+;+;+;
    Even more as an idea use pipes, maybe.
    But you will need to say something about Aliases as well if this is a planning application.

  • CS6 Photoshop asked do I want to load previous settings from CS5.5

    How do I get all the features in CS6 back as when I installed it it asked did I want to load previous settings. As I didn't know what this ment I said yes, now I don't have things like the new perspective tool.
    How do I reload these features?

    Delete the preference file in your prefs folder. Provide system information and we'll tell you where.
    Mylenium

  • Load combobox items from file

    Hi,
    I dont know do I use correct components here, but I have tried to load some dropdown selector's items from file. I have file, which items changed all the time, so I have to load those to user's dropdown selectro every time when program starts. Eny ideas?
    A.A
    Solved!
    Go to Solution.

    Use a property node Strings
    Strings [] Property
    Short Name: Strings[]
    Requires: Base Package
    Class: ComboBox Properties
    Array of the strings from which you can select in the combo box control. Use the Strings And Values [] property to specify custom values for each string.
    If you use this property with a combo box control that has custom values, the number of values for the combo box control determines the number of strings you can set using this property. For example, if the combo box control has the values Free, Discount, and Full, you can set only three strings using this property.
    If the combo box control has more values than the number of strings you wire to this property, LabVIEW creates strings for any values that do not have corresponding strings. For example, if the combo box control has the values Free, Discount, and Full and you wire the strings Voucher and Coupon to this property, LabVIEW sets the last string to <Full>.
    This property is similar to the Edit Items item on the shortcut menu of a combo box control and to the Labels option on the Edit Items page of the Combo Box Properties dialog box.
    Omar

  • Loading control settings from a different VI?

    This question is a bit difficult to explain, but I'll try.
    I have a main program (main.vi), and a sub vi (setup.vi) that loads the front panel in order to do setup.  The setup.vi has the option to "save settings", in which it writes all of the controls to a .txt file.  When I click "done", the setup.vi builds a cluster with all of the parameters in order to easily pass all of the information in to main.vi.  
    Now, when main.vi loads, I want it to be able to read the default setup from setup.vi, and build the same cluster from that data - and I am having a difficult time figuring out how to do it.  I have attached the sub-vis that setup.vi uses to both save and load the controls.  They are fairly simple.
    Attachments:
    LoadSetup.vi ‏12 KB

    How about adding an boolean input 'silent default' to your setup.vi, that if true, just loads the default and doesn't need the user action?
    Try to keep one action in only one vi. So if you need changes, there is only place to go  
    Greetings from Germany
    Henrik
    LV since v3.1
    “ground” is a convenient fantasy
    '˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'

  • Load "Selected" in a Property Loader test step from file

    Hi,
    The Import/Export tool stores its selected properties in the file �PLPropertyLoader.ini�. Is it possible to use this file to specify which properties a �Property Loader Test Step� should load? How? Then the information about what to export and load dynamically later is stored in the same location and the risk possibilities is reduced to one place.
    Best regards,
    Morten Pedersen
    CIM Industrial Systems A/S
    Denmark

    Morten -
    By default, the Property Loader step type stores its selected property list in the step's property "Step.PropertyList". The Edit Property Loader dialog box has the "Property List Source" expression control that specifies this as its value.
    If you created a Station Globals array property of type "DatabasePropertyMapping", you could specify that the steps use this property. You might have to set to show hidden properties to find the "DatabasePropertyMapping" type in the insert menu. Note that when you do this when you edit the selected list in a step you are editing the selected list stored in the station global array property.
    Scott Richardson (NI)
    Scott Richardson
    National Instruments

  • Is it possible to get info on software instrument settings from projects?

    I had a hard drive problem recently and decided to re-install my OS. When I did this some of my Logic 8 project files would not open my Absynth 3 tracks due to the registration being messed up from my system ID changing. Absynth 4 opens fine but not Absynth 3. My problem is that I have a few tracks that use Absynth 3 and I need to recover or find out what sounds I used on Absynth 3 so I can try and rebuild the sounds in Absynth 4.
    Is it possible to show package contents on a project file to recover plug in specific information from Absynth 3 or does anyone by chance have any suggestions on how I can find this out. When I show package contents on my project file I get 2 files, Display State and Document Data. I couldn't get either of these to open individually. I'm just curious if I can get the name of the sound or preset from these files. Any info is greatly appreciated.

    The simplest way is to reinstall and re-evaluate Absynth 3, I think. Where exactly is the problem with it?

  • Load OTF font from file

    I've read in several places, that java 6+ supports OTF fonts, yet I can not find, how one can load an OpenType font frm a file.
    There are numerous examples of how to load TTF fonts, by calling
    Font.createFont(Font.TRUETYPE_FONT, fontFile);but none seems to notice the glaringly obvious problem, that the OPENTYPE_FONT font type constant does not exist.
    So... is it possible? How is it possible?

    As it turns out, the OTF fonts load just fine with Font.TRUETYPE_FONT set as the font type.

  • How to save/load JTextPane to/from file?

    One of the simplest questions re Swing.
    How to save a JTextField onto a file?
    And, how to read back it onto a newed JTextPane?
    Yes, I have searched, searched and searched on the net, in vain.

    Assuming he's wanting to do the reasonable thing, I'm trying to do it too.
    linuxoid, I suspect he (and I) are looking for a way to save the contents. After all, a control that you can't get the information out of is pretty useless.
    Styled text is often just a BLOB to the rest of the app. It is in my case, and it probably is in his.
    I'm having the same trouble he is.
    I want to make a JTextPane, let the user edit it, then get some reasonably portable representation of it's current contents that I can serialize. A string representation of XML sounds dandy. Incomprehensible binary is acceptable. A representation in some markup language that I can insert in some other document and have it act like I'm inserting text in the editor would make me more than happy.
    Ideally, what I, and probably he, are looking for is something like
    JTextPane myPainIsGreat = new JTextPane();
    ... life goes on...the user writes poetry and turns the words tacky colors...
    String thisICanDealWith = myPainIsGreat.getStyledTextRepresentation();
    knowing better I'd settle for
    myPainIsGreat.writeStyled(someWriter)
    sadly, JTextPane's write just returns unstyled text

  • Read and save settings from instruments

    Currently, the 'save config' case saves the data read from the user interface (in the 'aggressor settings' tab)
    how can I change this 'save config' event so that;
    - Read all the insturment settings from hp8133s and hp8648 (along with GPIB addrs)
    - Load into the user interface
    - Save to a file (*.ini)
    Thanks,
    Attachments:
    Pulse Channel with Load and Save_no event_v09.4.6.llb ‏2917 KB

    I have created this case, "load instrument settings"
    First four settings are from hp8133A voltage output.vi (from instrument library)
    and the last two pulse setting VIs were modified version from voltage output.vi
    I have created an array to gather all output values, but don't know how to pass it on to the front panel...
    could you please advise on how to accomplish this?
    Attachments:
    Pulse Channel with Load and Save_no event_v09.4.13.llb ‏3169 KB

  • Problems with load DSO from file

    I am working with BI 7.0.
    I am loading data from file to DSO and my problem is that data is not active in my DSO, the data are loaded how New Data and I haven´t the data in query and DSO.
    The settings of my dso are:
    Type: standard
    SIDs Generation upon Activation: X
    Set Quality Status to 'OK' Automatically: X
    Activate Data Automatically: X
    I have created one transformation from datasource to DSO and one DTP that extract from datasource ( No PSA).
    When I execute the DTP there aren´t errors, the status is green and ok but the data is not active.
    If I try activate the data manually the job is launched but the data no active.
    Thanks.

    hai
    Isabel Bautista 
    u r saying the data is not active in dso and also u r loading the data from file directly( no psa).
               i think u know in B.I the data should be in psa then only u can load the data using DTP .so how can u load the data with out data in psa  .i thinks may be because of this u r data is not activating in dso
    if it helps
    assign some points ok

  • Is it possible to load or import 1 journal from file?

    Hi to all,
    We are searching how to load or import from and excel file some journals into the journal table of SAP BPC. As we have seen it is possible to load all the table but not only to add one journal to the table.
    Anybody knows if it is possible to load 1 journal from file into SAP BPC and add it to the table of journals?
    in a standard way or using logic??
    Thanks a lot!!!!

    I don't think that there is a method available to ONLY add 1 Journal record, since the sequence of Journals is an Autogenerated key.  The best way would be to simply add the Journal, so that the appropriate values are logged and tracked accordingly.  The table may be loaded, since the "whole" table has a defined key for the sequence of Journal entered transactions.
    Hope this helps.

  • Can I dynamically load html from file, but do not stuck the UI

    I load my html from files.
    Use JEditorPane to setContentType("text/html"),
    use JEditorPane.read method to dynamically load html from file,
    the jeditorpane is add into a jdialog,
    when my application showing the dialog, the dialog was stuck,
    user can not click other UI component, I think it is not look dynamically
    So any other suggestion?
    You are appreciated.
    Thanks in advanced.

       yourDialog.setModal(false);

Maybe you are looking for

  • MySQL ODBC DNS

    Hi to everyone! First of all let me tell you that i've been looking for an example on how to do this for a long time before even considering making this post. Let's go back to business, I'm having an issue trying to connect a mySQL database through "

  • How to export local class to global class in abap ?

    is there any report that can export local class to a global class ? thanks !

  • CSM without any sticky

    I have set up a real basic configuration with a verver on port 80 pointing to a serverfarm with two servers. I have no sticky enabled and no persistent rebalance on the vserver. If I go to the URL that points to the VIP the connection is made with th

  • 5800 PROBLEM AFTER UPDATE HELP!!

    I updated my 5800 Xpressmusic to v40.0.005.C03.01.  Everything seemed to be ok until I needed to send a message, when I realised that the full-screen keyboard was not an option for entering letters!! HOW CAN I BRING IT BACK??

  • Recommended Audio Interface for MacBook Pro w/ Leopard

    There is more to getting a four pin firewire audio interface to work than buying one. Tech forums are full of driver related issues. Is there a tried and true FW audio interface for the MBP w/Leopard that anyone is using now? Thanks.