An attempt to convert Apples SerialPortSample project over to Swift