Motor control toolbox for MPC5643L

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Motor control toolbox for MPC5643L

756 Views
swetha_jayakuma
Contributor I

One of our customer, has a question regarding the chip MPC5643L. They are using your motor control toolbox

(Version # 1.2 ) together with Matlab 2013b for model based application software design, and one of the customers requires that the code generated from the model meet MISRA C rules, but seems like some of the freescale library *.c and *.h files does not meet the MISRA C rules.   

Do you have any customer that uses the above motor control toolbox for their products? Have they ever had the same issue? If yes, is there any solutions to make the code MISRA C complied? Or do you have any supporting documents which states that the library files are reliable even not MISRA C complied?

Appreciate support on the above questions from the customer.

Thanks!

0 Kudos
1 Reply

621 Views
petervlna
NXP TechSupport
NXP TechSupport

Hello,

Following answer from Daniel will clarify all your doubts:

Please allow me a few comments which i think will answer your main 3 questions:

 

1) The generated code is complaint to MIRSA standard?

We need to differentiate between 3 layers of generated code:

  • front-end layer is the "User Application" that is developed using standard MathWorks Simulink blocks. For such use-cases the generated code is MISRA-C and ISO26262 and IEC61508 compliant (assured by MathWorks various toolboxes) 

MISRA C setup:

pastedImage_3.png

ISO/IEC Certification Kit: IEC Certification Kit - MATLAB & Simulink 

  • back-end layer is the "Peripheral Driver" code that is typically reused from NXP SDK. Those drivers are only MISRA-C compliant. In same cases, for toolboxes releases prior to mid 2017 including MCP574xP 2.0.0 those drivers are hand-written and not compliant - that is why we are currently working on switching MPC families to SDK PA drivers as well.
  • glue up layer between Simulink Application interface and Peripheral Drivers code is implemented in TLC by our team, and once again is not MISRA compliant.

 

2) The generated code is any ISO complaint?

We - Model Based Design Team - do not provide a qualification kit for such purpose. Our main intentions are easy prototyping and to open up the NXP HW into the world of MathWorks products. Then using their offerings and additional toolboxes ISO 26262 Support in MATLAB and Simulink - Automotive Industry Standards - MATLAB & Simulink to allow users to pursue various options.

 

3) can it be used is safety critical applications?

Typically, when we talk about safety critical application we think about running application using lockstep systems. NXP offers such microprocessors and the most common ones are the MPC families. Is that what you mean by safety ?

 

More:

https://community.nxp.com/message/1084826?commentID=1084826#comment-1084826 

Regards,

Peter

0 Kudos