After doing lots of testing, I've come up with some interesting observations.
When OS X goes to sleep, either from an idle timeout or a forced sleep 
(selecting 'Sleep' from the Apple menu), *some* USB to Serial adapters can end 
up in an unresponsive state after OS X wakes up. I've tested this with the 
three most common adapters, Keyspan, FTDI and Prolific. The Prolific adapters 
seem to tolerate a sleep cycle just fine without any untoward side effects. But 
the Keyspan and FTDI adapters get very grumpy when they wake up after being put 
to sleep. In the case of the Keyspan, all open connections are closed when it 
goes to sleep. Upon awakening, the Keyspan port remains closed until the app 
re-opens it. But.. I found that if an app is actively polling the serial port 
at the time it is put to sleep, for example while W2.exe is running and polling 
the port very rapidly, the adapter can wake up in an unresponsive, or 
unreliable state. The Keyspan adapter must be unplugged and replugged to 
recover. This happens every time with the
 Keyspan adapter IF it is being actively polled at the time it goes to sleep. 
If it is not being polled at the time the OS goes to sleep, for example while 
the W2 Utility is connected but idle, the Keyspan will wake up healthy and 
responsive. It's not necessary to unplug and replug to get it back, but the 
port still remains closed until it is re-opened by the app. In the case of the 
FTDI adapter, the port is not closed when it goes to sleep. If it is not being 
actively polled at the time it goes to sleep, then it wakes up healthy and all 
is well. But if it IS being polled when it goes to sleep, for example by 
W2.exe, then it wakes up totally messed up and must be unplugged and replugged 
to regain consciousness. 
Thanks, Dale, for pointing this out. I'm surprised this hasn't come up before. 
I've been writing serial port apps for the Mac for many years. This is the 
first time I've had someone point out this problem when an app is running when 
the Mac goes to sleep.
I will be adding code to all my apps to close the serial port whenever the 
computer is going to sleep and to reopen the port upon awakening. In the mean 
time, users of the Keyspan and FTDI USB/Serial adapters should close all apps 
that use the serial port before putting the Mac to sleep (W2.exe, W2 Utility, 
K3 Utility, and P3 Utility) .
David, W4SMT

--- On Fri, 9/3/10, dalej <[email protected]> wrote:













 
 



  


    
      
      
      Hello again David,
To follow up.  I also get a spinning beach ball sometimes, which I just did now 
after waking it up.  I then have to force quit the W2 app and restart it after 
unplugging and replugging the USA19 adapter.  
73Dale, k9vuj

__,_._,___


 



  








______________________________________________________________
Elecraft mailing list
Home: http://mailman.qth.net/mailman/listinfo/elecraft
Help: http://mailman.qth.net/mmfaq.htm
Post: mailto:[email protected]

This list hosted by: http://www.qsl.net
Please help support this email list: http://www.qsl.net/donate.html

Reply via email to