Closed SantoshSah closed 7 years ago
Hi @SantoshSah,
The getSystemInfo
method should print out in the console what was read from the tag. You should see something like:
** SYSTEM INFO END **
... byte array od read data ...
Could you please paste this printout.
Hello @valentiniljaz ,
Console output:
** SYSTEM INFO START **
** SYSTEM INFO END ** Uint8Array(1)
Error reading: E_SYSTEM_INFO_FAILED | CODE: undefined
Please see detail in below screenshot.
I am using below code:
this.nfcvService.waitForTag();
this.nfcvService.onTag(
(tag) => {
console.log('Found tag', tag);
this.nfcvService
.getSystemInfo(false)
.then((systemInfo) => {
console.log('SystemInfo:', systemInfo); // Check the tag's UID and AFI (optionally)
this.nfcvService.waitForTag();
})
.catch((error) => {
console.log('Error reading:', error);
this.nfcvService.waitForTag();
});
},
(error) => {
console.log('Error on tag', error);
this.nfcvService.waitForTag();
});
The return value of getSystemInfo
should be an array of bytes, where the first byte should be 0
. In your case you received value of 3
, which means there was an error reading system info. Value 3
also tells you what kind of error occurred, but to know for sure I would need the datasheet of your tag. Have you, by any chance, received the datasheet from the manufacturer?
Hello @valentiniljaz ,
I have carried over our conversation from https://github.com/chariotsolutions/phonegap-nfc/issues/195#issuecomment-291551518.
I am able to use single intent after setting parameter value from
true
tofalse
but getting same error messageE_SYSTEM_INFO_FAILED | CODE:undefined
every time i move mobile to tag.