Multipacket read of CAN Bus on Colibri i.MX6 with WEC7

Does the function ‘CANTransfer(HANDLE hCAN, PCAN_TRANSFER_BLOCK pCANTransferBlock)’ support multipacket read at a time ? For example,

CAN_PACKET packet[50];
BYTE data[50][8];
INT result[50];

for(i=0;i<50;i++)
{
		packet[i].dwTimeout = 10000;
		packet[i].bAbortTxIfTimeout = TRUE;
		packet[i].byRW = CAN_RW_READ;
		packet[i].pbyBuf = data[i];
		packet[i].PRIO = 0; // Don't care in reception
		packet[i].wLen = 8;
		packet[i].lpiResult = &result[i];
	
}
	

CAN_TRANSFER_BLOCK xfer;
xfer.iNumPackets = 50;
xfer.pCANPackets = packet;

The driver should perform the operations you schedule in sequence, but will stop as soon as it encounters an error. So if the first read timeouts it will not wait the other 49 packets.

Please consider that this is the driver interface, we plan to support CAN in our libraries and this behaviour may change. This may also require some changes in the driver or its interface.
We try to avoid this, of course, but our main goal is to keep the library API stable across the platforms.

Thanks Valter. I tied it and this driver worked as you said. The timeout paratmeter could be set by DWORD dwTimeout in struct CAN_PACKET. Dring the period of dwTimeout , if the CAN messages were sent intensively, it stayed at CANTransfer() and kept receiving messages stored sequently at the place by pbyBuf pointer.