Jump to content
 

What every embedded programmer should know about ...

  • entries
    29
  • comments
    15
  • views
    2,149

Contributors to this blog

Getting started with Embedded software

Sign in to follow this  
N9WXU

67 views

I have often been asked "how do I get started" in embedded software.  As I think about this question, I realize that the basic steps to get started with embedded software are nearly identical to the basic steps required to bring up a new MCU or new hardware.  There is always a bootstrapping process and a logic progression of steps before you are "home-free" and building your product.  So here is my bootstrapping process, but broken down into each step so the process is clear for those just starting out.

Step 1 - Collect the tools.

The tools of the trade for embedded engineering are quite simple.

  1. Development environment.
  2. Hardware to develop on.
  3. Measurement tools to check signals.
  4. Programming tool (sometimes built into a development kit)
  5. Serial Monitoring tool (sometimes built into a development kit)
  6. an LED (usually built into a development kit)

Step 2 - Install the development environment

This process can be quite simple, like installing MPLAB IDE, or it can be quite involved, like installing the ESP-IDF environment for the ESP32.  You will be living in this environment for the duration of your project so get it right.

Step 3 - That First Project.

This first project is THE MOST IMPORTANT ONE.  If it goes well, you are off to the races, but if it goes poorly, you will likely regret your choice of MCU and start hunting for a different one.  The first project is to blink an LED.  The actual code is trivial, but this project will ensure the entire development workflow is working and you can program your target.

Step 4 - Building Out

This is where you start exploring your new world.  What are the peripherals? How do they work?  What kinds of things do folks do with these peripherals?

Step 5 - Techniques of the experts

Now you probably know enough to bull your way to success.  I have seen some amazing projects built by folks who simply did not know how to quit.  But, it would sure be nice if you could stand on the shoulders of giants and make your program easy and effective.  Back in university one of my professors told a story of his first program.  He was a physicist and needed to run a simulation.  The idea was to write a program for the departments new computer to perform the simulation.  Like many simulation, this one involved a newtonian solver for some of the math.  This sort of solver converges on the correct answer iteratively.  So he started his work.  After a few days, he was bugging his computer science friend on the syntax of fortran and how to declare variables.  Eventually, he had it doing one pass through math.  Finally, he figured he knew his tool chain (fortran) and plowed ahead.  A week later he proudly showed off his new program to his friend.  His CS friend was impressed that this new programmer has produced such a complex application and it was working.  His friend asked to see the program and was shocked at the 1 meter high printout.  Scanning through the printout, he quickly discovered that while the physicist had figured out how to setup the math, he never figured out how to write a loop.  The entire program was the same set of functions RETYPED (he did not figure out cut/paste) hundreds of times until the math had run enough times to converge on the result.  Brute force does work....but there is usually a better way.

Enough talking.  It is time to get started.  If you want to follow along, download and install MPLAB IDE from www.microchip.com/mplab and find a Curiosity Nano Evaluation Kit DM164144 (https://new.microchipdirect.com/product/search/all/DM164144).

Next time, we will install the IDE, setup MCC and start that all-important LED blink.

Good Luck.

Sign in to follow this  


0 Comments


Recommended Comments

There are no comments to display.

Guest
Add a comment...

×   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...