Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
eafb918
update actions to beta3 (#1)
rido-min Apr 21, 2021
2ee962f
add device models of Armadillo-IoT GW G3L (#206)
Shin-yaKoga Apr 21, 2021
bc1e815
Add Sam4s_SK161 DTDL Model (#195)
Voiceye-MYCHOI Apr 21, 2021
39f503f
Add IL20 model. (#202)
WinmateIot Apr 21, 2021
bab3bcb
INCON Trium-i models (#203)
MDSEva Apr 21, 2021
d44eb8a
add smarphone model (#204)
lucadruda Apr 22, 2021
708b892
[seeedkk] Add the reterminal_aziot_example model (#208)
matsujirushi Apr 22, 2021
3899800
Ritaylor/newazurespheremodel (#205)
richardtaylorrt Apr 22, 2021
70e1d6e
Merge branch 'main' of https://github.com/Azure/iot-plugandplay-model…
rido-min Apr 22, 2021
db0a8cd
Update README with links, new commands, and update instructions (#211)
rido-min Apr 22, 2021
a0f8e09
Add new model e1000_ibs01g, x1000_ibs01g, e1000_ibs02ir2 , x1000_ibs0…
kajiwarat Apr 23, 2021
974cb81
laonpeople IoT PnP Device Certified (#212)
MDSEva Apr 23, 2021
a1d2832
rt5015 (#213)
PosiflexTech Apr 23, 2021
d551dfd
Add iei standard.json model (#215)
rayhuang199 Apr 23, 2021
a266af7
add iBase MI996 model (#219)
ibasesw Apr 23, 2021
1062707
ADD ARCHMI_9XXA (#221)
iolp1230 Apr 23, 2021
e9b5e7f
Add Forenex Model Of FES101E6 (#223)
Forenex-IOT Apr 23, 2021
52717a4
Add Winmate Model of FA3S (#224)
WinmateIot Apr 23, 2021
68ec0c6
[seeedkk] Update the reterminal_aziot_example (#227)
matsujirushi Apr 23, 2021
54fd57e
Create model for altair on azure sphere (#228)
gloveboxes Apr 26, 2021
428f35c
Create powermeter-1.json (#231)
paul-chao-techware Apr 27, 2021
eecf889
Add VECOW SPC-7000 model (#225)
WayneHou118 Apr 27, 2021
8924b7b
add ViTAM_9XXA (#226)
ryanaplex Apr 27, 2021
bf37d87
Add smartipc_gh414 dtdl model (#232)
Voiceye-MYCHOI Apr 27, 2021
9f53865
Update Winmate Model of FA3S (#233)
WinmateIot Apr 27, 2021
28e2de5
Add models for TinyML artificial nose (#230)
kartben Apr 27, 2021
cab37c7
STMicroelectronics B_L4S5I_IOT01A IoT Node 1.5 discovery kit (#218)
dmelpi Apr 27, 2021
cd83d84
Request a device models of HANASIS device (#234)
MDSEva Apr 28, 2021
aa11da9
develco PnP first bundles (#236)
mtrere Apr 29, 2021
f1acd92
Add cExpress-AR、cEpress-EL、MXE-210、LEC-PX30 (#194)
ADLINK-COM Apr 29, 2021
2291066
Add models for innodisk (#235)
Shaing Apr 30, 2021
0a217f9
Stwin1b (#237)
dmelpi Apr 30, 2021
47e0e82
Create boxer_rk88-2.json (#238)
chiaotseng Apr 30, 2021
3a0219d
Add Multitech MTCAP and Tektelic Kona Micro models (#239)
jburhenn Apr 30, 2021
720a282
Pnp cert (#240)
dmelpi May 3, 2021
0562c36
[seeedkk] Add the wioterminal_watchdog_vl53l0x (#241)
matsujirushi May 4, 2021
829c9fe
[seeedkk] Add the wioterminal_watchdog (#242)
matsujirushi May 4, 2021
52a4c9b
Add RT-2016 (#243)
PosiflexTech May 4, 2021
2198602
Create qc710-1.json (#244)
koala6616 May 5, 2021
82303ca
Add new myDevices models (#247)
jburhenn May 5, 2021
e17bb21
Update README.md
digimaun May 5, 2021
1c96903
[seeedkk] Add the wioterminal_dust (#248)
matsujirushi May 6, 2021
82e96fe
Add Tartabit Asset Tracker model (#254)
bocajim May 6, 2021
9591589
Add Renesas RX65N Cloud Kit Model (#251)
TatsuyaOgawanx May 7, 2021
4130968
Rename display name for PhoneAsADevice (#256)
lucadruda May 7, 2021
6aef1e5
[seeedkk] Add the wioterminal_digital_signage (#255)
matsujirushi May 10, 2021
e5e7903
Add IviewKorea (IV-CO255PPC) Dtdl Model (#262)
Voiceye-MYCHOI May 10, 2021
ae00d9e
add device model of Armadillo-IoT GW G3M1 weighing machine (#257)
Shin-yaKoga May 10, 2021
a8610d0
[DevelcoProducts] DTDLs for gateway with every single sensor (#252)
davidegualandris May 10, 2021
d1af4ca
updating wrong develco DTDL (#258)
mtrere May 10, 2021
4eef916
Add himax_aiot_nb-g2.json (#245)
HimaxSPD May 11, 2021
3013621
Adding STMicroelectronics IoT Node 2 kit (#264)
dmelpi May 11, 2021
0250dd6
Mydevices round 6 submissions (#265)
jburhenn May 11, 2021
5f5238d
Add wise_4250as_s231-1.json, wise_systeminformation-1.json, wise_temp…
TigerDuck118 May 12, 2021
2164d89
Add nanoX_EL , Delete MXE-210 (#266)
ADLINK-COM May 12, 2021
b2033e1
Create androiddeviceinfo-1.json (#267)
chiaotseng May 12, 2021
5b9a4b3
[seeedkk] Modify the wioterminal_digital_signage (#268)
matsujirushi May 12, 2021
971ada0
updated DTDL vibration sensor (#269)
mtrere May 12, 2021
5555ed1
Create d230-1.json (#270)
chiaotseng May 13, 2021
5be499a
[DevelcoProducts] wrong property type fixed (#271)
davidegualandris May 13, 2021
2f13d9c
Add Himax_AIoT_NB_G2 v2 Model (#274)
HimaxSPD May 14, 2021
cdb1fa4
add device models of Armadillo-IoT GW A6 based devices (#277)
Shin-yaKoga May 17, 2021
3c023d5
Create imx8mp (#279)
ADLINK-COM May 17, 2021
b8ba0df
Add UPX-TGL01 model. (#280)
chiaotseng May 18, 2021
ed04c3a
[DevelcoProducts] new DTDLs (#281)
davidegualandris May 18, 2021
3f2d3e3
[DEVELCO] new gateway DTDL (#282)
davidegualandris May 20, 2021
e08ab20
add Armadillo-IoT GW A6 DoorsMonitor's model v2 (#283)
Shin-yaKoga May 21, 2021
90ec968
Create cscg_gateway-1.json (#284)
chiaotseng May 21, 2021
f47c91a
Create ncube-1.json (#285)
chiaotseng May 21, 2021
5edc881
Add AVCON models (#286)
chiaotseng May 21, 2021
36fa6d0
Add AgoraOpinion model (#287)
jburhenn May 21, 2021
d26f706
Added impinj fixedreader + R700 model files (#272)
kwennerImpinj May 21, 2021
f3425f0
Add Leetop models. (#288)
chiaotseng May 24, 2021
c5e729c
Create apollo-1.json (#289)
chiaotseng May 24, 2021
aee3185
Cognian Technologies Syncromesh Gateway (with sphere module) device m…
sujithiyer May 24, 2021
db764f1
add components
rido-min May 25, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
86 changes: 77 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Related tools, samples, and specs can be found in the [Azure/iot-plugandplay-mod
`C:\iot-plugandplay-models\MyThermostat.json`

1. Validate the models locally using the `dmr-client` tool to [validate](#validate-models).
1. Add the new interfaces to the `dtmi` folder using the folder/filename convention. See the [add-models](#import-a-model-to-the-dtmi-folder) tool below.
1. Add the new interfaces to the `dtmi` folder using the folder/filename convention. See the [import](#import-a-model-to-the-dtmi-folder) command below.
1. Review and cross check with the [PR requirements](pr-reqs.md) and ensure all elements are conform to [DTDL v2](https://aka.ms/dtdl) specification.
1. Commit the changes locally and push to your fork.
1. From your fork, create a PR that targets the `main` branch.
Expand Down Expand Up @@ -72,68 +72,136 @@ Microsoft will respond to a PR with all checks in 3 business days.

The tools used to validate the models during the PR checks can also be used to add and validate the DTDL interfaces locally.

> Note: These tools require the [.NET SDK](https://dotnet.microsoft.com/download) (3.1 or greater)
> Note: This tool requires the [.NET SDK](https://dotnet.microsoft.com/download) (3.1 or greater)

### Install `dmr-client`

#### Linux/Bash

```bash
curl -L https://aka.ms/install-dmr-client-linux | bash

# Expected SHA checksum
curl -sL https://aka.ms/install-dmr-client-linux | shasum -b -a 256
2d1c1ca24943527982ef30f5e8f9716bdbf2ca11407b2af73183453b98d251a0 *-
```

#### Windows/Powershell

```powershell
iwr https://aka.ms/install-dmr-client-windows -UseBasicParsing | iex

# Expected SHA checksum
curl -sL https://aka.ms/install-dmr-client-windows | shasum -b -a 256
0245ae8318e7caf27dd63f3841646f2def3e2ced127ffcb741814be3b063fd7a *-
```

#### Update / Uninstall

To update the client you must uninstall the current version first:

```
dotnet tool uninstall -g microsoft.iot.modelsrepository.commandline
```

> [Note] Previous versions must be uninstalled with `dotnet tool uninstall -g dmr-client`. Use the `dotnet tool list -g` command to check the id of the tool you want to uninstall

### Import a Model to the `dtmi/` folder

If you have your model already stored in json files, you can use the `dmr-client import` command to add those to the `dtmi/` folder with the right file name.

```bash
# from the local repo root folder
dmr-client import --model-file "MyThermostat.json"

> dmr-client import --model-file "MyThermostat.json"
```

>Note: You can use the `--local-repo` argument to specify the local repo root folder
> This command will rename and locate the file in the appropriate folder

### Validate Models

You can validate your models with the `dmr-client validate` command.

```bash
dmr-client validate --model-file ./my/model/file.json
# Validate a model file using the DTDL parser

> dmr-client validate --model-file ./my/model/file.json
```

>Note: The validation uses the latest DTDL parser version to ensure all the interfaces are compatible with the DTDL language spec

To validate external dependencies, those must exist in the local repo. To validate those you can specify a `local` or `remote` folder to validate against.

```bash
# from the repo root folder
dmr-client validate --model-file ./my/model/file.json --repo .
# Validate a model file using the DTDL parser checking dependencies with the current folder as a local repo

> dmr-client validate --model-file ./my/model/file.json --repo .
```

#### Strict validation

The Device Model Repo includes additional [requirements](pr-reqs.md), these can be validated with the `strict` flag.

```bash
dmr-client validate --model-file ./my/model/file.json --repo . --strict true
# Validate a model file using the DTDL parser checking dependencies with the current folder as a local repo in strict mode

> dmr-client validate --model-file ./my/model/file.json --repo . --strict
```

#### Export models

Models can be exported from a given repo (local or remote) to a single file using a JSON Array.

```bash
dmr-client export --dtmi "dtmi:com:example:TemperatureController;1" -o TemperatureController.expanded.json
# Retrieves an interface from a custom repo by DTMI

> dmr-client export --dtmi "dtmi:com:example:Thermostat;1" --repo https://raw.githubusercontent.com/Azure/iot-plugandplay-models/main
```

#### Create Index

The model repo can host a `index.json` file with all the `ids` avaialble in the repository. Read the [Index Spec](https://github.com/Azure/iot-plugandplay-models-tools/wiki/Model-Index)

```bash
# Builds a model index for the repository. If models exceed the page limit new page files will be created relative to the root index.

> dmr-client index --local-repo .
```

```bash
# Build a model index with a custom page limit indicating max models per page.

> dmr-client index --local-repo . --page-limit 100
```

#### Create Expanded files

```bash
# Expand all models from the root directory of a local models repository following Azure IoT conventions.
# Expanded models are inserted in-place.

> dmr-client expand --local-repo .
```

```bash
# The default --local-repo value is the current directory. Be sure to specifiy the root for --local-repo.

> dmr-client expand
```

## Consuming

There are Azure SDKs available for the models repository in the following languages:

|Platform|Package|Source|Samples|
|--------|-------|------|-------|
|.NET | [Azure.IoT.ModelsRepository](https://www.nuget.org/packages/Azure.IoT.ModelsRepository)|[Source](https://github.com/Azure/azure-sdk-for-net/tree/master/sdk/modelsrepository/Azure.IoT.ModelsRepository)|[Samples](https://github.com/Azure/azure-sdk-for-net/tree/master/sdk/modelsrepository/Azure.IoT.ModelsRepository/samples)|
|Java |[com.azure/azure-iot-modelsrepository](https://search.maven.org/artifact/com.azure/azure-iot-modelsrepository)|[Source](https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/modelsrepository/azure-iot-modelsrepository)|[Samples](https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/modelsrepository/azure-iot-modelsrepository/src/samples)|
|Node|*coming soon*|||
|Python|*coming soon*|||

### Retrieve models without any SDK

Any HTTP client can consume the models by just applying the [convention](https://github.com/Azure/iot-plugandplay-models-tools/wiki/Resolution-Convention) to translate *DTMI ids* to relative paths:

Eg, the interface:
Expand Down
13 changes: 13 additions & 0 deletions dtmi/aaeon/boxer_rk88-2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:AAEON:BOXER_RK88;2",
"@type": "Interface",
"displayName": "AAEON-BOXER-RK88",
"contents": [
{
"@type": "Component",
"name": "LinuxDeviceInfo1",
"schema": "dtmi:Synnex:LinuxDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/aaeon/upx_tgl01-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:AAEON:UPX_TGL01;1",
"@type": "Interface",
"displayName": "AAEON-UPX-TGL01",
"contents": [
{
"@type": "Component",
"name": "WindowsDeviceInfo1",
"schema": "dtmi:Synnex:WindowsDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/adlink/cexpress_ar-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:ADLINK:cExpress_AR;1",
"@type": "Interface",
"displayName": "ADLINK-cExpress-AR",
"contents": [
{
"@type": "Component",
"name": "WindowsDeviceInfo1",
"schema": "dtmi:Synnex:WindowsDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/adlink/cexpress_el-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:ADLINK:cExpress_EL;1",
"@type": "Interface",
"displayName": "ADLINK-cExpress-EL",
"contents": [
{
"@type": "Component",
"name": "WindowsDeviceInfo1",
"schema": "dtmi:Synnex:WindowsDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/adlink/i_pi_smarc_imx8mp_plus-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:ADLINK:I_Pi_SMARC_IMX8MP_Plus;1",
"@type": "Interface",
"displayName": "ADLINK-I-Pi-SMARC-IMX8MP-Plus",
"contents": [
{
"@type": "Component",
"name": "LinuxDeviceInfo1",
"schema": "dtmi:Synnex:LinuxDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/adlink/lec_imx8mp-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:ADLINK:lec_imx8mp;1",
"@type": "Interface",
"displayName": "ADLINK-LEC-IMX8MP",
"contents": [
{
"@type": "Component",
"name": "LinuxDeviceInfo1",
"schema": "dtmi:Synnex:LinuxDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/adlink/lec_px30-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:ADLINK:LEC_PX30;1",
"@type": "Interface",
"displayName": "ADLINK-LEC-PX30",
"contents": [
{
"@type": "Component",
"name": "WindowsDeviceInfo1",
"schema": "dtmi:Synnex:WindowsDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/adlink/mxe_210-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:ADLINK:MXE_210;1",
"@type": "Interface",
"displayName": "ADLINK-MXE-210",
"contents": [
{
"@type": "Component",
"name": "WindowsDeviceInfo1",
"schema": "dtmi:Synnex:WindowsDeviceInfo;1"
}
]
}
13 changes: 13 additions & 0 deletions dtmi/adlink/nanox_el-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"@context": "dtmi:dtdl:context;2",
"@id": "dtmi:ADLINK:nanoX_EL;1",
"@type": "Interface",
"displayName": "ADLINK-nanoX-EL",
"contents": [
{
"@type": "Component",
"name": "WindowsDeviceInfo1",
"schema": "dtmi:Synnex:WindowsDeviceInfo;1"
}
]
}
23 changes: 23 additions & 0 deletions dtmi/advantech/wise_4250as_s231-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"@id": "dtmi:Advantech:WISE_4250AS_S231;1",
"@type": "Interface",
"displayName": "WISE-4250AS-S231",
"@context": "dtmi:dtdl:context;2",
"contents": [
{
"@type": "Component",
"name": "Temperature",
"schema": "dtmi:Advantech:WISE_Temperature;1"
},
{
"@type": "Component",
"name": "Humidity",
"schema": "dtmi:Advantech:WISE_Humidity;1"
},
{
"@type": "Component",
"name": "SystemInformation",
"schema": "dtmi:Advantech:WISE_SystemInformation;1"
}
]
}
Loading