Tag write error

Hello,

hope someone can help me: I try to write NFC tags using the openHAB Android app, but getting the error “Tag write error”. This is happening with different devices. I also tested to write the tags using different apps like NFC Tools, with which it is no problem.
So to investigate the issue, I would like to know where the openHAB is logging those errors?

Thanks

Hi,

the app is logging the error message: openhab-android/WriteTagActivity.kt at main · openhab/openhab-android · GitHub. Can you check the app log in the settings?

What Android versions have these devices?

Hi mueller-ma,

this is the app log from settings:


Device information
Model: 21081111RG
Manufacturer: Xiaomi
Brand: Xiaomi
Device: amber
Product: amber_eea
OS: 11
Display: 1080x2186, 2.75 density
Data usage policy: DataUsagePolicy(canDoLargeTransfers=true, loadIconsWithState=true, autoPlayVideos=true, canDoRefreshes=true), data saver: 1, battery saver: false

--------- beginning of events
03-22 07:47:04.068 10751 10751 I menu_item_selected: [0,Protokoll löschen]
--------- beginning of main
03-22 07:47:05.964 10751 10751 D LogActivity: onOptionsItemSelected()
03-22 07:47:05.967 10751 10751 I wm_on_top_resumed_lost_called: [14959573,org.openhab.habdroid.ui.LogActivity,topStateChangedWhenResumed]
03-22 07:47:05.968 10751 10751 I wm_on_paused_called: [0,org.openhab.habdroid.ui.LogActivity,performPause,0]
03-22 07:47:05.971 10751 10751 I wm_on_restart_called: [0,org.openhab.habdroid.ui.PreferencesActivity,performRestartActivity,0]
03-22 07:47:05.972 10751 10751 D ServerConfiguration: load: ServerConfiguration(id=1, name=openHAB, localPath=ServerPath(url=https://:9443/, userName=, password=), remotePath=ServerPath(url=https://myopenhab.org/, userName=, password=), sslClientCert=null, defaultSitemap=DefaultSitemap(name=uicomponents_page_3e49d3534a, label=NoHome), wifiSsids=[])
03-22 07:47:05.973 10751 10751 I wm_on_start_called: [0,org.openhab.habdroid.ui.PreferencesActivity,handleStartActivity,1]
03-22 07:47:05.973 10751 10751 V PhoneWindow: DecorView setVisiblity: visibility = 0, Parent = android.view.ViewRootImpl@f2852ff, this = DecorView@5ad4c21[PreferencesActivity]
03-22 07:47:05.973 10751 10751 I wm_on_resume_called: [0,org.openhab.habdroid.ui.PreferencesActivity,RESUME_ACTIVITY,0]
03-22 07:47:05.973 10751 10751 I wm_on_top_resumed_gained_called: [179316519,org.openhab.habdroid.ui.PreferencesActivity,topWhenResuming]
03-22 07:47:05.973 10751 10751 V PhoneWindow: DecorView setVisiblity: visibility = 0, Parent = android.view.ViewRootImpl@f2852ff, this = DecorView@5ad4c21[PreferencesActivity]
03-22 07:47:05.974 10751 32603 I okhttp.OkHttpClient: → GET https://myopenhab.org/api/v1/settings/notifications
03-22 07:47:05.974 10751 32603 I okhttp.OkHttpClient: User-Agent: Mozilla/5.0 (Linux; Android 4.0.4; Galaxy Nexus Build/IMM76B) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.133 Mobile Safari/535.19
03-22 07:47:05.974 10751 32603 I okhttp.OkHttpClient: Cache-Control: no-cache
03-22 07:47:05.974 10751 32603 I okhttp.OkHttpClient: → END GET
03-22 07:47:05.974 10751 7007 D ConnectionFactory: checkAvailableConnection: found types [ConnectionType(type = Wifi, network=435)]
03-22 07:47:05.974 10751 7007 D AbstractConnection: Checking reachability of https://:9443/ (via 435)
03-22 07:47:05.975 10751 7007 I System.out: [socket]:check permission begin!
03-22 07:47:05.979 10751 7007 D AbstractConnection: Socket connected (attempt 0)
03-22 07:47:05.980 10751 7007 D ConnectionFactory: Connecting to local URL via ConnectionType(type = Wifi, network=435)
03-22 07:47:06.005 10751 10751 I wm_on_stop_called: [0,org.openhab.habdroid.ui.LogActivity,LIFECYCLER_STOP_ACTIVITY,0]
03-22 07:47:06.005 10751 10751 V PhoneWindow: DecorView setVisiblity: visibility = 4, Parent = android.view.ViewRootImpl@7d52b56, this = DecorView@161c6fb[LogActivity]
03-22 07:47:06.005 10751 10751 I wm_on_destroy_called: [0,org.openhab.habdroid.ui.LogActivity,performDestroy,0]
03-22 07:47:06.006 10751 10751 D View : [Warning] assignParent to null: this = DecorView@161c6fb[LogActivity]
03-22 07:47:06.009 10751 10751 I InputTransport: Destroy ARC handle: 0xb4000071341d90c0
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: ← 200 OK https://myopenhab.org/api/v1/settings/notifications (127ms)
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: Server: nginx/1.18.0 (Ubuntu)
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: Date: Tue, 22 Mar 2022 06:47:07 GMT
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: Content-Type: application/json; charset=utf-8
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: Content-Length: 35
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: Connection: keep-alive
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: X-Powered-By: Express
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: ETag: W/“23-/xrOAw4kk/UMX+JDa+0r4GFH8rY”
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: Set-Cookie: ██
03-22 07:47:06.101 10751 32603 I okhttp.OkHttpClient: ← END HTTP
03-22 07:47:06.109 10751 7007 D FcmRegistrationWorker: Run with action org.openhab.habdroid.action.REGISTER_GCM
03-22 07:47:06.110 10751 7007 D FcmRegistrationWorker: Register device at openHAB-cloud with URL: addAndroidRegistration

I cleared it before trying to write the tag and I enabled the extended logs. But I cannot find any message regarding the NFC tag.
The Android versions of the devices I tried are 9, 10 and 11.

I can confirm the Tag Write Error. I tried it with NFC tags that had previously been written with the openHAB app, and tags that are blank.

The previously written tags still work to trigger actions, but as soon as you go into writing mode in the OH app, you get the error.

I’m on Android 12 and using the stable version of the app. The last time I tried this was probably a year ago, with the same phone.

Similarly, the app doesn’t appear to generate any logs whether I’m writing or reading tags.

Fixed: Release 2.20.5-beta · openhab/openhab-android · GitHub

3 Likes