Hi @pcchang ,
Thanks for your interest in NXP MIMXRT series!
In the process you mentioned, the calculation is done by one combination per 4 bits. Divide the 32-bit wdata_swap into 8 combinations, then each is a 1*4 matrix, and multiply it with a 4*4 matrix to get another 1*4 matrix. It is the corresponding four bits in wdata_ECC.
Best regards,
Gavin