Julius Gustavsson, System Architect at Volvo Cars and lead for the LPA project, dives into Volvo's groundbreaking use of Rust in their Electronic Control Units. He details the journey from 2018 to implementing a low-power processor, discussing both the excitement and skepticism in the industry. The conversation covers the integration of hardware abstraction layers, the challenges of migrating from C to Rust, and the development of a software bill of materials for compliance. Gustavsson also highlights the importance of collaboration with external experts to navigate these complex innovations.
Volvo Cars has successfully integrated Rust into their Electronic Control Units, marking a significant technological advancement in the automotive industry.
The collaborative approach in the development process allowed Volvo to overcome initial challenges, fostering a productive team environment and diverse skill growth.
Rust's strong safety and reliability features contribute to faster deployment and better-tested systems, highlighting its potential for future automotive projects.
Deep dives
Introduction of Rust at Volvo
Volvo Cars has pioneered the use of Rust programming language by integrating it into their low-power processor project, known as LPA. This project marks the first instance of an automotive ECU being fully written in Rust. Initially, when the project began around 2018, both the programming language and embedded ecosystem were still evolving, but the team at Volvo recognized the potential benefits of Rust. Their early experiments with proof of concepts demonstrated Rust’s unique ability to enhance reliability and ease of development compared to traditional C/C++ approaches.
Challenges and Proof of Concept
During the early phase of exploring Rust, the team developed a hardware abstraction layer using Android UI to control car fans, achieving success on the first attempt. This proof of concept utilized temporary systems to send CAN signals and highlighted the benefits of Rust in simplifying the communication process. Rust’s design requires developers to plan their code thoroughly, which helps to tie up loose ends and avoid unexpected issues common in C/C++ programming. Overall, this experience not only validated the use of Rust but also demonstrated how it could lead to faster deployment and better-tested systems.
Project Development and Team Dynamics
As the LPA project developed, teamwork and external collaboration were crucial for its success. Volvo engaged experts from external firms to overcome the initial lack of support for Rust on automotive hardware platforms, ensuring that the project could proceed effectively. A formal approach to project management encouraged the team to set deadlines and measure progress, fostering a productive environment. This collaborative spirit, combined with a shared enthusiasm for Rust, helped the development team grow, diversify their skill sets, and adapt quickly to this innovative technology.
Tooling and Compliance in Rust Development
The LPA team built out a custom toolchain and CI/CD process that allowed extensive testing and validation of their Rust code before deployment. They utilized libraries and designed tooling to comply with automotive standards, including diagnostic protocols essential for safety-critical applications. With Rust’s strong safety features, the team ensured that their approach maintained high reliability without sacrificing performance. This strategic focus on automated testing and compliance helped in creating robust systems ready for scaling in future projects.
Future Prospects for Rust at Volvo
Looking ahead, the use of Rust in Volvo is anticipated to expand, particularly in security-critical coding areas where reliability is paramount. The previous challenges related to hardware and development environments have started to dissipate, opening new avenues for integrating Rust throughout the organization. Ongoing collaboration within the Rust community and with other automotive manufacturers will facilitate knowledge sharing and drive further advancements. Ultimately, the executives at Volvo are optimistic about Rust’s role in future automotive projects and the continual evolution of their technology stack to meet emerging industry demands.
The car industry is not known for its rapid adoption of new technologies. Therefore, it's even more exciting to see a company like Volvo Cars embracing Rust for core components of their software stack.
We talked to Julius Gustavsson, System Architect at Volvo Cars, about the use of Rust for their Electronic Control Units (ECUs) in Volvo's EX90 and Polestar 3 models and how they are building a Rust ecosystem within the company.
About Volvo
Volvo Cars is a Swedish premium car manufacturer founded in 1927. The company is known for its focus on robustness, safety, and sustainability. Its headquarters are in Gothenburg, Sweden, and it has manufacturing plants in Sweden, Belgium, China, and the United States.
About Julius Gustavsson
Prior to Volvo Cars, Julis worked at Ericsson, among other companies. His background is in embedded systems and software development. His master's thesis was about System-on-Chip (SoC) design.