Using LabView class in multiple projects

Hello,
I have created a LabView class that I'd like to use in multiple projects while using source control (we use Serena for this) with the source files of the class in a centralized location (not seperately for each project as I don't want the code of the class to diverge in the different projects). Now I'm wondering what is the best way to accomplish this. I see a couple of different possibilities:
- Have the class VIs at a certain location in the repository and link to all the files from the other projects in the repository. This will mean I will have all the files in all the project folders on disk but only one archive in the repository for them as they all link to the same location. Problem: Serena cannot create links to folders, so every VI has to be linked and if the structure of the class changes or VIs, the links have to be updated in each project -> not very nice
- Have the class VIs at a certain location in the repository that will be checked out to a certain path on the local hard drive and add the class VIs to the projects from this fixed path. Problem: it's not guaranteed that the path will be the same on all computers. Some team members might check out to a different location -> bad solution
- Use a .llb file that is also in the repository and create links to it from the different projects, i.e. the source files will only exist at one location on the hard drive but in every project folder there will be an .llb-file that will come from a single archive in the repository -> actually my favourite solution. Problem: I use the VI Server to call VIs by relative path inside the class and this works differently inside the .llb, since there seems to be no folder structure anymore. If there was a good workaround for this, this might be the best solution
Does anybody have experiences on how to do something like this? Are there other possibilities to do it?
Thanks,
Tobias

Hi,
thanks for your reply.
I think I have to make my question a little clearer. Say I have a class ClassA that uses some VIs that are in the same folder (or subfolders) as the class file. Now I put all of this in an SCC repository at the path /SCC/ClassA/. Now I have two projects that use this class and are located in the SCC repository at /SCC/Project1/ and /SCC/Project2/. Now some people might check out /SCC/ to c:/Projects, other people might check it out to d:/SCC so the absolute paths of the resulting files on the disks could be different. This makes it hard to add ClassA to both projects because on one computer the path to it would be c:/Projects/ClassA/<ClassName> on the other it would be d:/SCC/ClassA/<ClassName>. A common solution for this that we use for C++ projects is to create links inside the SCC, link the source files or a DLL inside the SCC to the /SCC/Project1/ and /SCC/Project2/ folders. This will create multiple copies of the DLL on the harddisk, one in the Project1 folder and one in the Project2 folder.
Another solution might be the one you proposed, to have the sharde files inside the <LabVIEW> folder. However there are a couple of downsides to this, as far as I can see:
- It won't work for people who don't have local admin rights (and actually having to change the files inside the "Program files" folder for development is not a good idea, imho)
- It makes it quite hard to guarantee that both the projects and the shared files are always the same version (for example if I want to build an older version of Project1 I might need an older version of the ClassA, too. If I have it all inside one project in SCC, I can just get an older label to some folder and build it. If I have the shared files in the <LabVIEW> directory, I will have to replace this. There is no way to have multiple versions (older and newer) parallely on the disk in different folders. 
Tobias

Similar Messages

  • Passing argument to, when using one class for multiple assets

    I had a class that I was passing a simple argument to like so:
    var quiz_1_2:CaseStudyQuiz = new CaseStudyQuiz(2);
    addChild(quiz_1_2);
    I now would like to use this class for multiple MCs in my library. I thought I could let Flash create a class for each of them and specifying the CaseStudyQuiz class as the Base class. When I do that, I get the following error:
    1136: Incorrect number of arguments.  Expected 0.
    Obviously this is because the class created by flash does not except an argument. Does that mean, I would have to create a seperate class for each of the movies that use that class? And if so, what would I have to do in that class for it to except the parameter and pass it on to my base class?
    Thank you very much for any help with this!!!

    use the super() function and pass your parameter.  but you still might get a runtime error but i don't think that will cause a problem.

  • How to share common classes across multiple projects in Jdeveloper?

    Hi Experts,
    I have a basic question.
    I am using Jdeveloper 11g and have divided my application into 2 projects (Model(ejb's) and Viewcontroller(jsf+managed beans etc)).
    The model project has a stateless session bean(named VisitingScholarBean) which uses a java bean class(named VisitingScholarDetails) defined in the ViewController project.
    The relevant Method in the stateless session bean is public void saveVSDetails(VisitingScholarDetails vsDetails).
    Now the issue is that the VisitingScholarDetails class is part of only the ViewController project but is being used in the Model project.
    So when I try to run the application it gives an error saying that
    weblogic.application.ModuleException: Exception preparing module: EJBModule(VisitingScholar-Model-ejb)
    [EJB:011023]An error occurred while reading the deployment descriptor. The error was:
    edu/nyu/ecoms/oaa/vs/web/backing/VisitingScholarDetails.
         at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:452)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
         Truncated. see log file for complete stacktrace
    java.lang.ClassNotFoundException: edu.nyu.ecoms.oaa.vs.web.backing.VisitingScholarDetails
         at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:283)
         at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:256)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
         at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:176)I cannot replicate the same VisitingScholarDetails class in both projects as it will lead to duplication.
    Please let me know how to include the VisitingScholarDetails class in the ejb-jar without replicating it in the Model and View Controller projects.
    Thanks for your time and help.
    Edited by: user10376431 on Jan 24, 2010 6:25 AM

    Welcome User in OTN,
    to make two projects can access its classes you should goto the project property ---> Dependencies then add the other project.
    in your case:
    try to goto you Model project property ----> Dependencies ---> Edit Dependencies .
    you will find your ViewController project. Expand it thin check to Build Output.
    you can make this for ViewContoller project also as:
    goto you ViewContoller project property ----> Dependencies ---> Edit Dependencies .
    you will find your Model project. Expand it thin check to Build Output.
    Sameh Nassar

  • How to use LabVIEW in a multiple coder environment?

    The subject basically says it all.  This thought hit me the other day, now that we will be two persons (and eventually perhaps more) coding on a source code written only by me so far.  In my job, we commit and update source code to a SVN repository by using TortoiseSVN.  This works very well with C/C++, since the source code files are in plain text and will be merged by TortoiseSVN.  But since VI files are binary, I gather that this will not be possible.  I tried comparing two different revisions of my own commited code, and this didn't work.  How is this particular problem solved in other multideveloper environments?

    Source code control merging and all of that stuff is secondary to the design itself. I have had a half-dozen developers working on the same project but different "sand boxes" and yes we managed to get 6 person months worth of work done in a month.
    Integration of tested components is when things get touchy but if done in a orderly manner, no suprises there either.
    Rules that have helped us;
    1) Use  Tree.VI  (or Root.vi , Catalog.vi) to hold all of the top level VIs. This will ensure we find out about possible integration issues when they happen.
    2) Never save broken code to SCC. It is all too easy to start ignoring a broken tree.
    3) Communicate with your team! let them know where you are going next.
    4) Assume your team mebers will mis-use your code and build in error checking to let them know what they did wrong.
    5) Never save a VI unless you can explain why you are saving it.
    Backup-up often.
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Using same title in multiple projects?

    I just created an animated title in a project and would like to use that title in another timeline (project). I would like to put it in an event. Is that possible?
    In FCP 7 I could create a title and save it to a bin. How can I do this?
    Cheers.
    Tom

    First method would be to create a new project, copy/paste the title to that project, then export/share the project as a quicktime movie. Then import the result into your event of choice.
    Second method (though I'm not 100% sure it will work) is select the event you want to store the title. Create a new compound clip (option-G) and give it a name. Copy the title from the project. Next, select the new compound clip in the event and "Open in Timeline" from the "Clip" menu. Finally, paste the title into the timeline. Again, not sure if this will work (copy/paste from/to a project/event compound clip) but worth a try....

  • How to use labview to control a robotic arm by EMG signal

    Hello,
    I am working on simulation of an active Exoskeleton (wearable robot) for the upper limb using LabVIEW for my senior project. I need to use the EMG signal as an input to move the elbow joint (flexing and extending). I downloaded labview biomedical toolkit to take a ready simulated EMG signal but have a weak experience in LabVIEW.
    The design criterial I am planning to use is to establish a threshold for the EMG signal using a comparator (above 0 for example) and set a counter for everytime the signal passes the threshold as(+1) in every count. Then, specify a degree value for the counter (for example when the counter reaches 10000) and feed this value of the counter to a simple simulated structure for the joint (simple angle of 2 lines) or a meter to represent the movement.. e.g. every 10000 count = 1 degree of movement. Zero crossing can also be used instead of the comparator and the signal will be filtered and that is easy to do. However, my problem is in converting this logic into LabVIEW. I don’t know how to set a counter for the signal and make every number of counts refer to a specific degree of movement and I also don’t know how to form the simulated joint structure in LabVIEW or even how to transfer this into a simple meter device in LabVIEW.
    I have only one month to do this project so any help or ideas you provide are highly appreciated
    Thank you ,

    CarlFHellwig 
    Thank you for providing this example I just implement  it in the software to check the counter results.
    In fact, the design criteria I desided to use latly is to use is to establish a threshold for the EMG signal using a comparator and correlate the EMG signal with the angles of movement of a simple simulated structure "motor" for a single joint (simple angle of 2 lines) eg. 30,60,90,120,150 degrees for flexing and extending. Zero crossing can also be used instead of the comparator and the signal will be filtered and that is easy to do. 
    In other words, the idea is to drive a motor for different angles based on the input EMG signals. I am now stuck with developing the algorithm of how the angles are related to the RMS value of the signal while flexing and extending and how to convert this RMS into angular velocity and angular position to form the simulation. 
    I will be grateful if someone guided me to a person did a similar project to discuss some issues. 
     

  • Using LabVIEW OOP Objects with TestStand 2010

    I need to use labview classes in Teststand 2010. I am not able to pass reference between Labview and Teststand.

    Or leave it in Labview and use an action engine.
    http://forums.ni.com/t5/LabVIEW/Community-Nugget-4-08-2007-Action-Engines/m-p/503801?view=by_date_as...
    That's what I have done.
    Regards
    Ray Farmer

  • Complete hardware simulation using LabView, Multisim, and MAX (easy answer accepted!)

    Hello, all!
    Sorry, I'm new, but I've checked around for a definitive answer on this, but I'm not 100% sure.  I'm learning LabView for an upper-division Physics class.  We're using NI hardware (DAQ-MX) and a mix of lab hardware - primarily basic stuff such as voltmeters, oscilloscopes, and breadboards with simple components.  I'm also doing some work with NIM instrumentation, but that's secondary to my needs here.  So, when I'm away from school, is it possible to do a complete simulation of my classwork using LabView, Multisim (for my breadboard), and the Measure and Automation Explorer (for the DAQ-MX)?  I know that I can create a circuit and drop it into Labview, but I'm not so sure about the DAQ.  I'm hoping for something that's a "seamless" recreation of what I'm doing in class.  I can take a simple "yes" or "no"; as long as I know that it's possible, I can look for the solution.
    Thanks for the help!
    Solved!
    Go to Solution.

    I have an easy answer and a harder answer:
    Easy Answer
    You can simulate almost any NI instrument in MAX.  Right click the Devices and Interfaces item in the left pane and select Create New...  Unfortunately, this limits you to whatever the driver designer thought would be a good signal.  It is good for simple testing, but you will rapidly run into its limitations.
    Harder Answer
    Use LabVIEW classes to make a hardware abstraction layer.  This my seem like an advanced topic for a beginning LabVIEW programmer, and it is, but it also neatly solves the problem of switching between simulation VIs and real acquisition VIs without writing a bunch of switching code.  In short, you create a LabVIEW class which has the interface you want for you data acquisition.  This can be your simulation code.  You then create a child class which has exactly the same interface, but uses the DAQmx/NI-SCOPE/NI-DMM/etc. that you really want to use.  Switching between the two is as simple as selection the class you want to use at run time.  This is a lot of info in a short time.  If you want to go this route, read the LabVIEW help on LabVIEW classes and work through the examples.  I would encourage you to do this, since the sooner you learn how to effectively use object-oriented LabVIEW, the easier your life will be.
    As a further bit of information, most of the measurement instrument groups (e.g. NI-SCOPE, NI-FGEN, NI-DMM, etc.) allow you to simulate an instrument if you use the open with options VI instead of the standard open VI.  The inputs are rather arcane, but get the job done.
    Let us know if you have further questions.
    This account is no longer active. Contact ShadesOfGray for current posts and information.

  • Using Flash Components in multiple SWCs inside AS-only project

    Ok, this is a somewhat complicated issue dealing with SWCs and compilers. I've outlined steps to reproduce the problem below. I'm using the method outlined here to bring in Flash content to my project. I have 15-20 SWCs already, and it's working fine for those assets, the problem is specifically related to Flash's components (ComboBox, RadioButton etc.) If anyone has *any* advice on this, please let me know as we are completely stumped at this point!
    The issue we're having involves using multiple external SWC files which contain AS3 components from Flash CS4. When two SWCs are linked to an ActionScript project (using Flash Builder 4 Beta (build 4.0.0)) there are collisions in the referenced classes which cause the most recently published SWC to knock out any duplicate classes in the other SWCs. A simple way to replicate this is as follows:
    1. Create one FLA, called 'compA', drag one ComboBox, RadioButton and TextInput component onto the stage. Select all and convert to symbol, marking the symbol for export with a class name of Test1.
    2. Create a second FLA, called 'compB', drag one ComboBox, Label and UIScrollbar onto the stage. Convert these to a symbol with a classname of 'Test2'.
    3. Create a new ActionScript-only project in Flash Builder, called 'ComponentTest'.
    4. Create a 'libs' folder in this new project. Select 'Project -> Properties -> ActionScript Build Path' and add the libs folder as a new SWC folder in the Library Path window.
    5. Go back to compA.fla and right click the Test1 symbol in the library. Select 'Export SWC file...' and save it as compA.swc in the libs folder.
    6. Do the same thing for compB.fla.
    7. Edit ComponentTest.as and in the constructor, create an instance of Test1 and Test2, placing each on the stage.
    8. Run the app, and the ComboBox will only be functional in one instance (whichever was published last.) The other ComboBox will behave like a MovieClip, cycling over the two frames in the stage asset (avatar and skin.) It will have no association to anything in the fl.* package.
    Looking at the 'Referenced Libraries' in Flash Builder, compA may show it contains classes for the RadioButton and TextInput, but no ComboBox classes are referenced (sometimes it will show no classes at all, but this appears to be an unrelated bug with refreshing external libraries in Flash Builder.)
    Unzipping the SWC files and examining their catalog.xml manifests shows all the necessary classes are listed (i.e. ComboBox is in both.)
    Removing either SWC will cause the remaining one to work properly, so the problem appears to be in compiling the ComponentTest project which includes both.
    Attempted Workarounds:
    1. Create a new FLA, drag all components used in both files onto the stage and export a SWC called 'components.swc'. Add this SWC to the project's libs folder. In both compA and compB FLA files, add this SWC as an external library in the ActionScript 3.0 Publish settings. Re-export both SWCs. The theory is that the compiler will look for the required classes in the components.swc first, and thus not include them in the export, however this is not the case.
    2. Same as above, deleting ComponentShim from both FLAs before exporting. The result is that no component classes are included, so all components act like MovieClips.
    3. Add the Components source folder to the external library path of both FLAs, assuming the compiler will favor classpath references over compiled class references (ComponentShim). Same result.
    Summary: We have been unable to find a way to use Flash Components in a project if they are referenced in more than one asset library. If we were able to import them once, and have all SWCs which need those classes use a single source, this might not be an issue, but the compiler does not appear to handle this (and we are admittedly not advanced enough to even know if this is possible.)

    Hi!
    I'm having the same problem. Any news on the matter?
    Also, this looks like a very similar problem.
    Best regards,
    X_AmonPL.

  • Packed project Library Labview Class Issues

    I packed  my whole Labview project as a packed proj library during   teststand Deployment 
    I am using classes in my  labview project 
    unfortunalely by one of sub seq calls got the following error !
    "Type mismatch. The LabVIEW Class does not match the class expected by the VI.
    Cannot pass a base LabVIEW Class to call a method initially defined in a derived LabVIEW Class."

    The error message is quite clear:
    You are using inheritance where you do have methods which are not part of the parent class (as dynamic dispatch).
    During the call, you pass an object of the parent class and try to call the (unknown) method of the child.
    Why this is happening can only explain your code....
    Norbert
    CEO: What exactly is stopping us from doing this?
    Expert: Geometry
    Marketing Manager: Just ignore it.

  • Best way to save a vi that is used in multiple projects?

      Hello,
    I have an archive of vi's that I use in multiple projects.  As an example, I store all my vi's in a folder called 'Archive'.  When I start a new project, I make a new directory, say 'Proj A', and then I drag copies of the original vi's from 'Archive'  into 'Proj A'.  When I launch Proj A, labview always loads the files from their original location ('Archive') instead of 'Proj A'.
    Is there a better or more proper way?  I heard LV8.0 may take care of this issue.
    Thanks,
    Tony.
    P.S.  I apologize for posting two blank threads a few minutes back.  Can't figure out how to delete them.
    Message Edited by TonyO on 10-13-2005 02:02 PM

    User.lib as mentioned by the others is the way to go if you have no issues reagarding sharing the contents of user.lib across multiple machines. The complications I have seen with this is that if I move an application to my customer's machine and some of the VI's were stored in user.lib the application will not find them unless I thought ahead and pulled out the parts the app needs. I also do not want to give away my entire re-use library everytime I include one of the containded functions.
    If you just want to pull out elements from your collection then templates can be of some use.
    If you need to selectively pull out parts of your archieve for use when required, then a "Tree.VI" can help. A Tree.VI is a VI that contains all of the top level and dynamixally loaded VI's used by the function to operate correctly. By opening the Tree.VI and doing a "Save with options"... single prompt preserve hiarchy... the requred VI's are copied to the new location and saved with the relative paths adjusted to point at the new location. This takes care of the cross linking issues.
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • How to use multiple projects in single application :)

    Hai ,
    I ve to use single .portal for accessing multiple projects in a application. if i create two new projects in a application i cant able to use .portlet file of one project to display in another .portal . is there any way to display both the project .portlet files in a single portal. :)

    not really.. sorry
    Kunal Mittal

  • Multiple projects in one web role using Azure cloud?

    How to run One webrole with multiple projects using azure?
    In my solution One WCF service and ane website i want run both on one solution,
    How to run both in one domain?
    anilbabu

    Thanks for replying,
    I want to this type of output,
    In my project one solution two projects(one website and one WCF service)
    what i am asking is 
    this type 
    running both projects single service
    http://postimg.org/image/oijwkbn7h/
    After
    i a hosting into azure that url's like this
    How can i get this type of output
    EX: http://multliplehos.cloudapp.net/ 
    Service url: http://multliplehos.cloudapp.net/Service1.svc
    anilbabu

  • Is it possible to create a schedule in Labview . Example: i want to off the lights at 7pm and want it on at 8am. If there is can anyone teach, its for a school project. Im using labview 2011

    Is it possible to create a schedule in Labview . Example: i want to off the lights at 7pm and want it on at 8am. If there is can anyone teach, its for a school project. Im using labview 2011...thx

    Since this is a school project I recommend you do the work yourself. You will not learn asking others to do it for you. In addition, folks here will not do your homework for you. We are however more than wiling to answer specific questions for you. Post what you have done or tried and ask specific questions. I am confident you will get assistance.
    And to answer your question, yes LabVIEW can be used to implement a scheduling program.
    Mark Yedinak
    "Does anyone know where the love of God goes when the waves turn the minutes to hours?"
    Wreck of the Edmund Fitzgerald - Gordon Lightfoot

  • Use of MS Project Management 2010 to Manage Multiple projects over a given time period

    Is there some information (article/s) I can research about using MS Project Management 2010 for managing multiple projects over a given time period? I'm being asked by a potential client to take a job as a Program Manager to manage five projects all
    at once. Each of the projects has it's own MS Project Management software, project leader, and project team. An overall project plan has to be put together to manage this large project. There are some dependencies with these projects inorder to complete
    on a specific date.
    Thanks

    SSCDML --
    In order to manage this program of five projects using Microsoft Project 2010, I would recommend you do the following:
    Create a shared resource pool file containing the resources in all five projects.
    Connect each of the five projects as sharing files with the shared resource pool file to share the resources.
    Create a master project for the program containing each of the five projects as subprojects.
    In the master project, set cross-project links as needed to show dependencies between projects.
    Hope this helps.
    Dale A. Howard [MVP]

Maybe you are looking for

  • Lightroom 5 suddenly not recognizing CR2 files...

    I plugged in my card reader today to import some raw files, and lightroom said they could not be imported because the files weren't recognized. I opened them just fine in photoshop so I know the files are okay. I also tried copying to my desktop and

  • Appleworks wont open

    I have an iBook G4, have had it for about a year and a half and all of the sudden Appleworks wont open, I try and a message pops up saying it unexpectedly quit even though it was never open. I removed some file from my recent files folder because som

  • Create tables in different database schemas using EJB 3 Entity Persistent

    Hi All, I would like to find out how to get the following tasks done using EJB 3.0 Java Entity Persistent: ( i ) Create tables in different schemas such as STUDENT under EDUCATION schema and table PATIENT in HOSPITAL schema. We can then reference the

  • Help to create Adobe form to upload

    Hi Gurus, I have to create and upload pdf form to create Quote in R/3. in pdf form i should able to add item data <b>dynamically</b> form of records one by one. it could 1 or 10 or many.  this process have to happen form itself 1. mat1 EA 2000  4 800

  • AD Site / IP Range Boundary Question

    We have one small office that is included in our primary AD Site and this will not change. This site has its own boundary and DP's. I am creating a DP for that office and am wondering how I can ensure that this office will exclusively use that DP onc