Home | History | Annotate | Download | only in src

Lines Matching refs:BufIndex

766     uint16_t BufIndex=0,i=0;
787 NdefMap->SendRecvBuf[BufIndex] = 0x00;
788 BufIndex ++;
790 NdefMap->SendRecvBuf[BufIndex] = 0x06;
791 BufIndex++;
795 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
799 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
804 BufIndex+=8;
807 NdefMap->SendRecvBuf[BufIndex] = 0x01;
808 BufIndex++;
811 NdefMap->SendRecvBuf[BufIndex] = 0x0B;
812 BufIndex++;
814 NdefMap->SendRecvBuf[BufIndex] = 0x00;
815 BufIndex++;
818 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(TrxLen/16);
819 BufIndex++;
826 NdefMap->SendRecvBuf[BufIndex] = 0x80;
827 BufIndex++;
830 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(i + 1);
831 BufIndex++;
839 NdefMap->SendRecvBuf[BufIndex] = 0x80;
840 BufIndex++;
843 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(NdefMap->Felica.CurBlockNo + i);
844 BufIndex++;
849 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = (uint8_t) BufIndex;
852 NdefMap->SendLength = BufIndex;
964 uint8_t BufIndex=0, ErrFlag = FALSE;
986 NdefMap->SendRecvBuf[BufIndex] = 0x00;
987 BufIndex++;
990 NdefMap->SendRecvBuf[BufIndex] = 0x08;
991 BufIndex++;
995 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
999 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1004 BufIndex+=8;
1006 NdefMap->SendRecvBuf[BufIndex] = 0x01; /* Number of Services (n=1 ==> 0x80)*/
1007 BufIndex++;
1009 NdefMap->SendRecvBuf[BufIndex] = 0x09; /* Service Code List*/
1010 BufIndex++;
1012 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* Service Code List*/
1013 BufIndex++;
1015 NdefMap->SendRecvBuf[BufIndex] = 0x01; /* Number of Blocks to Write*/
1016 BufIndex++;
1018 NdefMap->SendRecvBuf[BufIndex] = 0x80; /* 1st Block Element : byte 1*/
1019 BufIndex++;
1021 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* 1st Block Element : byte 2, block 1*/
1022 BufIndex++;
1025 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.Version;
1026 BufIndex++;
1028 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.Nbr;
1029 BufIndex++;
1031 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.Nbw;
1032 BufIndex++;
1034 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)((NdefMap->FelicaAttrInfo.Nmaxb) >> 8);
1035 BufIndex++;
1037 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)((NdefMap->FelicaAttrInfo.Nmaxb) & (0x00ff));
1038 BufIndex++;
1040 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1041 BufIndex++;
1043 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1044 BufIndex++;
1046 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1047 BufIndex++;
1049 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1050 BufIndex++;
1054 NdefMap->SendRecvBuf[BufIndex] = 0x0F; /* Write Flag Made On*/
1055 BufIndex++;
1057 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.RdWrFlag; /* Read write flag*/
1058 BufIndex++;
1061 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.LenBytes[0];
1062 BufIndex++;
1064 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.LenBytes[1];
1065 BufIndex++;
1067 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.LenBytes[2];
1068 BufIndex++;
1085 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* Write Flag Made Off*/
1086 BufIndex++;
1088 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.RdWrFlag; /* Read write flag*/
1089 BufIndex++;
1102 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(( TotNoWrittenBytes & 0x00ff0000) >> 16);
1103 BufIndex++;
1105 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)((TotNoWrittenBytes & 0x0000ff00) >> 8);
1106 BufIndex++;
1108 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(TotNoWrittenBytes & 0x000000ff);
1109 BufIndex++;
1122 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(ChkSum >> 8);
1123 BufIndex++;
1125 NdefMap->SendRecvBuf[BufIndex] = (uint8_t )(ChkSum & 0x00ff);
1126 BufIndex++;
1129 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = BufIndex;
1134 NdefMap->SendLength = BufIndex;
1170 uint8_t BufIndex=0;
1184 NdefMap->SendRecvBuf[BufIndex] = 0x00;
1185 BufIndex++;
1188 NdefMap->SendRecvBuf[BufIndex] = 0x08;
1189 BufIndex++;
1193 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1197 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1203 BufIndex+=8;
1205 NdefMap->SendRecvBuf[BufIndex] = 0x01; /* Number of Services (n=1 ==> 0x80)*/
1206 BufIndex++;
1208 NdefMap->SendRecvBuf[BufIndex] = 0x09; /* Service Code List*/
1209 BufIndex++;
1211 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* Service Code List*/
1212 BufIndex++;
1214 NdefMap->SendRecvBuf[BufIndex] = 0x01; /* Number of Blocks to Write*/
1215 BufIndex++;
1217 NdefMap->SendRecvBuf[BufIndex] = 0x80; /* 1st Block Element : byte 1*/
1218 BufIndex++;
1220 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* 1st Block Element : byte 2, block 1*/
1221 BufIndex++;
1224 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.Version;
1225 BufIndex++;
1227 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.Nbr;
1228 BufIndex++;
1230 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.Nbw;
1231 BufIndex++;
1233 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)((NdefMap->FelicaAttrInfo.Nmaxb) >> 8);
1234 BufIndex++;
1236 NdefMap->SendRecvBuf[BufIndex
1237 BufIndex++;
1239 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1240 BufIndex++;
1242 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1243 BufIndex++;
1245 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1246 BufIndex++;
1248 NdefMap->SendRecvBuf[BufIndex] = 0x00; /*RFU*/
1249 BufIndex++;
1251 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.WriteFlag;
1252 BufIndex++;
1254 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.RdWrFlag; /* Read write flag*/
1255 BufIndex++;
1258 NdefMap->SendRecvBuf[BufIndex] = 0x00;
1259 BufIndex++;
1261 NdefMap->SendRecvBuf[BufIndex] = 0x00;
1262 BufIndex++;
1264 NdefMap->SendRecvBuf[BufIndex] = 0x00;
1265 BufIndex++;
1274 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(ChkSum >> 8);
1275 BufIndex++;
1277 NdefMap->SendRecvBuf[BufIndex] = (uint8_t )(ChkSum & 0x00ff);
1278 BufIndex++;
1281 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = BufIndex;
1286 NdefMap->SendLength = BufIndex;
1445 uint8_t BufIndex=0,
1462 NdefMap->SendRecvBuf[BufIndex] = 0x00;
1463 BufIndex++;
1466 NdefMap->SendRecvBuf[BufIndex] = 0x08;
1467 BufIndex++;
1471 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
1475 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
1480 BufIndex+=8;
1482 NdefMap->SendRecvBuf[BufIndex] = 0x01; /* Number of Services (n=1 ==> 0x80)*/
1483 BufIndex++;
1485 NdefMap->SendRecvBuf[BufIndex] = 0x09; /* Service Code List*/
1486 BufIndex++;
1488 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* Service Code List*/
1489 BufIndex++;
1523 NdefMap->SendRecvBuf[BufIndex] = 0;
1524 BufIndex++;
1527 NoOfBlks = BufIndex;
1681 NdefMap->SendRecvBuf[BufIndex] = 0x80;
1682 BufIndex++;
1686 NdefMap->SendRecvBuf[BufIndex] = NdefMap->Felica.CurBlockNo + i;
1687 BufIndex++;
1692 NdefMap->SendRecvBuf[BufIndex] = CurBlk + i;
1693 BufIndex++;
1701 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1706 BufIndex += NdefMap->Felica.Wr_BytesRemained;
1710 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1718 BufIndex += 16 - NdefMap->Felica.Wr_BytesRemained;
1728 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1736 BufIndex += (uint8_t)(NdefMap->ApduBufferSize - (16 - NdefMap->Felica.Wr_BytesRemained));
1742 NdefMap->SendRecvBuf[BufIndex] =0x00;
1743 BufIndex++;
1764 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1769 BufIndex += ((NdefMap->FelicaAttrInfo.Nbw - 1 )*16);
1782 (void)memcpy( (&(NdefMap->SendRecvBuf[BufIndex])),
1789 BufIndex += (uint8_t)( BytesRemained - (16 -NdefMap->Felica.Wr_BytesRemained));
1795 NdefMap->SendRecvBuf[BufIndex] =0x00;
1796 BufIndex++;
1817 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
1822 BufIndex += ((NdefMap->FelicaAttrInfo.Nbw - 1 )*16);
1841 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
1846 BufIndex+=NdefMap->Felica.Wr_BytesRemained;
1849 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
1854 BufIndex+= (uint8_t)NdefMap->ApduBufferSize;
1864 NdefMap->SendRecvBuf[BufIndex] =0x00;
1865 BufIndex++;
1881 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = BufIndex;
1882 NdefMap->SendLength = BufIndex;
1896 NdefMap->SendRecvBuf[BufIndex] = NdefMap->FelicaAttrInfo.Nbw;
1897 BufIndex++;
1902 NdefMap->SendRecvBuf[BufIndex] = 0x80;
1903 BufIndex++;
1905 NdefMap->SendRecvBuf[BufIndex] = NdefMap->Felica.CurBlockNo + i;
1906 BufIndex++;
1910 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
1915 BufIndex += (NdefMap->FelicaAttrInfo.Nbw*16);
1918 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = BufIndex;
1925 NdefMap->SendLength = BufIndex;
1934 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)( NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo);
1935 BufIndex++;
1940 NdefMap->SendRecvBuf[BufIndex] = 0x80;
1941 BufIndex++;
1942 NdefMap->SendRecvBuf[BufIndex] = NdefMap->Felica.CurBlockNo + i;
1943 BufIndex++;
1947 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
1952 BufIndex += (uint8_t)((NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo )*16);
1955 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = BufIndex;
1961 NdefMap->SendLength = BufIndex;
1997 NdefMap->SendRecvBuf[BufIndex] = BlkNo;
1998 BufIndex++;
2005 NdefMap->SendRecvBuf[BufIndex] = 0x80;
2006 BufIndex++;
2009 NdefMap->SendRecvBuf[BufIndex] = CurBlk + i;
2010 BufIndex++;
2016 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
2020 /* increment the bufindex and bytes written*/
2021 BufIndex += (uint8_t )BytesRemainedInCard ;
2027 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
2031 /* increment the bufindex and bytes written*/
2032 BufIndex += (uint8_t)(NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex);
2039 NdefMap->SendRecvBuf[BufIndex] =0x00;
2040 BufIndex++;
2068 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = BufIndex;
2069 NdefMap->SendLength = BufIndex;
2729 uint8_t BufIndex = 0;
2743 NdefMap->SendRecvBuf[BufIndex] = 0x00;
2744 BufIndex++;
2747 NdefMap->SendRecvBuf[BufIndex] = 0x06;
2748 BufIndex++;
2752 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
2756 (void)memcpy((&(NdefMap->SendRecvBuf[BufIndex])),
2762 BufIndex+=8;
2764 NdefMap->SendRecvBuf[BufIndex] = 0x01; /* Number of Services (n=1 ==> 0x80)*/
2765 BufIndex++;
2767 NdefMap->SendRecvBuf[BufIndex] = 0x0B; /* Service Code List*/
2768 BufIndex++;
2770 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* Service Code List*/
2771 BufIndex++;
2773 NdefMap->SendRecvBuf[BufIndex] = 0x01; /* Number of Blocks to read)*/
2774 BufIndex++;
2776 NdefMap->SendRecvBuf[BufIndex] = 0x80; /* 1st Block Element : byte 1*/
2777 BufIndex++;
2779 NdefMap->SendRecvBuf[BufIndex] = 0x00; /* 1st Block Element : byte 2, block 1*/
2780 BufIndex++;
2782 NdefMap->SendRecvBuf[PH_NFCFRI_NDEFMAP_FELI_PKT_LEN_INDEX] = BufIndex;
2787 NdefMap->SendLength = BufIndex;
2845 BufIndex=0;
2847 for(BufIndex = StartIndex;BufIndex <=EndIndex;BufIndex++)
2849 CheckSum += TempBuffer[BufIndex];