googlearchive / platinum-bluetooth

A set of Polymer elements to discover and communicate with nearby Bluetooth devices
https://elements.polymer-project.org/elements/platinum-bluetooth
Apache License 2.0
22 stars 13 forks source link

Add a new <platinum-bluetooth-service> element #6

Closed beaufortfrancois closed 8 years ago

beaufortfrancois commented 9 years ago

Something like this below would help readibility.

<platinum-bluetooth-device services-filter='["f000ffc0-0451-4000-b000-000000000000"]' id="plane-device">
  <platinum-bluetooth-service service="75b64e51-f181-4ed1-921a-476090d80ba7">
    <platinum-bluetooth-characteristic id="engineCharacteristic"
      characteristic="75b64e51-f184-4ed1-921a-476090d80ba7"
      auto-write>
    </platinum-bluetooth-characteristic>
    <platinum-bluetooth-characteristic id="rudderCharacteristic"
      characteristic="75b64e51-f185-4ed1-921a-476090d80ba7"
      auto-write>
    </platinum-bluetooth-characteristic>
  </platinum-bluetooth-service>
</platinum-bluetooth-device>
ketile commented 8 years ago

This is helpful in my opinion. Currently working on a project with many characteristics belonging to the same service and this is easier to both read and write.

beaufortfrancois commented 8 years ago

I will add this new element for sure in the next version.

beaufortfrancois commented 8 years ago

For info, I've started coding next version at https://github.com/PolymerElements/platinum-bluetooth/compare/v2?expand=1

beaufortfrancois commented 8 years ago

Fixed with https://github.com/PolymerElements/platinum-bluetooth/commit/966dd981bb4b765c621dbfc85fde1a0db83f1913

beaufortfrancois commented 8 years ago

@ketile You can give it a try now by checking out WIP https://github.com/PolymerElements/platinum-bluetooth/pull/15

ketile commented 8 years ago

@beaufortfrancois Great!