WebPBrick icon indicating copy to clipboard operation
WebPBrick copied to clipboard

Disconnect before trying to connect again after a failed serial connection attempt

Open maehw opened this issue 10 months ago • 0 comments

Describe the bug

Need to disconnect before trying to connect again after a failed serial connection attempt.

To Reproduce

Steps to reproduce the behavior:

  1. Switch RCX off or put out of line of sight from the IR tower.
  2. Press the "Serial Connect" button
  3. See the error message "Connected to serial device (baudrate: 2400). ❌️ No communication with RCX possible. RCX needs to be switched on and placed close to and in line of sight of the IR tower."
  4. Need to press "Serial Disconnect" and then "Serial Connect" again after having switched the RCX on or in line of sight.

Expected behavior

The IDE knows when a connection attempt has failed and could

  1. Close the serial connection.
  2. Re-label the connection button to "Serial Connect" without requiring the user to press the button twice.

Even better would be to leave the serial connection open (the serial device will be the same) and re-attempt the communication ping with the RCX.

Screenshots

grafik

Operating system & webbrowser:

Considered irrelevant.

RCX hardware & firmware:

Considered irrelevant.

Additional context

Only involves changing JavaScript code and no deep insights into how the serial communication between IR tower and RCX works.

maehw avatar Apr 22 '24 09:04 maehw