Skip to content

Serial_::write tries to send with closed host #63

Open
@daniel-starke

Description

@daniel-starke

Serial_::write in CDC.cpp checks if the CDC connection is open by checking if DTR or RTS line state is set. The OS usually sets DTR on open and resets it on close. RTS on the other hand is often left as it is. This means that the check against both leads into the assumption of an valid connection even though there is no peer to read the data, which on the other hand leads into 250 ms delays in USB_Send after the send buffer got saturated. I suggest to check only if DTR is set.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions