Software is everywhere

In the first of a series of four articles, Niroshan Rajadurai from Vector Software looks at the challenges facing the automotive software industry
Despite the concerns of recent vehicle recalls due to software defects, the automotive software industry is developing fast, with 90 per cent of innovation coming from software driven features. Manufacturers have had to become software companies as in-vehicle technology is the top selling point for 39 per cent of car buyers with only 14 per cent favouring traditional performance.
The most overused statistic when understanding the scale of automotive technology development is that there are more lines of code in a single vehicle today than there were on the first rocket to the moon. This means the embedded software environment has become increasingly more complex as consumers demand cars packed with features they expect from their home environment or mobile phone with connected technology and apps to enhances their lifestyle.
Manufacturers have responded by pushing the boundaries of automotive development through producing high-end entertainment systems, head-up displays, hybrid propulsion and safety features such as parking assistance – all of which add layers of software complexity as well as the opportunity to grab market share.
We have seen a complete turnaround from the days of mechanical dominance with 80 per cent hardware and 20 per cent software to the total reverse. Manufacturers are competing to offer greater utility and convenience but this comes at a price – financially for the consumer and practically for software engineers.
Standardisation
The new automotive market trends and pressures are heightened in such a safety-critical environment. Automotive safety legislation has had to increase to keep up with the developing engineering software challenges that include provision of fail-safe paths and increased logic in failure detection isolation and recovery (FDIR) algorithms to help drivers and other road users and pedestrians stay safe.
Estimates are that we already have approximately 23 million connected cars on the road and that number is set to reach 152 million by 2020. The challenge for embedded computing is the sheer scale and rate of development. Hundreds if not thousands of pieces of software must work together in modern day automotive technology with updates being released daily. If we are not careful, all this software could become unwieldy and an obstruction to innovation when complying with safety legislation – have we already reached this stage?
Due to more than 50 per cent of recalls attributed to software bugs, many manufacturers have started to look for ways to improve development processes to produce a high quality product with reliable functionality.
In today’s modern automotive manufacturing environment, groups of developers are working on separate functions. Requirements are being written, code is developed and the integration takes place at the final stage before testing begins. The onus is on OEMs and tier-one suppliers, who are responsible for designing and building these systems, to make sure they comply with the ISO 26262 standard for their pre-defined safety function. The OEMs and tier-one suppliers have the task of piecing together the technology, components, software and documentation to achieve certification.
This safety-compliant trend is driving the requirement for ISO 26262 compliance all the way through the system development process. The safety burden has been extended from the automotive OEM right through to the providers of the technology that goes into the chip. This is of course positive, as it makes the cars we drive safer.
A joined up thinking, more agile approach is needed, and this is what Autosar aims to provide – an open and standardised automotive software architecture jointly developed by automobile manufacturers, suppliers and tool developers. Its ideal is to create a global partnership with one common standard, which would make a software engineer’s life easier.
Although regulations and guidelines are a positive addition, it is easy to see why engineers, developers and manufacturers are up against it when trying to comply with ISO 26262, Autosar and Automotive Spice.
Integration and consolidation need to drive the next wave of automotive software innovation. The number of ECUs being employed has doubled in the past ten years, exploding the number of lines of code. The current levels of software complexity, due in part to subsystems for connecting software programmes, introduces more potential safety issues from software incompatibility or malfunction.
More than half of auto recalls are now due to software bugs, not mechanical issues. With an industry average of five to ten bugs per thousand lines of code, those errors pile up fast. According to published charts, the software system in an average car contains between ten and 100 million lines of code. That would mean that the average car has between 50,000 and 100,000 latent bugs lurking and waiting to be revealed at any time.
This risk is not acceptable for technology that is designed to protect lives, hence the stringent legislation to mitigate these errors. In the aerospace industry there are strict coding standards to ensure airborne code is free from dead code, a zero tolerance approach if you will. Time, resource pressures and shrinking profit margins limit the automotive industry. Coding standards such as Misra C were introduced to help address this; however Misra C still does not go all the way towards addressing correctness in software.
Economics
The exponential increase in software has implications on the automotive economy with 17 per cent of projects seeing an increase in code in their next permutation. Manufacturers want to get a new product to market as quickly as possible to capture market share and rank above the competition.
Sending out a vehicle with software bugs is potentially catastrophic, so testing procedures are naturally in place to deal with this. However the build and test phases are resource and time hungry and slow down the time to market.
Forty per cent of engineers have reported that projects are behind schedule – not good for the bottom line. Manufacturers are in somewhat of a Catch 22 situation. With the amount of code increasing daily, how can manufacturers keep ahead of the curve on budget and still comply with safety regulations? The answer lies with the testing phase. Automated test tools are not new and research shows a direct and unsurprising correlation between the use of automated test tools and code base sizes.
The use of automated test tools obviously helps engineers to pick up potential errors in code bases, and more companies than ever are taking steps earlier on in the development cycle to limit software defects and work more efficiently.
Traditionally static testing methods are employed but this is a flawed approach as this style of testing only analyses the construction of the code’s language. Particularly in safety-critical industries, dynamic testing offers more security and tests the executable file, the functional data and the way the code behaves.
Automated dynamic testing is the most effective way to test embedded software and will enhance the development process, alleviating pressure on all involved.
Conclusion
Automotive software engineers need guidance on how to meet the safety requirements while operating under time constraints and market pressures, as well as providing best practices for developing software that can be easily tested to produce vehicles that are safe and fit for purpose. Owing to the scale of the software that exists today, testing must cover integration, unit and full system along with code coverage. Manufacturers have a responsibility to provide a safe product of optimum quality, and, without sufficient and automated dynamic testing in place, recalls are inevitable, which damage profits, consumer trust and public safety.
Niroshan Rajadurai is director of EMEA for Vector Software

Comments
Software
Very well written mate. I have also developed a software realted to automobiles. This article will help me in reviewing the software again. Thanks.