I am trying to implement the remote wakeup scenario in CAN network with Infotainment ECU. I am currently referring this AUTOSAR Network management document for the implementation https://www.autosar.org/fileadmin/user_upload/standards/foundation/19-11/AUTOSAR_PRS_NetworkManagementProtocol.pdf
I need some clarification about CAN NM message state for checking the remote wakeup in complex device driver (CDD) components. I have 2 channel in Infotainment ECU that are CAN FD and HSCAN. I have configured PNC (Partial Networking) in HSCAN channel.
So my idea is to implement the remote wakeup of Infotainment ECU by checking the NM state from "CanNm_GetState" API directly. As per the AUTOSAR specification, CanNm_GetState API Returns the
state and the mode of the network management from CANM Module.
My idea is like this:
Suppose Infotainment ECU is in sleep state and Other ECU's required Network active request, then Infotainment ECU get CAN NM message from other ECU. So CANNM module in AUTOSAR will update the CAN NM state based on the received PNC ID.
During this time, my CDD (Complex device driver component) can get either 4 state through CanNm_GetState() API.
NM Mode=> "Network Mode"
NM Mode => "Prepare Bus-Sleep Mode"
NM Mode => "Bus-Sleep Mode"
As per AUTOSAR specification, Network mode contains Repeat message state, Normal operation state and Ready sleep state.
So as per the AUTOSAR Network management document, I have understood that
Inactive Mode are Bus Sleep, Prepare Bus Sleep.
Active Mode are Repeat Message State, Normal operation State and Ready Sleep State.
Now I want to clarify below questions:
What will be the NM state (
CanNm_GetStatereturn value) if we enable the Application messages ofHSCANmessages in CAN ? WillNMstate updated byCANMduring this time (local wakeup with application messages) ?If Infotaiment ECU want to wakeup during remote wakeup request (With valid PNC ID), should I only check
Ready sleepstate ofCANMusingCanNm_GetStateAPI ?
I hope my understandings are correct and your help will be appreciated.