Use Cases#
This section describes use cases that can be demonstrated with current implementation of the component.
Transmit from CCPLEX side and receive at FSI#
Configure a channel in dt as shown in section “Add channel for NvFsiCom”. We have configured a demo channel_3 channel of below configuration:
frame-count = <4>; frame-size = <64>; core-id = <0>;
Configure an NvSci channel in DT as shown in the “Add channel for NvFsiCom” section. We have configured a demo channel_3 channel below.
Configure the same channel on the FSI side. Refer to the “Add channel in CddCcplexCom” section.
Read channel info from DT. Use the
NvFsiComGetNodeInfo()
API.Register and initialize the channel with NvFsiCom daemon. Use
NvFsiComInit()
API.Use
NvFsiComWrite()
to send data to FSI.Refer to
DemoAppCom.c
sample usage of above APIs where data is sent on channel channel_3.Refer to
SWC_Rx_Indication()
inDemoApp.c
on FSI for sample code to receive data.
Transmit from FSI side and receive at CCPLEX#
Repeat steps 1 and 2 in Sec 5.1.
NvFsiComWaitForEvent()
is an API to get notification for incoming data on CCPLEX. API is called inDemoAppCom.c
to receive the notification for data reception.Call
NvFsiComRead()
to read data on CCPLEX. API is called inDemoAppCom.c
to read the data.LdCom_Transmit
can be called from SWC on FSI to transmit the data. It is demonstrated inDemoApp.c
on FSI.
Transmit From FSI and Receive at CCPLEX in Multiple Thread of a Process#
A process on CCPLEX can receive messages from FSI in different threads. Group channels into multiple Group Ids. Each group can have one or more FSI-CCPLEX-COM channels. Each group can receive messages parallel in different threads. Use NvFsiComGrp*
APIs.
DemoAppComMultiThread
is a sample implementation to demonstrate this functionality. Channels within a group can receive messages sequentially only. For all channels to receive messages in parallel, user will need to configure each group with single channel.
Repeat steps 1 and 2 in Sec 5.1
Add a channel group as shown below:
FsiComApp_grp1{ compatible = "nvidia,tegra-fsicom-grp1"; group_id = <1>; /* Channels which are grouped can receive message in one thread */ nChannels = <2>; /* Number of channels in group */ channelid_list = <2 1>; /* Channel 2 and Channel 1 are grouped */ }
Refer
DemoAppMultiThread
implementation to useNvFsiComGrp*
APICode on FSI side remains same.
Transmit from CCPLEX and Receive Messages on FSI by Polling#
This use case is supported for all FSI cores. Update channel configuration as mentioned below to enable polling support for a channel:
On FSI Side#
Set “Multi Core Support” to True in FsiCom configuration in BSW configurator.
Set “Supports Notification” to false for the channel for which polling has to be used in FsiCom channel configuration in BSW configurator.
PDU and LdCom are supported only for channels which use notifications. For polling based channel, user SWC on FSI needs to connect to
If_CS_CddCcplexComPolling
client server port (user RTE interface to read and write).
Note
Known limitation: “FSI to DBB isolation” in LIS needs to be disabled for polling to work.
On CCPLEX Side#
Configuration update for “FsiComQnxIvc” Node:
Add polling core configuration:
fsi_core_polling=<2 3>; /* Mention cores on which polling support is needed */
Set channel property:
notification = "disabled"; /* To disable interrupts for the channel */
Note
Refer to channel_10 or channel_11 in Configuration section for example configuration.