Jump to content

Advice on planning new Labview project


Recommended Posts

I have never used LabView before but am considering it for an automation control project I am thinking about taking on. I am looking for advice on how big a project this might be, how long it would take me to learn LabView for it, and when I said "thinking about" it means I also need your advice as to whether I am crazy for trying to tackle a project such as this in the first place so let me start by explaining what it is. (I apologize as I don't know the correct terminology but will do my best to explain.)

The project is a computer controlled ski flex tester that would have one screw-drive pressure sensitive plunger working on a vertical plane to compress and measure flex pressure on top of the ski (directly in the middle.) There would be a second linear motion system that runs a pressure sensor and separate height measurement tool under the whole length of the ski using a highly accurate indexed stepper motor (to match position with height/pressure). So we have a total of 2 motors, 2 pressure sensors and one height sensor. It would need feedback control from the vertical pressure/plunger system, as well as data capture and database storage with a graphical analysis and GUI control interface for certain parameters (ie start test for 150lbs person).

Now for the second part of the equation: me. I have 15 years of programming experience in VB, C, ASP, .NET, am strong with databases, have some experience in RS232 hardware communication, but very little robotics and only high school electronics education.

So here are the questions:

1. Is LabView the correct tool for the job or is straight Visual Studio a better option?

2. What is a ball-park estimate of time for a) a lab view expert, and b) me.

3. Am I crazy to start this as a newbie?

4. It seems like there are a lot of tutorials and sites like this to help, is it reasonable to think that you can get help for specific questions and problems quickly, or are unforeseen roadblocks a real possibility.

Many thanks for any help you folks can provide.

Link to comment

QUOTE (xcgeek @ Mar 26 2008, 07:34 PM)

I have never used LabVIEW before but am considering it for an automation control project I am thinking about taking on. I am looking for advice on how big a project this might be, how long it would take me to learn LabView for it, and when I said "thinking about" it means I also need your advice as to whether I am crazy for trying to tackle a project such as this in the first place so let me start by explaining what it is. (I apologize as I don't know the correct terminology but will do my best to explain.)

The project is a computer controlled ski flex tester that would have one screw-drive pressure sensitive plunger working on a vertical plane to compress and measure flex pressure on top of the ski (directly in the middle.) There would be a second linear motion system that runs a pressure sensor and separate height measurement tool under the whole length of the ski using a highly accurate indexed stepper motor (to match position with height/pressure). So we have a total of 2 motors, 2 pressure sensors and one height sensor. It would need feedback control from the vertical pressure/plunger system, as well as data capture and database storage with a graphical analysis and GUI control interface for certain parameters (ie start test for 150lbs person).

Now for the second part of the equation: me. I have 15 years of programming experience in VB, C, ASP, .NET, am strong with databases, have some experience in RS232 hardware communication, but very little robotics and only high school electronics education.

So here are the questions:

1. Is LabView the correct tool for the job or is straight Visual Studio a better option?

2. What is a ball-park estimate of time for a) a lab view expert, and b) me.

3. Am I crazy to start this as a newbie?

Ignoring the mechanical parts, it doesn't sound bad at all for an expert. Everyone eats a project one bite at a time, you are working with a handicap. LabVIEW is a data flow programming language which is wonderful, but your intuition and thinking is all wrong for it. It takes a while for it to dawn you all the ramifications. LabVIEW is very gentle in terms of getting syntax right. In many cases syntax is never an issue. This save a lot of time for the new user and the old. Much of the helpful information is online and that always takes time to get in synch with. If you have the subscription service then you can call for help and the NI engineers are very kind and excellent. (Lets see you get that from those other languages.)

I couldn't possibly guess how long it would take anyone. Not my forte. No one makes me count time like that so i can't guess well.

QUOTE

4. It seems like there are a lot of tutorials and sites like this to help, is it reasonable to think that you can get help for specific questions and problems quickly, or are unforeseen roadblocks a real possibility.

Many thanks for any help you folks can provide.

The forums at NI, LAVA, and this one are all responsive. All are searchable. You can get lot's of help . Sometimes the quality of the questions makes a difference. I personally think you need to explain the decisions you will be trying to make with the DAQ you take. Explaining the problem at that level can get you some really interesting solutions. If you go at it asking very specific things...what if those specific things are off track?

I certainly have not regretted learning LabVIEW. I find it fascinating (though I find the documentation of functions too dense and too much left unsaid at the same time). A hard core programmer has different hammers to choose from, but I am happy with this one.

Enjoy,

Mike

Link to comment

If you're really that green to LabVIEW, but have the kind of experience you're talking about with other languages, I'd recommend arranging to take the LabVIEW Basics course offered by NI (or through a local NI Alliance member company). It's a little pricey, but you will more than make up for that cost in the time and tears you'll save on the project. You might also do well to consult a local LabVIEW expert (CLD or CLA) early in the project to help you lay out a plan for the software.

When introducing new people to LabVIEW, I've found that it's much harder for them to really grok the language unless they have a "real" project to cut their teeth on. You obviously won't have that problem, so from that perspective I think what you're talking about is a great project. However, the surest way to ruin someone's (or your own) enthusiasm for a new toolset is to throw them in the deep end and leave them to drown, so regardless of how you approach it you will need a safety net of some kind. Either knowledgeable people to go to for help, or a nice large cushion of time to let you make some mistakes and fix some poor choices along the way.

For the record, my first project (years ago) was more complicated than what you're talking about, and I had none of the resources I mentioned above. It was a nightmare, and at the end of the day the code was horrid. (For those of you who know me, I'm not talking about that project. This is a different one. An even worse one :P.)

Link to comment

Labview is great for this sort of thing and I don't think it's an overly complicated project if you have some good programming experience (which you do). You might have to make some adjustments for working with real hardware and sensors, but the great thing about the Labview development environment is how easy it is to prototype hardware functions, assuming you can hook everything up to the development system. You don't mention too many specifics about the hardware you'll be using. Are you able to use NI hardware for your system? If so, Labview is practically the default choice.

However, what you'll be lacking, no matter how much programming experience you have, is the ability to really structure the Labview code effectively so that it is easy to maintain and expand in the future.

What I've found with beginners is that it doesn't take them too long to get used to the very basics of using VIs and connecting wires, but it does take quite a bit of experience before someone is able to sit down and create intelligent Labview code without constant direction. All I can do is echo the other reccomendations to try to get hooked up with some training/guidance so that you'll see the foundation for a smart and organized application.

One thing I've noticed is that it to me it seems that NI has added many features to the language which serve to ease the transition into dataflow programming. Sequence structures for example. I've seen a lot of examples where a programmer used to C or C++ will use them extensively to control the flow of their code, whereas a state-machine is often much more appropriate and flexible. I did this myself when I started with Labview. If you're not careful, your code will become utter hell to work with.

That said, you'll learn best by doing and I'm sure you'll be able to make your project work within a reasonable timeframe. Just treat it as a learning experience and be prepared for the re-write after you become more accustomed to G.

Link to comment

QUOTE (Andrew Marles @ Mar 26 2008, 09:56 PM)

Are you able to use NI hardware for your system? If so, Labview is practically the default choice.

The hardware controller hasn't been purchased yet, just the motors and sensors so I think this means if I'm going with LabView I should get a NI compliant controller?

Thank you for all the very helpful advice. The $1600 price tag for the LabView Basics course is quite steep, but I can see that it could save considerable time. I'll have to see what the budget allows.

Link to comment

QUOTE (xcgeek @ Mar 27 2008, 01:29 AM)

The hardware controller hasn't been purchased yet, just the motors and sensors so I think this means if I'm going with LabView I should get a NI compliant controller?

Welcome to LAVA-- You've started in the right spot.

Definitely better to go for LabVIEW compliant controller, something that already has LabVIEW drivers ready for it. (But that doesn't necessarily mean an NI controller.)

I've had good luck with stepper motor controllers from Copley Controls-- For a variety of reasons I ended up talking to my controllers through a rs232 port, homebrew drivers, but I think they also can be controlled with through a CAN network using pre-made drivers. Lots of other options from other manufacturers too-- don't feel locked to the NI motor controllers, just from reading the specs, they seem really good, but they might be more than you need and they cost accordingly.

Best Regards, Louis

Link to comment

"I have a bad feeling about this". If I were on my own there is no way I would take on something like this while trying to learn a new language. Most likely LV can do what this project requires, but with your background and experience in other languages it might be a lot more efficient for you (and less frustrating to your customers) to just learn the robotics (not that hard) and write the code in something you know already. There is no way that anyone can predict just how long this project will take. I inherited a project that was supposed to be done in "90 days", but went 6-months overdue because the engineer (a C programmer) was learning LV while he was working on the project. This guy eventually got so frustrated he hired me - then left - and I inherited the project as a "lone gunman". I spent the next 6 months on-site with the customer breathing down my neck daily just getting the code to work, then another year going out there to fix the occasional bug that crept up almost weekly. "Newbie" code is buggy, not well written and horrendous trying to decipher. I got it done, but it almost resulted in my permanent burnout.

I don't want to discourage you. LV is well worth knowing. But start small. "Baby steps". And think of your peers. :)

Link to comment

QUOTE (PaulG. @ Mar 27 2008, 09:36 AM)

"I have a bad feeling about this". If I were on my own there is no way I would take on something like this while trying to learn a new language. Most likely LV can do what this project requires, but with your background and experience in other languages it might be a lot more efficient for you (and less frustrating to your customers) to just learn the robotics (not that hard) and write the code in something you know already. There is no way that anyone can predict just how long this project will take. I inherited a project that was supposed to be done in "90 days", but went 6-months overdue because the engineer (a C programmer) was learning LV while he was working on the project. This guy eventually got so frustrated he hired me - then left - and I inherited the project as a "lone gunman". I spent the next 6 months on-site with the customer breathing down my neck daily just getting the code to work, then another year going out there to fix the occasional bug that crept up almost weekly. "Newbie" code is buggy, not well written and horrendous trying to decipher. I got it done, but it almost resulted in my permanent burnout.

I don't want to discourage you. LV is well worth knowing. But start small. "Baby steps". And think of your peers. :)

Ditto Paul's comments!

The easiest/cheapest way to start is to ask your local NI rep to visit to get you started. That will not always get you good code if the local rep is not an experienced developer.

While talking to the NI rep, ask them for the name of a local developer or company with a good reputation in your area. Hire them to cunsult on the code structure and methods to handle your challenges. If the local LV person/group knows their stuff, they should be able to layout a structure that will work the first time (well almost).

Ben

Link to comment

QUOTE (xcgeek @ Mar 27 2008, 01:29 AM)

Have a look at LabVIEW Mastery.

QUOTE (PaulG. @ Mar 27 2008, 10:36 AM)

I don't want to discourage you.
LV
is well worth knowing. But start small. "Baby steps".

I couldn't agree with Paul more - learning a new programming language is like learning a new spoken language - there might be some similarities with other languages that you speak, but there'll be more differences than not. Going from C to LabVIEW? Think English to French - you're not going to be speaking it fluently on your first project.

Link to comment

QUOTE (xcgeek @ Mar 27 2008, 12:29 AM)

The hardware controller hasn't been purchased yet, just the motors and sensors so I think this means if I'm going with LabView I should get a NI compliant controller?

Thank you for all the very helpful advice. The $1600 price tag for the LabView Basics course is quite steep, but I can see that it could save considerable time. I'll have to see what the budget allows.

For an experienced programmer, I would recommend starting by purchasing the Basic I book, reading through it, and working through the exercises. The course might be nice but is rather expensive and somewhat basic for someone who already understands programming concepts. If that seems to go well, then I would proceed with the Basics II book and exercises before actually starting your own project.

In my opinion LabVIEW can very easy to learn the basics of but there can be some gotchas along the way, especially for people with only procedural-based programming language(s) background. Your project sounds quite doable, provided the schedule is long and flexible.

Link to comment

Thank you again for all the advice and encouragement. As I've been a full time programmer for so long, I readily recognize the warning signs and there are enough red flags going up to give me some pause. It certainly has given me a much clearer idea of time and effort commitement:

"I have a bad feeling about this"

"there can be some gotchas along the way"

"but your intuition and thinking is all wrong for it."

"learning a new programming language is like learning a new spoken language"

"If you're not careful, your code will become utter hell to work with."

"provided the schedule is long and flexible"

"Either knowledgeable people to go to for help, or a nice large cushion of time to let you make some mistakes and fix some poor choices along the way."

I may take PaulG's advice:

"but with your background and experience in other languages it might be a lot more efficient for you"

and investigate the NI Measurement Studio that would allow me to work in MS Visual Studio.NET and work in an environment I'm familiar with. Perhaps I will post a question in the "NI Developer Forum -> Software Boards -> Measurement Studio for .NET Languages" to see if people familiar with that product have an recommendations (unless someone here has experience with NI Measurement Studio.)

Thank you again for all the help - No matter which way I go, I know that your responses just saved me a lot of grief, time, and tears. :book:

Link to comment

QUOTE (xcgeek @ Mar 27 2008, 10:48 AM)

Thank you again for all the help - No matter which way I go, I know that your responses just saved me a lot of grief, time, and tears. :book:

Which is not to say that it can't be done in LabVIEW -- LabVIEW is probably a great fit for this application but you can't just jump into a new language (especially one that requires a paradigm shift in thinking like LabVIEW does) and expect good results. All software projects require good architecture, planning and execution/implementation (regardless of language).

Link to comment

QUOTE (Omar Mussa @ Mar 27 2008, 03:02 PM)

Which is not to say that it can't be done in LabVIEW -- LabVIEW is probably a great fit for this application but you can't just jump into a new language (especially one that requires a paradigm shift in thinking like LabVIEW does) and expect good results. All software projects require good architecture, planning and execution/implementation (regardless of language).

Well put.

Link to comment

I'm going to offer a bit of a different perspective here and it's offered just FWIW.

There are several issues/threads involved here.

1. Can LabViEW be used for such a project -- and the answer to that is: obviously yes.

2. Is LabVIEW the "best" choice for such a project -- that's more difficult to answer unless we agree on the criteria for "best" but, FWIW, I'd say LV is better for such a project than most other languages other factors being roughly equivalent.

3. Can one learn LF while doing such a project -- Yes, of course that's possible; moreover, what's interesting about that question IMO is its converse: viz, can one learn C++ <or name your favorite language> while doing such a project? I think that answer to that is -- almost undoubtedly no, again other factors being roughly equivalent.

4. What role does prior experience with other languages and similar projects (in terms of scope and such) play in determining how easily one could learn LV while programming such a project? Here's the really tough one IMO. I think it all depends on what your specific prior experience was, how well you follow the general guidelines on modularizing code etc, and how much comfort you have in stretching into a new paradigm while coding an active project?

Depending on your timeframe, budget and personal predilections I would suggest considering this to be an ideal opportunity to really learn ABOUT programming in LV -- but only as long as that doesn't compromise the commitments you have to the ultimate customers of the project. Yes, your code won't be "ideal" -- how could it be? Of course it won't be as easy to rescale later -- how could it be? But would it be scaleable, maintainable, and extensible -- YES, if you follow the guideline of something like the LaVIEW Style Book (some title like that) from Blume, or the LabVIEW style documents.

FWIW I think the most fundamental question for you (or it would be were I in your shoes) is: How best can I reasonably serve my clients while also developing my skill base and developing code which will be allow for the big 3 (scaling, maintaining, extending) in the future? LV is, IMO, a much better solution for the long-term than any other language I know BUT your clients deserve your primary commitment.

OK so that's probably more than 2 cents but it's likely worth less than 2 cents...

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.