high integrity systems c o d e
play

High Integrity Systems C.O.D.E. Developing Certified Components for - PowerPoint PPT Presentation

High Integrity Systems C.O.D.E. Developing Certified Components for High Integrity Embedded Systems http://www.hidecs.co.uk/ Email: Paul_E.Bennett@topmail.co.uk 22 February 2013 Paul E. Bennett IEng MIET 1 HIDECS Consultancy In a paper by


  1. High Integrity Systems C.O.D.E. Developing Certified Components for High Integrity Embedded Systems http://www.hidecs.co.uk/ Email: Paul_E.Bennett@topmail.co.uk 22 February 2013 Paul E. Bennett IEng MIET 1 HIDECS Consultancy

  2. In a paper by Phil Koopman, titled “The Grand Challenge of Embedded System Dependability” he sets out that “Four significant challenges in embedded system dependability are: • embedded-specific security approaches, • unifying security with safety, • dealing with composable emergent properties, • and enabling domain experts to use advanced dependability techniques.” 22 February 2013 Paul E. Bennett IEng MIET 2 HIDECS Consultancy

  3. Where mistakes are made (Out of control, 2nd edition 2003, Health & Safety Executive HSE – UK) 22 February 2013 Paul E. Bennett IEng MIET 3 HIDECS Consultancy

  4. Capability & Correctness 22 February 2013 Paul E. Bennett IEng MIET 4 HIDECS Consultancy

  5. Software Needs Hardware ● Software does not operate without the support of the hardware on which it runs. ● Hardware can suffer random failures ● Environmental Factors ● Stress Induced Failures ● Wear-Out Failures ● Software only suffers systematic failures 22 February 2013 Paul E. Bennett IEng MIET 5 HIDECS Consultancy

  6. Software Needs Hardware Failure = f(h)+f(s) f(h) f(s) 22 February 2013 Paul E. Bennett IEng MIET 6 HIDECS Consultancy

  7. Software Needs Hardware For a Single Channel of Control Failure = f(h)+f(s) 10E0 to <10E-99 10E0 to 10E-3 f(h) f(s) 22 February 2013 Paul E. Bennett IEng MIET 7 HIDECS Consultancy

  8. Design Integrity is vital ● Know the working environmnt ● Design to operate within limitations of that enviornment ● Be clear about the Tasks to be performed ● Task Description ● Task Analysis ● Hazop Study & Risk Assessment ● Revisit the early concept ● It will not usually be right on the first pass so go back and look at what you can improve as early as possible. 22 February 2013 Paul E. Bennett IEng MIET 8 HIDECS Consultancy

  9. Have a Robust Process ● To develop a High Integrity System you need to be at CMM-3 or better from the start ● Your process needs to manage a multitude of versions and changes ● You need to keep the information and knowledge safe and secure ● You need to know that you and your clients are working to the same specification 22 February 2013 Paul E. Bennett IEng MIET 9 HIDECS Consultancy

  10. Specification Discovery Specification and Design Implementation Job Design Task Training Analysis Human/ Requirements Computer Operational Specification Interface Trials Design Function Manufacture Analysis Functional Design 22 February 2013 Paul E. Bennett IEng MIET 10 HIDECS Consultancy

  11. The Document Trail 22 February 2013 Paul E. Bennett IEng MIET 11 HIDECS Consultancy

  12. An Engineering Process Model Accept Process Requirements Issue Function Review 22 February 2013 Paul E. Bennett IEng MIET 12 HIDECS Consultancy

  13. An Engineering Process Model Accept Process f1 Requirements Issue Function Review f1 f3 f1 Work Change Work Review Instruction Instruction f2 Change Change Proposal Proposal f1 Problem Simple f4 f4 Report Review Explanation 22 February 2013 Paul E. Bennett IEng MIET 13 HIDECS Consultancy

  14. Why Forth? ● Stable Virtual Machine (about 40 years) ● Extensible ● Supportive of Structured Programming ● Supportive of Component Oriented Approach ● Does not rely on sub-setting to be “Safe” ● Fully Certifiable 22 February 2013 Paul E. Bennett IEng MIET 14 HIDECS Consultancy

  15. Why Forth? Perihperal Interfaces Processor 22 February 2013 Paul E. Bennett IEng MIET 15 HIDECS Consultancy

  16. Why Forth? Forth Kernel Parameter Stack Return Stack Perihperal Interfaces Processor 22 February 2013 Paul E. Bennett IEng MIET 16 HIDECS Consultancy

  17. Why Forth? Forth Kernel Peripheral Support Code Parameter Stack Return Stack Perihperal Interfaces Processor 22 February 2013 Paul E. Bennett IEng MIET 17 HIDECS Consultancy

  18. Why Forth? Application Specific Base Forth Kernel Peripheral Support Code Parameter Stack Return Stack Perihperal Interfaces Processor 22 February 2013 Paul E. Bennett IEng MIET 18 HIDECS Consultancy

  19. Why Forth? Application Application Specific Base Forth Kernel Peripheral Support Code Parameter Stack Return Stack Perihperal Interfaces Processor 22 February 2013 Paul E. Bennett IEng MIET 19 HIDECS Consultancy

  20. Component Oriented ● All systems are constructed from components ● Components have Datasheets describing their attributes, functionaility and limitations. ● Components are complete in themselves ● Components can be certified for compliance with their specification. ● Non-compliance becomes obvious upon proper inspection. 22 February 2013 Paul E. Bennett IEng MIET 20 HIDECS Consultancy

  21. Certifiying Software Components ● NPL have been running approximately 5,000 random C compilations per evening on a selection of C compilers. So far there have been no matches observed at the object code level. ● Forth already has at least two fully certified compiler implementations for High Integrity Applications. ● Choosing Forth made such certification effort much easier to complete. 22 February 2013 Paul E. Bennett IEng MIET 21 HIDECS Consultancy

  22. Producing High Integrity Code ● Think of writing the comments first (use the comments as a statement of what you expect to be achieved). ● Review the comments to establish the state the true intent for the code you have yet to write. ● Write the code to meet the statement of requirements expressed by the comments. ● Statically Inspect the code to ensure implementation matches intent ● Perform a functional test of all logical paths in the code. ● Perform a limitations test (trying to make the code fail). ● 100% Path and Function Coverage is possible. 22 February 2013 Paul E. Bennett IEng MIET 22 HIDECS Consultancy

  23. Code Inspection Sample \ DSQRT (c) PEB 28/10/05 : DSQRT ( ud -- u ) (G u is the nearest integer value of the square root of the ) ( unsigned number ud. Results are rounded down. ) -1 >R BEGIN R> 1+ >R R@ 2* 1+ S>D D- 2DUP D0>= NOT UNTIL 2DROP R> ; 22 February 2013 Paul E. Bennett IEng MIET 23 HIDECS Consultancy

  24. Code Inspection Sample \ DSQRT (c) PEB 28/10/05 : DSQRT ( ud -- u ) (G u is the nearest integer value of the square root of the ) ( unsigned number ud. Results are rounded down. ) -1 >R BEGIN R> 1+ >R R@ 2* 1+ S>D D- 2DUP D0>= NOT UNTIL 2DROP R> ; The above code fails certification as the word's glossary comment does not match the actual action of the code below it. The result returned is only valid if the input value is a positive signed number (31 bits instead of 32 - based on system with 16 bit width). 22 February 2013 Paul E. Bennett IEng MIET 24 HIDECS Consultancy

  25. Code Inspection Sample \ DSQRT (c) PEB 28/10/05 : DSQRT ( +dn -- +n ) (G +n is the nearest positive integer value of the square root of ) ( the positive double length integer +dn. Results are rounded ) ( down to the nearest positive integer. ) -1 >R BEGIN R> 1+ >R R@ 2* 1+ S>D D- 2DUP D0>= NOT UNTIL 2DROP R> ; After analysis, the code was deemed suitable for the application it was intended for but the glossary entry had to be re-worded to properly document its intention and limitations. 22 February 2013 Paul E. Bennett IEng MIET 25 HIDECS Consultancy

  26. Summary ● You need a development process to at least CMM level 3 capability. ● Component Oriented Approaches keep the problems bounded. ● Forth is a very good Component Oriented Development Environment ● Forth code can be as certifiable as hardware. 22 February 2013 Paul E. Bennett IEng MIET 26 HIDECS Consultancy

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend