// send sync byte to COM port with 9th bit = 1
void SendSyncByte (unsigned char sync)
{
	while (! (_inp(PORT+5) & 32))
	{}					// wait till port ready
	_outp(PORT+3, (32+8+2+1));		// 8 bit, 1 stop, parity always 1
	_outp(PORT+0, sync);
}
// send data byte to COM port with 9th bit = 0
void SendDataByte (unsigned char data)
{
	while (! (_inp(PORT+5) & 32))
	{}					// wait till port ready
	_outp(PORT+3, (32+16+8+2+1));		// 8 bit, 1 stop, parity always 0
	_outp(PORT+0, data);
}