Changes between Version 14 and Version 15 of azure_iot_hub


Ignore:
Timestamp:
Jun 17, 2019, 11:28:43 PM (3 years ago)
Author:
coas-nagasima
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • azure_iot_hub

    v14 v15  
    33Azure IoT Hub へ接続する[https://github.com/Azure/azure-iot-sdk-c Azure IoT Hub Device C SDK]を使ったサンプルです。
    44ターゲットデバイスは、[http://gadget.renesas.com/ja/product/sakura.html GR-SAKURA]で、Ethernet上のHTTPかMQTTで通信します。
    5 MQTTは、mbedTLS版でのみ接続できます。
    6 [http://gadget.renesas.com/ja/product/peach.html GR-PEACH]でも動作確認できています。[=#gr_peach 下記]を参照してください。
     5MQTTは、mbedTLS版でのみ確認できています。
     6[http://gadget.renesas.com/ja/product/peach.html GR-PEACH]版は[https://dev.toppers.jp/trac_user/contrib/wiki/azure_iot_hub_peach こちら]を参照してください。
    77
    88サンプルを動作させるには、[=#following1 下記]の手順でAzure側にデバイスを追加し、そのデバイスの接続文字列を取得し、ソースコード「app_iothub_client/src/client.c」の以下の個所を書き換える必要があります。
     
    164164送られたメッセージを確認するには、[=#following1 上記]サイトの「[https://docs.microsoft.com/ja-jp/azure/iot-hub/quickstart-send-telemetry-c#read-the-telemetry-from-your-hub ハブから利用統計情報を読み取る]」の手順で行います。
    165165
    166 == GR-PEACH == #gr_peach
    167 
    168 ベースのソフトに[http://dev.toppers.jp/trac_user/contrib/wiki/asp3_tinet_ecnl_rx TOPPERS/ASP3版ECNL]を使用します。注意点として、「get_time」という関数が「c-utility/adapters/agenttime_mbed.c」に定義されていますが、ベースのソフトにも定義されているので、Azure IoT SDK側の「get_time」関数を「azure_get_time」などにリネームして競合を避ける必要があります。
    169 
    170166= 謝辞 =
    171167
    172168日本マイクロソフトの太田様には、Azure IoT Hubの操作や設定、メッセージの確認方法など、詳しく教えて頂きました。ありがとうございました。[[br]]
    173169 日本マイクロソフト株式会社[[br]]
    174  太田 寛[[br]]
    175  [[Image("data:image/svg+xml;base64,PHN2Zy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ZnPg==", 32px, middle, alt="Twitter", title="Twitter", link=https://twitter.com/embedded_george, target="_blank")]]@embedded_george[[br]]
    176  [[Image("data:image/svg+xml;base64,PHN2ZyBhcmlhLWhpZGRlbj0idHJ1ZSIgZm9jdXNhYmxlPSJmYWxzZSIgZGF0YS1wcmVmaXg9ImZhYiIgZGF0YS1pY29uPSJnaXRodWItc3F1YXJlIiByb2xlPSJpbWciIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDQ0OCA1MTIiIGNsYXNzPSJzdmctaW5saW5lLS1mYSBmYS1naXRodWItc3F1YXJlIGZhLXctMTQgZmEtMngiPjxwYXRoIGZpbGw9ImN1cnJlbnRDb2xvciIgZD0iTTQwMCAzMkg0OEMyMS41IDMyIDAgNTMuNSAwIDgwdjM1MmMwIDI2LjUgMjEuNSA0OCA0OCA0OGgzNTJjMjYuNSAwIDQ4LTIxLjUgNDgtNDhWODBjMC0yNi41LTIxLjUtNDgtNDgtNDh6TTI3Ny4zIDQxNS43Yy04LjQgMS41LTExLjUtMy43LTExLjUtOCAwLTUuNC4yLTMzIC4yLTU1LjMgMC0xNS42LTUuMi0yNS41LTExLjMtMzAuNyAzNy00LjEgNzYtOS4yIDc2LTczLjEgMC0xOC4yLTYuNS0yNy4zLTE3LjEtMzkgMS43LTQuMyA3LjQtMjItMS43LTQ1LTEzLjktNC4zLTQ1LjcgMTcuOS00NS43IDE3LjktMTMuMi0zLjctMjcuNS01LjYtNDEuNi01LjYtMTQuMSAwLTI4LjQgMS45LTQxLjYgNS42IDAgMC0zMS44LTIyLjItNDUuNy0xNy45LTkuMSAyMi45LTMuNSA0MC42LTEuNyA0NS0xMC42IDExLjctMTUuNiAyMC44LTE1LjYgMzkgMCA2My42IDM3LjMgNjkgNzQuMyA3My4xLTQuOCA0LjMtOS4xIDExLjctMTAuNiAyMi4zLTkuNSA0LjMtMzMuOCAxMS43LTQ4LjMtMTMuOS05LjEtMTUuOC0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V6bS02LjctNy40Yy0uNC45LTEuNyAxLjEtMi44LjQtMS4zLS42LTEuOS0xLjctMS41LTIuNi40LS42IDEuNS0uOSAyLjgtLjQgMS4zLjcgMS45IDEuOCAxLjUgMi42eiIgY2xhc3M9IiI+PC9wYXRoPjwvc3ZnPg==", 32px, middle, alt="GitHub", title="GitHub", link=https://github.com/ms-iotkithol-jp, target="_blank")]]
     170 太田 寛 [[Image("data:image/svg+xml;base64,PHN2ZyBpZD0iTG9nb19GSVhFRCIgZGF0YS1uYW1lPSJMb2dvIOKAlCBGSVhFRCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNDAwIDQwMCI+PGRlZnM+PHN0eWxlPi5jbHMtMXtmaWxsOm5vbmU7fS5jbHMtMntmaWxsOiMxZGExZjI7fTwvc3R5bGU+PC9kZWZzPjx0aXRsZT5Ud2l0dGVyX0xvZ29fQmx1ZTwvdGl0bGU+PHJlY3QgY2xhc3M9ImNscy0xIiB3aWR0aD0iNDAwIiBoZWlnaHQ9IjQwMCIvPjxwYXRoIGNsYXNzPSJjbHMtMiIgZD0iTTE1My42MiwzMDEuNTljOTQuMzQsMCwxNDUuOTQtNzguMTYsMTQ1Ljk0LTE0NS45NCwwLTIuMjIsMC00LjQzLS4xNS02LjYzQTEwNC4zNiwxMDQuMzYsMCwwLDAsMzI1LDEyMi40N2ExMDIuMzgsMTAyLjM4LDAsMCwxLTI5LjQ2LDguMDcsNTEuNDcsNTEuNDcsMCwwLDAsMjIuNTUtMjguMzcsMTAyLjc5LDEwMi43OSwwLDAsMS0zMi41NywxMi40NSw1MS4zNCw1MS4zNCwwLDAsMC04Ny40MSw0Ni43OEExNDUuNjIsMTQ1LjYyLDAsMCwxLDkyLjQsMTA3LjgxYTUxLjMzLDUxLjMzLDAsMCwwLDE1Ljg4LDY4LjQ3QTUwLjkxLDUwLjkxLDAsMCwxLDg1LDE2OS44NmMwLC4yMSwwLC40MywwLC42NWE1MS4zMSw1MS4zMSwwLDAsMCw0MS4xNSw1MC4yOCw1MS4yMSw1MS4yMSwwLDAsMS0yMy4xNi44OCw1MS4zNSw1MS4zNSwwLDAsMCw0Ny45MiwzNS42MiwxMDIuOTIsMTAyLjkyLDAsMCwxLTYzLjcsMjJBMTA0LjQxLDEwNC40MSwwLDAsMSw3NSwyNzguNTVhMTQ1LjIxLDE0NS4yMSwwLDAsMCw3OC42MiwyMyIvPjwvc3ZnPg==", 32px, middle, alt="Twitter", title="Twitter", link=https://twitter.com/embedded_george, target="_blank")]]@embedded_george [[Image("data:image/svg+xml;base64,PHN2ZyBhcmlhLWhpZGRlbj0idHJ1ZSIgZm9jdXNhYmxlPSJmYWxzZSIgZGF0YS1wcmVmaXg9ImZhYiIgZGF0YS1pY29uPSJnaXRodWItc3F1YXJlIiByb2xlPSJpbWciIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDQ0OCA1MTIiIGNsYXNzPSJzdmctaW5saW5lLS1mYSBmYS1naXRodWItc3F1YXJlIGZhLXctMTQgZmEtMngiPjxwYXRoIGZpbGw9ImN1cnJlbnRDb2xvciIgZD0iTTQwMCAzMkg0OEMyMS41IDMyIDAgNTMuNSAwIDgwdjM1MmMwIDI2LjUgMjEuNSA0OCA0OCA0OGgzNTJjMjYuNSAwIDQ4LTIxLjUgNDgtNDhWODBjMC0yNi41LTIxLjUtNDgtNDgtNDh6TTI3Ny4zIDQxNS43Yy04LjQgMS41LTExLjUtMy43LTExLjUtOCAwLTUuNC4yLTMzIC4yLTU1LjMgMC0xNS42LTUuMi0yNS41LTExLjMtMzAuNyAzNy00LjEgNzYtOS4yIDc2LTczLjEgMC0xOC4yLTYuNS0yNy4zLTE3LjEtMzkgMS43LTQuMyA3LjQtMjItMS43LTQ1LTEzLjktNC4zLTQ1LjcgMTcuOS00NS43IDE3LjktMTMuMi0zLjctMjcuNS01LjYtNDEuNi01LjYtMTQuMSAwLT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XptLTkuMS05LjFjLS45LjYtMi42IDAtMy43LTEuNXMtMS4xLTMuMiAwLTMuOWMxLjEtLjkgMi44LS4yIDMuNyAxLjMgMS4xIDEuNSAxLjEgMy4zIDAgNC4xem0tNi41LTkuN2MtLjkuOS0yLjQuNC0zLjUtLjYtMS4xLTEuMy0xLjMtMi44LS40LTMuNS45LS45IDIuNC0uNCAzLjUuNiAxLjEgMS4zIDEuMyAyLjguNCAzLjV6bS02LjctNy40Yy0uNC45LTEuNyAxLjEtMi44LjQtMS4zLS42LTEuOS0xLjctMS41LTIuNi40LS42IDEuNS0uOSAyLjgtLjQgMS4zLjcgMS45IDEuOCAxLjUgMi42eiIgY2xhc3M9IiI+PC9wYXRoPjwvc3ZnPg==", 32px, middle, alt="GitHub", title="GitHub", link=https://github.com/ms-iotkithol-jp, target="_blank")]]
    177171----
    178172{{{#!div style="text-align: right"