फ़ंक्शन ConfigureMonitor [SWS_DM_01696] Upstream: RS_AP_00137, RS_Diag_04179, RS_AP_00121
ara::core::Result< void > ConfigureMonitor (MonitorHandleType monitor Handle, InitMonitorNotifier initMonitor, std::function< std::int8_t()> getFaultDetectionCounter) noexcept;
Configures a monitor with Monitor-internal debouncing. Any overloaded ConfigureMonitor shall be only called once per monitor. The monitor can only be used after this initialisation step.
उपयोग
विधि ara::diag::MultipleMonitor::ConfigureMonitor मॉनिटर-आंतरिक डिबाउंसिंग के लिए एक डायग्नोस्टिक मॉनिटर को प्रारंभ करती है [SWS_DM_01696]। पैरामीटर monitorHandle के माध्यम से कॉन्फ़िगर किए जाने वाले मॉनिटर को संबोधित किया जाता है, जबकि initMonitor के साथ पुनरारंभीकरण के लिए एक नोटिफ़ायर कॉलबैक और getFaultDetectionCounter के साथ वर्तमान त्रुटि गणना मान (FDC) को क्वेरी करने के लिए एक फ़ंक्शन पंजीकृत किया जाता है [SWS_DM_01696]। निष्पादन समकालिक रूप से होता है और एक ara::core::Result<void> लौटाता है AUTOSAR_AP_SWS_Diagnostics §8.44.2.1.3.4 “ConfigureMonitor”।
त्रुटि हैंडलिंग और समवर्तीता
त्रुटि की स्थिति में, त्रुटि परिणाम DiagErrc::kInvalidArgument लौटाया जाता है [SWS_DM_01696]। यह विशेष रूप से तब हो सकता है जब अमान्य फ़ंक्शन पॉइंटर्स पास किए जाते हैं या आंतरिक डिबाउंसिंग में असंगत स्थितियाँ मौजूद होती हैं (व्याख्या)। प्रश्न Q-3de0f2b0cc427ef3 (खुला) ऑपरेशन को noexcept के साथ-साथ अपवाद-सुरक्षित (exception safe) के रूप में निर्दिष्ट किया गया है, लेकिन स्पष्ट रूप से गैर-थ्रेड-सुरक्षित (not thread-safe) के रूप में चिह्नित किया गया है [SWS_DM_01696]। इसलिए समान मॉनिटर इंस्टेंस पर कॉलों को एप्लिकेशन स्तर पर सिंक्रनाइज़ किया जाना चाहिए।
क्रम और इंटरैक्शन
ConfigureMonitor के प्रत्येक ओवरलोड को किसी मॉनिटर के लिए केवल ठीक एक बार कॉल किया जा सकता है; मॉनिटर केवल इस इनिशियलाइज़ेशन चरण के बाद ही उपयोग के लिए तैयार होता है [SWS_DM_01696]। मॉनिटर-आंतरिक डिबाउंसिंग के मामले में, Diagnostic Monitor एप्लिकेशन स्वतंत्र रूप से डिबाउंस लॉजिक को संसाधित करता है और केवल अंतिम परिणामों को Diagnostic Management को प्रेषित करता है AUTOSAR_AP_SWS_Diagnostics §7.3.4.1.5.3 “Monitor-internal debouncing”। अन्य डिबाउंसिंग तंत्रों के लिए, समय-आधारित [SWS_DM_01697], काउंटर-आधारित [SWS_DM_01702] या बिना डिबाउंस की गई निगरानी [SWS_DM_01973] के लिए वैकल्पिक ओवरलोड उपलब्ध हैं।
यह उपयोग नोट विनिर्देश के आधार पर स्वचालित रूप से तैयार किया गया था।
इम्प्लीमेंटर गाइड जल्द आएगी (जटिलता I2)
| Header-Datei | #include "ara/diag/multiple_monitor.h" |
|---|---|
| Scope | class ara::diag::MultipleMonitor |
| Exception-Sicherheit | exception safe |
| Thread-Sicherheit | not thread-safe |
Parameter (in)
| Parameter | Beschreibung |
|---|---|
| monitorHandle | Identifies the requested monitor |
| initMonitor | Possibility to register an InitMonitor callback |
| getFaultDetectionCounter | Possibility to register a function to get the current FDC for this event. |
Rückgabewert
| Typ | Beschreibung |
|---|---|
| ara::core::Result< void > | Returns nothing or an error. |
Fehler
| Fehlercode | Beschreibung |
|---|---|
| DiagErrc::kInvalidArgument | rollback_semantics e.g. kPreFailed with internal debouncing |
Request a governed re-review of this record. The record is not changed immediately.
- Record
AUTOSAR/AP/record/SWS_DM_01696- Status
- valid/unmigrated
- Version
AUTOSAR/AP/record/SWS_DM_01696@rel:R25-11#5ecc3372- Content hash
5ecc3372- Source
- https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01696
Status: valid/unmigrated
Version: rel:R25-11#8434f254
Versionshistorie & Revisions (1 transition, 4 revision)
- Current State
valid/unmigrated- Reason
- mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
- Campaign
2026-08-13-status-backfill- Active Version
AUTOSAR/AP/record/SWS_DM_01696@rel:R25-11#8434f254
Recorded Revisions (4):
- R25-11
rel:R25-11#c62b40112026-09-30 - R23-11
rel:R23-11#daa241aa2026-10-14 - R24-11
rel:R24-11#b8bb06ec2026-10-14 - R25-11
rel:R25-11#8434f2542026-10-14 active
Requirement Text as-of this release:
Curation Decisions:
Reachable Artifacts & Dependents:
| Date | Actor | Transition | Reason / Rationale | Campaign |
|---|---|---|---|---|
| 2026-08-13 | tool | none → valid/unmigrated | mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record | 2026-08-13-status-backfill |
gemini-3.8-flash-low· 2026-10-13 · जर्मन मूल