Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed: Unable to send NDEF message #35

Open
IZZAGOLD opened this issue Nov 3, 2023 · 1 comment
Open

Fixed: Unable to send NDEF message #35

IZZAGOLD opened this issue Nov 3, 2023 · 1 comment

Comments

@IZZAGOLD
Copy link

IZZAGOLD commented Nov 3, 2023

Hello, I am the owner of Pixel 4a and 7a (android 13 and 14). I couldn't emulate the tag.
I found the solution in the following: in the NFCTagType4.java file
change
public final byte[] ndefDataBuffer = new byte[0xFFFE];
on
public final byte[] ndefDataBuffer = new byte[0x7FFF];

change
public final byte[] ccDataBuffer = new byte[15];
on
public final byte[] ccDataBuffer = new byte[] {
0x00, 0x0f, // CCLEN
0x20, // Mapping Version
0x00, 0x3b, // Maximum R-APDU data size
0x00, 0x34, // Maximum C-APDU data size
0x04, 0x06, // Tag & Length
(byte)0xe1, 0x04, // NDEF File Identifier
(byte)0x7F, (byte)0xFF, // Maximum NDEF size
0x00, // NDEF file read access granted
(byte)0xff, // NDEF File write access denied
};

delete
setUpCapabilityContainerContent and its call
I don't use tag rewriting and I don't care about the writable property.
Please improve these points. Thank you

@dmolinamesa01
Copy link

dmolinamesa01 commented Jun 14, 2024

Hi, I'm facing this problem. When I scan the tag with NFC tools always says that readonly is not able. I have also tried to get the content message working with react-native-nfc-manager but its impossible to get the content message. I couldn't solve it running your fix. Where did you get this info to set that on this file? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants