Try it. It works quite well. It’s not that the driver hangs, it is that the 
driver won’t accept serial input until the DTR requirement is satisfied. So, 
you simply set the handshake characteristics for the port, and the driver will 
immediately start accepting data.

Think back on what the requirements were - when the DTR state changed, the port 
would grab the Getty’s attention, establishing a new user session. This was 
back in the days of very minimal hardware capabilities. In fact many of the 
systems did not have hardware UARTs. The driver was active even if not opened 
so that it could do its task. These days the drivers for cu and tty are the 
same, and are not actually opened until the application opens them. I haven’t 
seen a system with serial TTYs active for years - we do that using networking 
these days.

Again, it really doesn’t matter which port of the pair you call out in the 
application, just set it up properly and use it. That means setting it up 
completely, including blocking characteristics and handshaking. And, if you 
want it to work well, use GCD blocks to handle the reads so that you spend 
minimal time in the handler code. That definitely gives cool to the system.


> On Jun 8, 2015, at 6:17 PM, Carl Hoefs <[email protected]> wrote:
> 
> 
>> On Jun 8, 2015, at 6:13 PM, Jack Brindle <[email protected] 
>> <mailto:[email protected]>> wrote:
>> 
>> You set the port environment immediately after you open it
> 
> A tty device hangs on open until DTR is asserted, so how can you open it to 
> change it if it blocks?
> -Carl
> 

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Usb mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/usb/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to