I am having trouble trying to get this macro to work. I am not sure how to trace the problem down. The reason I would like to stay on my BearTrackHideaway is that a Bonjour sync has issues if I am on the StarLink network. Any suggestions would be greatly appreciated....Thx
A little more info is probably needed for us to help. What is the problem you’re facing? What is not working as expected? What is your desired outcome?
If you can answer those questions, no doubt we can help figure out the issue.
-Chris
Couple of things I've noticed:
-
in your first
If
you use the value of the variableLastWirelessNetwork
but I can't see where you actually set that to anything. -
In the subsequent
If
actions you seem to be setting the network location to BearTrackHideaway regardless of what the current network is. -
Your periodic trigger will never trigger!
Given those points 2 and 3, why don't you set the network location to BearTrackHideaway and reset the periodic trigger to values that'll work?
Like this maybe?
Occasionally my network kicks over to StarLink (or I forget to change back) and this macro does not force me back to BearTrackHideaway which is my preferred network. I have Bonjour set up as a sync location, but it only works if I am on BearTrackHideaway. Only rarely do I use StarLink for resolving issues with the satellite. Desired outcome is to test the network and change back to BearTrackHideaway if it is not connected. These are both only available at home.
This is what I was trying to base this macro off of.
First off - the macro will not trigger every 15 seconds because on any day 12:00AM and 12:00AM are the same time. Try changing it to 12:01AM and 11:59PM.
To check if the macro is actually triggering, put a display text action or a play a sound action at the end.
I have made the changes you suggest. The macro does trigger and report the current network, it does not change the network with the Set Network Location command.
Have you looked in the KM Engine log file to see if any errors have been logged? If there have been, what are they?
Also, please upload your macro so it can be examined without any retyping being needed.
I am looking at the log now. This is what I see when I trigger the macro.
Test Network.kmmacros (8.3 KB)
I think the Set Network Location
Action switches to a preconfigured Network Location such as "Home" or "Work". It does not switch directly to a named Wireless Connection.
You would first need a Network Location configured in System Preferences called "BearTrackHideawayHome" or anything you want, configured as you want.
Then you can use the Set Network Location
Action to switch to that configuration and its settings.
There is also this previous thread which might have a solution for your task: