Support for more compilers (it only works for sure under Borland C++ 3.1) (work for Microsoft Visual C++ is in progress) //A bug in the sendByte function was discovered so that more than one byte of //data couldn't be sent at the same time without a possibility of data loss. //This was pointed out to me by Elias Gil. *** fixed on 16 August 1998 by Keith Welker (with the help of Elias Gil In general, convert all(all possible any ways) functions so they are passed the port string "COM?" instead of a UART *. Implement the code necessary to open more than 1 port at a time. The global UART will then be an array. Use a #define to determine the number of possible ports open at one time. The "COM?" string will be used to determine which port is to be used. (Don't forget about the interrupt service routine). Implement an autobaud detect. It should use a string to pass to the port that will cause return of some data. Detect for buffer overrun and then exit. Say that the setting can be changed in the header file 'rs232.h'. decrease the minimum allowed baud rate of 600. detectPortIrq not implemented yet. It might be based on what the current interrupt vector is. If it is the standard bios vector, it is probably free. Need to be able to detect if the com port is in use. This will make this code gracefully work under windows Nt. It will work now as long as you don't try to use a port that is already in use. Implement a EXIT_ON_FAILURE #define system in case you prefer to handle errors gracefully without exiting. //Fix getPortAddress so it returns a value instead of a pointer. // This way we don't need to declare static memory in the function. ** fixed on 25 May 1998 Keith Welker Turn the global UART structures into pointers. We can then allocate the memory in openPort and free it in closePort. This will be useful for opening and closing multiple ports. Use getBiosPortAddress instead of getPortAddress throughout the code. Make a C++ wrap for this code!!