Being one of the most important parts of current technology, Embedded systems programming is also getting enhanced along with technology day by day. People who want to start embedded development generally have their interest because of two reasons:
- They want to make their software affect physical things.
- They want to learn the exact thing that’s happening down there at the bottom.
So, the initial question, which came to mind is, “How would I get started with embedded systems programming?”
If you are looking for the first goal mentioned above, we would recommend you access the many good hobbyist embedded platforms such as Arduino, Raspberry Pi, Particle, etc.
But if you are willing to achieve the second goal mentioned, your task will be a bit complicated. So, here we offer you a guide, which can help you get started with Embedded systems programming.
Embedded Systems Programming Tutorial For Beginners:
Learn ‘C’
‘C’ has been selected as an elementary language for the majority of embedded toolchains.
If your embedded software coding requires more than a few hobbyist platforms, then undoubtedly you will need to learn C.
#include<stdio.h> #include<conio.h> void main() { char nm[20]; int i,n; clrscr(); printf("Enter the your name \n"); gets(nm); printf("How many time\n"); scanf("%d", &n); for(i=1;i<=n;i++) { printf("%3d\t%s\n",i,nm); } getch(); }
Learn Some Basic Electronics
This doesn’t mean that you have to take any class on it. You just have to get a basic knowledge of voltage, current, power, resistance, and Ohm’s law.
Online tutorials or experimenting with simulators and real circuits can be proven as useful measures for it.
Get the basic Equipment
As we all know it is embedded software, so it has to deal with real-world objects too. For this, you will need some physical equipment such as:
Soldering Iron, batteries, LEDs, jumper wires, Some testing devices like Digital Multi-Meter (DMM), and A hardware debugger / JTAG adapter (Eg: OLMEX adapter, or ST-Link)
You can also take some help from a Logic Analyzer such as Saleae.
Understanding Web Statistics (AWStats) – How People View A Website?
Choose a Microcontroller and Toolchain
Now, when you have all of the basic components and coding ready for your project, you will need a microcontroller to run your programs, a compiler to compile your programs for your target microcontroller, and some additional tools to load your programs on your hardware and debug them.
The most admirable microcontroller is STM32 family of microcontrollers which are well supported by toolchain: arm-gcc along with openCCD.
This combination may not be as sophisticated as Arduino, but it is suitable for most real-world projects.
You can get an STM discovery kit, which is cheap, relatively accessible, and can be proven as a good starter option.
The most common architecture for embedded micros and arm-GCC can easily target all of them.
open CCD is the open software, that will communicate with a hardware debugger and will offer a gdb debugger server, which will help you in loading the program and stepping through your code running on target with gdb.
Pick Components & Dig into their Datasheets
Now, you are all set to see some results. Now, all you have to do is take out some components and then arrange them together.
The ideas of taking components can be taken from Sparkfun and Adafruit. If you are willing to see some cheaper options, you can also consider Digikey and Mouser.
After finding the things you want, you will have to dig in their datasheets (essentially the manuals for electronic components).
This will provide you with information on how will it work and other important queries. But datasheets can be tricky, you must not rely on them completely.
Also Read: Top 10 Programming Languages
Verdict
Datasheets are the source of all information, but they don’t need to be accurate every time. This will give you a basic idea of how to get started with Embedded Systems programming tutorial.