Contact emails

mattreyno...@google.com

Explainer

https://github.com/WICG/serial/blob/main/EXPLAINER_BLUETOOTH.md

Specification

https://wicg.github.io/serial/#serialport-interface

Summary

This feature adds a boolean SerialPort.connected attribute. The attribute
is true if the serial port is logically connected. For wired serial ports,
a port is logically connected if the port is physically attached to the
system. For wireless serial ports, a port is logically connected if the
device hosting the port has any open connections to the host.

Previously, only wired serial ports dispatched connect and disconnect
events. With this feature, Bluetooth RFCOMM serial ports will dispatch
these events when the port becomes logically connected or disconnected.

This feature is intended to allow applications to detect when a Bluetooth
RFCOMM serial port is available without opening the port.


Blink component

Blink>Serial
<https://bugs.chromium.org/p/chromium/issues/list?q=component:Blink%3ESerial>

Motivation

A wireless serial port opened by an application is closed when the wireless
device moves out of range of the host. In this scenario, the application
that opened the wireless serial port may attempt to re-open it. However, if
the wireless device was disconnected intentionally (for instance, if the
user disconnected the device from the system control panel) then the
application should avoid re-opening the port in order to prevent
reconnecting to the device.

Exposing the logical connection state of the device hosting the wireless
serial port enables applications to distinguish these cases and avoid
reconnecting when the device was disconnected intentionally.


Initial public proposal

https://github.com/WICG/serial/pull/197

Search tags

serial <https://chromestatus.com/features#tags:serial>, rfcomm
<https://chromestatus.com/features#tags:rfcomm>, bluetooth
<https://chromestatus.com/features#tags:bluetooth>, connect
<https://chromestatus.com/features#tags:connect>

TAG review

No TAG review is planned for this minor API change. Bluetooth RFCOMM
support was previously reviewed:
https://github.com/w3ctag/design-reviews/issues/854

Risks

Interoperability and Compatibility

Web Serial has not yet been adopted by other browser engines which makes
this incremental change a low interoperability risk.


Gecko: Neutral (https://mozilla.github.io/standards-positions/#webserial)
Deferring to the Web Serial (Add-On Gated) position. Mozilla has not
commented on this specific feature.

WebKit: Negative (https://webkit.org/tracking-prevention) Apple is opposed
to Web Serial API, we assume they also oppose any extensions to the API.

Web developers: Positive (requested by an internal partner)

Other signals:

WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that
it has potentially high risk for Android WebView-based applications?

Web Serial API is not implemented for Android WebView.


Debuggability

None


Is this feature fully tested by web-platform-tests
<https://chromium.googlesource.com/chromium/src/+/main/docs/testing/web_platform_tests.md>
?

No. Web Serial tests that were previously in web-platform-tests have been
temporarily moved to Chrome's wpt_internal. We plan to upstream them again
after specifying a test API.

Flag name on chrome://flags

None

Finch feature name

EnableBluetoothSerialPortProfileInSerialApi

Requires code in //chrome?

False

Tracking bug

https://crbug.com/1488031

Launch bug

https://launch.corp.google.com/4297948

Estimated milestones

No milestones specified


Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5118102654418944

This intent message was generated by Chrome Platform Status
<https://chromestatus.com/>.

-- 
You received this message because you are subscribed to the Google Groups 
"blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to blink-dev+unsubscr...@chromium.org.
To view this discussion on the web visit 
https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAHB%2BDAiJmnJTvQdiMezidfK4vu7r6_nLxyYfjg1n%2B8%2BAcEEyZQ%40mail.gmail.com.

Reply via email to