Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Most useful programming language for an Electronic Engineer?

  1. Jan 19, 2014 #1
    So I'm quite new to this field but I'm trying to learn and absorb as much knowledge as I can while I study. I was casually looking on a few job sites the other day and a lot the vacancies require an engineer with at least basic programming skills. The languages listed were; VHDL, Embedded C, Delphi, C++, Assembly or other any other low level language. My question to anyone who can help is, which is the most useful/practical to have a grounding in when I'm finally ready to enter the engineering work arena?
  2. jcsd
  3. Jan 19, 2014 #2


    User Avatar
    Science Advisor

    I think it would be really useful to have good grounding in a low level language like C, which can easily run on simple embedded systems.

    If possible it would also be good to complement that with some knowledge of a higher level language like Python (pylab) or Matlab (or a clone like gnu-octave).

    The low level language like C is really good for implementing things (on a micro-controller etc), while the high level software is really good for analyzing and simulating in the design phase.
  4. Jan 20, 2014 #3
    c,c++ and asm on pic, arm, atmel, 68000 plus spice, fpga and dsp languages.
  5. Jan 20, 2014 #4
    My vote is with C and it's immediate derivatives. And for job seeking have code that you have written - if you are strong in C( etc) they will know if it crosses over to their applications. Better to be a master of one than "familiar" with many.
  6. Feb 19, 2014 #5
    Cheers for the input guys. I have decided to start with C. A lot of it is making sense and after looking at some higher level language I can see how they're all built off the basic principles of C. I also just bought an Arguing Uno and coding that thing in C is a breeze.
  7. Feb 20, 2014 #6
    Everyone says C which is a great language but realistically it depends highly on what kind of job you end up with and what your interests are. The vast majority of jobs occupied by EEs do not require C programming skills. C programming is pretty specific to working in embedded devices.

    Python is an excellent general purpose language. I highly recommend it regardless of your interests and ambitions.

    Excel VBA will be useful in almost any job.

    On top of these, it highly depends on your interests and ambitions.
    C, C++ - Embedded
    C, C++, Python, Matlab, Fortran - Scientific computing, Analog, DSP, RF
    ASM - Almost useless in practice, important to understand though
    Ruby, Python, Javascript, CSS, HTML - WebDev (more software engineering esque)
    R - Statistics

    But overall, the language you learn isn't necessarily that important. It is more valuable to have deep knowledge about what to tell computers to do, not how to tell them to do it. What I mean, is that it is better to know a lot about implementation strategies (how to work with threads/processes and when/when not to use them, how to manage shared memory, how to work with an operating system...), algorithms (how to apply algorithms, not necessarily how to write them), design methods (UML!), etc..

    For example, it is far better to know how to design a driver for a new type of sensor than it is to know every possible "pointer hack" in C. And, it is better to know what methods you need to apply to a certain data set than to know everything there is to know about list comprehensions in Python.

    Ultimately, when it comes to languages, you should learn only as much as is necessary to implement your solution to a problem. The language is not the solution, it is only the tool you use to implement it.
  8. Feb 20, 2014 #7


    User Avatar
    Science Advisor

    C++ or C# will teach you to think clearly about what you want the computer to do, and the ways it can be done. It will teach you to write concise statements correctly and to tame your code as otherwise it tends to become unmanageable.

    Once you have spent a decade in the engineering industry, you should expect to have heavily used at least three quite different languages. One of them will almost certainly be C++ or C#, so start with one of those structured C varieties as the first tool in your tool bag.

    Each time you add another language to your tool bag, you will increase your appreciation of the languages you have used before. The point will come when you realise that language is not that important. You can switch to a new language in less than a day because the way you think has been disciplined by the common factors of your wide experience.
  9. Feb 20, 2014 #8


    User Avatar
    Gold Member

    It is important to learn C regardless of what else you will do. It teaches you about programmatic structure and is applicable at many levels. I don't actually use it much as a digital hardware designer, but when I need it, I need it.

    VHDL is important if you want to design synthesizable hardware (although Verilog is easier). Understanding how to "write hardware" is important. Understanding the difference between solving a problem with C and VHDL is important. More and More hardware can now be synthesized from C (though I don't happen to do that).

    If you want to run synthesis tools you need TCL. I hate TCL. It is an "anal" language. Everyone touts as simple, but anyone that actually uses it knows the tricky stuff that happens. Any language that counts the braces in comments is weird, in my book. Digital EDA tools use TCL variants.

    If you want to write general scripts to mine data or automate processes you need perl or python (I like perl because it suits my "hacker" mentality). Python is the scripting language of choice these days. I use it to run the lab instruments and automate testing.

    So, looking at your list I'd say
    VHDL (for digital hardware design)
    and, not on your list,
  10. Feb 22, 2014 #9


    User Avatar
    Science Advisor

    I'd mostly agree with meBigGuy except I'd go for Verilog (if you're in the US) over VHDL. Verilog is also used for modeling analog circuits and is quite useful.

    C is key to understand how to program. I haven't written any C in over 10 years.

    Python is important for driving test equipment and is more modern than Perl.

    As stated above MATLAB is used a lot in industry but it is pretty easy to pick up (it is very, very high level).

    Good luck!
  11. Feb 22, 2014 #10


    User Avatar
    Gold Member

    I agree about Verilog, actually. I only listed VHDL because Verilog wasn't on the original list so I assumed non-US. Personally, I only use Verilog.
  12. Feb 22, 2014 #11
    meBigGuy, is Verilog a mainly US language? I'm from the UK, are different languages preferred in different regions?
  13. Feb 22, 2014 #12


    User Avatar
    Gold Member

    I mainly see VHDL on European projects and US Military projects. VHDL is a more formal (strongly typed), more complex language than Verilog (and in some ways more capable, with higher level SW constructs). Verilog is very C like. VHDL is very ADA like.

    I'm not exactly sure about why the division exists. I happen to think verilog is faster and easier to use. But VHDL may have advantages from the point of view of long term maintenence, reuse and large projects. I'll never switch to VHDL unless forced. System Verilog adds a lot to verilog, especially for verification.
  14. Feb 22, 2014 #13
    VHDL seems to be the norm in Canada as well actually.
  15. Feb 27, 2014 #14
    My vote is learn asm for a microcontroller like Microchip PIC's, following that C (Kernighan & Ritchie) followed by C++ or C#. The reason for my choices is that asm is the base language of any processor and understand how memory is utilized, accessed and moved is extremely beneficial in understanding the higher level languages. Microcontrollers use numerous memory mapped ports that determine functionality and while the higher languages C, C++ can do their job, if something is not working correctly, diving in with an ICE (in circuit emulator) or debugger at the asm level helps identify the problem. Understanding how memory is used with pointers (a C thing) will help the C++ concepts of new and other variable allocation/initialization issues.
    I'm only briefly familiar with VHDL, but if you plan on any FPGA work, it would be one of the languages of choice as well.
  16. Feb 28, 2014 #15
    I've found that there are four areas of engineering programming:
    Embedded - programming micro-controllers
    GUI - Programming interfaces, setting up lab experiments, and writing production support SW
    Logic Design - Programming logic ICs
    PLC - Programming industrial controls.

    For embedded, C and C derivatives are king.
    For GUIs, Visual Basic and Labview are popular
    Logic Design - VHDL
    PLCs - Allen Bradley controllers

    A EE purist may not spend time on any of these languages, but being able to step in and touch up a piece of code or write a GUI will save you a lot of time that would otherwise be wasted waiting for others.
  17. Mar 5, 2014 #16


    User Avatar
    Gold Member

    I'm not sure which language is best, but I do know that if you can grasp the "if, when, else principal" along with state machines, you should be able to adopt to any language.

    I learned these principals during senior design where we used VHDL.
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook