Skip to content

ClosePort doc / example #24

@PizzaProgram

Description

@PizzaProgram

There is no info about:

  • What is the recommended way to close a port? (1. Stop => 2. Flush => 3. Close? or simply Close is enough and safer?)
  • How to get the "PortID" for that?
  • Does serialFlush() function has auto-timeout, if something goes wrong?

https://github.com/rwaldron/io-plugins#serialcloseportid

Why needed?

  1. If a port is not closed, it happens many times, that new connection can not be established, because the port is "still busy" somehow.

  2. For example at Node-Red both Arduino node and (even the enhaced) Johnny5 implementation seems to lack of that. If people are clicking DEPLOY =>reconnection is nearly impossible without unplugging the Arduino board.

So how to apply these function safely?

PS: I love Johnny5 🥇 , THX for this great work!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions