Skip to content
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

fix(serial): only delay on redirect thread with low baud rate (RDT-629) #250

Closed
wants to merge 1 commit into from

Conversation

quangthanh010290
Copy link

No description provided.

@hfudev
Copy link
Member

hfudev commented Dec 27, 2023

Hi @thanhlev, thank you for your PR! Could you provide more detail on the motivation behind this change?

The original reason for setting the read interval to 0.05 seconds was to prevent the read thread defined here from being executed too frequently. If this thread is executed too often, it may not have enough time to execute functions on your custom threads, if you're using multi-threading in you test scripts.

@github-actions github-actions bot changed the title fix(serial): only delay on redirect thread with low baud rate fix(serial): only delay on redirect thread with low baud rate (RDT-629) Dec 27, 2023
@quangthanh010290
Copy link
Author

Hi @thanhlev, thank you for your PR! Could you provide more detail on the motivation behind this change?

The original reason for setting the read interval to 0.05 seconds was to prevent the read thread defined here from being executed too frequently. If this thread is executed too often, it may not have enough time to execute functions on your custom threads, if you're using multi-threading in you test scripts.

Hi @hfudev , Thanks for your reply.
I ran into an issue with baud rate 3M (missed data and NULL character on received data unexpectedly ), with baud 200K - got NULL character on received data unexpectedly.

The change will only target high baud rate testing

@hfudev
Copy link
Member

hfudev commented Dec 28, 2023

@thanhlev Could you help post the error message here and provide a minimal reproducible code snippet? Let's see if there's another way to fix it.

The current fix by your PR would cause problems when used together with multiple threads.

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

Successfully merging this pull request may close these issues.

2 participants