LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Hi, everyone..I'm working as a programmer on electron

ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioPS: please forgive my English..I'm still learning.
0 Kudos
Message 1 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioHi Erminio,

1) No syntax.

2) Source code reads like schematic diagram. I already new how to read a schematic. I just had to familiarize myself with what all the "chips" I had to work with.

3) No memory concerns (within reason).

4) Speed of development. A Phd I used to work with taught both LV and CVI. When asked to quote a job, he would estimate the LV project, and double it for the C version. (Bit stuffing and the like excluded)

5)No syntax.

6) No function call concerns. Function calls (i.e. sub-VI calls) are handled transparently by development environment. You have to work pretty hard if you want to screw up function calls.

7) Power. If you have the full package of LV you can can quickly tie together a plethera (sp?) of connections displays
analysis that bogles the mind once you know what you are doing. I have been at it for quite a while now and have yet to explore all of what LV has to offer. (thats why I read this list, it lets me explore interesting whole that others stuble into.)

😎 NI support. They are willing to say if their stuff will do something or not, nad sign their name to it. If it does not work they will get it fixed or find an alternative solution. I strongly urge you to search this site for "Aaron Galfand" to see what I mean.

I can go on and on but let me close by saying,

No syntax.

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 2 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioWow, I'm impressed both for your answers (and your curriculum..) and about Mr. Galfand! Just one question: all this pre-made stuff could be a weakness? I mean: as an assembler programmer, I know that I have full control of the HW (I hope so..); I guess sub-VI are like macros, so is it possible that they aren't optimized for my task?

Thanks

Erminio
0 Kudos
Message 3 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioHi, Ben..another thing, if I can: I see that a lot of National HW stuff is often used with LV: is the language useful without this too or should I buy a board even for a serial communication?
Please forgive me if a waste your time with questions maybe obvious..

Thanks

Erminio
0 Kudos
Message 4 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioActually, all the premade stuff is a major strength. National Instruments is very good at building the low-level drivers for accessing instrumentation. What's more they do it in a way that is general enough to provide lots of tools for customizing their operation. For example, with the DAQ drivers, if all you need to do is grab a bunch of samples at some predefined rate (no triggering, no gating, nothing fancy), they have subvis that do that. However, thise subvis are built on routines--that you also have access to--that provide all the bells and whistles.

But as in any environment, if you don't like the way they did something, you can always write your own version of the driver from scratch--or in some cases take their code and modify it.


Actually, subvis are more like subroutines. Macros are chunks of code that get reused by being inserted inline each place they are used. Hence, if you use the macro three times, there are three copies of it in memory. A subroutine (typically) exists in one place in memory and is called--there are exceptions called "reentrant" VIs, but thats a topic for another time.

I know that last bit is a little bit of hair splitting, but in some development environments (which shall remain nameless) once a macro is used you have to manually edit each instance independently if you want to change it...

By the way, another couple of my favorite advantages of LV is that it is readable code. I have had people who didn't even know LV be able to look at my code and in broad terms be able to tell what it was doing.

Also because values are passed explicitly by wires connecting icons (subvis) together, there are also no such thing as named variables.

Hope this helps...

Mike...

PS: Did an
ybody mention that with LV there's no syntax?

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 5 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioOnly buy hardware if you need it for what you are doing. So if you have an unused serial port on your PC--use it. The only time you might have to add a card for serial communications is if you don't have a port that's available, or if you need some special type of serial port--like an RS-485 connection (the ones in your PC are RS-232).

What's more I have written many LV applications that don't use any external HW at all. Things like off-line analysis programs, or data viewers.

Personally, I tend to consider LV as being a truly general-purpose programming language. C and C++ are special-purpose languages for people wanting to write operating systems and word processors 😉 ...

Finally Erminio, there is no such thing as wasted bandwidth o
f you are using it to learn and educate yourself. And remember, even obvious questions need to be asked (and answered!), because if they aren't, all you are left with are assumptions.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 6 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioThanks a lot, Mike; I'm going to learn LV.

Have a good day

Erminio
0 Kudos
Message 7 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioIf you are only doing serial comm (RS232) then you won't need any
special hardware.

As for a choice of languages, you could easily do this task in
LabVIEW, LabWindows/CVI, Microsoft C or C++, Visual Basic, QuickBASIC,
or any of a number of languages. They all support serial I/O without
any special requirements or options.

The big advantage to LV is the shallow learning curve involved. It is
very easy to learn, essentially it amounts to flowcharting. If you
can read schematics or have ever coded ladder logic for a PLC, then
you will find LabVIEW trivial.

The big drawback to LV is the cost for the development system, which
runs around 1500 dollars and up. It is certainly easier for
development than C++ but if you can work in MSVC++ or V
isual Basic,
the tools cost is certainly much less for these environments (only
around $100).

As for development time, LV is generally much faster than C++ and is
certainly easier to learn, though there are performance limitations in
LV that don't really exist in C++. LV may or may not be easier and
faster to develop in than VB but that depends on the individual.

If this is a one time project and you don't normally do hardware test
or data acquisition, then you may be better off with Visual Basic. If
you intend to do a lot of development of this sort, then it's probably
worth investing in LV.

Douglas De Clue
LabVIEW developer
ddeclue@bellsouth.net


Erminio wrote in message news:<5065000000050000000A8E0000-1027480788000@exchange.ni.com>...
> Hi, Ben..another thing, if I can: I see that a lot of National HW
> stuff is often used with LV: is the language useful without this too
> or should I buy a board even for a serial communication?
> Please forgive me if a waste you
r time with questions maybe obvious..
>
> Thanks
>
> Erminio
0 Kudos
Message 8 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioHi All,

Sorry about the delay in responding, I was in the lab coding yesterday.

Thank you Mike for answering in my behalf.

I would like add ac ouple of other thoughts (partial hair-splitting begins).

LV is the development environment.
"G" is the language.
I say this because it is only a matter of time before MS develops their own environment to develop "G".

LV (for me) is fun. I do it in my spare time. I can not get enough of it.

Some would call it an addiction.

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 9 of 17
(3,886 Views)
ics boards using assembler and looking for a high level language (I mean, PC based) to communicate with the boards and to control. Someone suggested me C++..please, tell me: why did you choose LabView? Why could it be better than C++? Thanks a lot! ErminioI only learnt LV at my first job after getting a BE (Hons) in Electrical Engineering. (Uni didn't have LV) As part of my degree learned C and a bit of Java.

The main project for my degree involved a micro controlled robot that got heaps of data and sent it to a PC via a serial port.

Writing C for the micro was the easy part. Getting the data to the PC was the tricky part. My partner wrote the code for the PC and had a problem getting the serial port to work, due to the fact that the PC's in the electronics lab were Windows 98 and in the computer lab they were Win2k. Win 2k doesn't allow you to access the serial port without the proper driver.
So my partner lost a couple of weeks try to get it to work.

We didn't get it finished in the end.

If I did it
again, I would put most of the control functions on the PC and write the PC software in LV. (Effectively using the Micro to get data and control the motors).
(And it would be finshed on time!).

I also like LV because it doesn't have syntax. LV makes the code look pretty with the colours.
0 Kudos
Message 10 of 17
(3,886 Views)