Embedded software interview question collection

Hi all,

Lately I've been assigned to interview many candidates. Sometimes it's hard to ask questions that actually can reveal candidate's true potential, skills, etc.

I'm trying to collect some good interview questions for embedded software engineer positions Can anyone contribute? Thanks!

Reply to
dreamguy007
Loading thread data ...

I don't believe you would be able to do in during interview. Rejecting a bad candidate is the best thing interviewer could expect.

Start with the definition of "volatile".

--
WBR, Yuriy.
"Resistance is futile"
Reply to
Yuriy K.

Describe a situation where you had to diagnose a bug caused by priority inversion.

Reply to
Clifford Heath

Give them a circuit diagram of one of your products and ask them to look over it for a few minutes and then have them describe to you what the components are for, why pins are connected in a certain way etc. You don't necessarily expect an embedded software engineer to be able to design the circuit, but this will give you an idea of whether they are comfortable working at that level.

- Charles

Reply to
charlesoram

Ask them about their favorite programming language, CPU, or EDA software, bench scope, etc. Ask them what features in it they hate the most.

A person who can't list the faults or shortcomings in their tools haven't used them enough.

Kelly

Reply to
Kelly Hall

We would:

  • Ask them to calculate the number of pixels on the screen that corresponded to some real-world distance.

  • Ask them to write said calculation in C (it was just one line -- at least if we were going to hire them).

  • Ask them to rewrite said calculation without using floating point.

  • Then we'd ask some leading questions to see if they'd realize that they had an overflow or underflow problem (with 16-bit integer arithmetic you either had one or the other).

  • Ask them how to avoid underflow.

  • Ask them how to avoid overflow.

  • As a bonus, if they were still standing we'd ask them how to rearrange the calculation so that it would round to the nearest 1/2, instead of always down.

It's amazing how many telecom guys have never realized that 'int' means 'could be 16 bit' and how many 16-bit processor guys have never realized that 'long' means 'at least 32 bits'.

We would _not_ look for people to get all of the answers right while standing there by the white board. What we _did_ look for was a general knowledge of C, flexibility, the ability to listen to guidance from fellow engineers, and grace under pressure.

Later on we'd ask them to describe some project that they'd worked on. We were looking both for communications skills and for indications that they had actually participated in the project somehow, and not just been responsible for keeping the coffee warm.

Then we'd hand them off to the EE's, who would make them read schematics. Once again they wouldn't necessarily be expected to know how to do circuit design, they were just expected to know how to hook up an oscilloscope -- even knowing how to ask an EE to hook up an oscilloscope was considered sufficient.

And Lewin, if you're listening -- we didn't ask one C++ question, yet when we trained them up on it they did just fine.

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Posting from Google?  See http://cfaj.freeshell.org/google/

"Applied Control Theory for Embedded Systems" came out in April.
See details at http://www.wescottdesign.com/actfes/actfes.html
Reply to
Tim Wescott

-- snip --

I disagree. While you can't always identify good people, you can craft interviews so that good people can shine, and the bad candidates are revealed (mostly).

I think the biggest suggestion that I would make is that you shouldn't ask questions that have specific answers. Ask big, open-ended questions and pay careful attention to the responses. If your company is big enough to have an HR department this will give them fits, because the best way to avoid lawsuits is to put on blindfolds and have candidates fill in scan-tron sheets. Persevere, however.

I try to look for:

  • General competence with embedded systems design (not just writing programs in C or Ada or whatever).

  • General problem solving skills and a will to participate.

  • Curiosity and interest beyond just the software.
--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Posting from Google?  See http://cfaj.freeshell.org/google/

"Applied Control Theory for Embedded Systems" came out in April.
See details at http://www.wescottdesign.com/actfes/actfes.html
Reply to
Tim Wescott

Huh? Why would calculating the number of pixels on a screen involve floating point?

Steve

formatting link

Reply to
Steve at fivetrees

Well ive been arguing with a company because they cant get to grips what volatile really does and because of this the new piece of hardware they have released witb an embedded processor does not work if the cache is switched on!!!!

I have tried for 2 years to get them to understand but they still screw the design up.

I now need to got through all my code and try to move every variable into a seperate block of memory so there will be no memory corruption.

joolz

Reply to
Julian Gardner

floating

I took it that Tim was asking about distance on-screen, which I took could be diagonal. In that case, assuming the screen was flat, the natural solution would require a square root. Performing the calculation without floating point would demonstrate some skills useful in low-end embedded systems - how to get good enough answers. Of couse it might just be a trick question as in max(abs(x1-x2),abs(y1-y2))...

Well, that was my interpretation anyway.

Peter

Reply to
Peter Dickerson

I would ask what they have done outside of work that is relevent. If someone is passionate about something then they will do it for fun as well as when they have to.

Reply to
Tom Lucas

Show the candidate "coax" on a sheet of paper and ask how many syllables it has. The correct answer is of course two.

Peter

Reply to
Peter

Ah, my bad. I missed the "that corresponded to..." bit. Oops.

Steve

formatting link

Reply to
Steve at fivetrees

Off topic, but ... maybe it's because my brain hasn't clicked on yet, but what has the use of volatile got to do with cache?

--
Michael N. Moran           (h) 770 516 7918
5009 Old Field Ct.         (c) 678 521 5460
Kennesaw, GA, USA 30144    http://mnmoran.org

"So often times it happens, that we live our lives in chains
  and we never even know we have the key."
The Eagles, "Already Gone"

The Beatles were wrong: 1 & 1 & 1 is 1
Reply to
Michael N. Moran

volatile on a variable stops a compiler from doing optimisations like caching. This is useful if there is more than one thread using the variable because the actual variable and a cached copy would not match.

Peter

Reply to
Peter

And how would the compiler do this? Will it insert a complete cache flushing sequence after the variable update?

On the other hand, if you only worry about different threads, you do not need to worry about the cache. All threads run on the same CPU (multi core excluded here ;-) and will therefore use the same cached value, no problem.

You only need to worry about the cache if there is some kind of DMA at work. You might also run into problems with self modifying code using separate data and instruction caches.

Use volatile for variables that get updated outside the normal execution flow (from an interupt or from another thread). This prevents the compiler from re-using a value read into a register, but this has nothing to do with caches.

--
Stef    (remove caps, dashes and .invalid from e-mail address to reply by mail)
Reply to
Stef

Say the variable is really a hardware status bit, memory mapped. If declared volatile in the code there will be a memory access for each read. If the hardware diverts that read to the cached value, it will no longer reflect reality. So the system needs some means of automatically invalidating the cache. To me, this is a primary objection to using memory mapped i/o ports, which can easily be avoided with a separate i/o space.

I don't know if this is the OPs problem, but it seems likely.

--
"I was born lazy.  I am no lazier now than I was forty years
 ago, but that is because I reached the limit forty years ago. 
 You can't go beyond possibility."              -- Mark Twain
Reply to
CBFalconer

You can use the online testing at brainbench.com as the input filter for the bulk.

Ask about the design challenges that he dealt with in the past, and the real accomplishments.

"Can you please tell me what are you good at".

Vladimir Vassilevsky

DSP and Mixed Signal Design Consultant

formatting link

Reply to
Vladimir Vassilevsky

No square roots -- it's more like you need

distance_on_screen = distance_out_there * scale_factor,

and the scaling factor isn't an integer.

Besides, you could always do integer square roots.

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Posting from Google?  See http://cfaj.freeshell.org/google/

"Applied Control Theory for Embedded Systems" came out in April.
See details at http://www.wescottdesign.com/actfes/actfes.html
Reply to
Tim Wescott

Interesting. I didn't see one that really pertained to embedded systems, but one could do some generic stuff.

No, don't. I've been there. Everyone is prepared to talk about design challenges and accomplishments.

Ask them to choose some project that they feel proud about, and give a

45 minute chalk talk (you may have to explain what 'chalk' is to the 20-somethings). We* would ask them to give it as if we were engineers new on the team, or visiting firemen, or whatever. In the course of the chalk talk look for design challenges they overcame, and accomplishments that they made.

If they can't talk about the project that they're most proud about and make it clear what they've done personally then chances are they haven't really done anything.

Note that you will have to make some judgments about personality, but you can usually tell the difference between 'modest' and 'didn't do anything'.

I always liked "Can you please tell me what you're bad at". I finally ended up starting my answer with "Answering contrived, trendy interview questions".

Once again, this is a canned interview question that folks will have canned answers to. It's not a bad question to ask, but it's easy to fake the answer.

For a while we were interviewing candidates, and for some reason _everyone_ was bringing a physical sample of their work. We had EEs bringing circuit boards they'd designed, software guys bringing sheafs of paper. I'm sure that the mechanical engineers had to deal with dripping hydraulic cylinders. Come to think of it, I'm glad I wasn't interviewing for an engineer to develop sewage treatment equipment...

  • I say "we" because this came out of a several-year long push at a previous employer years ago. I was one of a few lead software engineers that did a lot of interviewing. While I contributed to what was asked, I was not the main developer of the interview strategy. I thought it was really keen, however, and would certainly do it again should I ever have to interview someone.
--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Posting from Google?  See http://cfaj.freeshell.org/google/

"Applied Control Theory for Embedded Systems" came out in April.
See details at http://www.wescottdesign.com/actfes/actfes.html
Reply to
Tim Wescott

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.