About ST25TV02kcTag encryption issues
Hi!St Community
My goal is to set a password for the user memory area on the card.
During the process of writing the encryption code for the card, I read the manual for the ST25TV02KC.

Based on the underlined sentence in the image, I first send the data related to the PresentPassword request format.

The corresponding configuration bits in the code are as follows
arr[0] = 0x20;
arr[1] = 0xb3;
arr[2] = 0x02;
arr[3] = uid[7];
arr[4] = uid[6];
arr[5] = uid[5];
arr[6] = uid[4];
arr[7] = uid[3];
arr[8] = uid[2];
arr[9] = uid[1];
arr[10] = uid[0];
arr[11] = 0x01;
arr[12] = 0x11;
arr[13] = 0x22;
arr[14] = 0x33;
arr[15] = 0x44;
arr[16] = 0x55;
arr[17] = 0x66;
arr[18] = 0x77;
arr[19] = 0x88;
arr[20] = (PY_CRC_16_S_X25(arr,20)%256);
arr[21] = (PY_CRC_16_S_X25(arr,20)/256);The send should have been successful, but the return value of the FIFO seems abnormal.

Could it be because the order of my operations was incorrect ?
Before this, I completed the read and write operations on the blocks according to the relevant instructions in the datasheet , and now I will demonstrate that
Related instruction:

Code section:

Print result(display normally):


So, in order to encrypt the block, what exactly should I do? What configurations do I need to set up first?
