2015-03-11 08:23 AM
Hi,
I'm trying to set up a NDEF with multiple records. // write NDEF message (command C-APDU - datasheet 5.2.1 p32) ndef[0] = 0x02; // PCB: ndef[1] = 0x00; // CLA: class byte ndef[2] = 0xD6; // INS: instruction byte ndef[3] = 0x00; // P1: param byte 1 ndef[4] = 0x02; // P2: param byte 2 ndef[5] = 5 + 5 + 7 + 5 + 1; // Lc: number of bytes of the data field // record &sharp1 ndef[6] = 0x91; // MB | ME | CF | SR | IL | TNF ndef[7] = 0x01; // type length ndef[8] = 5+1; // payload length ndef[9] = 'U'; // Type field: 'U' - URL, 'T' - text, ... ndef[10] = 0x01; // URI identifier -> 0x01 = ''http://www.'', 0x03 = ''http://'' ndef[11]='s'; ndef[12]='t'; ndef[13]='.'; ndef[14]='d'; ndef[15]='e'; // record &sharp2 ndef[16] = 0x51; // MB | ME | CF | SR | IL | TNF ndef[17] = 0x01; // type length ndef[18] = 5+1; // payload length ndef[19] = 'T'; // Type field: 'U' - URL, 'T' - text, ... ndef[20] = 0x02; // ndef[21] = 'e'; // ndef[22] = 'n'; // ndef[23]='H'; ndef[24]='a'; ndef[25]='l'; ndef[26]='l'; ndef[27]='o'; send_command(ndef, 30); // 28bytes DEF length + 2bytes CRC delay_ms(NDEF_WRITE_DELAY); i2c_read_n_reg_M24SR(M24SR_ADDR,0,5); Unfortunatly the data does not get written to the M24SR chip. What is wrong? #multiple-ndef #m24srSolved! Go to Solution.
2015-06-30 04:37 AM
2015-06-30 04:37 AM