Hi,
I think a S32DS demo example "lin_slave_baremetal_s32kxx" can be modified to handle MasterReq (0x3C) and SlaveResp (0x3D) diagnostic frames. The callback can be then
switch (lin1_State->currentEventId)
{
case LIN_PID_OK:
/* Set timeout */
LIN_DRV_SetTimeoutCounter(INST_LIN1, TIMEOUT);
/* If ID is 0x3C, slave node will receive data from master node */
if(0x3C == lin1_State->currentId)
{
/* Call to Receive Frame DATA Function */
LIN_DRV_ReceiveFrameData(INST_LIN1, rxBuff, sizeof(rxBuff));
}
/* If ID is 0x3D, slave node will send data */
if(0x3D == lin1_State->currentId)
{
/* Call to Send Frame DATA Function */
LIN_DRV_SendFrameData(INST_LIN1, txBuff2, sizeof(txBuff2));
}
From CANoe you first send MasterReq (0x3C) frame and later SlaveResp (0x3D) header to which slave should respond.
BR, Petr