| 1 | = Intel Edison で Physical Web のビーコン = |
| 2 | |
| 3 | Intel Edisonを[http://physical-web.org/ Physical Web]のビーコンにする。 |
| 4 | |
| 5 | 必要な物: |
| 6 | * Intel Edison |
| 7 | * [https://github.com/don/node-uri-beacon node-uri-beacon] |
| 8 | |
| 9 | == 事前準備 == |
| 10 | |
| 11 | * [wiki:IntelEdisonStart Edisonを使えるようにしておく。] |
| 12 | * opkgのフィードを設定しておく。 |
| 13 | |
| 14 | {{{ |
| 15 | # opkg install git |
| 16 | # opkg install bluez5-dev |
| 17 | }}} |
| 18 | |
| 19 | == node-uri-beaconをインストール == |
| 20 | |
| 21 | {{{ |
| 22 | # git clone https://github.com/don/node-uri-beacon.git |
| 23 | # cd node-uri-beacon/ |
| 24 | # npm install |
| 25 | }}} |
| 26 | |
| 27 | 途中、blenoのビルドに時間がかかる。 |
| 28 | ここでエラーになることがあるのだけど、うまく行くこともあり、調査中。 |
| 29 | |
| 30 | == 実行 == |
| 31 | |
| 32 | スマートフォンに[https://play.google.com/store/apps/details?id=physical_web.org.physicalweb Physical Webアプリ]をインストールしておく。 |
| 33 | |
| 34 | {{{ |
| 35 | # cd examples |
| 36 | # sudo node simpleBeacon.js |
| 37 | }}} |
| 38 | |
| 39 | Phsical Webアプリを起動すると、ビーコンが見えるはず。 |
| 40 | 広告するURLは、この「`simpleBeacon.js`」の中に書いてある。 |
| 41 | 適当に変更してOK。あまり長いURLはダメらしい。 |
| 42 | |
| 43 | [[Image(1.png, 300px)]] [[Image(2.png, 300px)]] |
| 44 | |
| 45 | ---- |
| 46 | 2014/11/2 |