Flow to Forward a Dialed number (use a Calling Card)

General discussions about Automagic and automation in general

Moderator: Martin

Post Reply
CjoeX
Posts: 2
Joined: 01 Nov 2019 19:27

Flow to Forward a Dialed number (use a Calling Card)

Post by CjoeX » 01 Nov 2019 20:30

I call some international numbers and wanted to automate it so those numbers are automatically forwarded to use a calling card I have. The flow would be if number is dialed with a "+". To end the call and redial the calling card number and then enter the number dialed after a couple of pauses. I am having a hard time ending the initial dialed call though. I tried it on MacroDroid and there is an option to end call which works. Ending the call as an action on Automagic doesn't. I've tried the workaround and it still seems not to work. Am I missing something? I have an s9+ running Pie.

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

Re: Flow to Forward a Dialed number (use a Calling Card)

Post by Desmanto » 03 Nov 2019 18:47

Ending call sometimes require root on some devices. The other method that guarantee to work properly is to use Control UI, find the element ID which correspond to the end call button and click it. The device screen should in ON state, because control UI only works when the screen is ON.
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.

CjoeX
Posts: 2
Joined: 01 Nov 2019 19:27

Re: Flow to Forward a Dialed number (use a Calling Card)

Post by CjoeX » 04 Nov 2019 00:06

Interesting. How does Macrodroid accomplish it wihtout root? For the ControlUI route, but how do I find the element id for the end call button? Thanks.

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

Re: Flow to Forward a Dialed number (use a Calling Card)

Post by Desmanto » 05 Nov 2019 18:45

Maybe macrodroid also use the Control UI method, but it has hardcoded several element Id known for most phones.
To find the element Id, you need to use the control UI overlay. Look at my tutorial here : viewtopic.php?f=6&t=7320
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