wireless-adb-switch icon indicating copy to clipboard operation
wireless-adb-switch copied to clipboard

[BUG] widget says disconnected, when it is indeed connected. Android 14 Samsung S23 Ultra OneUI 6.1 mode: Shizuku app downloaded from github

Open drewauff opened this issue 1 year ago • 1 comments

System information

Describe your setup, so we can understand the cause of the bug better

  • Android version: <e.g. Android 12>
  • Android vendor: <e.g. MIUI, OneUI, Lineage OS>
  • Mode: <root or Shizuku>
  • WADBS version: <e.g. 1.0>
  • Where did you get the app from: <e.g. IzzyOnDroid or GitHub Releases page>
  • Any additional information you would like to share about your system

Problem description

Describe your problem with as much detail as possible. You may want to include some specific conditions the problem is occurring because of in your opinion (e.g. the widget is not working, but you are using a custom home screen launcher). Provide error logs if you are able to get any. You can capture logs using your PC or an app such as MatLog on your Android device.

  • [ ] This issue was not reported before
  • [ ] I agree to keep the discussion polite and on point

drewauff avatar Apr 08 '24 03:04 drewauff

Hello!

First of all, it seems like I really have to improve the issue template, because a lot of people are misusing it.

Now regarding your issue. You mentioned that you are using Shizuku mode. Did you start Shizuku from your computer? Otherwise, if you used wireless debugging to enable it, Shizuku won't work for WADBS. Refer to this comment for more info.

Smooth-E avatar Apr 12 '24 08:04 Smooth-E

  • Samsung S23 Ultra
  • Android 14 (stock)
  • unrooted
  • Shizuku
  • WADBS 1.1
  • Github

I start Shizuku locally on my phone

I also have a Tasker profile to (more or less) keep wireless debugging active and thererfore Shizuku.

drewauff avatar May 21 '24 01:05 drewauff

I start Shizuku locally on my phone

To properly use WADBS, you will have to start Shizuku from your PC. If you are using this method, it won't work.

I also have a Tasker profile to (more or less) keep wireless debugging active

What do you mean by this?

To clarify. The purpose of WADBS is to provide a quick way of turning wireless debugging on and off, with some convenience features like KDE Connect integration. WADBS is not an alternative to wireless debugging, it is just a tool that utilizes (hidden) system functionality.

Smooth-E avatar May 21 '24 01:05 Smooth-E

to start Shizuku you have to

  1. Turn on wifi
  2. activate wireless debugging and then
  3. run the Shizuku startup script

normally to run the script you would have to launch the Shizuku app the tap start.

I use Tasker to automate all of the that.....more or less

I want to use WADBS to sho the current IP and port on my desktop as a widget.

But as it stands right now the widget just display disconnected. Sometimes it does work but not for long.

drewauff avatar May 21 '24 05:05 drewauff

Can you describe in more detail, what your Tasker script does? Does the issue occur when you disable wireless debugging and then enable it back or does it occur completely randomly?

Smooth-E avatar May 21 '24 07:05 Smooth-E

This is the script that turns on wifi debugging if it is not already on

A1: Custom Setting [ Type: Global Name: adb_wifi_enabled Value: 1 Continue Task After Error:On ]

This is the script that check to see wireless debugging if it is running/activated then run the Shizuku startup script if wifi debugging is not active then activate it and then run the Shizuku starup script.

` A1: Tasker Function [ Function: CheckADBWifi() ]

A2: If [ %has_adb_wifi !~ true ]

    A3: Flash [
         Text: No access to ADB WiFi
         Continue Task Immediately: On
         Dismiss On Click: On ]

    A4: Stop [ ]

A5: End If

A6: ADB Wifi [
     Command: sh /storage/emulated/0/Android/data/moe.shizuku.privileged.api/start.sh
     Timeout (Seconds): 1 ]`

drewauff avatar May 22 '24 01:05 drewauff

During development I did not encounter such issue. The fact that wireless debugging turns off automatically when you disconnect from wifi (or if the network goes out of reach, for example) may be relevant. Also keep in mind that widgets update on an interval of about 2-3 seconds (even though the slider goes down to one second).

Smooth-E avatar May 22 '24 10:05 Smooth-E

Okay, I guess I stumbled upon the same problem as you did. For me sometimes the connection details widget says there is no connection even though there is. This varies from device to device. Since I am using the command line API or a hidden API, I generally cannot expect it to be stable. Since I usually have my widget update interval set to one second, the widget displays correct information on the next update. I will definitely look into this problem later, but for now it's a wont-fix. Feel free to reopen if you find a good path to consistently replicate this or if you determine the external conditions for this to occur. Thanks for being interesting in WADBS!

Smooth-E avatar May 27 '24 07:05 Smooth-E

appreciate the effort..Thank you 👍🏼

drewauff avatar May 27 '24 23:05 drewauff