Embedded firmware consulting is the fastest way for you to resolve issues and gain guidance on your path towards developing high quality software for your embedded products.
There are three basic ways in which Swedish Embedded Group can help:
- Direct involvement in development of your firmware project: RTOS, C Programming, CI automation development, device driver development and more.
- Education and training: which improves your understanding of how you can architecture things yourself.
- Recruitment and talent acquisition: developers that can get hired by you and continue their career as part of your team.
If you are ready to have an in depth discussion regarding any one of the above then go ahead and schedule a call right away.
Problems firmware consulting solves
Embedded Firmware Consulting is definitely for you if you are facing any one of these problems:
- You need to bring order to your firmware: you have a firmware but you have no way to state with confidence that it works and you want to be able to do that.
- You need to add new device driver support: you have new hardware on your board that needs to be supported.
- You need to add new application functionality: this can be BTLE (Bluetooth Low Energy) connectivity, motor control or just any firmware functionality that is currently missing in your product.
- You need to bring order into your team: your team lacks proper development workflows for effective collaboration. You want to put in place an effective development workflow giving your developers a platform that ensures their work is effective.
- You have previously hired freelancers to "work" on your firmware and you became very disappointed with the results: you got untested, horribly written, disorganized mess and now you finally understand the value of well written firmware.
- And more.
Firmware developers you should avoid hiring
Good firmware developers are hard to find. You should generally avoid hiring consultants, freelancers and programmers who:
- Do not deliver 100% line and branch coverage with every unit of work done: this will almost uniformly result in substandard result for your project.
- Write code that does not pass static analysis: passing static analysis should be on your list of essential requirements.
- Do not apply proven design patterns and build good structure: you don’t want to hire someone else to refactor your code later.
- Do not verify results of their work against user requirements automated system tests: making it impossible to tell what features they are actually adding that are important from the user point of view.
The baseline in your team must be a solid infrastructure, high quality software design and test driven trunk based development.
These are precisely the areas where Swedish Embedded leads the field.
Firmware Development Consulting
The main deliverable of firmware consulting is: high quality merge requests that solve problems and put checks in place that ensure that problems remain solved over time.
The sum of these merge requests becomes your final product.
Each merge request must include:
- Solution to one particular problem: a merge request must implement one main solution to a specific problem.
- Verification of behavior that can be used to ensure it remains solved: this often means verification at function level (unit tests) as well as verification at product level (system test).
- Software architecture must be sound: the code must be well written, use object oriented design, and be without any unnecessary garbage.
- Documentation must be included: if a new function is added - it’s intended behaviors must be explained in text documentation that is included along side of the source code. Presence of documentation must be enforced by CI.
- Refactoring of related code that is necessary in order to make a proper solution: often missed is the fact that it’s not enough to just implement something while repeating existing mistakes that have taken over your code-base. To avoid technical debt you must avoid putting off necessary cleanup for later.
- Source code must pass static analysis: using open tools or closed tools like PC-Lint.
- Source code must follow coding standard: This includes adherence to coding style for sources as well as scripts. Openly available tools are used to enforce this.
- All checks must be done automatically: the above should be integrated into your assembly (CI) pipeline so that developers should not have to verify adherence to these points manually.
Swedish Embedded helps you develop firmware using the above model as the baseline for ensuring quality.
You should demand the same from all other developers who are involved in your project or face unnecessary costs that come with poorly organized projects.
Simplify your firmware application development
We simplify your application development using variety of tools:
- Open source software: helping you adopt already made software as much as possible in ways that align well with your existing licensing model.
- Using Swedish Embedded SDK: which is a collection of scripts, docker image and tools designed to make it easy to implement advanced test driven development specifically for embedded firmware.
By providing you with a complete toolbox of software libraries, utilities, device drivers and simulation support, we are able to considerably simplify your firmware development and make our consulting work much more effective.
You no longer have to worry about the following:
- Device driver support: we maintain our platform to always stay up to date with latest device support and develop extra drivers for you and track latest developments in the open source tools and source code that is included.
- Simulation of your latest hardware: we can work with you to develop highly customized simulation scenarios that will help your developers write software for your products before hardware has been manufactured.
Together with Swedish Embedded Group you can get assistance with topics such as:
- RTOS: writing software for complex hardware devices often means that having full control over executing of the software is very important. RTOS makes it possible for us to implement a clean software architecture where complexity is split up into smaller easily understandable chunks.
- Control systems: control systems design on embedded systems requires thorough understanding of mathematics combined with understanding of realtime systems in order to implement efficient and fast algorithms on the available hardware. By utilizing control theory we can develop mathematically correct control algorithms for your embedded hardware device and make them run with high level of precision.
- Communication protocols: modern IoT systems rely on several standard protocols including CANOpen, LwM2M, Profinet and others to communicate with other embedded systems in the deployment environment. By using standard protocols and open source protocol stacks we can make your device communicate with other devices in the field.
- Hardware simulation: starting from a PCB working with instruction set simulation to simulate and verify your embedded firmware.
Automation of CI processes ensures that your project has a robust assembly line that helps your developers ensure that your main branch is always in a releasable state.
Overcome and eliminate your firmware challenges
Firmware development is unique in that the software written often has to work in close collaboration with the hardware. This mandates that we use special tools to implement important software development concepts. Tools that are sometimes unfamiliar to conventional software developers.
The essential concepts for effective firmware development include:
- Cross platform compilation: some software bugs can be identified merely by cross compiling a program to run on 64 bit linux. Good C code should work exactly the same regardless of which platform it is compiled for which is why we make sure that your code is always tested on both x86 and the primary compilation target. This helps identify potential problems early.
- Unit and integration testing: our platform SDK contains integration with two powerful open source unit testing frameworks (CMock and Unity) which enable us to write unit tests for ANY piece of code inside your firmware code-base. We are not limited to only testing higher level algorithms - we can help you test it all down to the lowest level device drivers. Everything is testable with the right tools in place.
- Debugging and tracing: many timing issues can be solved with debugging and tracing. However it is not always clear exactly how to trace and what to trace (and how to do it without negatively impacting application behavior). Using our tools we can build and simulate your firmware on variety of platforms and extract much more detailed information about what is going on inside your code.
- Automated simulation: this involves simulating your firmware. Simulation enables you to test scenarios involving multiple devices and to automate this testing process. Multi-device simulation has traditionally been hard to implement due to complicated coding skills being required. Swedish Embedded Platform SDK integrates simulation and testing into the main build process so that it becomes part of the normal development workflow.
Independent code and infrastructure review
Independent code review helps you by offering an extra set of eyes to spot potential issues in your source code.
Even the best developers can easily miss potential problems with their code - simply due to being too closely involved with it. This is not due to not being attentive, it is simply due to the blindness that stems from familiarity with the code.
Independent review solves this issue by having somebody from outside come in and review merge/pull requests of your team, giving valuable feedback, finding bugs and suggesting improvements. It also helps you with:
- Guidance towards better architecture: an architecture that does its function well AND has been documented clearly is a good start.
- Guidance regarding design patterns that can improve your code quality: some of these design patterns may not even be familiar to your programmers but they are very useful.
- Better workflow and infrastructure: to make reviews possible, it is necessary to have infrastructure in place for effective code review. This infrastructure must come about from specific needs of the project and so is going to emerge as a unique set of scripts specifically developed to execute YOUR workflow. An external observer can spot potential areas of improvement much quicker and guide your team towards effective implementation.
Achieve robust and portable system architecture
Portability is an increasingly important factor in firmware development because the market for hardware components can change extremely fast (as we have seen during 2020). This means that at any given time you may find yourself having to adopt your software to a completely new hardware.
If you do not address portability each and every day through automatic cross compilation and simulation, you are very likely to find yourself in a situation where you must quickly redo a lot of code. If this happens, you will find that it will be very difficult to avoid making mistakes and your project will very likely become delayed because of this.
We help you achieve portability for your embedded firmware in several ways:
- Native posix unit and integration testing: by mandating that majority of firmware code must be buildable for posix (which is absolutely necessary for unit tests anyway), we ensure that dependencies of your code are kept to a minimum. Native compilation does not guarantee clean code, but it does ensure that programmers run into hard blocks when they try to use obscure processor specific constructs and libraries - and this is a good thing.
- Extensive board support: it is no secret that we draw a lot of our lowest level hardware support from the Zephyr RTOS open source ecosystem. Zephyr hardware support is not always 100% perfect and very often drivers must be fixed and extended - but Zephyr is also a massive project with support for 400+ hardware configurations and numerous architectures - so the fact that some features may be missing is always expected. The upside is that you avoid having to write software support for 400+ boards yourself - and this is a good thing. By using existing board support it is possible to cross compile your application for many different boards - which makes prototyping and debugging very easy.
- Single board and multi-board simulation: modern connected IoT systems rarely exist in a vacuum. Often multiple boards need to communicate with each other. This complexity leads to test scenarios that are unique to embedded systems. Traditional simulation tools have been very good at simulating one CPU - but simulation multiple boards including all peripherals has traditionally been hard. Swedish Embedded Platform SDK once again solves this problem by leveraging open source technologies - but what we also do is integrate simulation into the build process itself and define templates and patterns for quickly prototyping your firmware. This makes it possible for us to easily define multiboard setups running different binary applications and test these complex user interaction scenarios in a fully automated way leading to better software quality and better developer experience for your team.
System level consulting
A consultant can not just focus on one layer and expect good results. A firmware consultant that is only good at application development will quickly discover that lack of understanding of kernel level code will become a bottleneck and a pain.
Thus we we cover the whole range of technologies from top to bottom:
- Zephyr RTOS Consulting: To develop high quality embedded systems it is good to take what is already available and adopt it to a specific application. Zephyr RTOS, being fully embraced by the Linux foundation is a fantastic alternative to the linux kernel on resource constrained devices (starting from 32KB FLASH). Open source nature and high focus by the community on quality of architecture means that development often proceeds with a blazing speed that is never achievable by any single team on their own. Keeping up to these changes can be a challenges. Getting technical help when you need it is absolutely essential.
- Renode simulation consulting: renode is another very powerful platform used by Swedish Embedded Platform SDK which takes care of emulation. Renode provides the infrastructure necessary for defining hardware configurations and interacting with the simulation which itself runs on a powerful emulator core. This in itself is a massive piece of infrastructure with support for over 50 hardware configurations and ability to define any combination of peripherals quite easily. Understanding how to leverage this to your best advantage is of utmost importance. We provide you with knowledge and experience in integrating these systems efficiently into your workflow. Swedish Embedded SDK provides a baseline for this integration.
- Swedish Embedded Platform SDK: the platform SDK itself provides a platform for integrating many different tools and allows us to deliver progressively better service to you as a consulting client. It ensures that we never need to solve the same problems twice. Meaning that you get a lot of development work done for you free of charge. However the most valuable work is the work that directly affects your product performance and for this it is necessary to do work directly related to your products. This is what a large portion of our consulting is about - helping you extract value out of what we already have and make any necessary changes to make this process of extracting value faster.
Schedule a call to find out more
If you think this makes sense in the context of what you want to accomplish then book a call.