C++ programming and electrical engineering

Click For Summary

Discussion Overview

The discussion revolves around the role of C++ programming in electrical engineering, exploring its potential applications and relevance within the field. Participants consider scenarios where C++ might be beneficial, as well as contrasting it with other programming languages and methods used in electronics.

Discussion Character

  • Exploratory
  • Technical explanation
  • Debate/contested

Main Points Raised

  • One participant questions the utility of C++ in electrical engineering, suggesting a disconnect between the two fields.
  • Another participant proposes that C++ can be used to design algorithms for tasks such as PCB routing or FPGA logic block routing, noting that some engineers prefer C++ for its data structure capabilities.
  • A different viewpoint mentions that basic programming is often used with PIC microcontrollers, implying a preference for simpler languages unless pursuing a professional path.
  • One participant argues that programming is not strictly necessary for electronics engineers, highlighting that many may focus on analog electronics or discrete logic without programming involvement.
  • A personal anecdote illustrates the trade-off between hardware and software, suggesting that using microcontrollers and programming can simplify certain tasks compared to traditional hardware solutions.
  • There is a mention that not all electrical engineers engage in electronics design, with some moving into fields like management or sales, indicating a diversity of career paths within the discipline.

Areas of Agreement / Disagreement

Participants express differing views on the necessity and utility of C++ in electrical engineering, with some advocating for its use in specific applications while others suggest that programming may not be essential for all engineers. The discussion remains unresolved regarding the overall importance of C++ in the field.

Contextual Notes

Some participants rely on personal experiences and anecdotal evidence, which may not represent broader trends or practices in electrical engineering. The discussion reflects varying levels of programming integration in different engineering roles.

land_of_ice
Messages
136
Reaction score
0
Is C++ programming used in electrical engineering work, it really doesn't seem as though it would be,but what could it be useful for, some kind of possible scenario ? (E.E. encorporates the use of electricity to make things happen mainly, whereas C++ has to do with computer design)
 
Technology news on Phys.org
Well you can use C++ to design algorithms. For example, implementing a routing algorithm for PCB routing, or routing of logic blocks or logic clusters on an FPGA. Some engineers would prefer the use of C++ to design such algorithms, because they find it easier to implement the algorithm using data structures in a particular language. Sometimes using only C may leave you with a lot of overhead. But it really depends on the application.
 
basic is used a lot with pics - unless you plan to go professional this would be the way to go.
 
One does not need to use programming whatsoever as an electronics engineer. However, you'll probably end up doing lots and lots of analog electronics or lots and lots of discrete logic.

I have a friend who wanted to make an LED flash when a button was pushed. He was going to use a 555 timer circuit along with a transistor (around a half-dozen parts, utilizing some resistors he didn't have on hand and probably an hour or two of tinkering). I suggested that he use a small microcontroller instead, and a half-dozen or so lines of c code. Or a few more lines to make really cool lighting effects (this was for a Deathstar cake his fiancée had been commissioned to make). Ironically, I'm the EE, and he's the CompSci.

In a nutshell, programming (and microcontrollers, CPLDs, FPGAs, etc.) allow you to trade hardware for software. And if you mess up, it's often much easier to fix software mistakes (by reprogramming, or uploading new software to reprogrammable devices) than hardware mistakes (track cutting, ugly board hacks, etc.)

And of course, not all EEs (nor even a significant portion of them) end up doing electronics design (e.g. power distribution systems), design at all (e.g. testing or technical writing), or even something that nebulously falls under the aegis of engineering! (E.g. management or sales, and that doesn't count the people that decide to ditch their EE degrees and go to law school or become a priest, or a banker--things that some of my classmates actually ended up doing!)
 

Similar threads

Replies
10
Views
5K
  • · Replies 9 ·
Replies
9
Views
4K
Replies
16
Views
3K
  • · Replies 11 ·
Replies
11
Views
2K
  • · Replies 49 ·
2
Replies
49
Views
4K
Replies
1
Views
2K
Replies
38
Views
4K
  • · Replies 13 ·
Replies
13
Views
2K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 17 ·
Replies
17
Views
3K