Today, I’m going to show you how to code in compliance with AUTOSAR guidelines using Helix QAC.

Let’s start with looking at the different categories of rules, the rules themselves and just some of the QAC diagnostics we use to enforce them.

As we can see, we have the AUTOSAR Required and Advisory rules. And let’s go ahead and open up the Required rule and take a look at the Automated rules.

So, ff we select Rule A0-1-1, we can see there are 5 different diagnostics – QAC warning messages —  that enforce this rule. Whilst if we take a look at Rule A1-1-1, where ‘all code must comply to C++ 14 and not use depreciated features’, we can see there are lot more diagnostics that can trigger a rule violation.

Bacause, let’s remember, it’s not just about the percentage of coverage, but the depth of enforcement by covering as many of the different potential use cases that could violate the rule.

Let’s come down now to the main UI. And here, we already have a project analyzed with our AUTOSAR compliance module.

As we can see in the center of the UI, we have the source code with a number of yellow bubbles down the left hand side. And this indicates where there are 1 or more violations, so if we select it now, we can see that this line has rule violation of A12-4-2.

Let’s take a look now at the ‘Rule Groups’ tab, where we can see which AUTOSAR rules have been violated on this particular file. So, if we expand out the rule groups, let’s start with the required, we can see not just the rules, but the individual diagnostics that indicate a rule violation.

So, if I just expand out A0-1-1 again, we can see we have the warning message 2983. We can now filter out the rules and this allows us to focus our attention on this particular rule. So, if I just right click A0-1-1 and do Show Only, I’ve now got the one violation. So this gives us a good starting point to work from and slowly enables more rules and allow us to work through these and correct those issues.  

Finally, if we take a look at the bottom panel, we can see a list of all the AUTOSAR violations in the file. All diagnostics have their own severity rating, and we can filter out the less critical issue to give us another starting point rather than looking at the individual rules.

So, once we decide where we want to start, we can then double click the diagnostic, it will then take us there, show us where we need to then make our code change to then re-analyze to ensure the issue has been resolved, and no new violations have been introduced.

And that is just one example of how Helix QAC can make it easy to comply with the AUTOSAR guidelines.

If you’re interested in learning more about how Helix QAC will help you, sign up for our next live demo.