Here's the task:
Locate By GPS (15)
Stay Awake
A1: GPS [ Set:On ]
A2: WiFi [ Set:On ]
A3: Get Location [ Source:Any Timeout (Seconds):100 Continue Task Immediately:Off ]
A4: If [ %LOCNTMS > %LOCTMS ]
A5: Variable Set [ Name:%mylocage To:%TIMES - %LOCNTMS Do Maths:On Append:Off ]
A6: Variable Set [ Name:%myloc To:%LOCN Do Maths:Off Append:Off ]
A7: Variable Set [ Name:%mylocacc To:%LOCNACC Do Maths:Off Append:Off ]
A8: Else
A9: Variable Set [ Name:%mylocage To:%TIMES - %LOCTMS Do Maths:On Append:Off ]
A10: Variable Set [ Name:%myloc To:%LOC Do Maths:Off Append:Off ]
A11: Variable Set [ Name:%mylocacc To:%LOCACC Do Maths:Off Append:Off ]
A12: End If
A13: Variable Set [ Name:%par1 To:<defaultnumber> Do Maths:Off Append:Off ] If [ %par1 ! Set ]
A14: Send SMS [ Number:%par1 Message:As of %mylocage seconds ago my location within %mylocacc meters is http://maps.google.com/maps?q=%myloc Store In Messaging App:Off ]
A15: GPS [ Set:Off ]
A16: WiFi [ Set:Off ]
I use this task in several profiles, one of which uses the Battery Level context.
I also have another set of profiles that execute the same task after a period of inactivity. For these profiles, the inactivity timer gets reset upon screen unlock, change in docked state, change in power state, etc. This way, if the phone is left unattended it will alert me, possibly before I know that it's missing.
You can execute the task with no parameters and it will send to the default number. If a parameter is supplied, it will send to that number instead. Don't forget to change the default number.