Lines Matching refs:Felica
157 NdefMap->Felica.Offset = Offset; in phFriNfc_Felica_RdNdef()
161 NdefMap->Felica.CurBlockNo = 0; in phFriNfc_Felica_RdNdef()
162 NdefMap->Felica.OpFlag = PH_FRINFC_NDEFMAP_FELI_RD_ATTR_RD_OP; in phFriNfc_Felica_RdNdef()
163 NdefMap->Felica.IntermediateCpyFlag = FALSE; in phFriNfc_Felica_RdNdef()
164 NdefMap->Felica.IntermediateCpyLen = 0; in phFriNfc_Felica_RdNdef()
165 NdefMap->Felica.Rd_NoBytesToCopy = 0; in phFriNfc_Felica_RdNdef()
166 NdefMap->Felica.EofCardReachedFlag= FALSE ; in phFriNfc_Felica_RdNdef()
167 NdefMap->Felica.LastBlkReachedFlag = FALSE; in phFriNfc_Felica_RdNdef()
168 NdefMap->Felica.CurrBytesRead = 0; in phFriNfc_Felica_RdNdef()
170 phFriNfc_Felica_HInitInternalBuf(NdefMap->Felica.Rd_BytesToCopyBuff); in phFriNfc_Felica_RdNdef()
186 if(( ( Offset == PH_FRINFC_NDEFMAP_SEEK_CUR) && (NdefMap->Felica.CurBlockNo == Nbc)) && in phFriNfc_Felica_RdNdef()
187 (NdefMap->Felica.EofCardReachedFlag == FELICA_RD_WR_EOF_CARD_REACHED )) in phFriNfc_Felica_RdNdef()
194 …NdefMap->Felica.CurrBytesRead = ((NdefMap->Felica.CurBlockNo * 16)- NdefMap->Felica.Rd_NoBytesToCo… in phFriNfc_Felica_RdNdef()
195 status = phFriNfc_Felica_HReadData(NdefMap,NdefMap->Felica.Offset); in phFriNfc_Felica_RdNdef()
216 …if( ( (NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex) > 0) && (NdefMap->Felica.CurBlockNo < Nbc… in phFriNfc_Felica_HReadData()
219 if (NdefMap->Felica.Rd_NoBytesToCopy > 0 ) in phFriNfc_Felica_HReadData()
225 if ( (status != NFCSTATUS_SUCCESS) && (NdefMap->Felica.IntermediateRdFlag == TRUE )) in phFriNfc_Felica_HReadData()
248 if ( (status != NFCSTATUS_SUCCESS) && (NdefMap->Felica.IntermediateRdFlag == TRUE )) in phFriNfc_Felica_HReadData()
273 if ( (BlocksToRead > Nbc) ||( (BlocksToRead) > ( Nbc - NdefMap->Felica.CurBlockNo)) ) in phFriNfc_Felica_HSetTrxLen()
275 BlocksToRead = Nbc - NdefMap->Felica.CurBlockNo; in phFriNfc_Felica_HSetTrxLen()
288 NdefMap->Felica.LastBlkReachedFlag =1; in phFriNfc_Felica_HSetTrxLen()
295 if ( ( BlocksToRead * 16) == ((Nbc *16) - (NdefMap->Felica.CurBlockNo * 16))) in phFriNfc_Felica_HSetTrxLen()
297 NdefMap->Felica.LastBlkReachedFlag =1; in phFriNfc_Felica_HSetTrxLen()
310 NdefMap->Felica.TrxLen = TranscLen; in phFriNfc_Felica_HSetTrxLen()
332 if( NdefMap->Felica.Rd_NoBytesToCopy > 0 ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
334 if ( (NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex) < NdefMap->Felica.Rd_NoBytesToCopy ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
336 … NdefMap->Felica.Rd_NoBytesToCopy -= (uint8_t)(NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
338 if (NdefMap->Felica.IntermediateCpyFlag == TRUE ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
342 … (&(NdefMap->Felica.Rd_BytesToCopyBuff[NdefMap->Felica.IntermediateCpyLen])), in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
348 … NdefMap->Felica.IntermediateCpyLen += (uint8_t)(NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
349 NdefMap->Felica.IntermediateCpyFlag = 1; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
357 if ( NdefMap->Felica.Rd_NoBytesToCopy == 0) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
359 NdefMap->Felica.EofCardReachedFlag =FELICA_RD_WR_EOF_CARD_REACHED; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
366 NdefMap->Felica.Rd_BytesToCopyBuff, in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
372 … else if ( (NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex) == NdefMap->Felica.Rd_NoBytesToCopy ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
374 if ( NdefMap->Felica.IntermediateCpyFlag == TRUE ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
378 … (&(NdefMap->Felica.Rd_BytesToCopyBuff[NdefMap->Felica.IntermediateCpyLen])), in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
379 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
385 NdefMap->Felica.Rd_BytesToCopyBuff, in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
386 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
390 NdefMap->ApduBuffIndex += NdefMap->Felica.Rd_NoBytesToCopy; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
391 NdefMap->Felica.Rd_NoBytesToCopy -= (uint8_t)(NdefMap->ApduBuffIndex); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
399 if ( NdefMap->Felica.IntermediateCpyFlag == TRUE ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
403 … (&(NdefMap->Felica.Rd_BytesToCopyBuff[NdefMap->Felica.IntermediateCpyLen])), in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
404 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
410 NdefMap->Felica.Rd_BytesToCopyBuff, in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
411 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
414 NdefMap->ApduBuffIndex += NdefMap->Felica.Rd_NoBytesToCopy; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
423 …if ( ((NdefMap->Felica.LastBlkReachedFlag == 1) && (( NdefMap->ApduBufferSize - NdefMap->ApduBuffI… in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
428 … NdefMap->Felica.CurrBytesRead = (uint16_t)((DataLen) - (NdefMap->Felica.CurrBytesRead + in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
433 NdefMap->Felica.CurrBytesRead); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
435 NdefMap->ApduBuffIndex += NdefMap->Felica.CurrBytesRead; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
444 … if( ( (NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex) <= NdefMap->Felica.TrxLen )|| in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
452 NdefMap->Felica.Rd_NoBytesToCopy = (uint8_t)(16-(( Nbc * 16) - (DataLen))); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
454 … if ( NdefMap->Felica.Rd_NoBytesToCopy > (NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex)) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
457 … NdefMap->Felica.Rd_NoBytesToCopy -= (uint8_t)(NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
467 … NdefMap->Felica.CurrBytesRead = (uint16_t)((DataLen)- (NdefMap->Felica.CurrBytesRead + in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
470 if(NdefMap->Felica.CurrBytesRead < in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
476 NdefMap->Felica.CurrBytesRead); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
485 if ( NdefMap->Felica.LastBlkReachedFlag == 1 ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
487 NdefMap->Felica.Rd_NoBytesToCopy = in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
488 (uint8_t)((NdefMap->Felica.CurrBytesRead > in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
490 (NdefMap->Felica.CurrBytesRead - in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
494 ResetFlag = ((NdefMap->Felica.Rd_NoBytesToCopy == 0)?TRUE:FALSE); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
499 …NdefMap->Felica.Rd_NoBytesToCopy = (uint8_t)( NdefMap->Felica.TrxLen - (NdefMap->ApduBufferSize - … in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
503 (void)memcpy( NdefMap->Felica.Rd_BytesToCopyBuff, in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
505 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
509 NdefMap->Felica.IntermediateCpyFlag = TRUE; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
511 NdefMap->ApduBuffIndex += ((NdefMap->Felica.CurrBytesRead < in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
514 NdefMap->Felica.CurrBytesRead: in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
523 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
525 NdefMap->ApduBuffIndex += NdefMap->Felica.Rd_NoBytesToCopy; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
534 if ((NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex) < NdefMap->Felica.TrxLen ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
537 if ( NdefMap->Felica.LastBlkReachedFlag == 1) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
539 NdefMap->Felica.Rd_NoBytesToCopy = (uint8_t)(16-(( Nbc * 16) - DataLen)); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
541 … if ( NdefMap->Felica.Rd_NoBytesToCopy > (NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex)) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
544 … NdefMap->Felica.Rd_NoBytesToCopy -= (uint8_t)(NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
550 …NdefMap->Felica.Rd_NoBytesToCopy = (uint8_t)(NdefMap->Felica.TrxLen - (NdefMap->ApduBufferSize - N… in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
561 (void)memcpy( NdefMap->Felica.Rd_BytesToCopyBuff, in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
563 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
565 NdefMap->Felica.IntermediateCpyFlag = TRUE; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
573 NdefMap->Felica.Rd_NoBytesToCopy); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
575 NdefMap->ApduBuffIndex += NdefMap->Felica.Rd_NoBytesToCopy; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
581 NdefMap->Felica.EofCardReachedFlag =FELICA_RD_WR_EOF_CARD_REACHED; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
588 else if ((NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex) == NdefMap->Felica.TrxLen ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
594 (NdefMap->Felica.TrxLen )); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
596 NdefMap->ApduBuffIndex += NdefMap->Felica.TrxLen; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
600 if ((NdefMap->ApduBufferSize - NdefMap->ApduBuffIndex) > NdefMap->Felica.TrxLen ) in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
605 NdefMap->Felica.TrxLen); in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
607 NdefMap->ApduBuffIndex += (uint16_t)NdefMap->Felica.TrxLen; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
615 NdefMap->Felica.Rd_NoBytesToCopy =0; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
616 NdefMap->Felica.IntermediateCpyLen =0; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
617 NdefMap->Felica.IntermediateCpyFlag =FALSE; in phFriNfc_Felica_HAfterRead_CopyDataToBuff()
640 (NdefMap->Felica.CurBlockNo < Nbc )) in phFriNfc_Felica_HChkApduBuff_Size()
652 (NdefMap->Felica.CurBlockNo == Nbc )) in phFriNfc_Felica_HChkApduBuff_Size()
657 ResetFlag = ((NdefMap->Felica.Rd_NoBytesToCopy > 0 )? in phFriNfc_Felica_HChkApduBuff_Size()
680 if ( NdefMap->Felica.CurBlockNo == Nbc ) in phFriNfc_Felica_HChkApduBuff_Size()
683 if ( NdefMap->Felica.Rd_NoBytesToCopy > 0) in phFriNfc_Felica_HChkApduBuff_Size()
685 if ( NdefMap->Felica.EofCardReachedFlag == TRUE ) in phFriNfc_Felica_HChkApduBuff_Size()
695 if( NdefMap->Felica.Rd_NoBytesToCopy > 0 ) in phFriNfc_Felica_HChkApduBuff_Size()
725 NdefMap->Felica.IntermediateRdFlag = TRUE; in phFriNfc_Felica_HChkApduBuff_Size()
751 NdefMap->Felica.Rd_NoBytesToCopy=0; in phFriNfc_Felica_HChkApduBuff_Size()
752 NdefMap->Felica.EofCardReachedFlag=FELICA_RD_WR_EOF_CARD_REACHED; in phFriNfc_Felica_HChkApduBuff_Size()
843 NdefMap->SendRecvBuf[BufIndex] = (uint8_t)(NdefMap->Felica.CurBlockNo + i); in phFriNfc_Felica_HSetTransceiveForRead()
895 NdefMap->Felica.Offset = Offset; in phFriNfc_Felica_WrNdef()
897 NdefMap->Felica.OpFlag = PH_FRINFC_NDEFMAP_FELI_WR_ATTR_RD_OP; in phFriNfc_Felica_WrNdef()
943 NdefMap->Felica.OpFlag = PH_FRINFC_NDEFMAP_FELI_WR_EMPTY_MSG_OP; in phFriNfc_Felica_EraseNdef()
1076 if ( (NdefMap->Felica.Wr_BytesRemained > 0) && (NdefMap->Felica.CurBlockNo == 0)) in phFriNfc_Felica_HUpdateAttrBlkForWrOp()
1091 if ( NdefMap->Felica.Wr_BytesRemained > 0 ) in phFriNfc_Felica_HUpdateAttrBlkForWrOp()
1093 …TotNoWrittenBytes = ( (NdefMap->Felica.CurBlockNo *16)- (16 - (NdefMap->Felica.Wr_BytesRemained))); in phFriNfc_Felica_HUpdateAttrBlkForWrOp()
1097 TotNoWrittenBytes = ( NdefMap->Felica.CurBlockNo *16); in phFriNfc_Felica_HUpdateAttrBlkForWrOp()
1338 if ( ( NdefMap->Felica.Offset == PH_FRINFC_NDEFMAP_SEEK_BEGIN) || in phFriNfc_Felica_HChkAttrBlkForWrOp()
1340 (NdefMap->Felica.Offset != PH_FRINFC_NDEFMAP_SEEK_BEGIN ) )) in phFriNfc_Felica_HChkAttrBlkForWrOp()
1345 NdefMap->Felica.EofCardReachedFlag = FELICA_EOF_REACHED_WR_WITH_BEGIN_OFFSET; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1349 NdefMap->Felica.EofCardReachedFlag = FALSE; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1354 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1355 NdefMap->Felica.CurBlockNo = 0; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1356 NdefMap->Felica.NoBlocksWritten = 0; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1357 phFriNfc_Felica_HInitInternalBuf(NdefMap->Felica.Wr_RemainedBytesBuff); in phFriNfc_Felica_HChkAttrBlkForWrOp()
1363 if (NdefMap->Felica.Offset == PH_FRINFC_NDEFMAP_SEEK_CUR ) in phFriNfc_Felica_HChkAttrBlkForWrOp()
1382 NdefMap->Felica.EofCardReachedFlag =FELICA_EOF_REACHED_WR_WITH_CURR_OFFSET; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1384 NdefMap->Felica.NoBlocksWritten = 0; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1391 NdefMap->Felica.NoBlocksWritten = 0; in phFriNfc_Felica_HChkAttrBlkForWrOp()
1428 status = phFriNfc_Felica_HReadData(NdefMap,NdefMap->Felica.Offset); in phFriNfc_Felica_HChkAttrBlkForRdOp()
1491 if ( NdefMap->Felica.EofCardReachedFlag == FELICA_EOF_REACHED_WR_WITH_BEGIN_OFFSET) in phFriNfc_Felica_HUpdateData()
1495 … BytesRemainedInCard= ( (NdefMap->FelicaAttrInfo.Nmaxb*16) - (NdefMap->Felica.CurBlockNo * 16)); in phFriNfc_Felica_HUpdateData()
1500 if ( NdefMap->Felica.EofCardReachedFlag == FELICA_EOF_REACHED_WR_WITH_CURR_OFFSET ) in phFriNfc_Felica_HUpdateData()
1505 if ( NdefMap->Felica.Wr_BytesRemained ) in phFriNfc_Felica_HUpdateData()
1507 …TotNoWrittenBytes = ( (NdefMap->Felica.CurBlockNo *16)- (16 - (NdefMap->Felica.Wr_BytesRemained))); in phFriNfc_Felica_HUpdateData()
1511 TotNoWrittenBytes = ( NdefMap->Felica.CurBlockNo *16); in phFriNfc_Felica_HUpdateData()
1519 if(NdefMap->Felica.Wr_BytesRemained > 0) in phFriNfc_Felica_HUpdateData()
1533 if ( NdefMap->ApduBufferSize >(uint32_t) (16 - NdefMap->Felica.Wr_BytesRemained)) in phFriNfc_Felica_HUpdateData()
1536 if ( NdefMap->Felica.EofCardReachedFlag ) in phFriNfc_Felica_HUpdateData()
1543 … BytesRemained = (uint8_t)NdefMap->ApduBufferSize - (16 - NdefMap->Felica.Wr_BytesRemained); in phFriNfc_Felica_HUpdateData()
1549 if (!NdefMap->Felica.EofCardReachedFlag) in phFriNfc_Felica_HUpdateData()
1573 NdefMap->Felica.PadByteFlag = TRUE; in phFriNfc_Felica_HUpdateData()
1574 NdefMap->Felica.NoBlocksWritten = BlkNo; in phFriNfc_Felica_HUpdateData()
1585 NdefMap->Felica.NoBlocksWritten = TotNoBlks-1; in phFriNfc_Felica_HUpdateData()
1589 if ( !(BytesRemained - (16 -NdefMap->Felica.Wr_BytesRemained)== 0 )) in phFriNfc_Felica_HUpdateData()
1597 if ( NdefMap->Felica.PadByteFlag ) in phFriNfc_Felica_HUpdateData()
1599 NdefMap->Felica.NoBlocksWritten = TotNoBlks-1; in phFriNfc_Felica_HUpdateData()
1608 … BlkNo =(uint8_t)(( BytesRemained - ((16 -NdefMap->Felica.Wr_BytesRemained)) )/16); in phFriNfc_Felica_HUpdateData()
1628 … if(((!NbwCheck) &&( BytesRemained- (16 - NdefMap->Felica.Wr_BytesRemained))%16) != 0) in phFriNfc_Felica_HUpdateData()
1632 NdefMap->Felica.PadByteFlag = TRUE; in phFriNfc_Felica_HUpdateData()
1633 NdefMap->Felica.NoBlocksWritten = BlkNo; in phFriNfc_Felica_HUpdateData()
1644 NdefMap->Felica.NoBlocksWritten = TotNoBlks-1; in phFriNfc_Felica_HUpdateData()
1649 if ( !(BytesRemained - (16 -NdefMap->Felica.Wr_BytesRemained)== 0 )) in phFriNfc_Felica_HUpdateData()
1658 if ( NdefMap->Felica.PadByteFlag ) in phFriNfc_Felica_HUpdateData()
1660 NdefMap->Felica.NoBlocksWritten = TotNoBlks -1; in phFriNfc_Felica_HUpdateData()
1675 NdefMap->Felica.NoBlocksWritten = 0; in phFriNfc_Felica_HUpdateData()
1684 if ( NdefMap->Felica.PadByteFlag == TRUE ) in phFriNfc_Felica_HUpdateData()
1686 NdefMap->SendRecvBuf[BufIndex] = NdefMap->Felica.CurBlockNo + i; in phFriNfc_Felica_HUpdateData()
1691 CurBlk = NdefMap->Felica.CurBlockNo +1; in phFriNfc_Felica_HUpdateData()
1697 …Map->ApduBufferSize - NdefMap->ApduBuffIndex) >= (uint32_t)(16 - NdefMap->Felica.Wr_BytesRemained)) in phFriNfc_Felica_HUpdateData()
1702 NdefMap->Felica.Wr_RemainedBytesBuff, in phFriNfc_Felica_HUpdateData()
1703 NdefMap->Felica.Wr_BytesRemained); in phFriNfc_Felica_HUpdateData()
1706 BufIndex += NdefMap->Felica.Wr_BytesRemained; in phFriNfc_Felica_HUpdateData()
1712 (16 - NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1715 NdefMap->NumOfBytesWritten = 16 - NdefMap->Felica.Wr_BytesRemained; in phFriNfc_Felica_HUpdateData()
1718 BufIndex += 16 - NdefMap->Felica.Wr_BytesRemained; in phFriNfc_Felica_HUpdateData()
1722 if (!NdefMap->Felica.EofCardReachedFlag) in phFriNfc_Felica_HUpdateData()
1729 … (&(NdefMap->ApduBuffer[(16 - NdefMap->Felica.Wr_BytesRemained)])), in phFriNfc_Felica_HUpdateData()
1730 … (NdefMap->ApduBufferSize - (16 - NdefMap->Felica.Wr_BytesRemained))); in phFriNfc_Felica_HUpdateData()
1734 …NumOfBytesWritten += (uint16_t)(NdefMap->ApduBufferSize - (16 - NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1736 … BufIndex += (uint8_t)(NdefMap->ApduBufferSize - (16 - NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1746 NdefMap->Felica.Wr_BytesRemained = (uint8_t)(16 - PadBytes); in phFriNfc_Felica_HUpdateData()
1749 (void)memcpy( NdefMap->Felica.Wr_RemainedBytesBuff, in phFriNfc_Felica_HUpdateData()
1750 … (&( NdefMap->ApduBuffer[(NdefMap->ApduBufferSize - NdefMap->Felica.Wr_BytesRemained)])), in phFriNfc_Felica_HUpdateData()
1751 ( NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1756 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
1765 … (&(NdefMap->ApduBuffer[(16 - NdefMap->Felica.Wr_BytesRemained)])), in phFriNfc_Felica_HUpdateData()
1771 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
1773 NdefMap->Felica.PadByteFlag =FALSE; in phFriNfc_Felica_HUpdateData()
1783 … (&(NdefMap->ApduBuffer[(16 - NdefMap->Felica.Wr_BytesRemained)])), in phFriNfc_Felica_HUpdateData()
1784 … ( BytesRemained - ((16 -NdefMap->Felica.Wr_BytesRemained) ))); in phFriNfc_Felica_HUpdateData()
1787 … NdefMap->NumOfBytesWritten += (uint16_t)( BytesRemained - (16 -NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1789 … BufIndex += (uint8_t)( BytesRemained - (16 -NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1800 NdefMap->Felica.Wr_BytesRemained = (uint8_t)(16 - PadBytes); in phFriNfc_Felica_HUpdateData()
1803 (void)memcpy(NdefMap->Felica.Wr_RemainedBytesBuff, in phFriNfc_Felica_HUpdateData()
1804 … (&(NdefMap->ApduBuffer[(NdefMap->ApduBufferSize - NdefMap->Felica.Wr_BytesRemained)])), in phFriNfc_Felica_HUpdateData()
1805 (NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1810 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
1818 … (&(NdefMap->ApduBuffer[(16 - NdefMap->Felica.Wr_BytesRemained)])), in phFriNfc_Felica_HUpdateData()
1824 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
1827 NdefMap->Felica.PadByteFlag =FALSE; in phFriNfc_Felica_HUpdateData()
1833 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
1842 NdefMap->Felica.Wr_RemainedBytesBuff, in phFriNfc_Felica_HUpdateData()
1843 (NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
1846 BufIndex+=NdefMap->Felica.Wr_BytesRemained; in phFriNfc_Felica_HUpdateData()
1857 BytesRemained = NdefMap->Felica.Wr_BytesRemained + NdefMap->ApduBufferSize; in phFriNfc_Felica_HUpdateData()
1873 NdefMap->Felica.IntermediateWrFlag = TRUE; in phFriNfc_Felica_HUpdateData()
1875 if ( NdefMap->Felica.PadByteFlag ) in phFriNfc_Felica_HUpdateData()
1877 NdefMap->Felica.NoBlocksWritten = 0; in phFriNfc_Felica_HUpdateData()
1892 … if ( NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo >= NdefMap->FelicaAttrInfo.Nbw) in phFriNfc_Felica_HUpdateData()
1905 NdefMap->SendRecvBuf[BufIndex] = NdefMap->Felica.CurBlockNo + i; in phFriNfc_Felica_HUpdateData()
1920 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
1922 NdefMap->Felica.NoBlocksWritten = NdefMap->FelicaAttrInfo.Nbw; in phFriNfc_Felica_HUpdateData()
1927 NdefMap->Felica.PadByteFlag = FALSE; in phFriNfc_Felica_HUpdateData()
1934 …ap->SendRecvBuf[BufIndex] = (uint8_t)( NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo); in phFriNfc_Felica_HUpdateData()
1938 … for ( i=1; i<= (NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo); i++) in phFriNfc_Felica_HUpdateData()
1942 NdefMap->SendRecvBuf[BufIndex] = NdefMap->Felica.CurBlockNo + i; in phFriNfc_Felica_HUpdateData()
1949 (NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo)*16); in phFriNfc_Felica_HUpdateData()
1952 … BufIndex += (uint8_t)((NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo )*16); in phFriNfc_Felica_HUpdateData()
1957 … NdefMap->NumOfBytesWritten = ((NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlockNo)*16); in phFriNfc_Felica_HUpdateData()
1958 …NdefMap->Felica.NoBlocksWritten = (uint8_t)(NdefMap->FelicaAttrInfo.Nmaxb - NdefMap->Felica.CurBlo… in phFriNfc_Felica_HUpdateData()
1963 NdefMap->Felica.PadByteFlag =FALSE; in phFriNfc_Felica_HUpdateData()
1964 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
1970 if ( NdefMap->Felica.EofCardReachedFlag) in phFriNfc_Felica_HUpdateData()
1977 NdefMap->Felica.PadByteFlag = TRUE; in phFriNfc_Felica_HUpdateData()
1988 NdefMap->Felica.PadByteFlag = TRUE; in phFriNfc_Felica_HUpdateData()
2000 NdefMap->Felica.NoBlocksWritten = BlkNo; in phFriNfc_Felica_HUpdateData()
2008 CurBlk = NdefMap->Felica.CurBlockNo +1; in phFriNfc_Felica_HUpdateData()
2013 if ( NdefMap->Felica.EofCardReachedFlag ) in phFriNfc_Felica_HUpdateData()
2043 NdefMap->Felica.Wr_BytesRemained = (uint8_t)(16 - PadBytes); in phFriNfc_Felica_HUpdateData()
2045 if ( NdefMap->Felica.EofCardReachedFlag ) in phFriNfc_Felica_HUpdateData()
2048 (void)memcpy(NdefMap->Felica.Wr_RemainedBytesBuff, in phFriNfc_Felica_HUpdateData()
2050 ( NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
2056 (void)memcpy( NdefMap->Felica.Wr_RemainedBytesBuff, in phFriNfc_Felica_HUpdateData()
2057 … (&(NdefMap->ApduBuffer[((NdefMap->ApduBufferSize - NdefMap->Felica.Wr_BytesRemained))])), in phFriNfc_Felica_HUpdateData()
2058 ( NdefMap->Felica.Wr_BytesRemained)); in phFriNfc_Felica_HUpdateData()
2064 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_HUpdateData()
2065 NdefMap->Felica.PadByteFlag = FALSE; in phFriNfc_Felica_HUpdateData()
2320 NdefMap->Felica.OpFlag = PH_FRINFC_NDEFMAP_FELI_CHK_NDEF_OP; in phFriNfc_Felica_Process()
2357 if ( NdefMap->Felica.OpFlag == PH_FRINFC_NDEFMAP_FELI_WR_ATTR_RD_OP ) in phFriNfc_Felica_Process()
2368 … else if( NdefMap->Felica.OpFlag == PH_FRINFC_NDEFMAP_FELI_RD_ATTR_RD_OP ) in phFriNfc_Felica_Process()
2378 else if( NdefMap->Felica.OpFlag == PH_FRINFC_NDEFMAP_FELI_CHK_NDEF_OP ) in phFriNfc_Felica_Process()
2388 NdefMap->Felica.OpFlag = PH_FRINFC_NDEFMAP_FELI_OP_NONE; in phFriNfc_Felica_Process()
2392 … else if ( NdefMap->Felica.OpFlag == PH_FRINFC_NDEFMAP_FELI_WR_EMPTY_MSG_OP ) in phFriNfc_Felica_Process()
2500 if ( NdefMap->Felica.IntermediateWrFlag == TRUE ) in phFriNfc_Felica_Process()
2504 … (void)memcpy( (&(NdefMap->Felica.Wr_RemainedBytesBuff[NdefMap->Felica.Wr_BytesRemained])), in phFriNfc_Felica_Process()
2508 NdefMap->Felica.Wr_BytesRemained += in phFriNfc_Felica_Process()
2516 NdefMap->Felica.IntermediateWrFlag = FALSE; in phFriNfc_Felica_Process()
2525 if ( NdefMap->Felica.EofCardReachedFlag ) in phFriNfc_Felica_Process()
2527 if ( NdefMap->Felica.CurBlockNo < NdefMap->FelicaAttrInfo.Nmaxb) in phFriNfc_Felica_Process()
2529 NdefMap->Felica.CurBlockNo += NdefMap->Felica.NoBlocksWritten; in phFriNfc_Felica_Process()
2531 … if (( NdefMap->Felica.CurBlockNo == NdefMap->FelicaAttrInfo.Nmaxb) && in phFriNfc_Felica_Process()
2534 … NdefMap->Felica.EofCardReachedFlag = FELICA_RD_WR_EOF_CARD_REACHED ; in phFriNfc_Felica_Process()
2549 … if ( ( NdefMap->Felica.CurBlockNo == NdefMap->FelicaAttrInfo.Nmaxb) && in phFriNfc_Felica_Process()
2552 … NdefMap->Felica.EofCardReachedFlag =FELICA_RD_WR_EOF_CARD_REACHED; in phFriNfc_Felica_Process()
2575 NdefMap->Felica.CurBlockNo += NdefMap->Felica.NoBlocksWritten; in phFriNfc_Felica_Process()
2607 NdefMap->Felica.Wr_BytesRemained = 0; in phFriNfc_Felica_Process()
2633 NdefMap->Felica.CurBlockNo += (uint8_t)(RecvTxLen/16); in phFriNfc_Felica_Process()
2649 NdefMap->Felica.Rd_NoBytesToCopy = 0; in phFriNfc_Felica_Process()