Best Embedded Linux Development Tools

Published: Aug 27, 2020 4:32:59 PM / Last update: Sep 13, 2020 / by KernelCare Team

Best Linux Embedded Development tools

Most developers are used to a graphical interface for development, so when diving into the world of IoT and embedded Linux development, it’s a new experience that requires more low-level programming and command-line execution. If you ever want to build systems such as IoT, GPS, automotive technology, manufacturing, or any other low-level electronics programming, you need an embedded development environment to work with. 

Embedded Linux is common with most of these systems because it’s open-source with plenty of documentation to get started, and it requires very little upfront costs to use the operating system. For this reason, developers interested in this path usually work with Linux programming and download the right tools to connect, program, and deploy their products. We’ve compiled a list of the best embedded Linux programming tools to get started whether you’re a beginner or a professional looking for a new tool.

Contents:

  1. Embedded Systems Editors
  2. Compilers
  3. Assemblers
  4. Debugger
  5. Linker
  6. Emulators
  7. Full Software Development Environments

Embedded Systems EditorsEmbedded Systems Editors

Developers should be familiar with common GUI editors, because it’s what they work with every day. For instance, Visual Studio is a common editor for C# and VB.NET. Java developers commonly use Eclipse or NetBeans. Python developers use PyCharm. Every developer has their favorite editors, and the best tools make it easy for developers to write color-coded code to more easily identify different syntax. Since embedded programming is mainly done in C or C++, the right solution should support these two languages.

 

  • Geany: Geany is much more GUI focused on syntax highlighting and support for HTML and XML tags. It’s also compatible with Java, PHP, Python, Perl and Pascal. We’re listing this one first, because it’s the easiest of all tools for most developers unfamiliar with Unix-style commands.
  • Lime: Developers familiar with Sublime Text Editor will appreciate its successor Lime. The interface is similar to Sublime, and it’s developed in the currently popular Go language.
  • Nano: Nano is beneficial for new and advanced programmers. It’s command-line based, but it still highlights and color-codes text so that C syntax is easily understandable.
  • Bluefish: Bluefish has a few additional features than the tools listed above. It’s for Linux development as well as web development, but it also works with remote files and has spell check and undo options. For larger projects, Bluefish has better organizational features and works well with multiple projects.
  • Vim: versatile and highly configurable text editor which is present on literally every platform. Despite the relatively high entry threshold, it used by many embedded developers who like it for a possibility to customize almost everything and use it almost everywhere even on small embedded systems where no graphics mode available.

 

Compilers
Compilers

After your program is written, it’s time to compile it. A compiler turns human code into binary for use on the local system such as a laptop or server. With embedded Linux, you need a compiler that will create binaries for the CPU on a target machine, not your host one. Compilers for embedded development are also referred to as cross-compiler toolchains. 

You could assemble your own, but this is tedious especially for a new developer. Instead, several tools exist that let you compile, link, and assemble C code. If you use Debian-based Linux such as Ubuntu for your programming, the operating system already has tools available. Run the following command to install them:

 

sudo apt install gcc-arm-linux-gnueabi g++-arm-linux-gnueabi

 

If you’d prefer to build your cross-compiler toolchain, here are a few tools that offer you compiler functionality so that you don’t have to build them from scratch:

  • Crosstool-NG: This basic cross-compiler toolchain will assemble your code and create the necessary link libraries.
  • Buildroot: Buildroot is great for beginners as it has a much more robust menu system and interface. It compiles, creates libraries, and builds a directory hierarchy making it easier to navigate large projects.
  • Yocto: Yocto takes compiling a step further and builds packages for the target embedded system. It also builds binaries and libraries, but the packages make it easier to distribute and install on an external system.Yocto is the most powerful and versatile solution in the cost of its extreme complexity.

Read more: Which Linux Distro is Best for Embedded Development?

 

Assemblers

Assemblers

Human code must be assembled into machine language. Compilers convert human code into object code and then into binaries. Assemblers perform a much faster conversion by creating binaries directly from low-level code much more closely resembling machine code. Assemblers are much faster than compilers, but they are restricted to low-level languages. For advanced developers who work with low-level assembly languages, an assembler can be used to map the coded instructions with CPU execution.

Linux has its own assembler named GNU Assembler (also known as gas or as). It’s included with the GNU Binutils, which is a collection of binary tools specific to the Linux operating system. You can see a list of tools included with the installation here.

To install Binutils, run the following command:

sudo apt install build-essential

 

But if you need to compile to arm64, install:


sudo apt install crossbuild-essential-arm64

 

Debugger

Debugger

Every developer knows that code must be tested and debugged. A debugger lets you view what happens with each line of execution. Your code might be syntactically correct, but logic errors will cause the program to crash. You can eliminate these errors using a debugger.

The GNU Project has a debugger available for download. It’s specific for C-based programming, so it’s perfect for debugging embedded systems code. To install it from the command line, use the following command:

 

sudo apt-get install libc6-dbg gdb valgrind

 

Linker

Linker

When you build a program, it’s common to have several files and libraries necessary for its operations. These files are linked during the compiling process using a linker. Compilers will often do the linking for you, but if you use assemblers to turn low-level code to machine language, you might need a linker to link the project files together. 

If you use one of the compilers listed above, you likely don’t need a linker, but the GNU Project has a linker available for more advanced project builds. The linker is available with the Binutils mentioned in the Assemblers section. Installing Binutils will include the linker. Use the following command to install the tools:

 

sudo apt-get install build-essential

 

Emulators

Emulators

If you’ve ever programmed for the Android operating system, you’ve probably worked with an emulator. An emulator is a program that replicates the target environment. Any interface items, commands, output images, and features are shown on your local computer similarly to what would be shown to your users on their embedded devices.

The most popular free tool is QEMU. QEMU lets you visualize your creations on several Linux distributions. For Debian or Ubuntu distributions, run the following command to install it:

 

sudo apt-get install qemu

 

Full Software Development Environments

Full Software Development Environments

The above list of software lets you customize your development environment, but several full IDE packages are available that will do all the editing and compiling for you without installing separate resources. The IDE development environments below will give you a full GUI, cross-platform support, and some have support for web applications that could be embedded into your projects.

 

  • PyCharm: PyCharm is made for Python developers, but it has cross-platform support and works well for Linux developers. JetBrains, the developers of PyCharm, has an added feature called CLion used specifically for embedded Linux programming.
  • Qt Creator: Qt Creator is specifically designed for embedded systems programming. It has an emulator for several target devices including automotive, IoT, TVs, mobile apps and more.
  • MPLAB X: This IDE is designed for embedded development of PIC microcontrollers and signal controllers.
  • Visual Studio: Most developers know Visual Studio for its .NET programming, but the VisualGDB plugin turns the Visual Studio interface into a cross-platform Linux development platform for embedded systems.
  • Eclipse: Eclipse is a common Java development IDE, but the Eclipse IDE for Automotive Software Developers add-on provides the tools and compiler for creating solutions for the automotive industry.
  • Arduino: For developers who want to test out embedded systems programming, Arduino is a good starting point. It contains the hardware and software for a full environment that helps beginners learn.
  • ARM Keil: For a full-scale development platform, ARM Keil can be used to program for almost any ARM-based device. It’s an IDE good for professionals that need to work with more popular devices on the market. The IDE has code templates and example projects for beginners to learn from.

 

Conclusion

If you want to get started with embedded Linux development, the tools above are a complete list of what you need to get your environment running. Embedded Linux programming is a different environment than standard desktop programming, but it’s a great way to be introduced to the way IoT and automotive systems work.

Topics: iot, embedded

KernelCare Team

Written by KernelCare Team

    cover for blog

    Download Whitepaper

    Subscribe to Email Updates

    Recent Posts