机场上云问题

Completed

Comments

19 comments

  • Boerma

    A,B服务除了共用一个EMQT服务外,mysql也共用吗?

    0
    Comment actions Permalink
  • chris

    mysql共用试过不共用也试过 都连接失败

    0
    Comment actions Permalink
  • Boerma

    能确定的是链接失败跟你截图的位置没关系。还有就是AB服务不能同时开启,不然将会有两个服务同时响应机场的mqtt消息,因为他们使用的是同一个mqtt服务且监听的主题都一样。

    0
    Comment actions Permalink
  • chris

    服务A单独可以连接上 服务B单独连接不上机场,我需要排查什么问题

    0
    Comment actions Permalink
  • Boerma

    如果不想走重新配置机场步骤,那么服务B必须与服务A共用同一个数据库。因为机场的绑定状态是注册到数据库里了。如果共用数据库依然不能链接,可尝试监控mqtt消息,看看是否有错误码。或者重启机场试试

    0
    Comment actions Permalink
  • chris

    好的 谢谢

    0
    Comment actions Permalink
  • chris

    刚测试了 关闭了A服务 打开B服务 公用的同一个数据库 mqtt消息没有错误码,机场连接还是显示组织ID不正确

    0
    Comment actions Permalink
  • chris

    mqtt都是正常的一些消息推送

    0
    Comment actions Permalink
  • chris

    EMQT机场连上又马上断开

    0
    Comment actions Permalink
  • Boerma

    你B服务的appid填了吗?

    0
    Comment actions Permalink
  • chris

    有的 配置文件都是一样的

    0
    Comment actions Permalink
  • chris

    现在B服务启动会有这样的错误 影响吗

    0
    Comment actions Permalink
  • DJI Developer Support
    显示组织ID不正确,检查一下数据的组织ID是否准确。 最后一张报错是没有影响的。
    0
    Comment actions Permalink
  • chris

    现在的错误是这个。我的设备id和组织码A服务和B服务用的是同样的 A服务能连接成功B服务则不能

    {
      "tid": "fd31cc9d-198c-4be9-8f3e-18342f6a387a",
      "bid": "a4b85ccc-c3fe-4f56-9805-896b6447cd3b",
      "method": "airport_organization_get",
      "data": {
        "result": 200001,
        "output": "illegal argument"
      },
      "timestamp": 1685005667762
    }

    0
    Comment actions Permalink
  • chris

    这是完整的两次连接机库的消息数据

    Topic: thing/product/4TADL210010050/stateQoS: 0

     
    {
      "tid": "c25f725a-7748-4d4b-809e-01fe0825c051",
      "bid": "8d8e6ff2-a1d3-44f8-9783-f08df8f7e18c",
      "timestamp": 1685005759964,
      "data": {
        "live_status": []
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:20:025

    Topic: thing/product/4TADL210010050/stateQoS: 0

     
    {
      "tid": "266bfb4e-430b-4855-a40d-11fd642869bd",
      "bid": "5ae30f33-ae6b-4c22-a954-a292ffcad0ad",
      "timestamp": 1685005759962,
      "data": {
        "live_capacity": {
          "available_video_number": 1,
          "coexist_video_number_max": 1,
          "device_list": [
            {
              "sn": "4TADL210010050",
              "available_video_number": 1,
              "coexist_video_number_max": 1,
              "camera_list": [
                {
                  "camera_index": "165-0-7",
                  "available_video_number": 1,
                  "coexist_video_number_max": 1,
                  "video_list": [
                    {
                      "video_index": "normal-0",
                      "video_type": "normal",
                      "switchable_video_types": [
                        "normal"
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:20:025

    Topic: thing/product/4TADL210010050/requestsQoS: 0

     
    {
      "method": "airport_organization_get",
      "bid": "f44cf885-e724-47f9-9342-d8dfcc2c7209",
      "tid": "f8712418-6afa-49bc-a74a-44bc34cc90d9",
      "timestamp": 1685005760156,
      "data": {
        "device_binding_code": "qwe",
        "organization_id": "W"
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:20:201

    Topic: thing/product/4TADL210010050/requests_replyQoS: 0

     
    {
      "tid": "f8712418-6afa-49bc-a74a-44bc34cc90d9",
      "bid": "f44cf885-e724-47f9-9342-d8dfcc2c7209",
      "method": "airport_organization_get",
      "data": {
        "result": 0,
        "output": {
          "organization_name": "xxxx"
        }
      },
      "timestamp": 1685005760238
    }

    2023-05-25 17:09:20:547

    Topic: thing/product/4TADL210010050/stateQoS: 0

     
    {
      "tid": "2664c2a3-38ed-4c7e-92fc-dd274572f475",
      "bid": "7a2d89bc-9d7b-41cf-9a8c-ded477506639",
      "timestamp": 1685005760520,
      "data": {
        "live_status": []
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:20:572

    Topic: thing/product/4TADL210010050/stateQoS: 0

     
    {
      "tid": "ad1adf67-a1bc-4ab9-b195-3eb90571c886",
      "bid": "07c8108d-98b4-4154-a68d-f9d2b82658ef",
      "timestamp": 1685005760518,
      "data": {
        "live_capacity": {
          "available_video_number": 1,
          "coexist_video_number_max": 1,
          "device_list": [
            {
              "sn": "4TADL210010050",
              "available_video_number": 1,
              "coexist_video_number_max": 1,
              "camera_list": [
                {
                  "camera_index": "165-0-7",
                  "available_video_number": 1,
                  "coexist_video_number_max": 1,
                  "video_list": [
                    {
                      "video_index": "normal-0",
                      "video_type": "normal",
                      "switchable_video_types": [
                        "normal"
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:20:572

    Topic: thing/product/4TADL210010050/requestsQoS: 0

     
    {
      "tid": "58e7ea74-41af-481f-80ea-067cef76133a",
      "bid": "82912d82-f3a8-47dc-b655-3609dadecb3b",
      "timestamp": 1685005760543,
      "method": "config",
      "data": {
        "config_type": "json",
        "config_scope": "product"
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:20:593

    Topic: thing/product/4TADL210010050/requests_replyQoS: 0

     
    {
      "tid": "58e7ea74-41af-481f-80ea-067cef76133a",
      "bid": "82912d82-f3a8-47dc-b655-3609dadecb3b",
      "method": "config",
      "data": {
        "ntp_server_host": "Google.mzr.me",
        "app_id": "125559",
        "app_key": "b778a761e9add527587a367f7eb6aed",
        "app_license": "mdDxoZPvi6oxbrJLweY+weKySwd1dKSDOjOZABDSz0m+lARv3gUGJaLVginiYdrqFAT0QXewmhoWdcTXT2ODAD0kp7nUlBSGBXreadhRrVQFwmVdA3pHTs2iJFx7HWfW4KzyCZdeeEKQDIQsAlFBUJgfsx55BpRryfpmTsxixVA="
      },
      "timestamp": 1685005760618
    }

    2023-05-25 17:09:20:614

    Topic: thing/product/4TADL210010050/stateQoS: 0

     
    {
      "tid": "c9d8797b-a6ac-44c7-8d81-2eebfeac05f7",
      "bid": "e16b9be0-8e7a-460a-81c6-1b28e046d6a6",
      "timestamp": 1685005761299,
      "data": {
        "live_status": []
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:21:348

    Topic: thing/product/4TADL210010050/stateQoS: 0

     
    {
      "tid": "5edbbbee-63ff-47c9-b5af-12adc4679d1c",
      "bid": "13957177-5b76-463f-b5d3-9002c8d3905c",
      "timestamp": 1685005761331,
      "data": {
        "live_status": []
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:21:425

    Topic: thing/product/4TADL210010050/stateQoS: 0

     
    {
      "tid": "602d60b2-b29c-4c94-8269-ab827e38608a",
      "bid": "5ae47833-cb8f-40fd-a5b2-a6fcc7878084",
      "timestamp": 1685005761330,
      "data": {
        "live_capacity": {
          "available_video_number": 1,
          "coexist_video_number_max": 1,
          "device_list": [
            {
              "sn": "4TADL210010050",
              "available_video_number": 1,
              "coexist_video_number_max": 1,
              "camera_list": [
                {
                  "camera_index": "165-0-7",
                  "available_video_number": 1,
                  "coexist_video_number_max": 1,
                  "video_list": [
                    {
                      "video_index": "normal-0",
                      "video_type": "normal",
                      "switchable_video_types": [
                        "normal"
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:21:425

    Topic: thing/product/4TADL210010050/requestsQoS: 0

     
    {
      "method": "airport_organization_bind",
      "bid": "1d47b0da-31c1-4591-9161-ac46bd637d63",
      "tid": "8d7162a7-07af-451e-8bf4-8a260d0344b2",
      "timestamp": 1685005765949,
      "data": {
        "bind_devices": [
          {
            "device_binding_code": "qwe",
            "organization_id": "W",
            "device_callsign": "",
            "sn": "4TADL210010050",
            "device_secret": "30129dc6c566c4af18ea77b94b3dfeee",
            "device_nonce": "3e3d7333909eab53942e683b8befa870",
            "device_model_key": "3-1-0"
          }
        ]
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:26:000

    Topic: thing/product/4TADL210010050/requests_replyQoS: 0

     
    {
      "tid": "8d7162a7-07af-451e-8bf4-8a260d0344b2",
      "bid": "1d47b0da-31c1-4591-9161-ac46bd637d63",
      "method": "airport_organization_bind",
      "data": {
        "result": 0,
        "output": {
          "err_infos": [
            {
              "sn": "4TADL210010050",
              "err_code": 0
            }
          ]
        }
      },
      "timestamp": 1685005766059
    }

    2023-05-25 17:09:26:047

    Topic: thing/product/4TADL210010050/requestsQoS: 0

     
    {
      "method": "airport_bind_status",
      "bid": "c57e8489-d48b-4c8f-a831-b494089f409e",
      "tid": "f414d78a-c71e-4114-8d26-85c8fa3ad1d6",
      "timestamp": 1685005766080,
      "data": {
        "devices": [
          {
            "sn": "4TADL210010050"
          }
        ]
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:26:126

    Topic: thing/product/4TADL210010050/requests_replyQoS: 0

     
    {
      "tid": "f414d78a-c71e-4114-8d26-85c8fa3ad1d6",
      "bid": "c57e8489-d48b-4c8f-a831-b494089f409e",
      "method": "airport_bind_status",
      "data": {
        "result": 0,
        "output": {
          "bind_status": [
            {
              "sn": "4TADL210010050",
              "is_device_bind_organization": true,
              "organization_id": "e3dea0f5-37f2-4d79-ae58-490af3228069",
              "organization_name": "xxx",
              "device_callsign": "城xx"
            }
          ]
        }
      },
      "timestamp": 1685005766180
    }

    2023-05-25 17:09:26:170

    Topic: thing/product/4TADL210010050/requestsQoS: 0

     
    {
      "method": "airport_bind_status",
      "bid": "d3c89687-98f0-42fc-b728-939a8c16e7e6",
      "tid": "bc6a51c4-bde6-4471-9376-044ea4107ba3",
      "timestamp": 1685005766144,
      "data": {
        "devices": [
          {
            "sn": "4TADL210010050"
          }
        ]
      },
      "gateway": "4TADL210010050"
    }

    2023-05-25 17:09:26:240

    Topic: thing/product/4TADL210010050/requests_replyQoS: 0

     
    {
      "tid": "bc6a51c4-bde6-4471-9376-044ea4107ba3",
      "bid": "d3c89687-98f0-42fc-b728-939a8c16e7e6",
      "method": "airport_bind_status",
      "data": {
        "result": 0,
        "output": {
          "bind_status": [
            {
              "sn": "4TADL210010050",
              "is_device_bind_organization": true,
              "organization_id": "e3dea0f5-37f2-4d79-ae58-490af3228069",
              "organization_name": "xxx",
              "device_callsign": "城x"
            }
          ]
        }
      },
      "timestamp": 1685005766286
    }
    0
    Comment actions Permalink
  • DJI Developer Support
    airport_organization_get下发的20001错误码是云端自定义的,官方demo在查询组织id未找到时会报这个错,请检查您数据库组织id是否准确
    0
    Comment actions Permalink
  • chris

    用的是同一个数据库

    0
    Comment actions Permalink
  • Boerma

    跟一下B服务这个函数,看看为什么从数据库中没有找到对应的绑定码

    0
    Comment actions Permalink
  • DJI Developer Support
    如果A、B服务使用的配置是一样的,就不会存在A服务能绑定成功,B服务绑定不成功的问题。检查B服务绑定时代码的报错。
    0
    Comment actions Permalink

Please sign in to leave a comment.