Skip to content
This repository has been archived by the owner on Dec 29, 2022. It is now read-only.

Master #198

Open
wants to merge 58 commits into
base: updates
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
62dab7b
add link to TI-CC2640
dermike Oct 18, 2015
7d574ae
add folders for external implementations for navigation usability
dermike Oct 18, 2015
f6fae26
Merge remote-tracking branch 'upstream/master' into imp-fixes
dermike Mar 13, 2016
8dc7cf6
fix order to match dir listing
dermike Mar 13, 2016
3ba7201
Update MainActivity.java
Pedrotok May 8, 2016
c25da58
Merge pull request #146 from Pedrotok/patch-1
mashbridge May 9, 2016
02e5db1
Update README.md
mashbridge May 17, 2016
51688b9
Add a python script for scanning for beacons on linux.
Oct 27, 2015
20d0e3b
Merge pull request #101 from tommythorsen/linux-url-scanner
scottjenson May 31, 2016
31ad53b
Fix input/output error
PrabhanshuAttri Jun 1, 2016
7a26217
Merged 2 commands
PrabhanshuAttri Jun 3, 2016
994b6c6
Merge pull request #152 from nirmankarta/master
scottjenson Jun 12, 2016
13ca2be
Replaced optparse(deprecated) to argparse
PrabhanshuAttri Jun 19, 2016
527c232
Update README.md
mashbridge Jun 21, 2016
a5b723e
Merge pull request #156 from nirmankarta/master
scottjenson Jun 22, 2016
a6126f3
Fix link to Linux (bluez)
scottjenson Jun 22, 2016
5299eeb
Merge remote-tracking branch 'upstream/master' into imp-fixes
dermike Jun 22, 2016
57ff58f
fix order to match dir listing
dermike Jun 22, 2016
9aa4fa5
Merge pull request #96 from dermike/imp-fixes
scottjenson Jun 22, 2016
b9c9968
Merge pull request #2 from google/master
PrabhanshuAttri Jun 22, 2016
4aa1f20
Added Python2.x check for compatibility.
PrabhanshuAttri Jun 22, 2016
30d6104
Added PyBeacon, a python package
PrabhanshuAttri Jun 22, 2016
6bfdb8b
Merge pull request #158 from nirmankarta/master
scottjenson Jun 22, 2016
7337ad7
Update README.md
mashbridge Jun 30, 2016
d522df8
Update README.md
mashbridge Jul 4, 2016
0240e6b
Update README.md
mashbridge Jul 28, 2016
6141b74
Add connectable timeout recommendation
beaufortfrancois Jul 28, 2016
59b7ff0
Merge pull request #163 from beaufortfrancois/patch-1
mashbridge Jul 28, 2016
b130bd9
Disable screen rotation (it leaks advertisers)
jfarfel Aug 11, 2016
099430b
Merge pull request #167 from jfarfel/patch-1
mashbridge Aug 11, 2016
4a58358
Update README.md
mashbridge Aug 15, 2016
e0bd7fb
Added correction stating that EID related keys used in association wi…
roywant Aug 18, 2016
869b5d1
Merge pull request #1 from roywant/roywant-patch-1
roywant Aug 20, 2016
d1034b1
Merge pull request #172 from roywant/master
mashbridge Aug 22, 2016
9479e78
Update README.md
mashbridge Aug 22, 2016
cbc9fd5
Edited Broadcast Capabilities to Capabilities; consistent with the ne…
roywant Aug 29, 2016
0fbbedd
Merge pull request #175 from roywant/master
mashbridge Aug 30, 2016
1771665
For always-connectable beacons, add a similar note about LED flash or…
cbrunschen Sep 5, 2016
0d3b4b2
Merge pull request #176 from google/cbrunschen-led-flash-1
mashbridge Sep 5, 2016
576ea7d
Set up directories for intern GATT apps
mashbridge Sep 23, 2016
8a2e5c2
First version of the app implemented. The app can scan for beacons, d…
galinapeycheva Sep 23, 2016
f03e478
Final checkin of the GATT Configuration iOS Sample
Sep 23, 2016
0ca0bb3
Merge pull request #181 from google/summer_over
denisasandu Sep 23, 2016
3233111
Merge branch 'master' of https://github.com/google/eddystone
galinapeycheva Sep 23, 2016
197a3b6
Added the BBC micro:bit implementation of a physical web beacon
Sep 26, 2016
3415954
Merge pull request #182 from showio/master
scottjenson Sep 27, 2016
a79c66b
add BBC micro:bit link to implementations directory list
dermike Sep 28, 2016
97225a9
Merge pull request #183 from dermike/microbit-imp-list
scottjenson Sep 28, 2016
b12ec91
Convert all UUIDs to lower case
bashtian Jan 2, 2017
4582b6d
Merge pull request #196 from bashtian/patch-1
mashbridge Jan 3, 2017
bd52c3e
Adding beacon implementations directory with mbed subdirectory
roywant Feb 6, 2017
5eeb8af
Merge pull request #205 from roywant/master
mashbridge Feb 7, 2017
75a08fe
Small edits
scottjenson Feb 7, 2017
3b7fc7c
fix home->hope typo
scottjenson Feb 7, 2017
365b8ac
add http:// to Physical Web link
scottjenson Feb 9, 2017
93bff7a
adding ignore files
roywant Apr 6, 2017
1ed9721
Update swift scanner sample to Swift v4.0
themz Jan 8, 2018
bb8738d
Merge pull request #237 from themz/scanner-sample-swift-v4.0
marcwan Jan 8, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 16 additions & 15 deletions configuration-service/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Eddystone Configuration GATT Service

**Note: https://github.com/google/eddystone/issues/132 needs resolution before this specification can be considered final.**

This document defines the specification for the Eddystone Configuration Service and offers some implementation guidance.

The Eddystone Configuration Service runs as a GATT service on the beacon while it is connectable and allows configuration of the advertised data, the broadcast power levels, and the advertising intervals. It also forms part of the definition of how Eddystone-EID beacons are configured and registered with a trusted resolver.
Expand All @@ -12,20 +10,23 @@ The primary goal of a standardized configuration service is interoperability bet

There are two ways to accomplish this. Your choice depends on whether your beacons are always connectable, or if they are non-connectable by default and become connectable through some action by the user.

We recommend that your beacons spend the majority of their lives in a non-connectable state, which avoids network congestion and collision issues in a dense wireless environment. In this case, the user will take some action to make a beacon temporarily connectable, perhaps by depressing a button, pulling a battery activation tab, or similar. Once your beacon becomes connectable, we recommend broadcasting the configuration GATT service's UUID as a 128-bit service UUID in the scan response, along with a local name data type that identifies your beacon. Configuration applications may look for both of these signals in the scan records of nearby beacons and use the information to highlight which ones are ready for configuration. (A flash of an LED or an audible beep upon connection from a client are helpful too, if your hardware has the necessary support.)
We recommend that your beacons spend the majority of their lives in a non-connectable state, which avoids network congestion and collision issues in a dense wireless environment. In this case, the user will take some action to make a beacon temporarily connectable, perhaps by depressing a button, pulling a battery activation tab, or similar. The connectable timeout should be at the very least 30 seconds to let enough time to user to start a configuration application. Once your beacon becomes connectable, we recommend broadcasting the configuration GATT service's UUID as a 128-bit service UUID in the scan response, along with a local name data type that identifies your beacon. Configuration applications may look for both of these signals in the scan records of nearby beacons and use the information to highlight which ones are ready for configuration. (A flash of an LED or an audible beep upon connection from a client are helpful too, if your hardware has the necessary support.)

If your beacons must be always connectable, you may wish to minimize the amount of data that's broadcast in a scan response to conserve the battery. In this case we recommend that in an occasional scan response you broadcast a short local name so that configuration clients can display it to the user and aid an easier association between your beacon and any other nearby beacons. The time between scan responses should be tuned to balance the power requirements with the patience of a human trying to find a connectable frame to configure your beacon -- once the hardware device address has been obtained it should be possible to connect to the beacon in a few seconds.
If your beacons must be always connectable, you may wish to minimize the amount of data that's broadcast in a scan response to conserve the battery. In this case we recommend that in an occasional scan response you broadcast a short local name so that configuration clients can display it to the user and aid an easier association between your beacon and any other nearby beacons. The time between scan responses should be tuned to balance the power requirements with the patience of a human trying to find a connectable frame to configure your beacon -- once the hardware device address has been obtained it should be possible to connect to the beacon in a few seconds. (Here too, a flash of an LED or an audible beep upon connection from a client may be helpful, if your hardware has the necessary support, especially if there are multiple connectable beacons in the vicinity.)

In either case, users may find it helpful if your beacons arrive broadcasting one of the following two frames:

* An Eddystone-URL frame type whose URL points to information about using your beacons. We recommend this for ease of recognition by the person who is configuring the device.
* An Eddystone-UID frame type where the namespace part of the UID is fixed to the one you've chosen for your organization and the instance part is randomized. This ensures the beacon is ready to be registered with a service that supports the UID format with no configuration necessary.

### Default unlock code
If a beacon ships in a `0x02` unlocked state, care must be taken to ensure that it has a default unlock code that's known to the owner.

### Single connection only
While a configuration client is connected to the beacon, the beacon must refuse other connections.

### Interleaving multiple advertisement frames.
If variable advertising intervals are supported (see `IS_VARIABLE_ADV_SUPPORTED` in the Broadcast Capabilities characteristic) it will be inevitable that some slots will be scheduled to broadcast at the same time. We recommend that implementers transmit those frames in slot order at the shortest permissible advertising interval (100 ms).
If variable advertising intervals are supported (see `IS_VARIABLE_ADV_SUPPORTED` in the Capabilities characteristic) it will be inevitable that some slots will be scheduled to broadcast at the same time. We recommend that implementers transmit those frames in slot order at the shortest permissible advertising interval (100 ms).

## Specification

Expand All @@ -43,7 +44,7 @@ If variable advertising intervals are supported (see `IS_VARIABLE_ADV_SUPPORTED`
</tr>
<tr>
<td>Notes</td>
<td>Where not explicitly stated, data written and read is defined in terms of big-endian arrays of signed bytes.</td>
<td>Where not explicitly stated, data written and read is defined in terms of big-endian arrays of bytes. However, there are exceptions for EID related keys: the Public ECDH Key in Characteristic 8, the Identity Key in Characteristic 9, and the service's public ECDH key when writing an EID slot in Characteristic 10, all three of which are little-endian. This exception exists because the reference design for eliptic curve-25519, which has been widely adopted, was implemented using little-endian arithmetic and is the basis for the EID design. Note: the elliptic curve-25519 reference design is little-endian, even though big-endian is used almost universally for all other cryptographic protocols</td>
</tr>
</table>

Expand Down Expand Up @@ -377,8 +378,8 @@ Writeable only in locked state.</td>
<tr>
<td>Return Codes</td>
<td>
Read Not Permitted: for any attempt to read or write while the beacon is locked.<br>
Write Not Permitted: for any attempt to write while the beacon is locked.
Read Not Permitted: for any attempt to read while the beacon is unlocked.<br>
Write Not Permitted: for any attempt to write while the beacon is unlocked.
</td>
</tr>
</table>
Expand Down Expand Up @@ -406,7 +407,7 @@ Length: 32 bytes
<tr>
<td>Description</td>
<td>
Reads the beacon's 256-bit public ECDH key.
Reads the beacon's 256-bit public ECDH key (little-endian).
</td>
</tr>
<tr>
Expand Down Expand Up @@ -444,7 +445,7 @@ Length: 16 bytes
<tr>
<td>Description</td>
<td>
Reads the identity key for the active slot. If the slot isn't configured as EID, returns an error.
Reads the identity key (little-endian) for the active slot. If the slot isn't configured as EID, returns an error.
<br><br>
To prevent this data being broadcast in the clear, it shall be AES-128 encrypted with the lock code for the beacon.
</td>
Expand All @@ -469,7 +470,7 @@ Read Not Permitted: for any attempt to read while the beacon is locked.</td>
</tr>
<tr>
<td>Characteristic&nbsp;UUID</td>
<td>a3c8<strong>750A</strong>-8ed3-4bdf-8a39-a01bebede295</td>
<td>a3c8<strong>750a</strong>-8ed3-4bdf-8a39-a01bebede295</td>
</tr>
<tr>
<td>Properties</td>
Expand Down Expand Up @@ -504,7 +505,7 @@ In the case of UID and URL frames, the data to be broadcast is supplied in the a
<br><br>
In the case of a TLM frame, the data is just the frame type byte, <code>0x20</code>. If another slot on the beacon has been configured as an EID frame type, the beacon shall broadcast the ETLM variety of telemetry. Otherwise, the plain TLM frame shall be broadcast. If the beacon is currently broadcasting a plain TLM frame and an EID frame is configured, the beacon shall switch to broadcasting the ETLM variety. If the beacon is configured to broadcast multiple EID frames, then the beacon should cycle through the set identity keys and use them in turn to broadcast an equal number of ETLM frames.
<br><br>
In the case of an EID frame, the length is either 33 or 17. If 33, it's the 32-byte service's public ECDH key and the exponent byte. This is the prefered method of provisioning an EID beacon. If 17, it's the result of encrypting the 16-byte identity key with the beacon's lock code, and the exponent. This is less secure and any provisioner who implements this should make it clear to the user.
In the case of an EID frame, the length is either 34 or 18. If 34, it's the frame type, the 32-byte service's public ECDH key (little-endian) and the exponent byte. This is the prefered method of provisioning an EID beacon. If 18, it's the frame type, the result of encrypting the 16-byte identity key (little-endian) with the beacon's lock code (big-endian), and the exponent. This is less secure and any provisioner who implements this should make it clear to the user.
<br><br>
Writing an empty array, or a single <code>0x00</code> byte clears the slot and stops Tx. If configured as an EID beacon this will also destroy the peripheral's state for this frame data.
</td>
Expand All @@ -531,7 +532,7 @@ Invalid Attribute Length: on any attempt to write with an illegal number of byte
</tr>
<tr>
<td>Characteristic&nbsp;UUID</td>
<td>a3c8<strong>750B</strong>-8ed3-4bdf-8a39-a01bebede295</td>
<td>a3c8<strong>750b</strong>-8ed3-4bdf-8a39-a01bebede295</td>
</tr>
<tr>
<td>Properties</td>
Expand All @@ -546,7 +547,7 @@ If a value of <code>0x0B</code> is written, the beacon shall reset to its factor
<br><br>
Any other value shall be ignored.
<br><br>
In addition, any write shall be ignored if the lock state is not <code>0x01</code>, i.e. locked and automatic lock disabled. The beacon must have been purposefully unlocked by the current client before a factory reset can be performed.
In addition, any write shall be ignored if the lock state is not <code>0x01</code>. The beacon must have been purposefully unlocked by the current client before a factory reset can be performed.
</td>
</tr>
<tr>
Expand All @@ -567,7 +568,7 @@ In addition, any write shall be ignored if the lock state is not <code>0x01</cod
</tr>
<tr>
<td>Characteristic&nbsp;UUID</td>
<td>a3c8<strong>750C</strong>-8ed3-4bdf-8a39-a01bebede295</td>
<td>a3c8<strong>750c</strong>-8ed3-4bdf-8a39-a01bebede295</td>
</tr>
<tr>
<td>Properties</td>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
android:theme="@style/AppTheme">
<activity
android:name=".MainActivity"
android:label="@string/app_name">
android:label="@string/app_name"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ private byte[] buildServiceData() throws IOException {
}

private boolean isValidHex(String s, int len) {
return !(s == null || s.isEmpty()) && (s.length() / 2) == len && s.matches("[0-9A-F]+");
return !(s == null || s.isEmpty()) && s.length() == len*2 && s.matches("[0-9A-F]+");
}

private byte[] toByteArray(String hexString) {
Expand Down
2 changes: 1 addition & 1 deletion eddystone-url/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Byte offset | Field | Description
0 | Frame Type | Value = `0x10`
1 | TX Power | Calibrated Tx power at 0 m
2 | URL Scheme | Encoded Scheme Prefix
3+ | Encoded URL | Length 0-17
3+ | Encoded URL | Length 1-17

### Tx Power Level

Expand Down
3 changes: 3 additions & 0 deletions eddystone-url/implementations/Arduino/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Arduino (BLEPeripheral)

[Arduino (BLEPeripheral)](https://github.com/sandeepmistry/arduino-BLEPeripheral/blob/master/examples/Eddystone/EddystoneURL/EddystoneURL.ino), a list of compatible hardware can be found [here](https://github.com/sandeepmistry/arduino-BLEPeripheral#compatible-hardware).
3 changes: 3 additions & 0 deletions eddystone-url/implementations/BBC-microbit/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# BBC micro:bit

[microbit-physicalweb](https://github.com/showio/microbit-physicalweb)
Loading