Serial port fixes for Android.