CLASSIC
Modul: canif
Rolle: constitutive
Konfidenz: 95%
SNIP_CLASSIC_CANIF_SECTION_8_3_16_CanIf_GetTrcvWakeupReason
Wortlaut
8.3.16 CanIf_GetTrcvWakeupReason
[SWS_CANIF_00289] Definition of API function CanIf_GetTrcvWakeupReason ⌈
Service Name
CanIf_GetTrcvWakeupReason
Syntax
Std_ReturnType CanIf_GetTrcvWakeupReason (
uint8 TransceiverId,
CanTrcv_TrcvWakeupReasonType* TrcvWuReasonPtr
)
Service ID [hex]
0x0f
Sync/Async
Synchronous
Reentrancy
Non Reentrant
Parameters (in)
TransceiverId
Abstracted CanIf TransceiverId, which is assigned to a CAN
transceiver, which is requested for wake up reason.
Parameters (inout)
None
Parameters (out)
TrcvWuReasonPtr
provided pointer to where the requested transceiver wake up
reason shall be returned
Return value
Std_ReturnType
E_OK: Transceiver wake up reason request has been accepted.
E_NOT_OK: Transceiver wake up reason request has not been
accepted.
Description
This service returns the reason for the wake up of the transceiver TransceiverId, via calling the
corresponding CAN Transceiver Driver service.
Available via
CanIf.h
⌋
Note: The ability to detect and differentiate the possible wake up reasons depends
strongly on the CAN transceiver hardware. For more details, please refer to the [2,
[SWS_CANIF_00368] ⌈The function CanIf_GetTrcvWakeupReason() shall call
CanTrcv_GetBusWuReason(Transceiver, Reason) on the corresponding requested CanTrcv.⌋
Note: The parameters of the function CanTrcv_GetBusWuReason() are of type:
• reason: CanTrcv_TrcvWakeupReasonType
• Transceiver: uint8 (Transceiver to which API call has to be applied)
(see [2, Specification of CAN Transceiver Driver])
[SWS_CANIF_00537]
Upstream requirements: SRS_BSW_00323
⌈If parameter TransceiverId of CanIf_GetTrcvWakeupReason() has an invalid
value, the CanIf shall report development error code CANIF_E_PARAM_TRCV to the
Det_ReportError service of the DET module, when CanIf_GetTrcvWakeupReason() is called.⌋
[SWS_CANIF_00649]
Upstream requirements: SRS_BSW_00323
⌈If parameter TrcvWuReasonPtr of CanIf_GetTrcvWakeupReason() has an invalid value, the CanIf shall report development error code CANIF_E_PARAM_POINTER
to the Det_ReportError service of the DET module, when CanIf_GetTrcvWakeupReason() is called.⌋
Note: Please be aware, that if more than one network is available, each network may
report a different wake-up reason. E.g. if an ECU uses CAN, a wake-up by CAN may
occur and the incoming data may cause an internal wake-up for another CAN network.
The service CanIf_GetTrcvWakeupReason() has a "per network" view and does
not vote the more important reason or sequence internally. The same may be true if
e.g. one transceiver controls the power supply and the other is just powered or un-powered. Then one may be able to return CANIF_TRCV_WU_POWER_ON, whereas the
other may state e.g. CANIF_TRCV_WU_RESET. It is up to the calling module to decide,
how to handle the wake-up information.
[SWS_CANIF_00371] ⌈Configuration of CanIf_GetTrcvWakeupReason():
The
number of supported transceiver types for each network is set up in the configuration phase (see CanIfTrcvCfg and CanIfTrcvDrvCfg). If no transceiver is used,
this function may be omitted. Therefore, if no transceiver is configured in LT or PB
class the API shall return with E_NOT_OK.⌋
Versionen & Provenienz · Zugeordnete Anforderungen
Diese Angaben zeigt der Versions-Explorer.
Begründung & Zuweisungs-Evidenz
Cited verbatim in the snippet (deterministic citation).
Dokumenten-Herkunft & Rückverfolgbarkeit
| Spezifikations-Dokument | SWS_CANInterface.pdf |
|---|---|
| Dokumentseite | Seite 98 |
| Ziel-Modul | canif (classic) |
| Ziel-Anforderung | SWS_Std_00005 |
| Semantische Rolle | constitutive |
| Automatisierungs-Konfidenz | 0.95 |