Need suggestions to go about a macro...

MrDenis

New member
Hi again everyone.

I've tried many ways around a specific automation I'm trying to make work, but have hit nothing but dead ends. Maybe someone will think of something else...

Situation: I have two devices, one of which is a work issued managed phone. I only use it for work, and it doesn't have a SIM card - it only connects through Wifi. I do need to take it with me once in a while, and I'm trying to set a macro up that would essentially "tell" my other phone to turn its hotspot on. I have MD on both phones, but the work phone is severely limited (can't sideload, no ADB, etc). The issue of course is, how can I "tell" my personal phone anything if it loses connection?! I am trying to avoid triggering the scenario from my personal phone as I don't always carry both and I don't want the hotspot to turn on without reason.

I tried to use a Bluetooth LE beacon, and it's the closest I got to success; I downloaded a small BTLE beacon simulator app on the work phone, and a macro on my personal phone that would turn on tethering when it detected the beacon. Works like a charm, except that the app doesn't support intents and is quite bare bones: the only way I found to turn the beacon on is through UI interaction, which doesn't work if the phone is locked/screen off. If I need to interact with my work device then I might as well just turn on the tethering manually so... It's the only app I found that worked at all as a BTLE transmitter too.

I didn't find another way to have two devices to communicated without both being somewhat connected to the internet, and obviously that's kind of the issue.

I thinking of setting up some kind of dead man's switch, passing a variable from one device to the other on a set timer. My issue is that this forces me to initiate the check from my personal phone and I'm trying to avoid this (unless I'm missing something of course). Furthermore, I fear battery life will be affected on both phones if I have too high a frequency, while the whole thing becoming useless if too low. I thought of going through IFTTT but I can't quite figure out how to trigger a recipe when something stops, as opposed to starts.

So yeah, that's where I'm at. It's such a small thing, yet so complicated! I really don't need this, just kinda want it to work... I'm so deep into this I'm starting to look at setting up something with webhooks and uptimerobot but talk about freaking overkill lol

Anyway, long one, but if any of you fine folks think of something I'm all ears!!
Thanks
 

Endercraft

Moderator (& bug finder :D)
Hi again everyone.

I've tried many ways around a specific automation I'm trying to make work, but have hit nothing but dead ends. Maybe someone will think of something else...

Situation: I have two devices, one of which is a work issued managed phone. I only use it for work, and it doesn't have a SIM card - it only connects through Wifi. I do need to take it with me once in a while, and I'm trying to set a macro up that would essentially "tell" my other phone to turn its hotspot on. I have MD on both phones, but the work phone is severely limited (can't sideload, no ADB, etc). The issue of course is, how can I "tell" my personal phone anything if it loses connection?! I am trying to avoid triggering the scenario from my personal phone as I don't always carry both and I don't want the hotspot to turn on without reason.

I tried to use a Bluetooth LE beacon, and it's the closest I got to success; I downloaded a small BTLE beacon simulator app on the work phone, and a macro on my personal phone that would turn on tethering when it detected the beacon. Works like a charm, except that the app doesn't support intents and is quite bare bones: the only way I found to turn the beacon on is through UI interaction, which doesn't work if the phone is locked/screen off. If I need to interact with my work device then I might as well just turn on the tethering manually so... It's the only app I found that worked at all as a BTLE transmitter too.

I didn't find another way to have two devices to communicated without both being somewhat connected to the internet, and obviously that's kind of the issue.

I thinking of setting up some kind of dead man's switch, passing a variable from one device to the other on a set timer. My issue is that this forces me to initiate the check from my personal phone and I'm trying to avoid this (unless I'm missing something of course). Furthermore, I fear battery life will be affected on both phones if I have too high a frequency, while the whole thing becoming useless if too low. I thought of going through IFTTT but I can't quite figure out how to trigger a recipe when something stops, as opposed to starts.

So yeah, that's where I'm at. It's such a small thing, yet so complicated! I really don't need this, just kinda want it to work... I'm so deep into this I'm starting to look at setting up something with webhooks and uptimerobot but talk about freaking overkill lol

Anyway, long one, but if any of you fine folks think of something I'm all ears!!
Thanks
Maybe you can use the Bluetooth beacon trigger and activate hot-spot action ?
 

MrDenis

New member
Maybe you can use the Bluetooth beacon trigger and activate hot-spot action ?
Like I said I tried, and it works great on the receiving end, but the only way I found to trigger the beacon on the sending side is through UI interaction, which doesn't work if the screen is off. If I found an app that can get intents or a MD internal process to do it, it would solve my issued for sure.

I'm trying to fully automate the process to avoid forgetting to do it; if I need to manually activate the beacon anyway, I might as well just turn on the hotspot manually on my other phone...
 

Endercraft

Moderator (& bug finder :D)
Hi again everyone.

I've tried many ways around a specific automation I'm trying to make work, but have hit nothing but dead ends. Maybe someone will think of something else...

Situation: I have two devices, one of which is a work issued managed phone. I only use it for work, and it doesn't have a SIM card - it only connects through Wifi. I do need to take it with me once in a while, and I'm trying to set a macro up that would essentially "tell" my other phone to turn its hotspot on. I have MD on both phones, but the work phone is severely limited (can't sideload, no ADB, etc). The issue of course is, how can I "tell" my personal phone anything if it loses connection?! I am trying to avoid triggering the scenario from my personal phone as I don't always carry both and I don't want the hotspot to turn on without reason.

I tried to use a Bluetooth LE beacon, and it's the closest I got to success; I downloaded a small BTLE beacon simulator app on the work phone, and a macro on my personal phone that would turn on tethering when it detected the beacon. Works like a charm, except that the app doesn't support intents and is quite bare bones: the only way I found to turn the beacon on is through UI interaction, which doesn't work if the phone is locked/screen off. If I need to interact with my work device then I might as well just turn on the tethering manually so... It's the only app I found that worked at all as a BTLE transmitter too.

I didn't find another way to have two devices to communicated without both being somewhat connected to the internet, and obviously that's kind of the issue.

I thinking of setting up some kind of dead man's switch, passing a variable from one device to the other on a set timer. My issue is that this forces me to initiate the check from my personal phone and I'm trying to avoid this (unless I'm missing something of course). Furthermore, I fear battery life will be affected on both phones if I have too high a frequency, while the whole thing becoming useless if too low. I thought of going through IFTTT but I can't quite figure out how to trigger a recipe when something stops, as opposed to starts.

So yeah, that's where I'm at. It's such a small thing, yet so complicated! I really don't need this, just kinda want it to work... I'm so deep into this I'm starting to look at setting up something with webhooks and uptimerobot but talk about freaking overkill lol

Anyway, long one, but if any of you fine folks think of something I'm all ears!!
Thanks
Now that I have 2 phones, I have approximately the same problem 😅
The beacon is not a problem, it will be enabled using UI interaction when the phone boots by itself. The problem is how do I tell my other phone that has the beacon on to connect to my hot-spot ? By default it will try to connect to it but we are never sure, especially because I usually parameter my hot-spot to only allow 1 device to connect so I can connect with my tablet. I might just activate another beacon on my hot-spot phone using UI interaction then receive it on my other phone.
 

Dm114

Well-known member
Now that I have 2 phones, I have approximately the same problem 😅
The beacon is not a problem, it will be enabled using UI interaction when the phone boots by itself. The problem is how do I tell my other phone that has the beacon on to connect to my hot-spot ? By default it will try to connect to it but we are never sure, especially because I usually parameter my hot-spot to only allow 1 device to connect so I can connect with my tablet. I might just activate another beacon on my hot-spot phone using UI interaction then receive it on my other phone.
 

Jacob L

Moderator (Lawsonator)
There's an action called connect to network, which you can add to the phone that needs to connect to hotspot.
 

Endercraft

Moderator (& bug finder :D)
There's an action called connect to network, which you can add to the phone that needs to connect to hotspot.
I know that, I'm using it but the thing is that I can't really tell my other phone to connect without using something like a beacon. But like I said I aldready have a solution, I just wanted to mention it. But thanks for the suggestion anyway.
 

Dm114

Well-known member
I know that, I'm using it but the thing is that I can't really tell my other phone to connect without using something like a beacon. But like I said I aldready have a solution, I just wanted to mention it. But thanks for the suggestion anyway.
It would be fair to share your solution to help other users...
 

MrDenis

New member
Now that I have 2 phones, I have approximately the same problem 😅
The beacon is not a problem, it will be enabled using UI interaction when the phone boots by itself. The problem is how do I tell my other phone that has the beacon on to connect to my hot-spot ? By default it will try to connect to it but we are never sure, especially because I usually parameter my hot-spot to only allow 1 device to connect so I can connect with my tablet. I might just activate another beacon on my hot-spot phone using UI interaction then receive it on my other phone.
How do you get UI interaction to work if the screen is off? Or when the phone boots for that matter? My Pixel 6 won't even get messages after rebooting until I unlock it once at least, let alone MD doing anything...
 

Endercraft

Moderator (& bug finder :D)
How do you get UI interaction to work if the screen is off? Or when the phone boots for that matter? My Pixel 6 won't even get messages after rebooting until I unlock it once at least, let alone MD doing anything...
The beacon will stay enabled as long as Bluetooth is on.
 

MrDenis

New member
The beacon will stay enabled as long as Bluetooth is on.
Ok yes but do you keep it on all the time? Even when you don't need to tether?

The way I was trying to get it going was turn on the beacon only when it didn't have connectivity, this telling my main phone to turn on the hotspot when it detects the beacon. If it's on all the time, my main would just constantly try to have the hotspot on... I'm just curious how you're going about it.
 

Endercraft

Moderator (& bug finder :D)
Ok yes but do you keep it on all the time? Even when you don't need to tether?

The way I was trying to get it going was turn on the beacon only when it didn't have connectivity, this telling my main phone to turn on the hotspot when it detects the beacon. If it's on all the time, my main would just constantly try to have the hotspot on... I'm just curious how you're going about it.
That's why if you look in the macro there are constraints to not activate it. Actually, I think I can improve it even more.
 

MrDenis

New member
That's why if you look in the macro there are constraints to not activate it. Actually, I think I can improve it even more.
Yeah I see how you maybe get around it but I don't know if I want to have the beacon all the time... Seems like a security/privacy risk to me.

But yes it could work that way I guess. I managed to get it going using IFTTT though and it seems decently efficient, even if using a 3rd party service.
 
Top