Embedded Systems
11.5K subscribers
943 photos
199 videos
1 file
636 links
News, articles, guides, analytics, projects and startups from the embedded industry.

Topics of the channel:
◽️ machine learning
◽️ internet of things
◽️ embedded software
◽️ advanced electronics
◽️ new engineering ideas

⤵️ Share and subscribe!
Download Telegram
💻 MIT Turbocharges Python’s Notoriously Slow Compiler

Python has long been one of—if not the—top programming languages in use. Yet while the high-level language’s simplified syntax makes it easy to learn and use, it can be slower compared to lower-level languages such as C or C++.

Researchers from MIT’s Computer Science and Artificial Intelligence Laboratory (CSAIL) hope to change that through Codon, a Python-based compiler that allows users to write Python code that runs as efficiently as a program in C or C++.

In terms of what’s next for Codon, researchers are currently working on native implementations of widely used Python libraries, as well as library-specific optimizations to get much better performance out of these libraries.

More information...

#articles #programming #python
💻 5 Visual Studio code tips for embedded developers

You might have heard a lot of buzz around Visual Studio Code lately. Visual Studio Code has become a popular development environment within the general software industry over the last few years. It’s a bare-bones environment that can be easily customized using extensions and tweaks to the default configuration.

Visual Studio Code is an exciting environment for embedded software developers looking to decouple themselves from their microcontroller vendors’ toolchains and ease integration with CI/CD processes. This post will explore five Visual Studio Code tips to help embedded software developers get the most out of it.

More information...

#articles #programming #software
📃 5 tips for writing configurable firmware

Embedded products today are no longer one-off products that are manufactured for years to come. Innovation and changes in technology are exponential, with teams needing to develop platform code that can be reused to launch many products in the years ahead. To meet this need, you must embrace configurability in firmware.

In some instances, configurable firmware will increase complexity and starting costs, and perhaps even be less efficient from a memory and performance perspective. However, configurability will give businesses developing embedded products the flexibility and scalability to meet their customers challenges into the future. Let’s explore five tips for writing configurable firmware that will dramatically improve your software.

More information...

#articles #programming #design
💻 5 Tips for Writing a Makefile for Embedded Software

Makefiles are a fundamental tool that every embedded software developer needs to understand. Here is a short version of the key takeaways from the article:

▫️ Use variables to simplify maintenance and debugging of Makefiles.
▫️ Define dependencies explicitly to ensure correct build order and avoid unnecessary recompilation.
▫️ Use pattern rules and automatic variables to reduce code duplication and improve readability.
▫️ Leverage conditionals to handle platform-specific settings and options.
▫️ Consider using a build system generator such as CMake to automate Makefile generation and reduce errors.

Well-designed Makefiles can save time and improve the quality of embedded software builds. Therefore, investing time and effort in creating good Makefiles is a worthwhile investment for embedded systems programmers.

More information...

#articles #programming
🧠 Fido – light-weight C++ machine learning library for embedded electronics

Fido is an light-weight, highly modular C++ machine learning library for embedded electronics and robotics. Fido is especially suited for robotic and embedded contexts, as it is written in C++ with minimal use of the standard library, comes packaged with a robotic simulator, and provides and easy interface in which to write robotic drivers.

More information...

#libraries #programming #machine_learning
💻 Make your Code Safe and Readable with Flags

The article provides tips on how to make code more readable and maintainable using flags. The article contains several examples of how to use flags in a variety of contexts, including function calls, loops, and state machines. The author also highlights the benefits of using flags, such as reducing complexity and improving safety by avoiding multiple states being active at the same time.

More information...

#articles #programming
💻 PiccoloBASIC – BASIC interpreter for the Raspberry Pi Pico board

PiccoloBASIC is an open-source BASIC interpreter for the Raspberry Pi Pico development board that’s based on “uBASIC: a really simple BASIC interpreter” by Adam Dunkels and relying on Arm’s LittleFS fail-safe filesystem for microcontrollers.

The project is still work in progress, but currently implemented features include:
▫️ Let, if, print, for, goto, gosub
▫️ String variables (let z$=”hello”)
▫️ Floating point numbers and variables (let z#=1.234)
▫️ Builtin functions [zero, randint, not, time]
▫️ Sleep, delay, randomize, push & pop (for integers)
▫️ Maths functions like cos, sin, tan, sqr, etc
▫️ LittleFS support
▫️ Rudimentary GPIO support

More information:
The main article
The GitHub repository

#raspberry #programming
💻 From C++ to Rust: Comparison from Embedded Software Engineer

In this captivating article, an experienced embedded software engineer delves into a comprehensive comparison between C++ and Rust programming languages, providing invaluable insights for those seeking to embrace the new language. Through an exploration of various concepts and implementation details, the author reveals their delightful discoveries during months of investigating Rust.

For software developers seeking a more streamlined and secure programming experience, this article serves as an enticing invitation to explore Rust as a worthy alternative to C++. By highlighting the key differentiators and benefits, the author paves the way for an engaging journey towards unlocking the full potential of Rust's capabilities.

More information...

#articles #programming #rust
📺 how NASA writes space-proof code

Explore the intricacies of NASA's embedded coding practices in this revealing video. Delve into the "Power of 10," NASA's rule set for crafting dependable software for space missions. Uncover the reasons behind NASA's avoidance of intricate control flow, insistence on fixed loop bounds, and exclusive use of stack memory. The video underscores the significance of concise functions, meticulous variable declaration, and thorough return value checks. Essential viewing for programmers keen on understanding how NASA upholds code safety for space exploration.

https://youtu.be/GWYhtksrmhE

#video #programming
Please open Telegram to view this post
VIEW IN TELEGRAM
✍️ Firmware Static Analysis with CodeChecker

Explore the nuances of firmware static analysis with CodeChecker! Delve into the familiar challenges of C programming, from undefined behavior to memory leaks. This article introduces CodeChecker, an open-source tool built on clang's static analyzer. Uncover the simplicity of integrating CodeChecker into firmware projects to catch bugs before they reach end-users. Navigate false positives with practical strategies like adding assertions and CodeChecker-specific comments. Join the conversation on static analysis tools in the comments and anticipate insights on running analysis in CI. Elevate your coding practices with CodeChecker, bolstering your code's resilience against potential vulnerabilities.

More information...

#articles #programming #software #tools
Please open Telegram to view this post
VIEW IN TELEGRAM
📺 Mastering Decision-Making in C: Switch vs. If Statements

In this programming guide, you will learn about decision-making in C, specifically comparing switch statements to if statements. The video demonstrates why switch statements are typically faster and more efficient, especially with multiple conditions. It further explores the underlying assembly language, highlighting the streamlined nature of switch statements against the sequential nature of if statements, making it a practical guide for new programmers.

https://youtu.be/fjUG_y5ZaL4

#video #programming
Please open Telegram to view this post
VIEW IN TELEGRAM
📺 Writing an I²C Driver for Accelerometer from Scratch for STM32F4

Learn how to write a comprehensive I²C driver from scratch in C for an STM32F4 microcontroller, interfacing with the Analog Devices ADXL355 accelerometer. This tutorial utilizes the datasheet and ST's HAL (hardware abstraction layer) to guide through the entire process.

Key steps include:
➡️ Understanding the schematic layout.
➡️ Setting up STM32CubeIDE for development.
➡️ Implementing low-level functions for communication.
➡️ Initializing the accelerometer and configuring its registers.
➡️ Reading data from the accelerometer.
➡️ Testing the driver for functionality and accuracy.

This tutorial offers valuable insights into hardware interfacing, register manipulation, and sensor configuration, empowering viewers to develop robust drivers for their STM32-based projects. Whether you're a beginner or an experienced developer, this video provides practical skills for STM32 programming.

https://youtu.be/_JQAve05o_0

#video #stm32 #programming
Please open Telegram to view this post
VIEW IN TELEGRAM
👩‍💻 Exploring printf on Cortex-M

The printf() function is a staple of embedded development. It’s a simple way to get logs or debug statements off the system and into a terminal on the host. Covering a wide array of printf methods, from UART to Semihosting, this article equips developers with essential knowledge to streamline their development processes and bolster system robustness.

More information...

#articles #programming
Please open Telegram to view this post
VIEW IN TELEGRAM
🔃 Mastering State Machines

This article explores the concept of state machines, fundamental in software design. A state machine is a computational model that defines the behavior of a system through a finite set of states, transitions between these states triggered by events, and actions associated with each transition.

The article begins with a simple example of a light switch controlled by a push button, demonstrating key components: states, events, and transitions. Progressing from implicit to explicit designs, it highlights the importance of modularity and code organization.

What You Will Learn:
➡️ Basics of state machines.
➡️ Implementing state machines in code.
➡️ Importance of modularity and code organization.
➡️ Handling state transitions and events.

Therefore, by emphasizing simplicity and good design practices, this article will show you how to effectively utilize state machines in their projects.

More information...

#articles #programming
Please open Telegram to view this post
VIEW IN TELEGRAM
🦀 Embedded Rust: where are we today?

The Rust is a perspective programming language that steadily gains its popularity but not in embedded systems. Despite the benefits that the Rust brings (such as memory safety), not many companies are using it yet. Instead, they tend to stick to C or C++, because they've already invested a lot of money on writing firmware in this languages and are hesitant to change.

Startups are more interested in Rust because they don't have any old systems to worry about, but bigger companies are taking their time to see if Rust is worth it. Learning Rust can be tough, and not many companies are offering support for it. However, as the need for safer languages grows, especially with the rise of IoT, Rust might become more popular in the future. Its role in embedded systems remains uncertain for now, but it could change over time.

More information...

#articles #programming #rust
Please open Telegram to view this post
VIEW IN TELEGRAM
The cheatsheet of modern C++ language

This 😹 GitHub repository houses a handy cheatsheet for modern C++ programmers, detailing key language features and library enhancements introduced in versions C++11, C++14, C++17, and C++20.

From fundamental concepts like move semantics and lambda expressions to advanced functionalities like coroutines and designated initializers, this resource covers a wide spectrum of topics.

Whether you're a beginner learning the ropes or an experienced developer looking to stay updated, this cheatsheet serves as a quick reference for leveraging the power of modern C++ in your projects.

More information...

#programming
Please open Telegram to view this post
VIEW IN TELEGRAM
🔃 CppUTest – unit testing and mocking framework for C/C++

CppUTest is a popular unit testing framework primarily used for Test-Driven Development (TDD) in C and C++ projects. It's specifically designed for embedded and resource-constrained systems, but it's also suitable for general software development.

CppUTest offers various features:
➡️ Support for setting up and tearing down test fixtures, allowing for the isolation of tests and the management of test environments.
➡️ Offers a wide range of assertion macros for validating expected behavior and outcomes in tests.
➡️ Capability for creating mock objects and mock-based tests.
➡️ Provides with a test runner utility for executing test cases and reporting test results.
➡️ Integration with popular build systems like CMake and Make.

In summary, CppUTest gives teams an opportunity to unlock the potential for streamlined development workflows and heightened code reliability.

More information:
🔗 The project's page
😹 The GitHub repository

#libraries #programming
Please open Telegram to view this post
VIEW IN TELEGRAM
🏍 Mastering motor control: implementation in C++

This article presents a comprehensive guide to developing real-time software for motor control systems using modern C++.

It offers detailed programming guidelines, including efficient interrupt handling, memory alignment, compiler-specific optimizations, and adherence to industry standards like MISRA C++.

The guide provides practical code examples available on 😹 GitHub, demonstrating the implementation of mentioned in article techniques in motor control applications.

More information...

#articles #programming
Please open Telegram to view this post
VIEW IN TELEGRAM
🚥 3 tips for using CMake with embedded software

CMake, an open-source and cross-platform tool, allows for efficient control over the software compilation process through platform-independent configuration files, generating native makefiles suitable for any compiler environment. This versatility makes CMake a valuable tool for managing complex build environments.

☑️Use Toolchain Files to Simplify Build Configuration:
➡️Different build types (Debug On-Target, Release On-Target, Simulation, Test, and Code Analysis) need specific configurations.
➡️Toolchain files help manage these variations, facilitating cross-compilation and implementation swaps.
➡️Typically, two toolchain files (host and on-target builds) are sufficient.

☑️Automate Build Commands with Custom Scripts:
➡️Avoid memorizing long CMake commands by encapsulating them in scripts.
➡️Custom scripts simplify the build process and reduce errors.
➡️Scripts can include parameters for toolchain files, build types, and other settings, making them useful in CI/CD systems.

☑️Pair CMake with Ninja for Faster Builds:
➡️Ninja is a high-speed build system focused on efficiency.
➡️Using Ninja with CMake can result in x4 to x6 times faster compilation times compared to traditional tools like Make.
➡️Simple setup commands integrate Ninja into the build process, significantly reducing build times and improving development efficiency.

Implementing these tips can streamline the build process for embedded software, making development faster, more efficient, and better suited to modern development practices.

More information...

#programming #cmake #software
Please open Telegram to view this post
VIEW IN TELEGRAM