Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I often tether my laptop through my iPhone to go online when I'm out and about.

Right now I do this manually by looking at the list of available Bluetooth devices and choosing "connect using access point" from the menu bar.

Is there a way to automate this so that my laptop just connects to the phone automatically if there's no regular WiFi present? If it can't be made fully automatic, I'll happily take a script or something similar that at least makes it easier.

share|improve this question
1  
probably going to want to write a script or AutoHotkey... –  studiohack Jan 16 '12 at 17:33

1 Answer 1

If you are willing to go the scripting route, then your best bet would be to write something in Windows PowerShell. PowerShell features a powerful scripting language, with numerous cmdlets to allow access to nearly every feature of the OS.

Unfortunately, the script would be highly dependent on the drivers of your wireless card, NIC, and bluetooth card, so there isn't a one-size-fits-all solution.

You'd probably need to first query the status of the wireless network (this thread includes a lot of information on this).

Now, this article might be useful to you for controlling your Bluetooth adapter, but you may be forced to interface with the adapter at the driver level since no standard API exists (outside of Winsock).

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.