neal@druhi.ATT.COM (Neal D. McBurnett) (03/22/90)
Does anyone out there have any experience, or know of someone who does, with using tasking and curses at the same time? We have a user task, the "scheduler", which is responsible for communicating with the outside world (including the terminal and a packet message interface). The scheduler then dispatches whichever task is waiting for a particular external event. We will also have a single task which handles input from the keyboard. I assume that what we need to do is find the code in the depths of curses which actually does a blocking read() call, and replace that with a get() on an appropriate queue which is fed by the scheduler. Ideally the scheduler would do a select() call on both the terminal and the network, but it might have to poll the two of them until we get a streams version of the tty driver. Will we have problems with other curses interactions? Is the input code in curses more complicated than a single call to read() (e.g. are there different mechanisms for different modes of input: cooked, raw, etc?). Are there timing issues we should beware of? I hate to re-invent the wheel, so let me know if this has been done before. Thanks! -Neal McBurnett // AT&T Bell Labs, Denver // neal@druhi.att.com, att!druhi!neal