pktiuk/DJI_Cloud_API_minimal

How can I get the djiBridge object

Closed this issue · 5 comments

window.djiBridge.platformIsVerified()
How does the window object get this djiBridge object?

I don't understand your question.

In the source code you have working example.

I tried running the code. When I click on login button, this is the error I'm receiving.

"login:43 Uncaught TypeError: Cannot read properties of undefined (reading 'platformVerifyLicense')
at HTMLButtonElement. (login:43:38)"

I believe the line of code is this:

`var token = window.djiBridge.platformVerifyLicense(
      APP_ID,
      APP_KEY,
      LICENSE
    );`

Its unable to find the djiBridge object in the "window". Are you setting this variable somewhere?

Do you open it on the dji pilot or in regular browser in pc?

I'm trying to open it on chrome on a laptop.

This app works only on DJI pilot
image

README directly states where you can open this app.