StHlthSigStc_MDD
Module Design Document
For
State of Health Signal Statistics
Sep 27, 2016
Prepared For:
Software Engineering
Nexteer Automotive,
Saginaw, MI, USA
Prepared By:
Software Group,
Nexteer Automotive,
Saginaw, MI, USAChange History
Sl. No. | Description | Author | Version | Date |
1 | Initial Version | Akilan Rathakrishnan | 1.0 | 15-Feb-2016 |
2 | Updated for EA4#5553 | Akilan Rathakrishnan | 2.0 | 04-May-2016 |
3 | Updated for EA4#7307 | Akilan Rathakrishnan | 3.0 | 27-Sep-2016 |
Table of Contents
1 StHlthSignStc High-Level Description 5
2 Design details of software module 6
Graphical representation of StHlthSigStc 6
3.1 User defined typedef definition/declaration 7
3.2 Variable definition for enumerated types 7
4.1.2 Module specific Lookup Tables Constants 8
5 Software Module Implementation 9
5.1.1 Initialization Functions: StHlthSigStcInit1 9
5.1.4 Server Runnable Functions 9
5.1.4.1 ClrSigStcHlthData_Oper 9
5.1.4.2 GetSigStcHlthData_Oper 9
5.1.4.3 StHlthStcPwrDwn_Oper 9
5.1.4.4 UpdStHlthStcData_Oper 9
5.1.5 Module Internal (Local) Functions 9
5.1.7 Global Function/Macro Definitions 10
6 Known Limitations with Design 12
Appendix A Abbreviations and Acronyms 14
StHlthSignStc High-Level Description
This component shall collect State of Health data signals from other component(s) and shall compute following statistical values for each signal: Minimum, Maximum, Average and Life Cycle Sample counter. This component shall provide statistical data for ignition cycle and for life cycle for each signal upon request.
Design details of software module
See FDD.
Graphical representation of StHlthSigStc
Data Flow Diagram
See FDD.
Component level DFD
See FDD.
Function level DFD
See FDD.
Variable Data Dictionary
User defined typedef definition/declaration
<This section documents any user types uniquely used for the module.>
Typedef Name | Element Name | User Defined Type | Legal Range (min) | Legal Range (max) |
Ary1D_u8_ StHlthSigStc1 | Array | uint8 | 0 | 65535 |
Ary1D_u32_ StHlthSigStc1 | Array | uint32 | 0 | 65535 |
StHlthSigStcPrmRec1 | GetStHlthDataOper | uint8 (*GetDataOper)(void ) | 0 | 4294967295 |
SamplePerSec | uint16 | 0 | 65535 | |
TaskRef | TaskType | 0 | 255 | |
RamStorgOffs | uint8 | 0 | 255 | |
NvmStorgOffs | uint8 | 0 | 255 | |
StHlthSigStcCrcAdrRec1 | * CrcStrtAdr | uint32 | 0 | 4294967295 |
StHlthSigStcPrmRec1 | *SigPrm | StHlthSigStcPrmRec1 | 0 | 4294967295 |
*CrcAdr | StHlthSigStcCrcAdrRec1 | 0 | 4294967295 |
Ary1D_u8_StHlthSigStc1 – Typedef for Ram buffer where State of Health Statistical data is kept for the current Ignition cycle. Size of this array is configurable.
Ary1D_u32_ StHlthSigStc1 – Typedef for Ignition cycle sample counter. Size of this array is configurable.
Variable definition for enumerated types
Enum Name | Element Name | Value |
See DataDict.m file |
Constant Data Dictionary
Program (fixed) Constants
Embedded Constants
Local Constants
Constant Name | Resolution | Units | Value |
See DataDict.m file | |||
CRCBUFSIZE_CNT_U08 | 1 | Cnt | (WORDSIZE_CNT_U08*NROFCRCAREA_CNT_U08) |
* Also see see FDD ES106A_StHlthSigStc_DataDict.m file
Global
<This section lists the global constants used by the module. For details on global constants, refer to the Data Dictionary for the application>
Constant Name |
See DataDict.m file |
Module specific Lookup Tables Constants
<(This is for lookup tables (arrays) with fixed values, same name as other tables)>
Constant Name | Resolution | Value | Software Segment |
StHlthSigStcCfgRecInst | StHlthSigStcCfgRec1 | Configured | StHlthSigStc_CONST |
Software Module Implementation
Sub-Module Functions
None
Initialization Functions: StHlthSigStcInit1
See DataDict.m file and model. This function exists in “StHlthSigStc.c” file.
PERIODIC FUNCTIONS
None
Interrupt Functions
None
Server Runnable Functions
ClrSigStcHlthData_Oper
See DataDict.m file and model. This function exists in “StHlthSigStc.c” file.
GetSigStcHlthData_Oper
See DataDict.m file and model. This function exists in “StHlthSigStc.c” file.
StHlthStcPwrDwn_Oper
See DataDict.m file and model. This function exists in “StHlthSigStc.c” file.
UpdStHlthStcData_Oper
See DataDict.m file and model. This function exists in “StHlthSigStc.c” file.
Module Internal (Local) Functions
Local Function #1
Function Name | StHlthSigStc_ClrDataSample | Type | Min | Max |
Arguments Passed | TarSel_Uls_T_logl | boolean | FALSE | TRUE |
Return Value | None | N/A | N/A | N/A |
Description
This function implements “StHlthStcPwrDwn” function in the FDD.
Local Function #2
Function Name | StHlthSigStc_GetSigStHlthData | Type | Min | Max |
Arguments Passed | SigId_Uls_T_enum | StHlthMonSig3 | 0 | 21 |
TarAdr | uint8* | 0x0000000 | 0xFFFFFFFF | |
Return Value | None | N/A | N/A | N/A |
Description
This function implements “GetSigStcHlthData” function in the FDD.
Local Function #3
Function Name | StHlthSigStc_UpdNvmPim | Type | Min | Max |
Arguments Passed | NvmPim_Ptr_T_u08 | uint8* | 0x0000000 | 0xFFFFFFFF |
NvmMaxVal_Uls_T_u08 | uint8 | 0 | 100 | |
NvmMinVal_Uls_T_u08 | uint8 | 0 | 100 | |
NvmAvrgVal_Uls_T_u08 | uint8 | 0 | 100 | |
NvmSampleCnt_Uls_T_u32 | Uint32 | 0 | Max of u32 | |
Return Value | None | N/A | N/A | N/A |
Description
This function implements “Update Nvm” function in the FDD.
Local Function #4
Function Name | StHlthSigStc_UpdDataSample | Type | Min | Max |
Arguments Passed | TaskRef_Uls_T_u08 | uint8 | 0 | 255 |
Return Value | None | N/A | N/A | N/A |
Description
This function implements “Update Nvm” function in the FDD.
Transition Functions
None.
Global Function/Macro Definitions
Global Function #1
Function Name | NONTRUSTED_NtWrapS_StHlthSigStc_UpdDataSample | Type | Min | Max |
Arguments Passed | FunctionIndex | NonTrustedFunctionIndexType | 0 | 65535 |
FunctionParams | NonTrustedFunctionParameterRefType | 0 | 0xFFFFFF | |
Return Value | void |
Description
Implements Nontrusted function wrapper for UpdDataSample. This will be called from UpdStHlthStcData_Oper upon client invocation.
Global Function #2
Function Name | NONTRUSTED_NtWrapS_StHlthSigStc_UpdNvmPim | Type | Min | Max |
Arguments Passed | FunctionIndex | NonTrustedFunctionIndexType | 0 | 65535 |
FunctionParams | NonTrustedFunctionParameterRefType | 0 | 0xFFFFFF | |
Return Value | void |
Description
Implements Nontrusted function wrapper for UpdNvmPim. This will be called from StHlthStcPwrDwn_Oper upon client invocation.
Global Function #3
Function Name | NONTRUSTED_NtWrapS_StHlthSigStc_ClrDataSample | Type | Min | Max |
Arguments Passed | FunctionIndex | NonTrustedFunctionIndexType | 0 | 65535 |
FunctionParams | NonTrustedFunctionParameterRefType | 0 | 0xFFFFFF | |
Return Value | void |
Description
Implements Nontrusted function wrapper for UpdNvmPim. This will be called from ClrSigStcHlthData_Oper upon client invocation.
Known Limitations with Design
Following constants are not used in the implementation even though they defined in the .m file. It is only used for the purpose of model simulation.
SHIFTFAC16_ULS_U08
SHIFTFAC24_ULS_U08
SHIFTFAC8_ULS_U08
Implementation uses different name for following PIM variables that are defined in .m file:
SigStcPrmInst
CrcInst
UNIT TEST CONSIDERATION
Config files in the contract folder are for a test project with sample configurations for two monitored signals CtrlrTStHlth and OutpAssiStHlth.
Abbreviations and Acronyms
Abbreviation or Acronym | Description |
---|---|
DFD | Design functional diagram |
MDD | Module design Document |
FDD | Functional Design Document |
Glossary
Note: Terms and definitions from the source “Nexteer Automotive” take precedence over all other definitions of the same term. Terms and definitions from the source “Nexteer Automotive” are formulated from multiple sources, including the following:
ISO 9000
ISO/IEC 12207
ISO/IEC 15504
Automotive SPICE® Process Reference Model (PRM)
Automotive SPICE® Process Assessment Model (PAM)
ISO/IEC 15288
ISO 26262
IEEE Standards
SWEBOK
PMBOK
Existing Nexteer Automotive documentation
Term | Definition | Source |
---|---|---|
MDD | Module Design Document | |
DFD | Data Flow Diagram |
References
Ref. # | Title | Version |
---|---|---|
1 | AUTOSAR Specification of Memory Mapping (Link:AUTOSAR_SWS_MemoryMapping.pdf) | v1.3.0 R4.0 Rev 2 |
2 | MDD Guideline | EA4 01.00.00 |
3 | Software Naming Conventions.doc | 1.0 |
4 | Software Design and Coding Standards.doc | 2.0 |
5 | FDD: ES106A_StHlthSigStc_Design | See Synergy subproject version |