Path: utzoo!mnetor!uunet!husc6!hao!oddjob!gargoyle!ihnp4!homxb!mtuxo!mtune!codas!burl!clyde!watmath!softart!riml From: riml@softart.UUCP (Research in Motion Limited) Newsgroups: comp.sys.ibm.pc Subject: Application-level multitasking for DOS Message-ID: <32@softart.UUCP> Date: 23 Dec 87 14:33:05 GMT Organization: Softart Microsystems Inc., Waterloo Ont. Canada Lines: 33 <> During the development of a product for one of our clients, we produced a simple multitasking package that allows an application under MS/PC-DOS (tm Microsoft, IBM) to spawn multiple tasks. There are bi-directional character pipes between tasks. The PC's 18.2 Hz interrupt is used to time-slice the processor. (We also have a routine to speed up the clock if you really need to, and you don't care about compatibility with other software.) This package is in the form of a Lattice (tm) C library of routines. You write your code in C, and then your main program starts up the multitasker. Whenever you wish, you may spawn ANY C function that takes a single integer parameter as a sub-task. Usually, the parameter is used to pass a pipe number to the sub-task. By-the-by, pipe sizes are dynamically allocated, as are the stack sizes for sub-tasks. This package has been in use for some 2 years now with no difficulties. It's not a dead-trivial thing to use, since there are some niceties to observe when multiple tasks are writing or reading from disk, but we've managed to get that going. It just seems that this might be a useful little package for others. Is there any interest out there? Our application, by the way, involves running up to 128 remote devices on a 125K baud network, and responding to 2 4800 baud serial inputs to produce signalling information to the 128 devices. As well, a windowing interface and multiple copies of an on-line message compiler are all capable of operating concurrently on a 4.77 MHz XT! Michael A. Barnstijn, Research In Motion Limited. ...!watmath!softart!riml (519) 888-7465 (E.S.T.)