27
26

More than 5 years have passed since last update.

dweet.ioでIoTデータをカジュアルに可視化する

Last updated at Posted at 2015-06-27

IoTデータをカジュアルに可視化する方法です。

1.PNG

dweet.ioって?

dweet.ioはIoTデータ可視化サービスです。
dweet.ioのAPIを叩くことで、IoTデータをガシガシ登録することができ、自動でグラフ表示してくれます。

2.PNG

また、グラフは、freeboard.ioとも連携しているので、ダッシュボードを作成することもできます。

3.PNG

結構おしゃれにもできます。

6.PNG

dweet.ioでできること

Dweeting

  • データ登録のこと
  • https://dweet.io/dweet/for/my-thing-name?hello=world の my-thing-nameを自分の好きなものに変えることで自分のデータを登録することができます。Lock(有料)をかけないとデータは誰でも見ることができ、誰でも対象のURLにデータを登録することができます。
  • JSONのデータも登録できます。
  • レスポンス
{
  "this": "succeeded",
  "by": "dweeting",
  "the": "dweet",
  "with": {
    "thing": "my-thing-name",
    "created": "2014-01-15T17:28:42.556Z",
    "content": {
      "hello": "world",
      "foo": "bar"
    }
  }
}

Getting Dweets

  • データ取得
  • 最新データhttps://dweet.io/get/latest/dweet/for/my-thing-nameと、全過去データhttps://dweet.io/get/dweets/for/my-thing-nameの取得ができます
  • レスポンス
{
  "this": "succeeded",
  "by": "getting",
  "the": "dweets",
  "with": [
    {
      "thing": "my-thing-name",
      "created": "2014-01-15T18:41:17.166Z",
      "content": {
        "this": "is cool!"
      }
    },
    {
      "thing": "my-thing-name",
      "created": "2014-01-15T18:41:01.583Z",
      "content": {
        "hello": "world",
        "foo": "bar"
      }
    }
  ]
}

Note that dweet.io only holds on to the last 500 dweets over a 24 hour period. If the thing hasn't dweeted in the last 24 hours, its history will be removed.

とあるようにデータは削除されていきます。

Real-time Streams

  • データのリアルタイム取得

Alerts(有料)

  • 通知
  • メールアドレスに通知することができます。

Client Libraries

  • Node.js
  • JavaScript
  • Python
  • Ruby

があります。お好きなクライアントからデータを登録できます。
軽く試すぐらいなら、Playからブラウザ経由でデータを登録できます。

dweet.ioのブラウザからできること

Play

  • dweet.ioの各種APIを試せます。

4.PNG

Lock

  • Lockの取得、設定ができます
  • 1Lock/month あたり$0.99です。
  • Lockをかけることで、

Locks allow you to protect and reserve your thing so that only people (and things) with special keys can access it. Once you lock a thing, the name of that thing cannot be used by anyone else.

とあるように、URLを自分専用にでき、データをプライベートにすることができます。

Discover

  • publicになっているIoTデータを見ることができます。
  • このページの一番最初の画像も公開されているURLのものです。

5.PNG

まとめ

自作した電子工作機器のデータを手軽に登録して、可視化したいときなどに使えそうです。
趣味の用途として使う分には便利かと思います。
データを可視化しようとすると、環境作って、ちょめちょめなど結構大変ですが、dweet.io使えばAPI叩けばいいだけなのでお手軽です。
また、Raspberry Piなどを使えば、最初からPythonも入っているのでdweet.ioのPythonクライント使って簡単にデータ登録開始できます。

27
26
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
27
26