"Set Speakerphone State: On" makes flow fail

Post your questions and help other users.

Moderator: Martin

bobeurone
Posts: 18
Joined: 15 Jul 2020 15:09

Re: "Set Speakerphone State: On" makes flow fail

Post by bobeurone » 08 Aug 2020 13:18

@Desmanto

below the sequence of screenshots on my Y5 2019 from searching accessibility in global settings:
f5241c1e-a13c-4df8-a05d-7b495ef5a93a.JPG
f5241c1e-a13c-4df8-a05d-7b495ef5a93a.JPG (85.5 KiB) Viewed 31434 times
1d5391ff-0a07-4082-b1ff-e0f0485ca791.JPG
1d5391ff-0a07-4082-b1ff-e0f0485ca791.JPG (106.69 KiB) Viewed 31434 times
00030b07-1b1f-4a71-9b0b-56625223a051.JPG
00030b07-1b1f-4a71-9b0b-56625223a051.JPG (33.17 KiB) Viewed 31434 times

User avatar
Desmanto
Posts: 2709
Joined: 21 Jul 2017 17:50

Re: "Set Speakerphone State: On" makes flow fail

Post by Desmanto » 08 Aug 2020 13:52

@bobeurone : "This service is malfunctioning". It seems the accessibility is broken. Try to disable and enable it again. Also try to disable it, restart the phone, enable it again. (and restart again, if it still malfunction).

Do you use other app which use accessibility too? If yes, try to turn them off first. Also try to disable any other feature in that accessibility setting which might interfere. If none works, go to Automagic Settings > Features & Permissions > Accessibility feedback type > try to change to other type. AFAIR, some huawei phones required to change this to make the AM Accessibility works.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.

bobeurone
Posts: 18
Joined: 15 Jul 2020 15:09

Re: "Set Speakerphone State: On" makes flow fail

Post by bobeurone » 08 Aug 2020 13:59

@Desmanto
Could it be the funky theme Space Dark I installed on the smartphone that disturbed accessibility?

bobeurone
Posts: 18
Joined: 15 Jul 2020 15:09

Re: "Set Speakerphone State: On" makes flow fail

Post by bobeurone » 08 Aug 2020 14:07

@Desmanto disabling => restart => renabling and now Overlay Control button works !! :D :D
Big thank you again.

bobeurone
Posts: 18
Joined: 15 Jul 2020 15:09

Re: "Set Speakerphone State: On" makes flow fail

Post by bobeurone » 08 Aug 2020 17:36

@Desmonto when clicking Airplane Mode text I don't get the Click("Airplane Mode") option but only the getText.
I tried clickById or checkById on the button but it did not work.
Text + Button.png
Text + Button.png (691.14 KiB) Viewed 31412 times
Any hint

User avatar
Desmanto
Posts: 2709
Joined: 21 Jul 2017 17:50

Re: "Set Speakerphone State: On" makes flow fail

Post by Desmanto » 09 Aug 2020 07:33

If CUI return getText("Mode avion"), try to use click("Mode avion"). clickById() and its kind only work for element id.

At my phone, I can still see the click, click (x,y) and clickById(). You need to experiment with various element box to see which one can provide the one you need.

Anyway, this seems to be off topic from the thread title, maybe you should create a new thread for the airplane mode. If you install new AM 1.38.0, and grant Read logs and dump permission, maybe you can toggle airplane mode without root.
To grant the permission in PC

Code: Select all

adb shell pm grant ch.gridvision.ppam.androidautomagic android.permission.READ_LOGS
adb shell pm grant ch.gridvision.ppam.androidautomagic android.permission.DUMP
I can't try it, as I have rooted. Even if I disable the root for Automagic, the binary is still probably there and still have the permission. Hence, what work for me, might not work for you.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.

bobeurone
Posts: 18
Joined: 15 Jul 2020 15:09

Re: "Set Speakerphone State: On" makes flow fail

Post by bobeurone » 09 Aug 2020 16:59

@Desmanto

My initial ask was about clicking the speaker button once phone call is answered.
With overlay control I could find the label of speaker "Haut-parleur" as you can see.
da0509c4-f37d-4b7d-8a34-c359770c50a8.JPG
da0509c4-f37d-4b7d-8a34-c359770c50a8.JPG (106.46 KiB) Viewed 31385 times
I implemented a parallel flow AnswerCall // Sleep(5s);click("Haut-parleur";.
Despite call is answered the click in parallel flow does not work.

User avatar
Desmanto
Posts: 2709
Joined: 21 Jul 2017 17:50

Re: "Set Speakerphone State: On" makes flow fail

Post by Desmanto » 10 Aug 2020 01:06

If you check the log, do you see the flow get executed? It is possible that your call trigger doesn't triggered at all, or maybe executed too early than your 5s delay.

Try clickById("com.android.incallui:id/showAudioButton") and click(576, 1244) too to see if it works. You might want to try other simple Control UI first in other place, such as other app. There is another possibility that your dialer is flagged secure and can't be controlled by CUI.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.

bobeurone
Posts: 18
Joined: 15 Jul 2020 15:09

Re: "Set Speakerphone State: On" makes flow fail

Post by bobeurone » 10 Aug 2020 07:23

@Desmanto The trigger of my flow works well since call is indeed answered, this is the parallel flow that is problematic and specifically clicking the speaker.

I already tried clickById("com.android.incallui:id/showAudioButton") with no more success. I did not try click(x,y) for speaker but for "Airplane mode" in tutorial click(x,y) did not work either and the flow was much simpler with no filter and no parallel branch. A speech() function before click() works well so the parallel branch is indeed executing.

Since I could not click either the "Airplane Mode" in your tutorial, I suspect my phone has some security setting that prevents specific actions on buttons. Any idea how I could check that?

User avatar
Desmanto
Posts: 2709
Joined: 21 Jul 2017 17:50

Re: "Set Speakerphone State: On" makes flow fail

Post by Desmanto » 10 Aug 2020 10:28

Try to change the accessibiity feedback type to other, as I mentioned before. Some huawei phone required to change it first. I don't have any friend using huawei here, can't test it. In most cases, accessibility frequently got killed by the system power saver. You have to toggle it again (disable and enable it again), never touch the kill all button. Then make sure you try the Control UI before any screen off, as the power saver usually kicks in after screen off.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.

Post Reply