Skip to content

uart_close will not be called while SerialPortActivity onDestroy #16

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
GoogleCodeExporter opened this issue Mar 16, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. I add trace message in serial driver in uart_close function
2. while SerialPortActivity onDestroy, uart_close will not be called
3. If remove following code in private class ReadThread extends Thread, 
uart_close will be called

                try {
                    byte[] buffer = new byte[64];
                    if (mInputStream == null) return;
                    size = mInputStream.read(buffer);
                    size =1;
                    if (size > 0) {
                        onDataReceived(buffer, size);
                    }
                } catch (IOException e) {
                    e.printStackTrace();
                    return;
                }

What is the expected output? What do you see instead?


What version of the product are you using? On what operating system?
android-serialport-api version1.1, on Android 2.3, 




Original issue reported on code.google.com by [email protected] on 12 Dec 2011 at 3:10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant