Mifare Classic & Ultralight Extension

Ciao @lieutenant_X, the extension when a tag is approched use the TAG_DISCOVERED action that is the lowest level to detect a tag, I was able to develop only this method.
To do what You need I have to develop TECH_DISCOVERED, I tried but with no success.

Ciao
Marco

The extension works well, but it lacks a block to detect whether an NFC card is currently in place. Any solution for that condition.

Hello
i want to use this extension for 2 screens: one is login screen, read uid and compare to DB - if match sign in.
the second screen is the sign up screen where i want to insert the uid into text box. how to do it? i cant at all? other solutions that use uid of nfc? help...
why only in screen1? also, why it always open the app when i scan tag? all tags just open the app in screen1, how to cancel open it?

An ai2 app will always open Screen1 first. You need to code with blocks to take you to another screen if that is what you want.

no
when i not in the app, in android
in google or some other app and scanned, it opens my app
why and how cancel

You need to show your setup for scanning a tag. Are you using a third party app of any kind ?

e.g. like so

i have nfc tools pro but not using

see this
why screen1 is there
how cancel opening auto app inventor app?

Well, there you go, the NFC tag will seek to open your app when it is scanned by your device.

and how to cancel it? why the developer did it at all it's not good...

Any Solution?

it is a good extension exactly what i needed, but it doesnt work in companion the following error

Error from Companion: java.lang.NoSuchMethodError: No static method newNfcAdapter(Landroid/content/Context;)Landroid/nfc/NfcAdapter; in class Lcom/google/appinventor/components/runtime/util/GingerbreadUtil; or its super classes (declaration of 'com.google.appinventor.components.runtime.util.GingerbreadUtil' appears in /data/app/~~ZMOvW3xkhogyAZbemZgbiA==/io.makeroid.companion-dRS8HOFBAapnzUrCL3QByg==/base.apk)

and in compiled apk app wont open, is there any solution, im on android 14

and is it possible that the got uid method fire on app first start so it is not required to scan tag twice, once to open app, second time to get id

Try it in App Inventor
Taifun

in app inventor compiled apk is working, uuid still doesnt work on startup (property last scanned UUID also is null), i hope it can be fixed in kodular its way better to use although app inventor finally ditched android 4 thank god it is way more useable now

Let's ask the author of the extension. @Marco_Perrone if it is possible to adjust the extension for Kodular

Taifun

1 Like

in android builder also is working (there is a bug the screen1 activity name does not follow app package name, so you can not use custom package name), i will use it for now, i hope the server will remain stable while im making my app

Hello, first of all, I would like to thank @Marco_Perrone for this fantastic extension. I have a few questions about it and would love some help: every time I scan an RFID tag, even when I'm not in the app developed with the extension, the app opens on the first screen. Is there any way to prevent this? And secondly, is there any way to use the extension on a screen other than the first one? Thanks!

Ciao Alejandro,
thank you!.
About the extension, the main problem about the app open every time is related to the intent and action TAG_DISCOVERED.
For the RFID android give 3 different action:
TAG_DISCOVERED
TECH_DISCOVERED
NDEF_DISCOVERED
I was able to implement only the first one.
About the screen try to change the manifest where you find andorid:name=".Screen1"
with the name of your screen where you use the extension.
Maybe can resolve both problems

Ciao
Marco

Ciao a tutti,
good news (I hope),
since I started developing this extension, many have asked me why their application opened as soon as they approached a tag, this was because the extension used intents.
I finally found a way to use ForegroundDispatch and readerCallback correctly, the result is that now the tags are only read when the app is open.
I did reading and writing tests on Mifare Classic and Ultralight EV1 tags.
I hope you will find the news useful for your projects

Here the new extension:
mifare.info.aix (25.1 KB)

Best Regards
Marco

1 Like