I want to send an APDU with a length of 1699 bytes via NFC (class IsoDep
) to a Java Card smartcard. I get the error
java.io.IOException: Transceive length exceeds supported maximum
My phone is a Samsung Galaxy S7.
I use extended-length in my applet on the card. I have verified that the card supports extended length. I tested this via pyapdutool by sending an APDU with 4000 bytes to the card.
I found that when I write this code, the result is false
:
final Tag t = (Tag) tag;
myTag = IsoDep.get(t);
boolean result = myTag.isExtendedLengthApduSupported();
I have this in my manifest:
<activity
android:name=".test"
android:label="@string/title_test"
android:launchMode="singleTop"
android:theme="@style/AppTheme.NoActionBar" >
<action android:name="android.nfc.action.TAG_DISCOVERED" />
<category android:name="android.intent.category.DEFAULT" />
<intent-filter>
<action android:name="android.nfc.action.NDEF_DISCOVERED" />
</intent-filter>
</activity>
How can I send an APDU with 1699 bytes (or any length greater than 261 bytes) through Android NFC?