Galaxy S23 and wifi

sperenz55

New member
Hi,

Since i updated my galaxy S23 with the last security update, the trigger WIFI doesn't work.
I can't enable/disable wifi with a macro.
I run all adb commande and reinstall macrodroid with helper and still get issue.
Someone can help me ?

Regards,
Jeremy
 

sperenz55

New member
- i check the accessibility service
- i give admin and change configuration access to macrodroid
- I try why only 1 macro available who will only enable/disable wifi
And on wifi logs, i can see the last time when macrodroid change the wifi was just before the update.
 

Dimlos

Well-known member
Can you enable/disable Wi-Fi with the ADB command? If so, using ADB Shell [Tasker Plugin] would be a temporary fix.
Maybe reviewing the power saving settings and permissions will solve the problem.
 

sperenz55

New member
with adb "svc wifi enable" it's working ! so yes it's a workaround but not a fix. Also i have may macro with wifi if i can avoid it... but yes it's better than nothing.
I check already power saving and permissions but it's good on this side.
 

sperenz55

New member
Same error with tasker and look like it's because of Google update.
Please find the error below 👇
18.59.20/M lastWifiDisableAgoMS: 1677866360829
18.59.20/E check AP state
18.59.20/Mirror android.net.ConnectivityManager.setMobileDataEnabled: unavailable
18.59.20/Mirror android.net.ConnectivityManager.setRadio: unavailable
18.59.20/Mirror android.net.wifi.WifiManager.setWifiApEnabled: unavailable
18.59.20/E AP state: 1
18.59.20/M lastWifiDisableAgoMS: 1677866360830
18.59.20/E current state: 3
18.59.20/E curval: 3
18.59.20/E WiFi: cur: true new: false
18.59.20/E add wait type Wifi Status Group time 2147483647
18.59.20/E add wait type Wifi Status Group done
18.59.20/E add wait task
18.59.21/E Erreur: null
18.59.21/E Couldn't toggle wifi: : Can't toggle wifi. Check notification.


Screenshot_20230303_190106_Google.jpg
 
Last edited:

dhj49er

Well-known member
Another Google restriction that unfortunately impacts on all apps that control WiFi.

A good reason to avoid Android 14.

Macrodroid and or Tasker developers may find a work around, but will need time to see if it's possible.

Fortunately ADB shell method works and is probably the only solution, at least for now.
 

MacroDroidDev

Administrator
Staff member
@sperenz55 That message from Tasker probably just means you need to get the Tasker Settings (helper app) to be able to do this, so I wouldn't assume it's totally broken.

Can you double check that the helper app has been granted location permission at all times, because it's vital for this to work and is something you might not notice.
 

sperenz55

New member
@sperenz55 That message from Tasker probably just means you need to get the Tasker Settings (helper app) to be able to do this, so I wouldn't assume it's totally broken.

Can you double check that the helper app has been granted location permission at all times, because it's vital for this to work and is something you might not notice.
Thank for your reply

After more investigation, the tasker helper provided with Google play used the last API. To bypass the restrictions, I must download an modified version that used the old API. And now it's working.

More information to the link https://github.com/joaomgcd/TaskerSettings

Do you think it could be possible to have the same behavior with Android assistant ?
 

Endercraft

Moderator (& bug finder :D)
But it may use the new API and that why my wifi couldn't be disable by macrodroid. How can I get and send you the log to show you the error ?
Pretty sure it's because for example for me the permission to toggle wifi will not be shown because the API is too low.
 

MacroDroidDev

Administrator
Staff member
The source code for the Tasker settings app is available here: https://github.com/joaomgcd/TaskerS...cd/taskersettings/actions/ActionToggleWifi.kt

I can assure you that the MacroDroid helper app calls exactly the same code. There is no fundamental issue with this not working in MacroDroid as when configured correctly it should work fine.

I suggest you uninstall the helper file and reinstall and then make sure you disable battery optimization and ensure the location permission is granted to always allow.
 

Endercraft

Moderator (& bug finder :D)
Pretty sure it's because for example for me the permission to toggle wifi will not be shown because the API is too low.
@MacroDroidDev I remember that in some thread the permission to toggle wifi on Xiaomi devices did not show because you used API 21 and API 23 was required. Could this be a similar case here ?
 

MacroDroidDev

Administrator
Staff member
No, this is not the case for Samsung. The helper file is currently using the same target SDK as the Tasker app (21) and the same implementation.

I have an updated helper file coming up that will target SDK23 and work on Xiaomi but lets not muddy the waters with that in this thread. It's very frustrating that this helper file even needs to exist as I seem to spend a very large amount of time advising users to disable battery optimization and set the location permission correctly. I am improving this in the next update as well so it should always prompt on startup if these are not set, but this still doesn't help in the case where the user doesn't load the app.
 

sperenz55

New member
Thank you for your help
After a full uninstall and install of Assistant app, wifi switch is working again. And it was not the location permission issue. Look like the application get stuck because no more log was added on the assistant. I don't understand why
 

Endercraft

Moderator (& bug finder :D)
Thank you for your help
After a full uninstall and install of Assistant app, wifi switch is working again. And it was not the location permission issue. Look like the application get stuck because no more log was added on the assistant. I don't understand why
Battery saver issues..
 
Top