Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to recognize a local folder as valid DTMI model repository. #594

Closed
oedze opened this issue Dec 18, 2022 · 7 comments
Closed

How to recognize a local folder as valid DTMI model repository. #594

oedze opened this issue Dec 18, 2022 · 7 comments
Labels
DTDL enhancement New feature or request Plug and Play Feature: Plug and Play related

Comments

@oedze
Copy link

oedze commented Dec 18, 2022

I am trying to import model definitions using the IoT Explorer. But the IoT Explorer always tells me it can't find any definitions for the model interface i am using. I tried a few things but can't seem to get it to recognize any models.

  • I tried selecting the Local folder option in the Iot Plug and Play settings by setting the folder to the exact folder where the json file is located, this didn't help.
  • I tried setting it to iot-plugandplay models folder(which is a direct clone from the github repo) and the device model id to dtmi:com:example:Thermostat;1, but with no luck. I did try this with the public repository set, which works, so my device is working properly (i think)

Some extra information:

  • The models were validated with the dmr-client.
  • I created the indexes and the expand files for the full repository using these steps
@rido-min
Copy link
Member

rido-min commented Jan 3, 2023

I would expect that local model resolution supports the DMR conventions
/cc @digimaun

@YingXue
Copy link
Member

YingXue commented Jan 28, 2023

Hi @oedze
It sounds like you are indeed doing things.
We will need you to set up the local file path (for example the path would be d:/ if my Thermostat.json file is in my d drive), and the Thermostat.json.json should have an @id property equals to dtmi:com:example:Thermostat;1 (
image
)
Once you save the values, the tool should be able to recognize the models.

@YingXue YingXue added the question Further information is requested label Jan 28, 2023
@YingXue
Copy link
Member

YingXue commented Feb 2, 2023

Closing with instructions given.

@YingXue YingXue closed this as completed Feb 2, 2023
@rido-min
Copy link
Member

rido-min commented Feb 2, 2023

I think there is some value by finding files in a folder hierarchy that follows the DMR convention. Do you want to track as a different feature?

@YingXue
Copy link
Member

YingXue commented Feb 6, 2023

Sorry for not reading the descriptions close enough. Yes so far Explorer does not support indexes and the expand file format. I am reopening the issue to investigate what we can do here.

@YingXue YingXue reopened this Feb 6, 2023
@YingXue YingXue added enhancement New feature or request Plug and Play Feature: Plug and Play related DTDL and removed question Further information is requested labels Feb 6, 2023
@oedze
Copy link
Author

oedze commented Feb 6, 2023

Sorry for not reading the descriptions close enough. Yes so far Explorer does not support indexes and the expand file format. I am reopening the issue to investigate what we can do here.

Hi @YingXue
yes, as @rido-min mentioned. I expected the local folder to work as a model repository. When i add the folder it's in the list with a big header above it called: "Model Repository Locations". I now added the thermostat-1.json file to the root of the folder structure and it works indeed.

It would be nice if the local folder would follow the conventions.
Maybe it's possible to add an extra option next to add Public Repository, Configurable Repository and Local folder called Local Repository . Then you also won't be breaking any local folders that are setup.

For now i can work with the local folder just fine, Thanks!

@YingXue YingXue mentioned this issue Feb 14, 2023
4 tasks
@YingXue
Copy link
Member

YingXue commented Feb 28, 2023

We have just release version 0.15.7 and addressed the feature request. Please give it a try if you'd like. Thank you.
https://github.com/Azure/azure-iot-explorer/releases/tag/v0.15.7

@YingXue YingXue closed this as completed Feb 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DTDL enhancement New feature or request Plug and Play Feature: Plug and Play related
Projects
None yet
Development

No branches or pull requests

3 participants