elixir-circuits / circuits_uart

Discover and use UARTs and serial ports in Elixir
Apache License 2.0
189 stars 48 forks source link

Passive mode configuration is not honored on open when port is not available #31

Closed akohring closed 6 years ago

akohring commented 6 years ago

When a UART.open request is made for a port that is not yet available, the uart_open and uart_process functions return before the active mode configuration is applied. This behavior causes a {:nerves_uart, _port, {:error, :ebadf} error message to be sent back to the calling process, which is only expected when active mode is configured.

sourcelevel-bot[bot] commented 6 years ago

Hello, @akohring! This is your first Pull Request that will be reviewed by Ebert, an automatic Code Review service. It will leave comments on this diff with potential issues and style violations found in the code as you push new commits. You can also see all the issues found on this Pull Request on its review page. Please check our documentation for more information.

akohring commented 6 years ago

Great feedback, thanks for reviewing so quickly! I have updated the PR based on your comments. Please let me know if anything else is needed.

fhunleth commented 6 years ago

Merged! Thanks!