5.12. CDD_IPC

5.12.1. Types

Base type

Type Name

Brief

enum

Cdd_Ipc_CoreType

CPU cores type.

enum

Cdd_Ipc_TxProcessingType

IPC Tx processing.

enum

Cdd_Ipc_InstanceType

IPC Instance type.

typedef void(*)(const PduInfoType *PduInfoPtr)

Cdd_Ipc_NotifyType

Notification callback function pointer.

5.12.1.1. enum Cdd_Ipc_CoreType

Enumerator

Value

Description

CDD_IPC_CPU1

0U

CPU1.

CDD_IPC_CPU2

1U

CPU2.

CDD_IPC_CPU3

2U

CPU3.

Brief: CPU cores type.

5.12.1.2. enum Cdd_Ipc_TxProcessingType

Enumerator

Value

Description

CDD_IPC_POLLING

1U

Polling mode.

CDD_IPC_INTERRUPT

2U

Interrupt mode.

Brief: IPC Tx processing.

5.12.1.3. enum Cdd_Ipc_InstanceType

Enumerator

Value

Description

CDD_IPC_CPU1_L_CPU2_R_INST0

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU2INTIPCSET(0U)

CPU1 - Local core, CPU2 - Remote core, Instance 1.

CDD_IPC_CPU1_L_CPU2_R_INST1

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU2INTIPCSET(1U)

CPU1 - Local core, CPU2 - Remote core, Instance 2.

CDD_IPC_CPU1_L_CPU2_R_INST2

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU2INTIPCSET(2U)

CPU1 - Local core, CPU2 - Remote core, Instance 3.

CDD_IPC_CPU1_L_CPU2_R_INST3

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU2INTIPCSET(3U)

CPU1 - Local core, CPU2 - Remote core, Instance 4.

CDD_IPC_CPU1_L_CPU3_R_INST0

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU3INTIPCSET(0U)

CPU1 - Local core, CPU3 - Remote core, Instance 1.

CDD_IPC_CPU1_L_CPU3_R_INST1

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU3INTIPCSET(1U)

CPU1 - Local core, CPU3 - Remote core, Instance 2.

CDD_IPC_CPU1_L_CPU3_R_INST2

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU3INTIPCSET(2U)

CPU1 - Local core, CPU3 - Remote core, Instance 3.

CDD_IPC_CPU1_L_CPU3_R_INST3

CPU1IPCSEND_BASE + IPC_O_CPU1TOCPU3INTIPCSET(3U)

CPU1 - Local core, CPU3 - Remote core, Instance 4.

CDD_IPC_CPU2_L_CPU1_R_INST0

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU1INTIPCSET(0U)

CPU2 - Local core, CPU1 - Remote core, Instance 1.

CDD_IPC_CPU2_L_CPU1_R_INST1

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU1INTIPCSET(1U)

CPU2 - Local core, CPU1 - Remote core, Instance 2.

CDD_IPC_CPU2_L_CPU1_R_INST2

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU1INTIPCSET(2U)

CPU2 - Local core, CPU1 - Remote core, Instance 3.

CDD_IPC_CPU2_L_CPU1_R_INST3

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU1INTIPCSET(3U)

CPU2 - Local core, CPU1 - Remote core, Instance 4.

CDD_IPC_CPU2_L_CPU3_R_INST0

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU3INTIPCSET(0U)

CPU2 - Local core, CPU3 - Remote core, Instance 1.

CDD_IPC_CPU2_L_CPU3_R_INST1

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU3INTIPCSET(1U)

CPU2 - Local core, CPU3 - Remote core, Instance 2.

CDD_IPC_CPU2_L_CPU3_R_INST2

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU3INTIPCSET(2U)

CPU2 - Local core, CPU3 - Remote core, Instance 3.

CDD_IPC_CPU2_L_CPU3_R_INST3

CPU2IPCSEND_BASE + IPC_O_CPU2TOCPU3INTIPCSET(3U)

CPU2 - Local core, CPU3 - Remote core, Instance 4.

CDD_IPC_CPU3_L_CPU1_R_INST0

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU1INTIPCSET(0U)

CPU3 - Local core, CPU1 - Remote core, Instance 1.

CDD_IPC_CPU3_L_CPU1_R_INST1

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU1INTIPCSET(1U)

CPU3 - Local core, CPU1 - Remote core, Instance 2.

CDD_IPC_CPU3_L_CPU1_R_INST2

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU1INTIPCSET(2U)

CPU3 - Local core, CPU1 - Remote core, Instance 3.

CDD_IPC_CPU3_L_CPU1_R_INST3

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU1INTIPCSET(3U)

CPU3 - Local core, CPU1 - Remote core, Instance 4.

CDD_IPC_CP3_L_CPU2_R_INST0

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU2INTIPCSET(0U)

CPU3 - Local core, CPU2 - Remote core, Instance 1.

CDD_IPC_CP3_L_CPU2_R_INST1

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU2INTIPCSET(1U)

CPU3 - Local core, CPU2 - Remote core, Instance 2.

CDD_IPC_CP3_L_CPU2_R_INST2

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU2INTIPCSET(2U)

CPU3 - Local core, CPU2 - Remote core, Instance 3.

CDD_IPC_CP3_L_CPU2_R_INST3

CPU3IPCSEND_BASE + IPC_O_CPU3TOCPU2INTIPCSET(3U)

CPU3 - Local core, CPU2 - Remote core, Instance 4.

Brief: IPC Instance type.

5.12.1.4. typedef Cdd_Ipc_NotifyType

typedef void(* Cdd_Ipc_NotifyType) (const PduInfoType *PduInfoPtr);

Brief: Notification callback function pointer.

5.12.2. Structures

Name

Brief

Cdd_Ipc_TxChannelConfigType

IPC Tx channel config type.

Cdd_Ipc_TxInstanceConfigType

IPC Tx instance config type.

Cdd_Ipc_RxChannelConfigType

IPC Rx channel config type.

Cdd_Ipc_RxInstanceConfigType

IPC Rx instance config type.

Cdd_Ipc_ConfigType

IPC config type.

5.12.3. Defines

Name

Brief

CDD_IPC_SW_MAJOR_VERSION

Driver Implementation Major Version.

CDD_IPC_SW_MINOR_VERSION

Driver Implementation Minor Version.

CDD_IPC_SW_PATCH_VERSION

Driver Implementation Patch Version.

CDD_IPC_AR_RELEASE_MAJOR_VERSION

AUTOSAR Major version specification implemented by CDD_IPC Driver.

CDD_IPC_AR_RELEASE_MINOR_VERSION

AUTOSAR Minor version specification implemented by CDD_IPC Driver.

CDD_IPC_AR_RELEASE_REVISION_VERSION

AUTOSAR Patch version specification implemented by CDD_IPC Driver.

CDD_IPC_VENDOR_ID

Texas Instruments Vendor ID.

CDD_IPC_MODULE_ID

CDD IPC Driver Module ID.

CDD_IPC_INSTANCE_ID

CDD IPC Instance ID.

CDD_IPC_E_UNINIT

API service used without module initialization.

CDD_IPC_E_ALREADY_INITIALIZED

API Cdd_Ipc_Init service called while the IPC driver has already been initialized.

CDD_IPC_E_PARAM_VALUE

API service called with invalid parameter value.

CDD_IPC_E_PARAM_POINTER

API service called with invalid data buffer pointer.

CDD_IPC_E_INVALID_LENGTH

API service called with invalid data length.

CDD_IPC_SID_GET_VERSION_INFO

Cdd_Ipc_GetVersionInfo() API Service ID.

CDD_IPC_SID_INIT

Cdd_Ipc_Init() API Service ID.

CDD_IPC_SID_SYNC

Cdd_Ipc_Sync() API Service ID.

CDD_IPC_SID_TRANSMIT

Cdd_Ipc_Transmit() API Service ID.

CDD_IPC_SID_MAIN_FUNCTION_READ

Cdd_Ipc_MainFunction_Read() API Service ID.

CDD_IPC_IS_TX_INSTANCE_FREE

Cdd_Ipc_IsTxInstanceFree() API Service ID.

CDD_IPC_SID_GET_COUNTER

Cdd_Ipc_GetCounter() API Service ID.

BIT_MASK_EIGHT

Bit mask for last 8 bits.

BIT_MASK_FOUR

Bit mask for last 4 bits.

BIT_SHIFT_BY_8

Shift bits by 8 bits.

5.12.4. Functions

Return type

Function Name

Brief

void

Cdd_Ipc_GetVersionInfo(Std_VersionInfoType * VersionInfoPtr)

Service to provide the version information of Cdd Ipc module.

void

Cdd_Ipc_Init(const Cdd_Ipc_ConfigType * ConfigPtr)

Service to initialize CDD IPC driver.

Std_ReturnType

Cdd_Ipc_Sync(Cdd_Ipc_CoreType RemoteCore)

Service to synchronise two cores communicating in IPC communication within a preconfigured timeout.

Std_ReturnType

Cdd_Ipc_Transmit(PduIdType ChannelId, const PduInfoType * PduInfoPtr)

Service to request transmission.

void

Cdd_Ipc_MainFunction_Read(void )

Service to perform the polling of confgured IPC Rx instances.

boolean

Cdd_Ipc_IsTxInstanceFree(PduIdType ChannelId)

Service to check the status of the instance that is configured for transmitting the message in the respective channel.

uint64

Cdd_Ipc_GetCounter(void )

Service to read the timestamp counter value.

5.12.4.1. function Cdd_Ipc_GetVersionInfo

void Cdd_Ipc_GetVersionInfo(
    Std_VersionInfoType * VersionInfoPtr
)

Brief: Service to provide the version information of Cdd Ipc module.

Parameters:

  • VersionInfoPtr is the pointer to CDD IPC driver version information.

Returns:

  • None

Return: None

Precondition: This API is available only if CDD_IPC_GET_VERSION_INFO_API is STD_ON

Postcondition: None

5.12.4.2. function Cdd_Ipc_Init

void Cdd_Ipc_Init(
    const Cdd_Ipc_ConfigType * ConfigPtr
)

Brief: Service to initialize CDD IPC driver.

Parameters:

  • ConfigPtr is the configuration pointer pointing to a generated configuration variant from plugin

Return: None

Precondition: Preconditions - Driver not already initialized

Postcondition: Postconditions - Driver in initialized state

5.12.4.3. function Cdd_Ipc_Sync

Std_ReturnType Cdd_Ipc_Sync(
    Cdd_Ipc_CoreType RemoteCore
)

Brief: Service to synchronise two cores communicating in IPC communication within a preconfigured timeout.

Parameters:

  • RemoteCore is the symbolic name of the remote core that needs to be synchronized with.

Returns:

  • E_OK Synchronization is successful.

  • E_NOT_OK Synchronization failed.

Return: Status of synchronization.

Precondition: None

Postcondition: None

5.12.4.4. function Cdd_Ipc_Transmit

Std_ReturnType Cdd_Ipc_Transmit(
    PduIdType ChannelId,
    const PduInfoType * PduInfoPtr
)

Brief: Service to request transmission.

Parameters:

  • ChannelId : When Cdd Ipc is integrated with Autosar Com stack, this parameter is a Pdu identifier used to address the respective channel. When Cdd Ipc is not integrated with Autosar Com stack, this parameter is a channel identifier used to address the respective channel.

  • PduInfoPtr is the pointer to a struct of type PduInfoType containing the complete data to be transmitted.

Returns:

  • E_OK Transmit request has been accepted.

  • E_NOT_OK Transmit request has not been accepted.

Return: Cdd_Ipc_Transmit request is accepted or not

Precondition: None

Postcondition: None

5.12.4.5. function Cdd_Ipc_MainFunction_Read

void Cdd_Ipc_MainFunction_Read(
    void 
)

Brief: Service to perform the polling of confgured IPC Rx instances.

Returns:

  • None

Return: None

Precondition: None

Postcondition: None

5.12.4.6. function Cdd_Ipc_IsTxInstanceFree

boolean Cdd_Ipc_IsTxInstanceFree(
    PduIdType ChannelId
)

Brief: Service to check the status of the instance that is configured for transmitting the message in the respective channel.

Parameters:

  • ChannelId : When Cdd Ipc is integrated with Autosar Com stack, this parameter is a Pdu identifier used to address the respective channel. When Cdd Ipc is not integrated with Autosar Com stack, this parameter is a channel identifier used to address the respective channel.

Returns:

  • TRUE Instance is free

  • FALSE Instance is busy

Return: IPC instance configured for transmitting the PDU is busy or not

Precondition: None

Postcondition: None

5.12.4.7. function Cdd_Ipc_GetCounter

uint64 Cdd_Ipc_GetCounter(
    void 
)

Brief: Service to read the timestamp counter value.

Return: 64-bit timestamp counter value

Precondition: None

Postcondition: None