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

[Question] Remove app selection on scanning #1

Open
ghost opened this issue Jul 12, 2021 · 6 comments
Open

[Question] Remove app selection on scanning #1

ghost opened this issue Jul 12, 2021 · 6 comments

Comments

@ghost
Copy link

ghost commented Jul 12, 2021

Hi, so I managed to make this project work and it works great! Except that each time I scan a tag it ask me what app to use even tho I'm currently in the unity app. I have other nfc apps installed that don't do that but can't find how.
I'm on android 10 with unity 2020.3.5
Screenshot_20210712_200310_com android nfc

@ChristophGeske
Copy link
Owner

I do not get such a message running it on my Galaxy S10.
But I also dont have other NFC Apps installed.

I guess you can set the app as a default in your Android settings so the popup dissapears.

I am not sure if you can prevent that by adding a function or changing the settings in Unity.
Have you tried install a brand new app on your phone which also uses the NFC function. Maybe you already set your other NFC apps as the default and thats why you get the popup.

@Stexe
Copy link

Stexe commented Jul 12, 2021

There is a solution to it that was discussed on the Unity forms about NFC scanning on Android. I forget the solution offhand, but if you look around you should be able to find it.

@ghost
Copy link
Author

ghost commented Jul 12, 2021

So I searched a bit and you can't set the default NFC app also I tried multiple apps from the appstore and none have this problem. I'll try to search on unity forums then.

@ghost
Copy link
Author

ghost commented Jul 12, 2021

Ok I found a solution ! All is needed is adding NDEF tags support, it also allow to extract basic text from them.
Here is where I found the fix :
Unity Forum post

I also removed <uses-sdk android:minSdkVersion="21"/> to support latest version of the android sdk

@Stexe
Copy link

Stexe commented Jul 13, 2021

Yeah, that's the page I was talking about (you can see I've even Liked the posts and posted there before). Glad it worked out, I never got to test it much myself.

@craftercis
Copy link

craftercis commented Jan 10, 2022

Ok I found a solution ! All is needed is adding NDEF tags support, it also allow to extract basic text from them. Here is where I found the fix : Unity Forum post

I also removed <uses-sdk android:minSdkVersion="21"/> to support latest version of the android sdk

Hey sorry for the bump. I implemented the code from that forum, he opens the standard NFC app not the one in the project. How can I fix this?

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

3 participants