DriveWorks SDK Reference
4.0.0 Release
For Test and Development only

HealthSignals.h
Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed
3 // under the Mutual Non-Disclosure Agreement.
4 //
5 // Notice
6 // ALL NVIDIA DESIGN SPECIFICATIONS AND CODE ("MATERIALS") ARE PROVIDED "AS IS" NVIDIA MAKES
7 // NO REPRESENTATIONS, WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
8 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ANY IMPLIED WARRANTIES OF NONINFRINGEMENT,
9 // MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.
10 //
11 // NVIDIA Corporation assumes no responsibility for the consequences of use of such
12 // information or for any infringement of patents or other rights of third parties that may
13 // result from its use. No license is granted by implication or otherwise under any patent
14 // or patent rights of NVIDIA Corporation. No third party distribution is allowed unless
15 // expressly authorized by NVIDIA. Details are subject to change without notice.
16 // This code supersedes and replaces all information previously supplied.
17 // NVIDIA Corporation products are not authorized for use as critical
18 // components in life support devices or systems without express written approval of
19 // NVIDIA Corporation.
20 //
21 // Copyright (c) 2021 NVIDIA Corporation. All rights reserved.
22 //
23 // NVIDIA Corporation and its licensors retain all intellectual property and proprietary
24 // rights in and to this software and related documentation and any modifications thereto.
25 // Any use, reproduction, disclosure or distribution of this software and related
26 // documentation without an express license agreement from NVIDIA Corporation is
27 // strictly prohibited.
28 //
30 
31 #ifndef DW_CORE_HEALTH_SIGNALS_H_
32 #define DW_CORE_HEALTH_SIGNALS_H_
33 
34 #include <dw/core/base/Types.h>
35 
36 #ifdef __cplusplus
37 extern "C" {
38 #endif
39 
40 // New Health Signal API Definition
41 // Note: All enums follow the rule that two enum values will have a Hamming Distance > 1
42 
46 typedef enum dwHealthState {
47  HEALTH_STATE_UNKNOWN = 0, // Unable to determine health state
52 
57 typedef enum dwSeverityLevel {
58  SEVERITY_LEVEL_UNKNOWN = 0, // Unable to determine severity level
64 
65 #define DW_MAX_MESSAGE_LENGTH 32
66 #define DW_MAX_HEALTH_KEY_VALUE_PAIRS 16
67 
71 typedef struct dwHealthKeyValue
72 {
76 
80 typedef struct dwHealthSignal
81 {
83 
85 
87 
88  uint8_t score;
89 
92  uint64_t id;
93 
96  uint32_t age;
97 
98  uint32_t sourceID;
99  uint32_t errorCode;
100 
101  uint32_t nValues;
104 
105 #define DW_MAX_HEALTH_SIGNAL_ARRAY_SIZE 64
106 
112 typedef struct dwHealthSignalArray
113 {
115  uint32_t count; // Number of health signals present in the array
117 
118 #ifdef __cplusplus
119 }
120 #endif
121 
122 #endif
NVIDIA DriveWorks API: Core Types
Basic health signal that describes the health status of a particular software element.
Definition: HealthSignals.h:80
#define DW_MAX_MESSAGE_LENGTH
Definition: HealthSignals.h:65
#define DW_MAX_HEALTH_KEY_VALUE_PAIRS
Definition: HealthSignals.h:66
char value[DW_MAX_MESSAGE_LENGTH]
Debug information related to the health signal.
Definition: HealthSignals.h:74
uint32_t nValues
Number of key value pairs defined in the field values below.
dwSeverityLevel
Enumerated levels of severity describing the consequence of health signal on the entire system...
Definition: HealthSignals.h:57
uint32_t age
Represents the time (number of cycles of the source generating the signal) since the last id change...
Definition: HealthSignals.h:96
dwHealthState healthState
Definition: HealthSignals.h:84
uint64_t id
Represents an ID for the current health state and will change whenever a new health state is reported...
Definition: HealthSignals.h:92
uint32_t errorCode
Defines the code of health failure being reported.
Definition: HealthSignals.h:99
Represents an array of health signals which are grouped together as one structure.
#define DW_MAX_HEALTH_SIGNAL_ARRAY_SIZE
char key[DW_MAX_MESSAGE_LENGTH]
Describes the information that the value represents.
Definition: HealthSignals.h:73
dwHealthState
Enumerated levels of health describing health status.
Definition: HealthSignals.h:46
uint8_t score
In range [0,255] where 0 implies critically unhealthy and 255 implies completely healthy.
Definition: HealthSignals.h:88
int64_t dwTime_t
Specifies a timestamp unit, in microseconds.
Definition: Types.h:82
dwSeverityLevel severityLevel
Definition: HealthSignals.h:86
dwTime_t timestamp
Definition: HealthSignals.h:82
Defines a pair of a key and value used to provide additional debugging information to the dwHealthSig...
Definition: HealthSignals.h:71
uint32_t sourceID
Defines the source of the health signal.
Definition: HealthSignals.h:98