作業メモ:Edison + IoT Analytics で Device not found in IoT cloudと出た
背景
23: Intel Edison実践編 (3) 〜 XDKで開発したプログラムからiotkit-agentにデータを送る | Developers.IO を読んで、Edison + IoT Analyticsを試す
↓
(・∀・)イイネ!!
↓
別の場所に移動してセンシング
↓
プロットされない・・orz
↓
Edisonでこんなエラーが・・
# systemctl status iotkit-agent -l ~(略)~ May 27 06:40:22 edison1 iotkit-agent[475]: 2015-05-27T06:40:22.106Z - error: Data Submission Error {"code":1404,"message":"Device not found i n IoT cloud. Try initializing and activating the device once again."} May 27 06:40:22 dev-tnaototo iotkit-agent[475]: 2015-05-27T06:40:22.108Z - info: Response received: {"code":1404,"message":"Device not found in Io T cloud. Try initializing and activating the device once again."} May 27 06:40:22 edison1 iotkit-agent[475]: 2015-05-27T06:40:22.191Z - error: Data Submission Error {"code":1404,"message":"Device not found i n IoT cloud. Try initializing and activating the device once again."} May 27 06:40:22 edison1 iotkit-agent[475]: 2015-05-27T06:40:22.193Z - info: Response received: {"code":1404,"message":"Device not found in Io T cloud. Try initializing and activating the device once again."}
↓
Activateし直してもダメ
↓
iotkit-admin initialize
やればいいの? ← イマココ
Getting Started Guide を参考にInitialize
cf. Intel® Internet of Things (IoT) Developer Kit IoT Cloud-Based Analytics User Guide (PDF)
# iotkit-admin initialize 2015-05-27T07:36:11.813Z - info: Token file: /usr/share/iotkit-agent/certs/token.json 2015-05-27T07:36:11.847Z - info: Using data store: /usr/share/iotkit-agent/data/ 2015-05-27T07:36:11.852Z - info: Initialized
# iotkit-admin activate <<device_activation_code>> 2015-05-27T07:36:37.771Z- info: Activating... 2015-05-27T07:36:39.589Z- info: Saving device token... 2015-05-27T07:36:39.602Z- info: Updating metadata... 2015-05-27T07:36:39.611Z- info: Metadata updated.
# systemctl restart iotkit-agent # systemctl status iotkit-agent -l ~(略)~ May 27 07:39:32 edison1 systemd[1]: Starting iotkit-agent... May 27 07:39:32 edison1 systemd[1]: Started iotkit-agent. May 27 07:39:35 edison1 iotkit-agent[520]: 2015-05-27T07:39:35.406Z - info: Device has already been activated. Updating ... May 27 07:39:35 edison1 iotkit-agent[520]: 2015-05-27T07:39:35.436Z - info: Updating metadata... May 27 07:39:35 edison1 iotkit-agent[520]: 2015-05-27T07:39:35.477Z - info: Metadata updated. May 27 07:39:37 edison1 iotkit-agent[520]: 2015-05-27T07:39:37.169Z - info: Starting listeners... May 27 07:39:37 edison1 iotkit-agent[520]: 2015-05-27T07:39:37.318Z - info: MQTT listener started on port: 1884 May 27 07:39:37 edison1 iotkit-agent[520]: 2015-05-27T07:39:37.322Z - info: TCP listener started on port: 7070 May 27 07:39:37 edison1 iotkit-agent[520]: 2015-05-27T07:39:37.329Z - info: UDP listener started on port: 41234
コンポーネント再登録
# iotkit-admin register temp temperature.v1.0 2015-05-27T07:55:40.115Z - info: Starting registration ... 2015-05-27T07:55:40.227Z - info: Device has already been activated. Updating ... 2015-05-27T07:55:40.235Z - info: Updating metadata... 2015-05-27T07:55:40.274Z - info: Metadata updated. Attributes sent # iotkit-admin register light light.v1.0 2015-05-27T07:55:40.115Z - info: Starting registration ... 2015-05-27T07:55:40.227Z - info: Device has already been activated. Updating ... 2015-05-27T07:55:40.235Z - info: Updating metadata... 2015-05-27T07:55:40.274Z - info: Metadata updated. Attributes sent
↓
プロットされるようになった(´∀`)
その他
IoT Analytics Dashboardにデバイスが一つ増えたけど、これ何だろう・・(-_-;)