From 24ccd2a2b54f5a6cf0de824c862178eb2cba9d63 Mon Sep 17 00:00:00 2001 From: Andrew Shvayka Date: Wed, 9 Dec 2020 17:11:32 +0200 Subject: [PATCH] Revert "[3.2.1] Develop/lwm2m (#3547)" This reverts commit df6151f5ae8d3b77a67318dbb774d55e3f297960. --- application/pom.xml | 4 - .../server/actors/device/DeviceActor.java | 2 +- .../device/DeviceActorMessageProcessor.java | 35 +- .../server/controller/BaseController.java | 4 - .../server/controller/DeviceController.java | 5 +- .../controller/DeviceLwm2mController.java | 75 -- .../service/lwm2m/LwM2MModelsRepository.java | 256 ----- .../device/DefaultDeviceAuthService.java | 4 +- .../DefaultTelemetrySubscriptionService.java | 1 - .../transport/DefaultTransportApiService.java | 44 - application/src/main/resources/banner.txt | 7 - .../src/main/resources/thingsboard.yml | 72 +- .../common/data/lwm2m/LwM2mInstance.java | 25 - .../server/common/data/lwm2m/LwM2mObject.java | 27 - .../common/data/lwm2m/LwM2mResource.java | 63 -- .../data/lwm2m/ServerSecurityConfig.java | 34 - .../data/security/DeviceCredentialsType.java | 4 +- common/queue/src/main/proto/queue.proto | 46 +- .../transport/coap/CoapTransportContext.java | 1 - .../transport/coap/CoapTransportResource.java | 66 +- .../transport/coap/CoapTransportService.java | 11 +- .../coap/adaptors/JsonCoapAdaptor.java | 1 - .../transport/coap/client/DeviceEmulator.java | 21 +- .../transport/http/DeviceApiController.java | 1 - common/transport/lwm2m/pom.xml | 123 --- ...TransportBootstrapServerConfiguration.java | 101 -- ...2MTransportBootstrapServerInitializer.java | 70 -- .../LwM2MTransportContextBootstrap.java | 60 -- .../secure/LwM2MBootstrapConfig.java | 102 -- .../secure/LwM2MBootstrapSecurityStore.java | 181 ---- .../secure/LwM2MBootstrapServers.java | 33 - .../LwM2MInMemoryBootstrapConfigStore.java | 71 -- .../secure/LwM2MServerBootstrap.java | 65 -- .../LwM2MSetSecurityStoreBootstrap.java | 205 ---- .../LwM2mDefaultBootstrapSessionManager.java | 66 -- .../secure/LWM2MGenerationPSkRPkECC.java | 121 --- .../lwm2m/secure/LwM2MGetSecurityInfo.java | 170 --- .../lwm2m/secure/LwM2MSecurityMode.java | 58 - .../lwm2m/secure/LwM2mRPkCredentials.java | 84 -- .../lwm2m/secure/ReadResultSecurityStore.java | 40 - .../lwm2m/server/LwM2MSessionMsgListener.java | 88 -- .../server/LwM2MTransportContextServer.java | 60 -- .../lwm2m/server/LwM2MTransportHandler.java | 333 ------ .../lwm2m/server/LwM2MTransportRequest.java | 335 ------ .../LwM2MTransportServerConfiguration.java | 102 -- .../LwM2MTransportServerInitializer.java | 72 -- .../lwm2m/server/LwM2MTransportService.java | 999 ------------------ .../lwm2m/server/LwM2mServerListener.java | 111 -- .../transport/lwm2m/server/ResultIds.java | 38 - .../server/adaptors/LwM2MJsonAdaptor.java | 49 - .../adaptors/LwM2MTransportAdaptor.java | 27 - .../client/AttrTelemetryObserveValue.java | 47 - .../lwm2m/server/client/LwM2MClient.java | 107 -- .../lwm2m/server/client/ModelObject.java | 41 - .../lwm2m/server/client/ResourceValue.java | 26 - .../client/ResultsAnalyzerParameters.java | 32 - .../secure/LwM2MSetSecurityStoreServer.java | 234 ---- .../secure/LwM2mInMemorySecurityStore.java | 212 ---- .../lwm2m/utils/LwM2mValueConverterImpl.java | 146 --- .../transport/lwm2m/utils/TypeServer.java | 29 - .../resources/credentials/serverKeyStore.jks | Bin 5716 -> 0 bytes .../credentials/shell/lwM2M_credentials.sh | 208 ---- .../credentials/shell/lwM2M_keygen.properties | 58 - .../lwm2m/src/main/resources/models/10241.xml | 81 -- .../lwm2m/src/main/resources/models/10242.xml | 659 ------------ .../lwm2m/src/main/resources/models/10243.xml | 263 ----- .../lwm2m/src/main/resources/models/10244.xml | 301 ------ .../lwm2m/src/main/resources/models/10245.xml | 217 ---- .../lwm2m/src/main/resources/models/10246.xml | 108 -- .../lwm2m/src/main/resources/models/10247.xml | 98 -- .../lwm2m/src/main/resources/models/10248.xml | 78 -- .../lwm2m/src/main/resources/models/10249.xml | 138 --- .../lwm2m/src/main/resources/models/10250.xml | 70 -- .../lwm2m/src/main/resources/models/10251.xml | 96 -- .../lwm2m/src/main/resources/models/10252.xml | 229 ---- .../lwm2m/src/main/resources/models/10253.xml | 72 -- .../lwm2m/src/main/resources/models/10254.xml | 119 --- .../lwm2m/src/main/resources/models/10255.xml | 165 --- .../lwm2m/src/main/resources/models/10256.xml | 117 -- .../lwm2m/src/main/resources/models/10257.xml | 275 ----- .../lwm2m/src/main/resources/models/10258.xml | 89 -- .../lwm2m/src/main/resources/models/10259.xml | 115 -- .../src/main/resources/models/10260-2_0.xml | 95 -- .../lwm2m/src/main/resources/models/10262.xml | 87 -- .../lwm2m/src/main/resources/models/10263.xml | 90 -- .../lwm2m/src/main/resources/models/10264.xml | 117 -- .../lwm2m/src/main/resources/models/10265.xml | 136 --- .../lwm2m/src/main/resources/models/10266.xml | 244 ----- .../lwm2m/src/main/resources/models/10267.xml | 244 ----- .../lwm2m/src/main/resources/models/10268.xml | 244 ----- .../lwm2m/src/main/resources/models/10269.xml | 244 ----- .../lwm2m/src/main/resources/models/10270.xml | 244 ----- .../lwm2m/src/main/resources/models/10271.xml | 244 ----- .../lwm2m/src/main/resources/models/10272.xml | 230 ---- .../lwm2m/src/main/resources/models/10273.xml | 230 ---- .../lwm2m/src/main/resources/models/10274.xml | 230 ---- .../lwm2m/src/main/resources/models/10275.xml | 230 ---- .../lwm2m/src/main/resources/models/10276.xml | 230 ---- .../lwm2m/src/main/resources/models/10277.xml | 230 ---- .../lwm2m/src/main/resources/models/10278.xml | 230 ---- .../lwm2m/src/main/resources/models/10279.xml | 230 ---- .../lwm2m/src/main/resources/models/10280.xml | 230 ---- .../lwm2m/src/main/resources/models/10281.xml | 230 ---- .../lwm2m/src/main/resources/models/10282.xml | 230 ---- .../lwm2m/src/main/resources/models/10283.xml | 230 ---- .../lwm2m/src/main/resources/models/10284.xml | 230 ---- .../lwm2m/src/main/resources/models/10286.xml | 48 - .../lwm2m/src/main/resources/models/10290.xml | 198 ---- .../lwm2m/src/main/resources/models/10291.xml | 208 ---- .../lwm2m/src/main/resources/models/10292.xml | 208 ---- .../lwm2m/src/main/resources/models/10299.xml | 113 -- .../lwm2m/src/main/resources/models/10300.xml | 142 --- .../src/main/resources/models/10308-2_0.xml | 145 --- .../lwm2m/src/main/resources/models/10309.xml | 115 -- .../lwm2m/src/main/resources/models/10311.xml | 164 --- .../lwm2m/src/main/resources/models/10313.xml | 253 ----- .../lwm2m/src/main/resources/models/10314.xml | 106 -- .../lwm2m/src/main/resources/models/10315.xml | 129 --- .../lwm2m/src/main/resources/models/10316.xml | 233 ---- .../lwm2m/src/main/resources/models/10318.xml | 189 ---- .../lwm2m/src/main/resources/models/10319.xml | 130 --- .../lwm2m/src/main/resources/models/10320.xml | 141 --- .../lwm2m/src/main/resources/models/10322.xml | 87 -- .../lwm2m/src/main/resources/models/10323.xml | 90 -- .../lwm2m/src/main/resources/models/10324.xml | 77 -- .../lwm2m/src/main/resources/models/10326.xml | 722 ------------- .../lwm2m/src/main/resources/models/10327.xml | 68 -- .../lwm2m/src/main/resources/models/10328.xml | 80 -- .../lwm2m/src/main/resources/models/10329.xml | 433 -------- .../lwm2m/src/main/resources/models/10330.xml | 120 --- .../lwm2m/src/main/resources/models/10331.xml | 221 ---- .../lwm2m/src/main/resources/models/10332.xml | 69 -- .../lwm2m/src/main/resources/models/10333.xml | 88 -- .../lwm2m/src/main/resources/models/10334.xml | 129 --- .../lwm2m/src/main/resources/models/10335.xml | 97 -- .../lwm2m/src/main/resources/models/10336.xml | 84 -- .../lwm2m/src/main/resources/models/10337.xml | 118 --- .../lwm2m/src/main/resources/models/10338.xml | 124 --- .../lwm2m/src/main/resources/models/10339.xml | 114 -- .../lwm2m/src/main/resources/models/10340.xml | 218 ---- .../lwm2m/src/main/resources/models/10341.xml | 84 -- .../lwm2m/src/main/resources/models/10342.xml | 84 -- .../lwm2m/src/main/resources/models/10343.xml | 96 -- .../lwm2m/src/main/resources/models/10344.xml | 96 -- .../lwm2m/src/main/resources/models/10345.xml | 96 -- .../lwm2m/src/main/resources/models/10346.xml | 96 -- .../lwm2m/src/main/resources/models/10347.xml | 154 --- .../lwm2m/src/main/resources/models/10348.xml | 96 -- .../lwm2m/src/main/resources/models/10349.xml | 84 -- .../lwm2m/src/main/resources/models/10350.xml | 116 -- .../lwm2m/src/main/resources/models/10351.xml | 79 -- .../lwm2m/src/main/resources/models/10352.xml | 114 -- .../lwm2m/src/main/resources/models/10353.xml | 87 -- .../lwm2m/src/main/resources/models/10354.xml | 217 ---- .../lwm2m/src/main/resources/models/10355.xml | 95 -- .../lwm2m/src/main/resources/models/10356.xml | 203 ---- .../lwm2m/src/main/resources/models/10357.xml | 95 -- .../lwm2m/src/main/resources/models/10358.xml | 70 -- .../lwm2m/src/main/resources/models/10359.xml | 78 -- .../lwm2m/src/main/resources/models/10360.xml | 70 -- .../lwm2m/src/main/resources/models/10361.xml | 92 -- .../lwm2m/src/main/resources/models/10362.xml | 91 -- .../lwm2m/src/main/resources/models/10363.xml | 57 - .../lwm2m/src/main/resources/models/10364.xml | 57 - .../lwm2m/src/main/resources/models/10365.xml | 57 - .../lwm2m/src/main/resources/models/10366.xml | 59 -- .../lwm2m/src/main/resources/models/10368.xml | 96 -- .../lwm2m/src/main/resources/models/10369.xml | 84 -- .../lwm2m/src/main/resources/models/2048.xml | 90 -- .../lwm2m/src/main/resources/models/2049.xml | 59 -- .../lwm2m/src/main/resources/models/2050.xml | 64 -- .../lwm2m/src/main/resources/models/2051.xml | 99 -- .../lwm2m/src/main/resources/models/2052.xml | 111 -- .../lwm2m/src/main/resources/models/2053.xml | 165 --- .../lwm2m/src/main/resources/models/2054.xml | 69 -- .../lwm2m/src/main/resources/models/2055.xml | 100 -- .../lwm2m/src/main/resources/models/2056.xml | 77 -- .../lwm2m/src/main/resources/models/2057.xml | 92 -- .../lwm2m/src/main/resources/models/31024.xml | 51 - .../lwm2m/src/main/resources/models/3200.xml | 129 --- .../lwm2m/src/main/resources/models/3201.xml | 78 -- .../lwm2m/src/main/resources/models/3202.xml | 128 --- .../lwm2m/src/main/resources/models/3203.xml | 88 -- .../lwm2m/src/main/resources/models/3300.xml | 138 --- .../lwm2m/src/main/resources/models/3301.xml | 118 --- .../lwm2m/src/main/resources/models/3302.xml | 108 -- .../lwm2m/src/main/resources/models/3303.xml | 118 --- .../lwm2m/src/main/resources/models/3304.xml | 118 --- .../lwm2m/src/main/resources/models/3305.xml | 228 ---- .../lwm2m/src/main/resources/models/3306.xml | 98 -- .../lwm2m/src/main/resources/models/3308.xml | 88 -- .../lwm2m/src/main/resources/models/3310.xml | 108 -- .../lwm2m/src/main/resources/models/3311.xml | 127 --- .../lwm2m/src/main/resources/models/3312.xml | 107 -- .../lwm2m/src/main/resources/models/3313.xml | 107 -- .../lwm2m/src/main/resources/models/3314.xml | 97 -- .../lwm2m/src/main/resources/models/3315.xml | 118 --- .../lwm2m/src/main/resources/models/3316.xml | 139 --- .../lwm2m/src/main/resources/models/3317.xml | 139 --- .../lwm2m/src/main/resources/models/3318.xml | 139 --- .../lwm2m/src/main/resources/models/3319.xml | 139 --- .../lwm2m/src/main/resources/models/3320.xml | 139 --- .../lwm2m/src/main/resources/models/3321.xml | 139 --- .../lwm2m/src/main/resources/models/3322.xml | 139 --- .../lwm2m/src/main/resources/models/3323.xml | 139 --- .../lwm2m/src/main/resources/models/3324.xml | 139 --- .../lwm2m/src/main/resources/models/3325.xml | 139 --- .../lwm2m/src/main/resources/models/3326.xml | 139 --- .../lwm2m/src/main/resources/models/3327.xml | 139 --- .../lwm2m/src/main/resources/models/3328.xml | 139 --- .../lwm2m/src/main/resources/models/3329.xml | 139 --- .../lwm2m/src/main/resources/models/3330.xml | 139 --- .../lwm2m/src/main/resources/models/3331.xml | 89 -- .../lwm2m/src/main/resources/models/3332.xml | 99 -- .../lwm2m/src/main/resources/models/3333.xml | 78 -- .../lwm2m/src/main/resources/models/3334.xml | 189 ---- .../lwm2m/src/main/resources/models/3335.xml | 79 -- .../lwm2m/src/main/resources/models/3336.xml | 119 --- .../lwm2m/src/main/resources/models/3337.xml | 139 --- .../lwm2m/src/main/resources/models/3338.xml | 99 -- .../lwm2m/src/main/resources/models/3339.xml | 98 -- .../lwm2m/src/main/resources/models/3340.xml | 159 --- .../lwm2m/src/main/resources/models/3341.xml | 139 --- .../lwm2m/src/main/resources/models/3342.xml | 98 -- .../lwm2m/src/main/resources/models/3343.xml | 89 -- .../lwm2m/src/main/resources/models/3344.xml | 99 -- .../lwm2m/src/main/resources/models/3345.xml | 109 -- .../lwm2m/src/main/resources/models/3346.xml | 139 --- .../lwm2m/src/main/resources/models/3347.xml | 79 -- .../lwm2m/src/main/resources/models/3348.xml | 69 -- .../lwm2m/src/main/resources/models/3349.xml | 88 -- .../lwm2m/src/main/resources/models/3350.xml | 88 -- .../lwm2m/src/main/resources/models/3351.xml | 131 --- .../lwm2m/src/main/resources/models/3352.xml | 124 --- .../lwm2m/src/main/resources/models/3353.xml | 123 --- .../lwm2m/src/main/resources/models/3354.xml | 134 --- .../lwm2m/src/main/resources/models/3355.xml | 156 --- .../lwm2m/src/main/resources/models/3356.xml | 120 --- .../lwm2m/src/main/resources/models/3357.xml | 131 --- .../lwm2m/src/main/resources/models/3358.xml | 106 -- .../lwm2m/src/main/resources/models/3359.xml | 105 -- .../lwm2m/src/main/resources/models/3360.xml | 128 --- .../lwm2m/src/main/resources/models/3361.xml | 130 --- .../lwm2m/src/main/resources/models/3362.xml | 97 -- .../lwm2m/src/main/resources/models/3363.xml | 100 -- .../lwm2m/src/main/resources/models/3364.xml | 97 -- .../lwm2m/src/main/resources/models/3365.xml | 123 --- .../lwm2m/src/main/resources/models/3366.xml | 176 --- .../lwm2m/src/main/resources/models/3367.xml | 138 --- .../lwm2m/src/main/resources/models/3368.xml | 100 -- .../lwm2m/src/main/resources/models/3369.xml | 105 -- .../lwm2m/src/main/resources/models/3370.xml | 141 --- .../lwm2m/src/main/resources/models/3371.xml | 141 --- .../lwm2m/src/main/resources/models/3372.xml | 115 -- .../lwm2m/src/main/resources/models/3373.xml | 115 -- .../lwm2m/src/main/resources/models/3374.xml | 132 --- .../lwm2m/src/main/resources/models/3375.xml | 150 --- .../lwm2m/src/main/resources/models/3376.xml | 97 -- .../lwm2m/src/main/resources/models/3377.xml | 168 --- .../lwm2m/src/main/resources/models/3378.xml | 115 -- .../lwm2m/src/main/resources/models/3379.xml | 123 --- .../src/main/resources/models/3380-2_0.xml | 204 ---- .../lwm2m/src/main/resources/models/3381.xml | 110 -- .../lwm2m/src/main/resources/models/3382.xml | 108 -- .../lwm2m/src/main/resources/models/3383.xml | 99 -- .../lwm2m/src/main/resources/models/3384.xml | 112 -- .../lwm2m/src/main/resources/models/3385.xml | 110 -- .../lwm2m/src/main/resources/models/3386.xml | 105 -- .../LWM2M_APN_Connection_Profile-v1_0_1.xml | 324 ------ .../models/LWM2M_Bearer_Selection-v1_0_1.xml | 211 ---- .../LWM2M_Cellular_Connectivity-v1_0_1.xml | 185 ---- .../LWM2M_Connectivity_Monitoring-v1_0_2.xml | 208 ---- .../models/LWM2M_DevCapMgmt-v1_0.xml | 174 --- .../models/LWM2M_LOCKWIPE-v1_0_1.xml | 143 --- .../resources/models/LWM2M_Portfolio-v1_0.xml | 126 --- .../models/LWM2M_Software_Component-v1_0.xml | 139 --- .../models/LWM2M_Software_Management-v1_0.xml | 279 ----- .../models/LWM2M_WLAN_connectivity4-v1_0.xml | 572 ---------- .../LwM2M_BinaryAppDataContainer-v1_0_1.xml | 147 --- .../resources/models/LwM2M_EventLog-V1_0.xml | 145 --- .../mqtt/session/GatewayDeviceSessionCtx.java | 1 - common/transport/pom.xml | 1 - common/transport/transport-api/pom.xml | 6 - .../common/transport/SessionMsgListener.java | 3 - .../common/transport/TransportService.java | 13 - .../lwm2m/LwM2MTransportConfigBootstrap.java | 96 -- .../lwm2m/LwM2MTransportConfigServer.java | 241 ----- .../DefaultTransportDeviceProfileCache.java | 47 +- .../service/DefaultTransportService.java | 23 +- docker/.env | 1 - docker/docker-compose.aws-sqs.yml | 7 +- docker/docker-compose.confluent.yml | 3 - docker/docker-compose.kafka.yml | 5 - docker/docker-compose.postgres.volumes.yml | 6 - docker/docker-compose.pubsub.yml | 5 - docker/docker-compose.rabbitmq.yml | 7 +- docker/docker-compose.service-bus.yml | 5 +- docker/docker-compose.yml | 14 - docker/docker-create-log-folders.sh | 4 +- docker/tb-lwm2m-transport.env | 6 - docker/tb-transports/lwm2m/conf/logback.xml | 50 - .../lwm2m/conf/tb-lwm2m-transport.conf | 23 - k8s/common/thingsboard.yml | 66 -- .../server/msa/ThingsBoardDbInstaller.java | 10 +- msa/tb/README.md | 4 +- msa/tb/docker-cassandra/Dockerfile | 1 - msa/tb/docker-postgres/Dockerfile | 1 - msa/tb/docker-tb/Dockerfile | 1 - msa/transport/lwm2m/docker/Dockerfile | 33 - .../lwm2m/docker/start-tb-lwm2m-transport.sh | 33 - msa/transport/lwm2m/pom.xml | 190 ---- msa/transport/pom.xml | 1 - pom.xml | 67 +- ...eviceCredentialsUpdateNotificationMsg.java | 8 - transport/lwm2m/pom.xml | 163 --- transport/lwm2m/src/main/conf/logback.xml | 45 - .../src/main/conf/tb-lwm2m-transport.conf | 23 - .../main/data/credentials/serverKeyStore.jks | Bin 5716 -> 0 bytes .../lwm2m/src/main/data/models/10241.xml | 98 -- .../lwm2m/src/main/data/models/10242.xml | 647 ------------ .../lwm2m/src/main/data/models/10243.xml | 251 ----- .../lwm2m/src/main/data/models/10244.xml | 318 ------ .../lwm2m/src/main/data/models/10245.xml | 203 ---- .../lwm2m/src/main/data/models/10246.xml | 93 -- .../lwm2m/src/main/data/models/10247.xml | 83 -- .../lwm2m/src/main/data/models/10248.xml | 63 -- .../lwm2m/src/main/data/models/10249.xml | 123 --- .../lwm2m/src/main/data/models/10250.xml | 87 -- .../lwm2m/src/main/data/models/10251.xml | 83 -- .../lwm2m/src/main/data/models/10252.xml | 168 --- .../lwm2m/src/main/data/models/10253.xml | 57 - .../lwm2m/src/main/data/models/10254.xml | 123 --- .../lwm2m/src/main/data/models/10255.xml | 104 -- .../lwm2m/src/main/data/models/10256.xml | 134 --- .../lwm2m/src/main/data/models/10257.xml | 292 ----- .../lwm2m/src/main/data/models/10258.xml | 93 -- .../lwm2m/src/main/data/models/10259.xml | 100 -- .../lwm2m/src/main/data/models/10260-2_0.xml | 81 -- .../lwm2m/src/main/data/models/10262.xml | 72 -- .../lwm2m/src/main/data/models/10263.xml | 75 -- .../lwm2m/src/main/data/models/10264.xml | 102 -- .../lwm2m/src/main/data/models/10265.xml | 121 --- .../lwm2m/src/main/data/models/10266.xml | 229 ---- .../lwm2m/src/main/data/models/10267.xml | 229 ---- .../lwm2m/src/main/data/models/10268.xml | 229 ---- .../lwm2m/src/main/data/models/10269.xml | 229 ---- .../lwm2m/src/main/data/models/10270.xml | 229 ---- .../lwm2m/src/main/data/models/10271.xml | 229 ---- .../lwm2m/src/main/data/models/10272.xml | 215 ---- .../lwm2m/src/main/data/models/10273.xml | 215 ---- .../lwm2m/src/main/data/models/10274.xml | 215 ---- .../lwm2m/src/main/data/models/10275.xml | 215 ---- .../lwm2m/src/main/data/models/10276.xml | 215 ---- .../lwm2m/src/main/data/models/10277.xml | 215 ---- .../lwm2m/src/main/data/models/10278.xml | 215 ---- .../lwm2m/src/main/data/models/10279.xml | 215 ---- .../lwm2m/src/main/data/models/10280.xml | 215 ---- .../lwm2m/src/main/data/models/10281.xml | 215 ---- .../lwm2m/src/main/data/models/10282.xml | 215 ---- .../lwm2m/src/main/data/models/10283.xml | 215 ---- .../lwm2m/src/main/data/models/10284.xml | 215 ---- .../lwm2m/src/main/data/models/10286.xml | 65 -- .../lwm2m/src/main/data/models/10290.xml | 183 ---- .../lwm2m/src/main/data/models/10291.xml | 193 ---- .../lwm2m/src/main/data/models/10292.xml | 193 ---- .../lwm2m/src/main/data/models/10299.xml | 130 --- .../lwm2m/src/main/data/models/10300.xml | 142 --- .../lwm2m/src/main/data/models/10308-2_0.xml | 130 --- .../lwm2m/src/main/data/models/10309.xml | 114 -- .../lwm2m/src/main/data/models/10311.xml | 149 --- .../lwm2m/src/main/data/models/10313.xml | 238 ----- .../lwm2m/src/main/data/models/10314.xml | 113 -- .../lwm2m/src/main/data/models/10315.xml | 115 -- .../lwm2m/src/main/data/models/10316.xml | 219 ---- .../lwm2m/src/main/data/models/10318.xml | 175 --- .../lwm2m/src/main/data/models/10319.xml | 116 -- .../lwm2m/src/main/data/models/10320.xml | 127 --- .../lwm2m/src/main/data/models/10322.xml | 73 -- .../lwm2m/src/main/data/models/10323.xml | 76 -- .../lwm2m/src/main/data/models/10324.xml | 63 -- .../lwm2m/src/main/data/models/10326.xml | 708 ------------- .../lwm2m/src/main/data/models/10327.xml | 54 - .../lwm2m/src/main/data/models/10328.xml | 66 -- .../lwm2m/src/main/data/models/10329.xml | 419 -------- .../lwm2m/src/main/data/models/10330.xml | 106 -- .../lwm2m/src/main/data/models/10331.xml | 207 ---- .../lwm2m/src/main/data/models/10332.xml | 55 - .../lwm2m/src/main/data/models/10333.xml | 74 -- .../lwm2m/src/main/data/models/10334.xml | 115 -- .../lwm2m/src/main/data/models/10335.xml | 83 -- .../lwm2m/src/main/data/models/10336.xml | 70 -- .../lwm2m/src/main/data/models/10337.xml | 104 -- .../lwm2m/src/main/data/models/10338.xml | 110 -- .../lwm2m/src/main/data/models/10339.xml | 100 -- .../lwm2m/src/main/data/models/10340.xml | 204 ---- .../lwm2m/src/main/data/models/10341.xml | 70 -- .../lwm2m/src/main/data/models/10342.xml | 70 -- .../lwm2m/src/main/data/models/10343.xml | 82 -- .../lwm2m/src/main/data/models/10344.xml | 82 -- .../lwm2m/src/main/data/models/10345.xml | 82 -- .../lwm2m/src/main/data/models/10346.xml | 82 -- .../lwm2m/src/main/data/models/10347.xml | 140 --- .../lwm2m/src/main/data/models/10348.xml | 82 -- .../lwm2m/src/main/data/models/10349.xml | 70 -- .../lwm2m/src/main/data/models/10350.xml | 102 -- .../lwm2m/src/main/data/models/10351.xml | 65 -- .../lwm2m/src/main/data/models/10352.xml | 100 -- .../lwm2m/src/main/data/models/10353.xml | 73 -- .../lwm2m/src/main/data/models/10354.xml | 203 ---- .../lwm2m/src/main/data/models/10355.xml | 81 -- .../lwm2m/src/main/data/models/10356.xml | 189 ---- .../lwm2m/src/main/data/models/10357.xml | 81 -- .../lwm2m/src/main/data/models/10358.xml | 56 - .../lwm2m/src/main/data/models/10359.xml | 64 -- .../lwm2m/src/main/data/models/10360.xml | 56 - .../lwm2m/src/main/data/models/10361.xml | 78 -- .../lwm2m/src/main/data/models/10362.xml | 77 -- .../lwm2m/src/main/data/models/10363.xml | 43 - .../lwm2m/src/main/data/models/10364.xml | 43 - .../lwm2m/src/main/data/models/10365.xml | 43 - .../lwm2m/src/main/data/models/10366.xml | 45 - .../lwm2m/src/main/data/models/10368.xml | 82 -- .../lwm2m/src/main/data/models/10369.xml | 70 -- transport/lwm2m/src/main/data/models/2048.xml | 75 -- transport/lwm2m/src/main/data/models/2049.xml | 44 - transport/lwm2m/src/main/data/models/2050.xml | 49 - transport/lwm2m/src/main/data/models/2051.xml | 84 -- transport/lwm2m/src/main/data/models/2052.xml | 96 -- transport/lwm2m/src/main/data/models/2053.xml | 150 --- transport/lwm2m/src/main/data/models/2054.xml | 54 - transport/lwm2m/src/main/data/models/2055.xml | 85 -- transport/lwm2m/src/main/data/models/2056.xml | 62 -- transport/lwm2m/src/main/data/models/2057.xml | 77 -- .../lwm2m/src/main/data/models/31024.xml | 68 -- transport/lwm2m/src/main/data/models/3200.xml | 114 -- transport/lwm2m/src/main/data/models/3201.xml | 63 -- transport/lwm2m/src/main/data/models/3202.xml | 113 -- transport/lwm2m/src/main/data/models/3203.xml | 73 -- transport/lwm2m/src/main/data/models/3300.xml | 123 --- transport/lwm2m/src/main/data/models/3301.xml | 103 -- transport/lwm2m/src/main/data/models/3302.xml | 93 -- transport/lwm2m/src/main/data/models/3303.xml | 103 -- transport/lwm2m/src/main/data/models/3304.xml | 103 -- transport/lwm2m/src/main/data/models/3305.xml | 213 ---- transport/lwm2m/src/main/data/models/3306.xml | 83 -- transport/lwm2m/src/main/data/models/3308.xml | 73 -- transport/lwm2m/src/main/data/models/3310.xml | 93 -- transport/lwm2m/src/main/data/models/3311.xml | 113 -- transport/lwm2m/src/main/data/models/3312.xml | 93 -- transport/lwm2m/src/main/data/models/3313.xml | 93 -- transport/lwm2m/src/main/data/models/3314.xml | 83 -- transport/lwm2m/src/main/data/models/3315.xml | 103 -- transport/lwm2m/src/main/data/models/3316.xml | 124 --- transport/lwm2m/src/main/data/models/3317.xml | 124 --- transport/lwm2m/src/main/data/models/3318.xml | 124 --- transport/lwm2m/src/main/data/models/3319.xml | 124 --- transport/lwm2m/src/main/data/models/3320.xml | 124 --- transport/lwm2m/src/main/data/models/3321.xml | 124 --- transport/lwm2m/src/main/data/models/3322.xml | 124 --- transport/lwm2m/src/main/data/models/3323.xml | 124 --- transport/lwm2m/src/main/data/models/3324.xml | 124 --- transport/lwm2m/src/main/data/models/3325.xml | 124 --- transport/lwm2m/src/main/data/models/3326.xml | 124 --- transport/lwm2m/src/main/data/models/3327.xml | 124 --- transport/lwm2m/src/main/data/models/3328.xml | 124 --- transport/lwm2m/src/main/data/models/3329.xml | 124 --- transport/lwm2m/src/main/data/models/3330.xml | 124 --- transport/lwm2m/src/main/data/models/3331.xml | 74 -- transport/lwm2m/src/main/data/models/3332.xml | 84 -- transport/lwm2m/src/main/data/models/3333.xml | 64 -- transport/lwm2m/src/main/data/models/3334.xml | 174 --- transport/lwm2m/src/main/data/models/3335.xml | 64 -- transport/lwm2m/src/main/data/models/3336.xml | 104 -- transport/lwm2m/src/main/data/models/3337.xml | 124 --- transport/lwm2m/src/main/data/models/3338.xml | 84 -- transport/lwm2m/src/main/data/models/3339.xml | 83 -- transport/lwm2m/src/main/data/models/3340.xml | 144 --- transport/lwm2m/src/main/data/models/3341.xml | 124 --- transport/lwm2m/src/main/data/models/3342.xml | 83 -- transport/lwm2m/src/main/data/models/3343.xml | 74 -- transport/lwm2m/src/main/data/models/3344.xml | 84 -- transport/lwm2m/src/main/data/models/3345.xml | 94 -- transport/lwm2m/src/main/data/models/3346.xml | 124 --- transport/lwm2m/src/main/data/models/3347.xml | 64 -- transport/lwm2m/src/main/data/models/3348.xml | 54 - transport/lwm2m/src/main/data/models/3349.xml | 73 -- transport/lwm2m/src/main/data/models/3350.xml | 73 -- transport/lwm2m/src/main/data/models/3351.xml | 148 --- transport/lwm2m/src/main/data/models/3352.xml | 141 --- transport/lwm2m/src/main/data/models/3353.xml | 140 --- transport/lwm2m/src/main/data/models/3354.xml | 151 --- transport/lwm2m/src/main/data/models/3355.xml | 173 --- transport/lwm2m/src/main/data/models/3356.xml | 137 --- transport/lwm2m/src/main/data/models/3357.xml | 148 --- transport/lwm2m/src/main/data/models/3358.xml | 123 --- transport/lwm2m/src/main/data/models/3359.xml | 122 --- transport/lwm2m/src/main/data/models/3360.xml | 145 --- transport/lwm2m/src/main/data/models/3361.xml | 147 --- transport/lwm2m/src/main/data/models/3362.xml | 114 -- transport/lwm2m/src/main/data/models/3363.xml | 117 -- transport/lwm2m/src/main/data/models/3364.xml | 114 -- transport/lwm2m/src/main/data/models/3365.xml | 140 --- transport/lwm2m/src/main/data/models/3366.xml | 193 ---- transport/lwm2m/src/main/data/models/3367.xml | 155 --- transport/lwm2m/src/main/data/models/3368.xml | 117 -- transport/lwm2m/src/main/data/models/3369.xml | 122 --- transport/lwm2m/src/main/data/models/3370.xml | 158 --- transport/lwm2m/src/main/data/models/3371.xml | 158 --- transport/lwm2m/src/main/data/models/3372.xml | 132 --- transport/lwm2m/src/main/data/models/3373.xml | 132 --- transport/lwm2m/src/main/data/models/3374.xml | 149 --- transport/lwm2m/src/main/data/models/3375.xml | 167 --- transport/lwm2m/src/main/data/models/3376.xml | 114 -- transport/lwm2m/src/main/data/models/3377.xml | 185 ---- transport/lwm2m/src/main/data/models/3378.xml | 132 --- transport/lwm2m/src/main/data/models/3379.xml | 140 --- .../lwm2m/src/main/data/models/3380-2_0.xml | 221 ---- transport/lwm2m/src/main/data/models/3381.xml | 127 --- transport/lwm2m/src/main/data/models/3382.xml | 125 --- transport/lwm2m/src/main/data/models/3383.xml | 116 -- transport/lwm2m/src/main/data/models/3384.xml | 129 --- transport/lwm2m/src/main/data/models/3385.xml | 127 --- transport/lwm2m/src/main/data/models/3386.xml | 122 --- .../LWM2M_APN_Connection_Profile-v1_0_1.xml | 287 ----- .../models/LWM2M_Bearer_Selection-v1_0_1.xml | 174 --- .../LWM2M_Cellular_Connectivity-v1_0_1.xml | 146 --- .../LWM2M_Connectivity_Monitoring-v1_0_2.xml | 167 --- .../data/models/LWM2M_DevCapMgmt-v1_0.xml | 130 --- .../data/models/LWM2M_LOCKWIPE-v1_0_1.xml | 98 -- .../main/data/models/LWM2M_Portfolio-v1_0.xml | 81 -- .../models/LWM2M_Software_Component-v1_0.xml | 95 -- .../models/LWM2M_Software_Management-v1_0.xml | 235 ---- .../models/LWM2M_WLAN_connectivity4-v1_0.xml | 528 --------- .../LwM2M_BinaryAppDataContainer-v1_0_1.xml | 164 --- .../main/data/models/LwM2M_EventLog-V1_0.xml | 101 -- .../ThingsboardLwm2mTransportApplication.java | 48 - .../src/main/resources/tb-lwm2m-transport.yml | 301 ------ transport/pom.xml | 1 - .../app/core/http/device-profile.service.ts | 15 - .../device/device-credentials.component.html | 25 - .../device/device-credentials.component.ts | 51 +- .../home/components/home-components.module.ts | 9 +- .../device-profile-dialog.component.ts | 1 + ...ile-transport-configuration.component.html | 8 +- ...ile-transport-configuration.component.html | 26 +- ...ofile-transport-configuration.component.ts | 96 ++ .../lwm2m-device-config-server.component.html | 120 --- .../lwm2m-device-config-server.component.ts | 223 ---- ...ile-transport-configuration.component.html | 140 --- ...ofile-transport-configuration.component.ts | 541 ---------- ...m-object-add-instances-list.component.html | 57 - ...m-object-add-instances-list.component.scss | 22 - ...m2m-object-add-instances-list.component.ts | 179 ---- .../lwm2m-object-add-instances.component.html | 54 - .../lwm2m-object-add-instances.component.ts | 67 -- .../lwm2m/lwm2m-object-list.component.html | 56 - .../lwm2m/lwm2m-object-list.component.ts | 234 ---- ...rve-attr-telemetry-resource.component.html | 86 -- ...serve-attr-telemetry-resource.component.ts | 156 --- ...lwm2m-observe-attr-telemetry.component.css | 49 - ...wm2m-observe-attr-telemetry.component.html | 102 -- .../lwm2m-observe-attr-telemetry.component.ts | 352 ------ .../lwm2m/lwm2m-profile-components.module.ts | 55 - .../device/lwm2m/profile-config.models.ts | 212 ---- .../lib/gateway/gateway-form.component.html | 2 +- .../home/pages/device/device.module.ts | 7 +- .../security-config-server.component.html | 80 -- .../lwm2m/security-config-server.component.ts | 128 --- .../lwm2m/security-config.component.html | 160 --- .../device/lwm2m/security-config.component.ts | 384 ------- .../device/lwm2m/security-config.models.ts | 154 --- .../components/json-object-edit.component.ts | 16 +- ui-ngx/src/app/shared/models/device.models.ts | 26 +- .../assets/locale/locale.constant-en_US.json | 77 +- 574 files changed, 204 insertions(+), 70717 deletions(-) delete mode 100644 application/src/main/java/org/thingsboard/server/controller/DeviceLwm2mController.java delete mode 100644 application/src/main/java/org/thingsboard/server/service/lwm2m/LwM2MModelsRepository.java delete mode 100644 common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mInstance.java delete mode 100644 common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mObject.java delete mode 100644 common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mResource.java delete mode 100644 common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/ServerSecurityConfig.java delete mode 100644 common/transport/lwm2m/pom.xml delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerConfiguration.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerInitializer.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportContextBootstrap.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapConfig.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapSecurityStore.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapServers.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MInMemoryBootstrapConfigStore.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MServerBootstrap.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MSetSecurityStoreBootstrap.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2mDefaultBootstrapSessionManager.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LWM2MGenerationPSkRPkECC.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MGetSecurityInfo.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MSecurityMode.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2mRPkCredentials.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/ReadResultSecurityStore.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MSessionMsgListener.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportContextServer.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportHandler.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportRequest.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerConfiguration.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerInitializer.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportService.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2mServerListener.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/ResultIds.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MJsonAdaptor.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MTransportAdaptor.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/AttrTelemetryObserveValue.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/LwM2MClient.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ModelObject.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResourceValue.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResultsAnalyzerParameters.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2MSetSecurityStoreServer.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2mInMemorySecurityStore.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/LwM2mValueConverterImpl.java delete mode 100644 common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/TypeServer.java delete mode 100644 common/transport/lwm2m/src/main/resources/credentials/serverKeyStore.jks delete mode 100755 common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_credentials.sh delete mode 100644 common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_keygen.properties delete mode 100644 common/transport/lwm2m/src/main/resources/models/10241.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10242.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10243.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10244.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10245.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10246.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10247.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10248.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10249.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10250.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10251.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10252.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10253.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10254.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10255.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10256.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10257.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10258.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10259.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10260-2_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10262.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10263.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10264.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10265.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10266.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10267.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10268.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10269.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10270.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10271.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10272.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10273.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10274.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10275.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10276.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10277.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10278.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10279.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10280.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10281.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10282.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10283.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10284.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10286.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10290.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10291.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10292.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10299.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10300.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10308-2_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10309.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10311.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10313.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10314.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10315.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10316.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10318.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10319.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10320.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10322.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10323.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10324.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10326.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10327.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10328.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10329.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10330.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10331.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10332.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10333.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10334.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10335.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10336.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10337.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10338.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10339.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10340.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10341.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10342.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10343.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10344.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10345.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10346.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10347.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10348.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10349.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10350.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10351.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10352.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10353.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10354.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10355.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10356.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10357.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10358.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10359.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10360.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10361.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10362.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10363.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10364.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10365.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10366.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10368.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/10369.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2048.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2049.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2050.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2051.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2052.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2053.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2054.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2055.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2056.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/2057.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/31024.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3200.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3201.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3202.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3203.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3300.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3301.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3302.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3303.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3304.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3305.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3306.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3308.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3310.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3311.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3312.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3313.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3314.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3315.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3316.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3317.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3318.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3319.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3320.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3321.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3322.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3323.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3324.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3325.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3326.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3327.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3328.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3329.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3330.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3331.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3332.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3333.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3334.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3335.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3336.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3337.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3338.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3339.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3340.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3341.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3342.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3343.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3344.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3345.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3346.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3347.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3348.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3349.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3350.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3351.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3352.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3353.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3354.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3355.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3356.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3357.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3358.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3359.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3360.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3361.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3362.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3363.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3364.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3365.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3366.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3367.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3368.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3369.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3370.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3371.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3372.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3373.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3374.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3375.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3376.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3377.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3378.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3379.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3380-2_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3381.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3382.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3383.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3384.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3385.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/3386.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_APN_Connection_Profile-v1_0_1.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_Bearer_Selection-v1_0_1.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_Cellular_Connectivity-v1_0_1.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_DevCapMgmt-v1_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_LOCKWIPE-v1_0_1.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_Portfolio-v1_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Component-v1_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Management-v1_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LWM2M_WLAN_connectivity4-v1_0.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml delete mode 100644 common/transport/lwm2m/src/main/resources/models/LwM2M_EventLog-V1_0.xml delete mode 100644 common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigBootstrap.java delete mode 100644 common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigServer.java delete mode 100644 docker/tb-lwm2m-transport.env delete mode 100644 docker/tb-transports/lwm2m/conf/logback.xml delete mode 100644 docker/tb-transports/lwm2m/conf/tb-lwm2m-transport.conf delete mode 100644 msa/transport/lwm2m/docker/Dockerfile delete mode 100755 msa/transport/lwm2m/docker/start-tb-lwm2m-transport.sh delete mode 100644 msa/transport/lwm2m/pom.xml delete mode 100644 transport/lwm2m/pom.xml delete mode 100644 transport/lwm2m/src/main/conf/logback.xml delete mode 100644 transport/lwm2m/src/main/conf/tb-lwm2m-transport.conf delete mode 100644 transport/lwm2m/src/main/data/credentials/serverKeyStore.jks delete mode 100644 transport/lwm2m/src/main/data/models/10241.xml delete mode 100644 transport/lwm2m/src/main/data/models/10242.xml delete mode 100644 transport/lwm2m/src/main/data/models/10243.xml delete mode 100644 transport/lwm2m/src/main/data/models/10244.xml delete mode 100644 transport/lwm2m/src/main/data/models/10245.xml delete mode 100644 transport/lwm2m/src/main/data/models/10246.xml delete mode 100644 transport/lwm2m/src/main/data/models/10247.xml delete mode 100644 transport/lwm2m/src/main/data/models/10248.xml delete mode 100644 transport/lwm2m/src/main/data/models/10249.xml delete mode 100644 transport/lwm2m/src/main/data/models/10250.xml delete mode 100644 transport/lwm2m/src/main/data/models/10251.xml delete mode 100644 transport/lwm2m/src/main/data/models/10252.xml delete mode 100644 transport/lwm2m/src/main/data/models/10253.xml delete mode 100644 transport/lwm2m/src/main/data/models/10254.xml delete mode 100644 transport/lwm2m/src/main/data/models/10255.xml delete mode 100644 transport/lwm2m/src/main/data/models/10256.xml delete mode 100644 transport/lwm2m/src/main/data/models/10257.xml delete mode 100644 transport/lwm2m/src/main/data/models/10258.xml delete mode 100644 transport/lwm2m/src/main/data/models/10259.xml delete mode 100644 transport/lwm2m/src/main/data/models/10260-2_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/10262.xml delete mode 100644 transport/lwm2m/src/main/data/models/10263.xml delete mode 100644 transport/lwm2m/src/main/data/models/10264.xml delete mode 100644 transport/lwm2m/src/main/data/models/10265.xml delete mode 100644 transport/lwm2m/src/main/data/models/10266.xml delete mode 100644 transport/lwm2m/src/main/data/models/10267.xml delete mode 100644 transport/lwm2m/src/main/data/models/10268.xml delete mode 100644 transport/lwm2m/src/main/data/models/10269.xml delete mode 100644 transport/lwm2m/src/main/data/models/10270.xml delete mode 100644 transport/lwm2m/src/main/data/models/10271.xml delete mode 100644 transport/lwm2m/src/main/data/models/10272.xml delete mode 100644 transport/lwm2m/src/main/data/models/10273.xml delete mode 100644 transport/lwm2m/src/main/data/models/10274.xml delete mode 100644 transport/lwm2m/src/main/data/models/10275.xml delete mode 100644 transport/lwm2m/src/main/data/models/10276.xml delete mode 100644 transport/lwm2m/src/main/data/models/10277.xml delete mode 100644 transport/lwm2m/src/main/data/models/10278.xml delete mode 100644 transport/lwm2m/src/main/data/models/10279.xml delete mode 100644 transport/lwm2m/src/main/data/models/10280.xml delete mode 100644 transport/lwm2m/src/main/data/models/10281.xml delete mode 100644 transport/lwm2m/src/main/data/models/10282.xml delete mode 100644 transport/lwm2m/src/main/data/models/10283.xml delete mode 100644 transport/lwm2m/src/main/data/models/10284.xml delete mode 100644 transport/lwm2m/src/main/data/models/10286.xml delete mode 100644 transport/lwm2m/src/main/data/models/10290.xml delete mode 100644 transport/lwm2m/src/main/data/models/10291.xml delete mode 100644 transport/lwm2m/src/main/data/models/10292.xml delete mode 100644 transport/lwm2m/src/main/data/models/10299.xml delete mode 100644 transport/lwm2m/src/main/data/models/10300.xml delete mode 100644 transport/lwm2m/src/main/data/models/10308-2_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/10309.xml delete mode 100644 transport/lwm2m/src/main/data/models/10311.xml delete mode 100644 transport/lwm2m/src/main/data/models/10313.xml delete mode 100644 transport/lwm2m/src/main/data/models/10314.xml delete mode 100644 transport/lwm2m/src/main/data/models/10315.xml delete mode 100644 transport/lwm2m/src/main/data/models/10316.xml delete mode 100644 transport/lwm2m/src/main/data/models/10318.xml delete mode 100644 transport/lwm2m/src/main/data/models/10319.xml delete mode 100644 transport/lwm2m/src/main/data/models/10320.xml delete mode 100644 transport/lwm2m/src/main/data/models/10322.xml delete mode 100644 transport/lwm2m/src/main/data/models/10323.xml delete mode 100644 transport/lwm2m/src/main/data/models/10324.xml delete mode 100644 transport/lwm2m/src/main/data/models/10326.xml delete mode 100644 transport/lwm2m/src/main/data/models/10327.xml delete mode 100644 transport/lwm2m/src/main/data/models/10328.xml delete mode 100644 transport/lwm2m/src/main/data/models/10329.xml delete mode 100644 transport/lwm2m/src/main/data/models/10330.xml delete mode 100644 transport/lwm2m/src/main/data/models/10331.xml delete mode 100644 transport/lwm2m/src/main/data/models/10332.xml delete mode 100644 transport/lwm2m/src/main/data/models/10333.xml delete mode 100644 transport/lwm2m/src/main/data/models/10334.xml delete mode 100644 transport/lwm2m/src/main/data/models/10335.xml delete mode 100644 transport/lwm2m/src/main/data/models/10336.xml delete mode 100644 transport/lwm2m/src/main/data/models/10337.xml delete mode 100644 transport/lwm2m/src/main/data/models/10338.xml delete mode 100644 transport/lwm2m/src/main/data/models/10339.xml delete mode 100644 transport/lwm2m/src/main/data/models/10340.xml delete mode 100644 transport/lwm2m/src/main/data/models/10341.xml delete mode 100644 transport/lwm2m/src/main/data/models/10342.xml delete mode 100644 transport/lwm2m/src/main/data/models/10343.xml delete mode 100644 transport/lwm2m/src/main/data/models/10344.xml delete mode 100644 transport/lwm2m/src/main/data/models/10345.xml delete mode 100644 transport/lwm2m/src/main/data/models/10346.xml delete mode 100644 transport/lwm2m/src/main/data/models/10347.xml delete mode 100644 transport/lwm2m/src/main/data/models/10348.xml delete mode 100644 transport/lwm2m/src/main/data/models/10349.xml delete mode 100644 transport/lwm2m/src/main/data/models/10350.xml delete mode 100644 transport/lwm2m/src/main/data/models/10351.xml delete mode 100644 transport/lwm2m/src/main/data/models/10352.xml delete mode 100644 transport/lwm2m/src/main/data/models/10353.xml delete mode 100644 transport/lwm2m/src/main/data/models/10354.xml delete mode 100644 transport/lwm2m/src/main/data/models/10355.xml delete mode 100644 transport/lwm2m/src/main/data/models/10356.xml delete mode 100644 transport/lwm2m/src/main/data/models/10357.xml delete mode 100644 transport/lwm2m/src/main/data/models/10358.xml delete mode 100644 transport/lwm2m/src/main/data/models/10359.xml delete mode 100644 transport/lwm2m/src/main/data/models/10360.xml delete mode 100644 transport/lwm2m/src/main/data/models/10361.xml delete mode 100644 transport/lwm2m/src/main/data/models/10362.xml delete mode 100644 transport/lwm2m/src/main/data/models/10363.xml delete mode 100644 transport/lwm2m/src/main/data/models/10364.xml delete mode 100644 transport/lwm2m/src/main/data/models/10365.xml delete mode 100644 transport/lwm2m/src/main/data/models/10366.xml delete mode 100644 transport/lwm2m/src/main/data/models/10368.xml delete mode 100644 transport/lwm2m/src/main/data/models/10369.xml delete mode 100644 transport/lwm2m/src/main/data/models/2048.xml delete mode 100644 transport/lwm2m/src/main/data/models/2049.xml delete mode 100644 transport/lwm2m/src/main/data/models/2050.xml delete mode 100644 transport/lwm2m/src/main/data/models/2051.xml delete mode 100644 transport/lwm2m/src/main/data/models/2052.xml delete mode 100644 transport/lwm2m/src/main/data/models/2053.xml delete mode 100644 transport/lwm2m/src/main/data/models/2054.xml delete mode 100644 transport/lwm2m/src/main/data/models/2055.xml delete mode 100644 transport/lwm2m/src/main/data/models/2056.xml delete mode 100644 transport/lwm2m/src/main/data/models/2057.xml delete mode 100644 transport/lwm2m/src/main/data/models/31024.xml delete mode 100644 transport/lwm2m/src/main/data/models/3200.xml delete mode 100644 transport/lwm2m/src/main/data/models/3201.xml delete mode 100644 transport/lwm2m/src/main/data/models/3202.xml delete mode 100644 transport/lwm2m/src/main/data/models/3203.xml delete mode 100644 transport/lwm2m/src/main/data/models/3300.xml delete mode 100644 transport/lwm2m/src/main/data/models/3301.xml delete mode 100644 transport/lwm2m/src/main/data/models/3302.xml delete mode 100644 transport/lwm2m/src/main/data/models/3303.xml delete mode 100644 transport/lwm2m/src/main/data/models/3304.xml delete mode 100644 transport/lwm2m/src/main/data/models/3305.xml delete mode 100644 transport/lwm2m/src/main/data/models/3306.xml delete mode 100644 transport/lwm2m/src/main/data/models/3308.xml delete mode 100644 transport/lwm2m/src/main/data/models/3310.xml delete mode 100644 transport/lwm2m/src/main/data/models/3311.xml delete mode 100644 transport/lwm2m/src/main/data/models/3312.xml delete mode 100644 transport/lwm2m/src/main/data/models/3313.xml delete mode 100644 transport/lwm2m/src/main/data/models/3314.xml delete mode 100644 transport/lwm2m/src/main/data/models/3315.xml delete mode 100644 transport/lwm2m/src/main/data/models/3316.xml delete mode 100644 transport/lwm2m/src/main/data/models/3317.xml delete mode 100644 transport/lwm2m/src/main/data/models/3318.xml delete mode 100644 transport/lwm2m/src/main/data/models/3319.xml delete mode 100644 transport/lwm2m/src/main/data/models/3320.xml delete mode 100644 transport/lwm2m/src/main/data/models/3321.xml delete mode 100644 transport/lwm2m/src/main/data/models/3322.xml delete mode 100644 transport/lwm2m/src/main/data/models/3323.xml delete mode 100644 transport/lwm2m/src/main/data/models/3324.xml delete mode 100644 transport/lwm2m/src/main/data/models/3325.xml delete mode 100644 transport/lwm2m/src/main/data/models/3326.xml delete mode 100644 transport/lwm2m/src/main/data/models/3327.xml delete mode 100644 transport/lwm2m/src/main/data/models/3328.xml delete mode 100644 transport/lwm2m/src/main/data/models/3329.xml delete mode 100644 transport/lwm2m/src/main/data/models/3330.xml delete mode 100644 transport/lwm2m/src/main/data/models/3331.xml delete mode 100644 transport/lwm2m/src/main/data/models/3332.xml delete mode 100644 transport/lwm2m/src/main/data/models/3333.xml delete mode 100644 transport/lwm2m/src/main/data/models/3334.xml delete mode 100644 transport/lwm2m/src/main/data/models/3335.xml delete mode 100644 transport/lwm2m/src/main/data/models/3336.xml delete mode 100644 transport/lwm2m/src/main/data/models/3337.xml delete mode 100644 transport/lwm2m/src/main/data/models/3338.xml delete mode 100644 transport/lwm2m/src/main/data/models/3339.xml delete mode 100644 transport/lwm2m/src/main/data/models/3340.xml delete mode 100644 transport/lwm2m/src/main/data/models/3341.xml delete mode 100644 transport/lwm2m/src/main/data/models/3342.xml delete mode 100644 transport/lwm2m/src/main/data/models/3343.xml delete mode 100644 transport/lwm2m/src/main/data/models/3344.xml delete mode 100644 transport/lwm2m/src/main/data/models/3345.xml delete mode 100644 transport/lwm2m/src/main/data/models/3346.xml delete mode 100644 transport/lwm2m/src/main/data/models/3347.xml delete mode 100644 transport/lwm2m/src/main/data/models/3348.xml delete mode 100644 transport/lwm2m/src/main/data/models/3349.xml delete mode 100644 transport/lwm2m/src/main/data/models/3350.xml delete mode 100644 transport/lwm2m/src/main/data/models/3351.xml delete mode 100644 transport/lwm2m/src/main/data/models/3352.xml delete mode 100644 transport/lwm2m/src/main/data/models/3353.xml delete mode 100644 transport/lwm2m/src/main/data/models/3354.xml delete mode 100644 transport/lwm2m/src/main/data/models/3355.xml delete mode 100644 transport/lwm2m/src/main/data/models/3356.xml delete mode 100644 transport/lwm2m/src/main/data/models/3357.xml delete mode 100644 transport/lwm2m/src/main/data/models/3358.xml delete mode 100644 transport/lwm2m/src/main/data/models/3359.xml delete mode 100644 transport/lwm2m/src/main/data/models/3360.xml delete mode 100644 transport/lwm2m/src/main/data/models/3361.xml delete mode 100644 transport/lwm2m/src/main/data/models/3362.xml delete mode 100644 transport/lwm2m/src/main/data/models/3363.xml delete mode 100644 transport/lwm2m/src/main/data/models/3364.xml delete mode 100644 transport/lwm2m/src/main/data/models/3365.xml delete mode 100644 transport/lwm2m/src/main/data/models/3366.xml delete mode 100644 transport/lwm2m/src/main/data/models/3367.xml delete mode 100644 transport/lwm2m/src/main/data/models/3368.xml delete mode 100644 transport/lwm2m/src/main/data/models/3369.xml delete mode 100644 transport/lwm2m/src/main/data/models/3370.xml delete mode 100644 transport/lwm2m/src/main/data/models/3371.xml delete mode 100644 transport/lwm2m/src/main/data/models/3372.xml delete mode 100644 transport/lwm2m/src/main/data/models/3373.xml delete mode 100644 transport/lwm2m/src/main/data/models/3374.xml delete mode 100644 transport/lwm2m/src/main/data/models/3375.xml delete mode 100644 transport/lwm2m/src/main/data/models/3376.xml delete mode 100644 transport/lwm2m/src/main/data/models/3377.xml delete mode 100644 transport/lwm2m/src/main/data/models/3378.xml delete mode 100644 transport/lwm2m/src/main/data/models/3379.xml delete mode 100644 transport/lwm2m/src/main/data/models/3380-2_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/3381.xml delete mode 100644 transport/lwm2m/src/main/data/models/3382.xml delete mode 100644 transport/lwm2m/src/main/data/models/3383.xml delete mode 100644 transport/lwm2m/src/main/data/models/3384.xml delete mode 100644 transport/lwm2m/src/main/data/models/3385.xml delete mode 100644 transport/lwm2m/src/main/data/models/3386.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_APN_Connection_Profile-v1_0_1.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_Bearer_Selection-v1_0_1.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_Cellular_Connectivity-v1_0_1.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_DevCapMgmt-v1_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_LOCKWIPE-v1_0_1.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_Portfolio-v1_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_Software_Component-v1_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_Software_Management-v1_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/LWM2M_WLAN_connectivity4-v1_0.xml delete mode 100644 transport/lwm2m/src/main/data/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml delete mode 100644 transport/lwm2m/src/main/data/models/LwM2M_EventLog-V1_0.xml delete mode 100644 transport/lwm2m/src/main/java/org/thingsboard/server/lwm2m/ThingsboardLwm2mTransportApplication.java delete mode 100644 transport/lwm2m/src/main/resources/tb-lwm2m-transport.yml rename transport/lwm2m/src/main/resources/logback.xml => ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.html (52%) create mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.html delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.html delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.html delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.scss delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.html delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.html delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.html delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.css delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.html delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-profile-components.module.ts delete mode 100644 ui-ngx/src/app/modules/home/components/profile/device/lwm2m/profile-config.models.ts delete mode 100644 ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.html delete mode 100644 ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.ts delete mode 100644 ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.html delete mode 100644 ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.ts delete mode 100644 ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.models.ts diff --git a/application/pom.xml b/application/pom.xml index 8cff85df9e..8a12fe05bb 100644 --- a/application/pom.xml +++ b/application/pom.xml @@ -85,10 +85,6 @@ org.thingsboard.common.transport coap - - org.thingsboard.common.transport - lwm2m - org.thingsboard dao diff --git a/application/src/main/java/org/thingsboard/server/actors/device/DeviceActor.java b/application/src/main/java/org/thingsboard/server/actors/device/DeviceActor.java index 9299929276..feecef859f 100644 --- a/application/src/main/java/org/thingsboard/server/actors/device/DeviceActor.java +++ b/application/src/main/java/org/thingsboard/server/actors/device/DeviceActor.java @@ -62,7 +62,7 @@ public class DeviceActor extends ContextAwareActor { processor.processAttributesUpdate(ctx, (DeviceAttributesEventNotificationMsg) msg); break; case DEVICE_CREDENTIALS_UPDATE_TO_DEVICE_ACTOR_MSG: - processor.processCredentialsUpdate(msg); + processor.processCredentialsUpdate(); break; case DEVICE_NAME_OR_TYPE_UPDATE_TO_DEVICE_ACTOR_MSG: processor.processNameOrTypeUpdate((DeviceNameOrTypeUpdateMsg) msg); diff --git a/application/src/main/java/org/thingsboard/server/actors/device/DeviceActorMessageProcessor.java b/application/src/main/java/org/thingsboard/server/actors/device/DeviceActorMessageProcessor.java index 605e601368..cf4aa3edda 100644 --- a/application/src/main/java/org/thingsboard/server/actors/device/DeviceActorMessageProcessor.java +++ b/application/src/main/java/org/thingsboard/server/actors/device/DeviceActorMessageProcessor.java @@ -24,7 +24,6 @@ import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections.CollectionUtils; import org.thingsboard.rule.engine.api.RpcError; import org.thingsboard.rule.engine.api.msg.DeviceAttributesEventNotificationMsg; -import org.thingsboard.rule.engine.api.msg.DeviceCredentialsUpdateNotificationMsg; import org.thingsboard.rule.engine.api.msg.DeviceNameOrTypeUpdateMsg; import org.thingsboard.server.actors.ActorSystemContext; import org.thingsboard.server.actors.TbActorCtx; @@ -37,9 +36,6 @@ import org.thingsboard.server.common.data.kv.AttributeKey; import org.thingsboard.server.common.data.kv.AttributeKvEntry; import org.thingsboard.server.common.data.kv.KvEntry; import org.thingsboard.server.common.data.rpc.ToDeviceRpcRequestBody; -import org.thingsboard.server.common.data.security.DeviceCredentials; -import org.thingsboard.server.common.data.security.DeviceCredentialsType; -import org.thingsboard.server.common.msg.TbActorMsg; import org.thingsboard.server.common.msg.TbMsgMetaData; import org.thingsboard.server.common.msg.queue.TbCallback; import org.thingsboard.server.common.msg.rpc.ToDeviceRpcRequest; @@ -65,7 +61,6 @@ import org.thingsboard.server.gen.transport.TransportProtos.ToDeviceRpcResponseM import org.thingsboard.server.gen.transport.TransportProtos.ToServerRpcResponseMsg; import org.thingsboard.server.gen.transport.TransportProtos.ToTransportMsg; import org.thingsboard.server.gen.transport.TransportProtos.TransportToDeviceActorMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ToTransportUpdateCredentialsProto; import org.thingsboard.server.gen.transport.TransportProtos.TsKvProto; import org.thingsboard.server.service.rpc.FromDeviceRpcResponse; import org.thingsboard.server.service.rpc.ToDeviceRpcRequestActorMsg; @@ -455,19 +450,11 @@ class DeviceActorMessageProcessor extends AbstractContextAwareMsgProcessor { dumpSessions(); } - void processCredentialsUpdate(TbActorMsg msg) { - if (((DeviceCredentialsUpdateNotificationMsg) msg).getDeviceCredentials().getCredentialsType() == DeviceCredentialsType.LWM2M_CREDENTIALS) { - log.info("1) LwM2Mtype: "); - sessions.forEach((k, v) -> { - notifyTransportAboutProfileUpdate(k, v, ((DeviceCredentialsUpdateNotificationMsg) msg).getDeviceCredentials()); - }); - } else { - sessions.forEach(this::notifyTransportAboutClosedSession); - attributeSubscriptions.clear(); - rpcSubscriptions.clear(); - dumpSessions(); - - } + void processCredentialsUpdate() { + sessions.forEach(this::notifyTransportAboutClosedSession); + attributeSubscriptions.clear(); + rpcSubscriptions.clear(); + dumpSessions(); } private void notifyTransportAboutClosedSession(UUID sessionId, SessionInfoMetaData sessionMd) { @@ -478,18 +465,6 @@ class DeviceActorMessageProcessor extends AbstractContextAwareMsgProcessor { systemContext.getTbCoreToTransportService().process(sessionMd.getSessionInfo().getNodeId(), msg); } - void notifyTransportAboutProfileUpdate(UUID sessionId, SessionInfoMetaData sessionMd, DeviceCredentials deviceCredentials) { - log.info("2) LwM2Mtype: "); - TransportProtos.ToTransportUpdateCredentialsProto.Builder notification = TransportProtos.ToTransportUpdateCredentialsProto.newBuilder(); - notification.addCredentialsId(deviceCredentials.getCredentialsId()); - notification.addCredentialsValue(deviceCredentials.getCredentialsValue()); - ToTransportMsg msg = ToTransportMsg.newBuilder() - .setSessionIdMSB(sessionId.getMostSignificantBits()) - .setSessionIdLSB(sessionId.getLeastSignificantBits()) - .setToTransportUpdateCredentialsNotification(notification).build(); - systemContext.getTbCoreToTransportService().process(sessionMd.getSessionInfo().getNodeId(), msg); - } - void processNameOrTypeUpdate(DeviceNameOrTypeUpdateMsg msg) { this.deviceName = msg.getDeviceName(); this.deviceType = msg.getDeviceType(); diff --git a/application/src/main/java/org/thingsboard/server/controller/BaseController.java b/application/src/main/java/org/thingsboard/server/controller/BaseController.java index 945e1d4c83..869cbea127 100644 --- a/application/src/main/java/org/thingsboard/server/controller/BaseController.java +++ b/application/src/main/java/org/thingsboard/server/controller/BaseController.java @@ -92,7 +92,6 @@ import org.thingsboard.server.queue.discovery.PartitionService; import org.thingsboard.server.queue.provider.TbQueueProducerProvider; import org.thingsboard.server.queue.util.TbCoreComponent; import org.thingsboard.server.service.component.ComponentDiscoveryService; -import org.thingsboard.server.service.lwm2m.LwM2MModelsRepository; import org.thingsboard.server.service.profile.TbDeviceProfileCache; import org.thingsboard.server.dao.tenant.TbTenantProfileCache; import org.thingsboard.server.service.queue.TbClusterService; @@ -212,9 +211,6 @@ public abstract class BaseController { @Autowired protected TbDeviceProfileCache deviceProfileCache; - @Autowired - protected LwM2MModelsRepository lwM2MModelsRepository; - @Value("${server.log_controller_error_stack_trace}") @Getter private boolean logControllerErrorStackTrace; diff --git a/application/src/main/java/org/thingsboard/server/controller/DeviceController.java b/application/src/main/java/org/thingsboard/server/controller/DeviceController.java index e2db45884f..da5d705ef8 100644 --- a/application/src/main/java/org/thingsboard/server/controller/DeviceController.java +++ b/application/src/main/java/org/thingsboard/server/controller/DeviceController.java @@ -278,8 +278,9 @@ public class DeviceController extends BaseController { try { Device device = checkDeviceId(deviceCredentials.getDeviceId(), Operation.WRITE_CREDENTIALS); DeviceCredentials result = checkNotNull(deviceCredentialsService.updateDeviceCredentials(getCurrentUser().getTenantId(), deviceCredentials)); - //log.info("0 LwM2M CredentialsUpdate start) - tbClusterService.pushMsgToCore(new DeviceCredentialsUpdateNotificationMsg(getCurrentUser().getTenantId(), deviceCredentials.getDeviceId(), result), null); + + tbClusterService.pushMsgToCore(new DeviceCredentialsUpdateNotificationMsg(getCurrentUser().getTenantId(), deviceCredentials.getDeviceId()), null); + logEntityAction(device.getId(), device, device.getCustomerId(), ActionType.CREDENTIALS_UPDATED, null, deviceCredentials); diff --git a/application/src/main/java/org/thingsboard/server/controller/DeviceLwm2mController.java b/application/src/main/java/org/thingsboard/server/controller/DeviceLwm2mController.java deleted file mode 100644 index 76915fbed1..0000000000 --- a/application/src/main/java/org/thingsboard/server/controller/DeviceLwm2mController.java +++ /dev/null @@ -1,75 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.controller; - -import lombok.extern.slf4j.Slf4j; -import org.springframework.security.access.prepost.PreAuthorize; -import org.springframework.web.bind.annotation.*; -import org.thingsboard.server.common.data.exception.ThingsboardException; -import org.thingsboard.server.common.data.lwm2m.LwM2mObject; -import org.thingsboard.server.common.data.lwm2m.ServerSecurityConfig; -import org.thingsboard.server.common.data.page.PageData; -import org.thingsboard.server.common.data.page.PageLink; -import org.thingsboard.server.queue.util.TbCoreComponent; - -import java.util.List; - -@Slf4j -@RestController -@TbCoreComponent -@RequestMapping("/api") -public class DeviceLwm2mController extends BaseController { - - - @PreAuthorize("hasAnyAuthority('TENANT_ADMIN', 'CUSTOMER_USER')") - @RequestMapping(value = "/lwm2m/deviceProfile/{objectIds}", method = RequestMethod.GET) - @ResponseBody - public List getLwm2mListObjects(@PathVariable("objectIds") int[] objectIds) throws ThingsboardException { - try { - return lwM2MModelsRepository.getLwm2mObjects(objectIds, null); - } catch (Exception e) { - throw handleException(e); - } - } - - @PreAuthorize("hasAnyAuthority('TENANT_ADMIN', 'CUSTOMER_USER')") - @RequestMapping(value = "/lwm2m/deviceProfile/objects", params = {"pageSize", "page"}, method = RequestMethod.GET) - @ResponseBody - public PageData getLwm2mListObjects(@RequestParam int pageSize, - @RequestParam int page, - @RequestParam(required = false) String textSearch, - @RequestParam(required = false) String sortProperty, - @RequestParam(required = false) String sortOrder) throws ThingsboardException { - try { - PageLink pageLink = createPageLink(pageSize, page, textSearch, sortProperty, sortOrder); - return checkNotNull(lwM2MModelsRepository.findDeviceLwm2mObjects(getTenantId(), pageLink)); - } catch (Exception e) { - throw handleException(e); - } - } - - @PreAuthorize("hasAnyAuthority('TENANT_ADMIN', 'CUSTOMER_USER')") - @RequestMapping(value = "/lwm2m/deviceProfile/bootstrap/{securityMode}/{bootstrapServerIs}", method = RequestMethod.GET) - @ResponseBody - public ServerSecurityConfig getLwm2mBootstrapSecurityInfo(@PathVariable("securityMode") String securityMode, - @PathVariable("bootstrapServerIs") boolean bootstrapServerIs) throws ThingsboardException { - try { - return lwM2MModelsRepository.getBootstrapSecurityInfo(securityMode, bootstrapServerIs); - } catch (Exception e) { - throw handleException(e); - } - } -} diff --git a/application/src/main/java/org/thingsboard/server/service/lwm2m/LwM2MModelsRepository.java b/application/src/main/java/org/thingsboard/server/service/lwm2m/LwM2MModelsRepository.java deleted file mode 100644 index e314cd8f51..0000000000 --- a/application/src/main/java/org/thingsboard/server/service/lwm2m/LwM2MModelsRepository.java +++ /dev/null @@ -1,256 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.service.lwm2m; - - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.model.ObjectModel; -import org.eclipse.leshan.core.util.Hex; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.data.domain.PageImpl; -import org.springframework.stereotype.Service; -import org.thingsboard.server.common.data.lwm2m.*; -import org.thingsboard.server.common.data.id.TenantId; -import org.thingsboard.server.common.data.page.PageData; -import org.thingsboard.server.common.data.page.PageLink; -import org.thingsboard.server.common.transport.lwm2m.LwM2MTransportConfigBootstrap; -import org.thingsboard.server.common.transport.lwm2m.LwM2MTransportConfigServer; -import org.thingsboard.server.dao.service.Validator; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; - -import java.math.BigInteger; -import java.security.*; -import java.security.cert.CertificateEncodingException; -import java.security.cert.X509Certificate; -import java.security.spec.ECGenParameterSpec; -import java.security.spec.ECParameterSpec; -import java.security.spec.ECPublicKeySpec; -import java.security.spec.ECPoint; -import java.security.spec.KeySpec; -import java.util.List; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.util.stream.Collectors; -import java.util.stream.IntStream; - -import static org.thingsboard.server.dao.service.Validator.validateId; - -@Slf4j -@Service -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true') || '${service.type:null}'=='monolith' || '${service.type:null}'=='tb-core'") -public class LwM2MModelsRepository { - - private static final String INCORRECT_TENANT_ID = "Incorrect tenantId "; - - @Autowired - LwM2MTransportConfigServer contextServer; - - - @Autowired - LwM2MTransportConfigBootstrap contextBootStrap; - - /** - * @param objectIds - * @param textSearch - * @return list of LwM2mObject - * Filter by Predicate (uses objectIds, if objectIds is null then it uses textSearch, - * if textSearch is null then it uses AllList from List) - */ - public List getLwm2mObjects(int[] objectIds, String textSearch) { - return getLwm2mObjects((objectIds != null && objectIds.length > 0) ? - (ObjectModel element) -> IntStream.of(objectIds).anyMatch(x -> x == element.id) : - (textSearch != null && !textSearch.isEmpty()) ? (ObjectModel element) -> element.name.contains(textSearch) : null); - } - - /** - * @param predicate - * @return list of LwM2mObject - */ - private List getLwm2mObjects(Predicate predicate) { - List lwM2mObjects = new ArrayList<>(); - List listObjects = (predicate == null) ? this.contextServer.getModelsValue() : - contextServer.getModelsValue().stream() - .filter(predicate) - .collect(Collectors.toList()); - listObjects.forEach(obj -> { - LwM2mObject lwM2mObject = new LwM2mObject(); - lwM2mObject.setId(obj.id); - lwM2mObject.setName(obj.name); - lwM2mObject.setMultiple(obj.multiple); - lwM2mObject.setMandatory(obj.mandatory); - LwM2mInstance instance = new LwM2mInstance(); - instance.setId(0); - List resources = new ArrayList<>(); - obj.resources.forEach((k, v) -> { - if (!v.operations.isExecutable()) { - LwM2mResource resource = new LwM2mResource(k, v.name, false, false, false); - resources.add(resource); - } - }); - instance.setResources(resources.stream().toArray(LwM2mResource[]::new)); - lwM2mObject.setInstances(new LwM2mInstance[]{instance}); - lwM2mObjects.add(lwM2mObject); - }); - return lwM2mObjects; - } - - /** - * @param tenantId - * @param pageLink - * @return List of LwM2mObject in PageData format - */ - public PageData findDeviceLwm2mObjects(TenantId tenantId, PageLink pageLink) { - log.trace("Executing findDeviceProfileInfos tenantId [{}], pageLink [{}]", tenantId, pageLink); - validateId(tenantId, INCORRECT_TENANT_ID + tenantId); - Validator.validatePageLink(pageLink); - return this.findLwm2mListObjects(pageLink); - } - - /** - * @param pageLink - * @return List of LwM2mObject in PageData format, filter == TextSearch - * PageNumber = 1, PageSize = List.size() - */ - public PageData findLwm2mListObjects(PageLink pageLink) { - PageImpl page = new PageImpl(getLwm2mObjects(null, pageLink.getTextSearch())); - PageData pageData = new PageData(page.getContent(), page.getTotalPages(), page.getTotalElements(), page.hasNext()); - return pageData; - } - - /** - * - * @param securityMode - * @param bootstrapServerIs - * @return ServerSecurityConfig more value is default: Important - port, host, publicKey - */ - public ServerSecurityConfig getBootstrapSecurityInfo(String securityMode, boolean bootstrapServerIs) { - LwM2MSecurityMode lwM2MSecurityMode = LwM2MSecurityMode.fromSecurityMode(securityMode.toLowerCase()); - return getBootstrapServer(bootstrapServerIs, lwM2MSecurityMode); - } - - /** - * - * @param bootstrapServerIs - * @param mode - * @return ServerSecurityConfig more value is default: Important - port, host, publicKey - */ - private ServerSecurityConfig getBootstrapServer(boolean bootstrapServerIs, LwM2MSecurityMode mode) { - ServerSecurityConfig bsServ = new ServerSecurityConfig(); - if (bootstrapServerIs) { - switch (mode) { - case NO_SEC: - bsServ.setHost(contextBootStrap.getBootstrapHost()); - bsServ.setPort(contextBootStrap.getBootstrapPort()); - bsServ.setServerPublicKey(""); - break; - case PSK: - bsServ.setHost(contextBootStrap.getBootstrapSecureHost()); - bsServ.setPort(contextBootStrap.getBootstrapSecurePort()); - bsServ.setServerPublicKey(""); - break; - case RPK: - bsServ.setHost(contextBootStrap.getBootstrapSecureHost()); - bsServ.setPort(contextBootStrap.getBootstrapSecurePort()); - bsServ.setServerPublicKey(getRPKPublicKey(this.contextBootStrap.getBootstrapPublicX(), this.contextBootStrap.getBootstrapPublicY())); - break; - case X509: - bsServ.setHost(contextBootStrap.getBootstrapSecureHost()); - bsServ.setPort(contextBootStrap.getBootstrapSecurePortCert()); - bsServ.setServerPublicKey(getServerPublicKeyX509(contextBootStrap.getBootstrapAlias())); - break; - default: - break; - } - } else { - bsServ.setBootstrapServerIs(bootstrapServerIs); - bsServ.setServerId(123); - switch (mode) { - case NO_SEC: - bsServ.setHost(contextServer.getServerHost()); - bsServ.setPort(contextServer.getServerPort()); - bsServ.setServerPublicKey(""); - break; - case PSK: - bsServ.setHost(contextServer.getServerSecureHost()); - bsServ.setPort(contextServer.getServerSecurePort()); - bsServ.setServerPublicKey(""); - break; - case RPK: - bsServ.setHost(contextServer.getServerSecureHost()); - bsServ.setPort(contextServer.getServerSecurePort()); - bsServ.setServerPublicKey(getRPKPublicKey(this.contextServer.getServerPublicX(), this.contextServer.getServerPublicY())); - break; - case X509: - bsServ.setHost(contextServer.getServerSecureHost()); - bsServ.setPort(contextServer.getServerSecurePortCert()); - bsServ.setServerPublicKey(getServerPublicKeyX509(contextServer.getServerAlias())); - break; - default: - break; - } - } - return bsServ; - } - - /** - * - * @param alias - * @return PublicKey format HexString or null - */ - private String getServerPublicKeyX509 (String alias) { - try { - X509Certificate serverCertificate = (X509Certificate) contextServer.getKeyStoreValue().getCertificate(alias); - return Hex.encodeHexString(serverCertificate.getEncoded()); - } catch (CertificateEncodingException | KeyStoreException e) { - e.printStackTrace(); - } - return null; - } - - /** - * - * @param publicServerX - * @param publicServerY - * @return PublicKey format HexString or null - */ - private String getRPKPublicKey(String publicServerX, String publicServerY) { - try { - /** Get Elliptic Curve Parameter spec for secp256r1 */ - AlgorithmParameters algoParameters = AlgorithmParameters.getInstance("EC"); - algoParameters.init(new ECGenParameterSpec("secp256r1")); - ECParameterSpec parameterSpec = algoParameters.getParameterSpec(ECParameterSpec.class); - if (publicServerX != null && !publicServerX.isEmpty() && publicServerY != null && !publicServerY.isEmpty()) { - /** Get point values */ - byte[] publicX = Hex.decodeHex(publicServerX.toCharArray()); - byte[] publicY = Hex.decodeHex(publicServerY.toCharArray()); - /** Create key specs */ - KeySpec publicKeySpec = new ECPublicKeySpec(new ECPoint(new BigInteger(publicX), new BigInteger(publicY)), - parameterSpec); - /** Get keys */ - PublicKey publicKey = KeyFactory.getInstance("EC").generatePublic(publicKeySpec); - if (publicKey != null && publicKey.getEncoded().length > 0 ) { - return Hex.encodeHexString(publicKey.getEncoded()); - } - } - } catch (GeneralSecurityException | IllegalArgumentException e) { - log.error("[{}] Failed generate Server RPK for profile", e.getMessage()); - throw new RuntimeException(e); - } - return null; - } -} - diff --git a/application/src/main/java/org/thingsboard/server/service/security/device/DefaultDeviceAuthService.java b/application/src/main/java/org/thingsboard/server/service/security/device/DefaultDeviceAuthService.java index 27c7dce6ef..c13cb5529a 100644 --- a/application/src/main/java/org/thingsboard/server/service/security/device/DefaultDeviceAuthService.java +++ b/application/src/main/java/org/thingsboard/server/service/security/device/DefaultDeviceAuthService.java @@ -53,8 +53,6 @@ public class DefaultDeviceAuthService implements DeviceAuthService { return DeviceAuthResult.of(credentials.getDeviceId()); case X509_CERTIFICATE: return DeviceAuthResult.of(credentials.getDeviceId()); - case LWM2M_CREDENTIALS: - return DeviceAuthResult.of(credentials.getDeviceId()); default: return DeviceAuthResult.of("Credentials Type is not supported yet!"); } @@ -67,4 +65,4 @@ public class DefaultDeviceAuthService implements DeviceAuthService { } } -} +} \ No newline at end of file diff --git a/application/src/main/java/org/thingsboard/server/service/telemetry/DefaultTelemetrySubscriptionService.java b/application/src/main/java/org/thingsboard/server/service/telemetry/DefaultTelemetrySubscriptionService.java index c822880310..5b3ad05ee9 100644 --- a/application/src/main/java/org/thingsboard/server/service/telemetry/DefaultTelemetrySubscriptionService.java +++ b/application/src/main/java/org/thingsboard/server/service/telemetry/DefaultTelemetrySubscriptionService.java @@ -201,7 +201,6 @@ public class DefaultTelemetrySubscriptionService extends AbstractSubscriptionSer } @Override - public void saveAndNotify(TenantId tenantId, EntityId entityId, String scope, List attributes, FutureCallback callback) { saveAndNotify(tenantId, entityId, scope, attributes, true, callback); } diff --git a/application/src/main/java/org/thingsboard/server/service/transport/DefaultTransportApiService.java b/application/src/main/java/org/thingsboard/server/service/transport/DefaultTransportApiService.java index 0bdeaf360e..98f5708bad 100644 --- a/application/src/main/java/org/thingsboard/server/service/transport/DefaultTransportApiService.java +++ b/application/src/main/java/org/thingsboard/server/service/transport/DefaultTransportApiService.java @@ -69,7 +69,6 @@ import org.thingsboard.server.gen.transport.TransportProtos.TransportApiResponse import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceCredentialsResponseMsg; import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceTokenRequestMsg; import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceX509CertRequestMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceLwM2MCredentialsRequestMsg; import org.thingsboard.server.queue.common.TbProtoQueueMsg; import org.thingsboard.server.queue.util.TbCoreComponent; import org.thingsboard.server.dao.device.provision.ProvisionFailedException; @@ -150,13 +149,6 @@ public class DefaultTransportApiService implements TransportApiService { } else if (transportApiRequestMsg.hasEntityProfileRequestMsg()) { return Futures.transform(handle(transportApiRequestMsg.getEntityProfileRequestMsg()), value -> new TbProtoQueueMsg<>(tbProtoQueueMsg.getKey(), value, tbProtoQueueMsg.getHeaders()), MoreExecutors.directExecutor()); - } else if (transportApiRequestMsg.hasLwM2MRequestMsg()) { - return Futures.transform(handle(transportApiRequestMsg.getLwM2MRequestMsg()), - value -> new TbProtoQueueMsg<>(tbProtoQueueMsg.getKey(), value, tbProtoQueueMsg.getHeaders()), MoreExecutors.directExecutor()); - } else if (transportApiRequestMsg.hasValidateDeviceLwM2MCredentialsRequestMsg()) { - ValidateDeviceLwM2MCredentialsRequestMsg msg = transportApiRequestMsg.getValidateDeviceLwM2MCredentialsRequestMsg(); - return Futures.transform(validateCredentials(msg.getCredentialsId(), DeviceCredentialsType.LWM2M_CREDENTIALS), - value -> new TbProtoQueueMsg<>(tbProtoQueueMsg.getKey(), value, tbProtoQueueMsg.getHeaders()), MoreExecutors.directExecutor()); } else if (transportApiRequestMsg.hasProvisionDeviceRequestMsg()) { return Futures.transform(handle(transportApiRequestMsg.getProvisionDeviceRequestMsg()), value -> new TbProtoQueueMsg<>(tbProtoQueueMsg.getKey(), value, tbProtoQueueMsg.getHeaders()), MoreExecutors.directExecutor()); @@ -404,40 +396,4 @@ public class DefaultTransportApiService implements TransportApiService { return TransportApiResponseMsg.newBuilder() .setValidateCredResponseMsg(ValidateDeviceCredentialsResponseMsg.getDefaultInstance()).build(); } - - private ListenableFuture handle(TransportProtos.LwM2MRequestMsg requestMsg) { - if (requestMsg.hasRegistrationMsg()) { - return handleRegistration(requestMsg.getRegistrationMsg()); - } else { - return Futures.immediateFailedFuture(new RuntimeException("Not supported!")); - } - } - - private ListenableFuture handleRegistration(TransportProtos.LwM2MRegistrationRequestMsg msg) { - TenantId tenantId = new TenantId(UUID.fromString(msg.getTenantId())); - String deviceName = msg.getEndpoint(); - Lock deviceCreationLock = deviceCreationLocks.computeIfAbsent(deviceName, id -> new ReentrantLock()); - deviceCreationLock.lock(); - try { - Device device = deviceService.findDeviceByTenantIdAndName(tenantId, deviceName); - if (device == null) { - device = new Device(); - device.setTenantId(tenantId); - device.setName(deviceName); - device.setType("LwM2M"); - device = deviceService.saveDevice(device); - deviceStateService.onDeviceAdded(device); - } - TransportProtos.LwM2MRegistrationResponseMsg registrationResponseMsg = - TransportProtos.LwM2MRegistrationResponseMsg.newBuilder() - .setDeviceInfo(getDeviceInfoProto(device)).build(); - TransportProtos.LwM2MResponseMsg responseMsg = TransportProtos.LwM2MResponseMsg.newBuilder().setRegistrationMsg(registrationResponseMsg).build(); - return Futures.immediateFuture(TransportApiResponseMsg.newBuilder().setLwM2MResponseMsg(responseMsg).build()); - } catch (JsonProcessingException e) { - log.warn("[{}][{}] Failed to lookup device by gateway id and name", tenantId, deviceName, e); - throw new RuntimeException(e); - } finally { - deviceCreationLock.unlock(); - } - } } diff --git a/application/src/main/resources/banner.txt b/application/src/main/resources/banner.txt index 111465dd8a..791f878366 100644 --- a/application/src/main/resources/banner.txt +++ b/application/src/main/resources/banner.txt @@ -1,10 +1,3 @@ - ______ __ _ __ __ - /_ __/ / /_ (_) ____ ____ _ _____ / /_ ____ ____ _ _____ ____/ / - / / / __ \ / / / __ \ / __ `/ / ___/ / __ \ / __ \ / __ `/ / ___/ / __ / - / / / / / / / / / / / / / /_/ / (__ ) / /_/ // /_/ // /_/ / / / / /_/ / -/_/ /_/ /_/ /_/ /_/ /_/ \__, / /____/ /_.___/ \____/ \__,_/ /_/ \__,_/ - /____/ - =================================================== :: ${application.title} :: ${application.formatted-version} =================================================== diff --git a/application/src/main/resources/thingsboard.yml b/application/src/main/resources/thingsboard.yml index 2db0783f8b..c8ddbb6b82 100644 --- a/application/src/main/resources/thingsboard.yml +++ b/application/src/main/resources/thingsboard.yml @@ -433,7 +433,7 @@ spring: database-platform: "${SPRING_JPA_DATABASE_PLATFORM:org.hibernate.dialect.PostgreSQLDialect}" datasource: driverClassName: "${SPRING_DRIVER_CLASS_NAME:org.postgresql.Driver}" - url: "${SPRING_DATASOURCE_URL:jdbc:postgresql://localhost:5432/thingsboard_ce_3_2_2}" + url: "${SPRING_DATASOURCE_URL:jdbc:postgresql://localhost:5432/thingsboard}" username: "${SPRING_DATASOURCE_USERNAME:postgres}" password: "${SPRING_DATASOURCE_PASSWORD:postgres}" hikari: @@ -488,7 +488,7 @@ js: # Built-in JVM JavaScript environment properties local: # Use Sandboxed (secured) JVM JavaScript environment - use_js_sandbox: "${USE_LOCAL_JS_SANDBOX:false}" + use_js_sandbox: "${USE_LOCAL_JS_SANDBOX:true}" # Specify thread pool size for JavaScript sandbox resource monitor monitor_thread_pool_size: "${LOCAL_JS_SANDBOX_MONITOR_THREAD_POOL_SIZE:4}" # Maximum CPU time in milliseconds allowed for script execution @@ -565,74 +565,6 @@ transport: bind_address: "${COAP_BIND_ADDRESS:0.0.0.0}" bind_port: "${COAP_BIND_PORT:5683}" timeout: "${COAP_TIMEOUT:10000}" - # Local LwM2M transport parameters - lwm2m: - # Enable/disable lvm2m transport protocol. - enabled: "${LWM2M_ENABLED:true}" - # We choose a default timeout a bit higher to the MAX_TRANSMIT_WAIT(62-93s) which is the time from starting to - # send a Confirmable message to the time when an acknowledgement is no longer expected. - # DEFAULT_TIMEOUT = 2 * 60 * 1000l; 2 min in ms - timeout: "${LWM2M_TIMEOUT:120000}" -# model_path_file: "${LWM2M_MODEL_PATH_FILE:./common/transport/lwm2m/src/main/resources/models/}" - model_path_file: "${LWM2M_MODEL_PATH_FILE:}" - support_deprecated_ciphers_enable: "${LWM2M_SUPPORT_DEPRECATED_CIPHERS_ENABLED:true}" - secure: - # Only Certificate_x509: - # To get helps about files format and how to generate it, see: https://github.com/eclipse/leshan/wiki/Credential-files-format - # Create new X509 Certificates: common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_credentials.sh - key_store_type: "${LWM2M_KEYSTORE_TYPE:JKS}" - # key_store_type: "${LWM2M_KEYSTORE_TYPE:PKCS12}" -# key_store_path_file: "${KEY_STORE_PATH_FILE:/usr/share/thingsboard/conf/credentials/serverKeyStore.jks}" - key_store_path_file: "${KEY_STORE_PATH_FILE:}" - key_store_password: "${LWM2M_KEYSTORE_PASSWORD_SERVER:server_ks_password}" - root_alias: "${LWM2M_SERVER_ROOT_CA:rootca}" - enable_gen_psk_rpk: "${ENABLE_GEN_PSK_RPK:true}" - server: - bind_address: "${LWM2M_BIND_ADDRESS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT:5685}" - bind_port_cert: "${LWM2M_BIND_PORT_CERT:5687}" - secure: - start_all: "${START_SERVER_ALL:true}" - #leshan.core (V1_1) - #DTLS security modes: - #0: Pre-Shared Key mode - #1: Raw Public Key mode - #2: Certificate mode X509 - #3: NoSec mode * - #OMA-TS-LightweightM2M_Core-V1_1_1-20190617-A (add) - #4: Certificate mode X509 with EST - # If only startAll == false - dtls_mode: "${LWM2M_SECURITY_MODE:1}" - bind_address: "${LWM2M_BIND_ADDRESS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT_SEC:5686}" - bind_port_cert: "${LWM2M_BIND_PORT_SEC_CERT:5688}" - # Only RPK: Public & Private Key -# create_rpk: "${CREATE_RPK:}" - public_x: "${LWM2M_SERVER_PUBLIC_X:405354ea8893471d9296afbc8b020a5c6201b0bb25812a53b849d4480fa5f069}" - public_y: "${LWM2M_SERVER_PUBLIC_Y:30c9237e946a3a1692c1cafaa01a238a077f632c99371348337512363f28212b}" - private_s: "${LWM2M_SERVER_PRIVATE_S:274671fe40ce937b8a6352cf0a418e8a39e4bf0bb9bf74c910db953c20c73802}" - # Only Certificate_x509: - alias: "${LWM2M_KEYSTORE_ALIAS_SERVER:server}" - bootstrap: - enable: "${BOOTSTRAP:true}" - bind_address: "${LWM2M_BIND_ADDRESS_BS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT_BS:5689}" - bind_port_cert: "${LWM2M_BIND_PORT_SER_BS:5691}" - secure: - start_all: "${START_BOOTSTRAP_ALL:true}" - # If only startAll == false - dtls_mode: "${LWM2M_SECURITY_MODE_BS:1}" - bind_address: "${LWM2M_BIND_ADDRESS_BS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT_SEC_BS:5690}" - bind_port_cert: "${LWM2M_BIND_PORT_SEC_CERT_BS:5692}" - # Only RPK: Public & Private Key - public_x: "${LWM2M_SERVER_PUBLIC_X_BS:993ef2b698c6a9c0c1d8be78b13a9383c0854c7c7c7a504d289b403794648183}" - public_y: "${LWM2M_SERVER_PUBLIC_Y_BS:267412d5fc4e5ceb2257cb7fd7f76ebdac2fa9aa100afb162e990074cc0bfaa2}" - private_s: "${LWM2M_SERVER_PRIVATE_S_BS:9dbdbb073fc63570693a9aaf1013414e261c571f27e27fc6a8c1c2ad9347875a}" - # Only Certificate_x509: - alias: "${LWM2M_KEYSTORE_ALIAS_BOOTSTRAP:bootstrap}" - # Redis - redis_url: "${LWM2M_REDIS_URL:''}" swagger: api_path_regex: "${SWAGGER_API_PATH_REGEX:/api.*}" diff --git a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mInstance.java b/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mInstance.java deleted file mode 100644 index 4545e4dc0a..0000000000 --- a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mInstance.java +++ /dev/null @@ -1,25 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.common.data.lwm2m; - -import lombok.Data; - -@Data -public class LwM2mInstance { - int id; - LwM2mResource [] resources; - -} diff --git a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mObject.java b/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mObject.java deleted file mode 100644 index 4bd700fdf9..0000000000 --- a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mObject.java +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.common.data.lwm2m; - -import lombok.Data; - -@Data -public class LwM2mObject { - int id; - String name; - boolean multiple; - boolean mandatory; - LwM2mInstance [] instances; -} diff --git a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mResource.java b/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mResource.java deleted file mode 100644 index 7228f02760..0000000000 --- a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/LwM2mResource.java +++ /dev/null @@ -1,63 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.common.data.lwm2m; - -import lombok.AllArgsConstructor; -import lombok.Data; - -import java.util.stream.Stream; - -@Data -@AllArgsConstructor -public class LwM2mResource { - int id; - String name; - boolean observe; - boolean attribute; - boolean telemetry; - String keyName; - - public LwM2mResource(int id, String name, boolean observe, boolean attribute, boolean telemetry) { - this.id = id; - this.name = name; - this.observe = observe; - this.attribute = attribute; - this.telemetry = telemetry; - this.keyName = getCamelCase (this.name); - } - - private String getCamelCase (String name) { - name = name.replaceAll("-", " "); - name = name.replaceAll("_", " "); - String [] nameCamel1 = name.split(" "); - String [] nameCamel2 = new String[nameCamel1.length]; - int[] idx = { 0 }; - Stream.of(nameCamel1).forEach((s -> { - nameCamel2[idx[0]] = toProperCase(idx[0]++, s); - })); - return String.join("", nameCamel2); - } - - private String toProperCase(int idx, String s) { - if (!s.isEmpty() && s.length()> 0) { - String s1 = (idx == 0) ? s.substring(0, 1).toLowerCase() : s.substring(0, 1).toUpperCase(); - String s2 = ""; - if (s.length()> 1) s2 = s.substring(1).toLowerCase(); - s = s1 + s2; - } - return s; - } -} diff --git a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/ServerSecurityConfig.java b/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/ServerSecurityConfig.java deleted file mode 100644 index 3f7f1d543c..0000000000 --- a/common/data/src/main/java/org/thingsboard/server/common/data/lwm2m/ServerSecurityConfig.java +++ /dev/null @@ -1,34 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.common.data.lwm2m; - -import lombok.Builder; -import lombok.Data; - -@Data -public class ServerSecurityConfig { - String host; - Integer port; - String serverPublicKey; - @Builder.Default - boolean bootstrapServerIs = true; - @Builder.Default - Integer clientHoldOffTime = 1; - @Builder.Default - Integer serverId = 111; - @Builder.Default - Integer bootstrapServerAccountTimeout = 0; -} diff --git a/common/data/src/main/java/org/thingsboard/server/common/data/security/DeviceCredentialsType.java b/common/data/src/main/java/org/thingsboard/server/common/data/security/DeviceCredentialsType.java index 84a634a100..e7faf1b5ce 100644 --- a/common/data/src/main/java/org/thingsboard/server/common/data/security/DeviceCredentialsType.java +++ b/common/data/src/main/java/org/thingsboard/server/common/data/security/DeviceCredentialsType.java @@ -19,8 +19,6 @@ public enum DeviceCredentialsType { ACCESS_TOKEN, X509_CERTIFICATE, - MQTT_BASIC, - LWM2M_CREDENTIALS - + MQTT_BASIC } diff --git a/common/queue/src/main/proto/queue.proto b/common/queue/src/main/proto/queue.proto index 08a0d0ba97..325a517988 100644 --- a/common/queue/src/main/proto/queue.proto +++ b/common/queue/src/main/proto/queue.proto @@ -183,47 +183,6 @@ message GetEntityProfileRequestMsg { int64 entityIdLSB = 3; } -message LwM2MRegistrationRequestMsg { - string tenantId = 1; - string endpoint = 2; -} - -message LwM2MRegistrationResponseMsg { - DeviceInfoProto deviceInfo = 1; -} - -message LwM2MRequestMsg { - LwM2MRegistrationRequestMsg registrationMsg = 1; -} - -message LwM2MResponseMsg { - LwM2MRegistrationResponseMsg registrationMsg = 1; -} - -message ValidateDeviceLwM2MCredentialsRequestMsg { - string credentialsId = 1; -} - -message ToTransportUpdateCredentialsProto { - repeated string credentialsId = 1; - repeated string credentialsValue = 2; -} - -message GetTenantRoutingInfoRequestMsg { - int64 tenantIdMSB = 1; - int64 tenantIdLSB = 2; -} - -message GetTenantRoutingInfoResponseMsg { - bool isolatedTbCore = 1; - bool isolatedTbRuleEngine = 2; -} - -message GetDeviceProfileRequestMsg { - int64 profileIdMSB = 1; - int64 profileIdLSB = 2; -} - message GetEntityProfileResponseMsg { string entityType = 1; bytes data = 2; @@ -520,10 +479,8 @@ message TransportApiRequestMsg { ValidateDeviceX509CertRequestMsg validateX509CertRequestMsg = 2; GetOrCreateDeviceFromGatewayRequestMsg getOrCreateDeviceRequestMsg = 3; GetEntityProfileRequestMsg entityProfileRequestMsg = 4; - LwM2MRequestMsg lwM2MRequestMsg = 5; ValidateBasicMqttCredRequestMsg validateBasicMqttCredRequestMsg = 6; ProvisionDeviceRequestMsg provisionDeviceRequestMsg = 7; - ValidateDeviceLwM2MCredentialsRequestMsg validateDeviceLwM2MCredentialsRequestMsg = 8; } /* Response from ThingsBoard Core Service to Transport Service */ @@ -532,7 +489,6 @@ message TransportApiResponseMsg { GetOrCreateDeviceFromGatewayResponseMsg getOrCreateDeviceResponseMsg = 2; GetEntityProfileResponseMsg entityProfileResponseMsg = 3; ProvisionDeviceResponseMsg provisionDeviceResponseMsg = 4; - LwM2MResponseMsg lwM2MResponseMsg = 6; } /* Messages that are handled by ThingsBoard Core Service */ @@ -573,10 +529,10 @@ message ToTransportMsg { AttributeUpdateNotificationMsg attributeUpdateNotification = 5; ToDeviceRpcRequestMsg toDeviceRequest = 6; ToServerRpcResponseMsg toServerResponse = 7; + /* For Tenant, TenantProfile and DeviceProfile */ EntityUpdateMsg entityUpdateMsg = 8; EntityDeleteMsg entityDeleteMsg = 9; ProvisionDeviceResponseMsg provisionResponse = 10; - ToTransportUpdateCredentialsProto toTransportUpdateCredentialsNotification = 11; } message UsageStatsKVProto{ diff --git a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportContext.java b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportContext.java index 20e8cc7fdc..d69cc1b25a 100644 --- a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportContext.java +++ b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportContext.java @@ -24,7 +24,6 @@ import org.springframework.stereotype.Component; import org.thingsboard.server.common.transport.TransportContext; import org.thingsboard.server.transport.coap.adaptors.CoapTransportAdaptor; - /** * Created by ashvayka on 18.10.18. */ diff --git a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportResource.java b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportResource.java index 685a637dab..63af515c00 100644 --- a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportResource.java +++ b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportResource.java @@ -16,15 +16,14 @@ package org.thingsboard.server.transport.coap; import lombok.extern.slf4j.Slf4j; -import org.eclipse.californium.core.CoapObserveRelation; import org.eclipse.californium.core.CoapResource; -import org.eclipse.californium.core.coap.CoAP; import org.eclipse.californium.core.coap.CoAP.ResponseCode; import org.eclipse.californium.core.coap.Request; -import org.eclipse.californium.core.network.Endpoint; import org.eclipse.californium.core.network.Exchange; +import org.eclipse.californium.core.network.ExchangeObserver; import org.eclipse.californium.core.server.resources.CoapExchange; import org.eclipse.californium.core.server.resources.Resource; +import org.springframework.util.ReflectionUtils; import org.thingsboard.server.common.data.DataConstants; import org.thingsboard.server.common.data.DeviceTransportType; import org.thingsboard.server.common.data.security.DeviceTokenCredentials; @@ -41,26 +40,26 @@ import org.thingsboard.server.common.transport.auth.ValidateDeviceCredentialsRes import org.thingsboard.server.gen.transport.TransportProtos; import org.thingsboard.server.gen.transport.TransportProtos.ProvisionDeviceResponseMsg; +import java.lang.reflect.Field; import java.util.List; import java.util.Optional; import java.util.Set; import java.util.UUID; -import java.util.Timer; -import java.util.TimerTask; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.ScheduledThreadPoolExecutor; import java.util.concurrent.atomic.AtomicInteger; import java.util.function.Consumer; @Slf4j public class CoapTransportResource extends CoapResource { + // coap://localhost:port/api/v1/DEVICE_TOKEN/[attributes|telemetry|rpc[/requestId]] private static final int ACCESS_TOKEN_POSITION = 3; private static final int FEATURE_TYPE_POSITION = 4; private static final int REQUEST_ID_POSITION = 5; private final CoapTransportContext transportContext; private final TransportService transportService; + private final Field observerField; private final long timeout; private final ConcurrentMap tokenToSessionIdMap = new ConcurrentHashMap<>(); private final Set rpcSubscriptions = ConcurrentHashMap.newKeySet(); @@ -74,20 +73,9 @@ public class CoapTransportResource extends CoapResource { // This is important to turn off existing observable logic in // CoapResource. We will have our own observe monitoring due to 1:1 // observe relationship. - this.setObservable(true); // enable observing - this.setObserveType(CoAP.Type.CON); // configure the notification type to CONs - this.getAttributes().setObservable(); // mark observable in the Link-Format - // schedule a periodic update task, otherwise let events call changed() - Timer timer = new Timer(); - timer.schedule(new UpdateTask(), 0, 5000); - } - - private class UpdateTask extends TimerTask { - @Override - public void run() { - // .. periodic update of the resource - changed(); // notify all observers - } + this.setObservable(false); + observerField = ReflectionUtils.findField(Exchange.class, "observer"); + observerField.setAccessible(true); } @Override @@ -199,7 +187,9 @@ public class CoapTransportResource extends CoapResource { new CoapOkCallback(exchange)); break; case SUBSCRIBE_ATTRIBUTES_REQUEST: - transportService.registerSyncSession(sessionInfo, new CoapSessionListener(sessionId, exchange), transportContext.getTimeout()); + attributeSubscriptions.add(sessionId); + advanced.setObserver(new CoapExchangeObserverProxy((ExchangeObserver) observerField.get(advanced), + registerAsyncCoapSession(exchange, request, sessionInfo, sessionId))); transportService.process(sessionInfo, TransportProtos.SubscribeToAttributeUpdatesMsg.getDefaultInstance(), new CoapNoOpCallback(exchange)); @@ -216,6 +206,8 @@ public class CoapTransportResource extends CoapResource { break; case SUBSCRIBE_RPC_COMMANDS_REQUEST: rpcSubscriptions.add(sessionId); + advanced.setObserver(new CoapExchangeObserverProxy((ExchangeObserver) observerField.get(advanced), + registerAsyncCoapSession(exchange, request, sessionInfo, sessionId))); transportService.process(sessionInfo, TransportProtos.SubscribeToRPCMsg.getDefaultInstance(), new CoapNoOpCallback(exchange)); @@ -251,6 +243,9 @@ public class CoapTransportResource extends CoapResource { } catch (AdaptorException e) { log.trace("[{}] Failed to decode message: ", sessionId, e); exchange.respond(ResponseCode.BAD_REQUEST); + } catch (IllegalAccessException e) { + log.trace("[{}] Failed to process message: ", sessionId, e); + exchange.respond(ResponseCode.INTERNAL_SERVER_ERROR); } })); } @@ -464,17 +459,24 @@ public class CoapTransportResource extends CoapResource { } } - public class CoapExchangeObserverProxy extends CoapObserveRelation { - - /** - * Constructs a new CoapObserveRelation with the specified request. - * - * @param request the request - * @param endpoint the endpoint - * @param executor - */ - protected CoapExchangeObserverProxy(Request request, Endpoint endpoint, ScheduledThreadPoolExecutor executor) { - super(request, endpoint, executor); + public class CoapExchangeObserverProxy implements ExchangeObserver { + + private final ExchangeObserver proxy; + private final String token; + + CoapExchangeObserverProxy(ExchangeObserver proxy, String token) { + super(); + this.proxy = proxy; + this.token = token; + } + + @Override + public void completed(Exchange exchange) { + proxy.completed(exchange); + TransportProtos.SessionInfoProto session = tokenToSessionIdMap.remove(token); + if (session != null) { + closeAndDeregister(session); + } } } diff --git a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportService.java b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportService.java index ba99d1b703..a6813e488d 100644 --- a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportService.java +++ b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/CoapTransportService.java @@ -18,9 +18,8 @@ package org.thingsboard.server.transport.coap; import lombok.extern.slf4j.Slf4j; import org.eclipse.californium.core.CoapResource; import org.eclipse.californium.core.CoapServer; - import org.eclipse.californium.core.network.CoapEndpoint; -import org.eclipse.californium.core.network.CoapEndpoint.Builder; +import org.eclipse.californium.core.network.config.NetworkConfig; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; import org.springframework.stereotype.Service; @@ -48,15 +47,11 @@ public class CoapTransportService { public void init() throws UnknownHostException { log.info("Starting CoAP transport..."); log.info("Starting CoAP transport server"); - this.server = new CoapServer(); + this.server = new CoapServer(NetworkConfig.createStandardWithoutFile()); createResources(); InetAddress addr = InetAddress.getByName(coapTransportContext.getHost()); InetSocketAddress sockAddr = new InetSocketAddress(addr, coapTransportContext.getPort()); - Builder builder = new Builder(); - builder.setInetSocketAddress(sockAddr); - CoapEndpoint coapEndpoint = builder.build(); - - server.addEndpoint(coapEndpoint); + server.addEndpoint(new CoapEndpoint(sockAddr)); server.start(); log.info("CoAP transport started!"); } diff --git a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/adaptors/JsonCoapAdaptor.java b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/adaptors/JsonCoapAdaptor.java index ef01657a7f..28292f6c20 100644 --- a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/adaptors/JsonCoapAdaptor.java +++ b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/adaptors/JsonCoapAdaptor.java @@ -31,7 +31,6 @@ import org.thingsboard.server.common.transport.adaptor.JsonConverter; import org.thingsboard.server.gen.transport.TransportProtos; import org.thingsboard.server.transport.coap.CoapTransportResource; - import java.util.Arrays; import java.util.HashSet; import java.util.List; diff --git a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/client/DeviceEmulator.java b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/client/DeviceEmulator.java index e0347330fd..ffc62280ec 100644 --- a/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/client/DeviceEmulator.java +++ b/common/transport/coap/src/main/java/org/thingsboard/server/transport/coap/client/DeviceEmulator.java @@ -28,7 +28,6 @@ import org.eclipse.californium.core.CoapClient; import org.eclipse.californium.core.CoapHandler; import org.eclipse.californium.core.CoapResponse; import org.eclipse.californium.core.coap.MediaTypeRegistry; -import org.eclipse.californium.elements.exception.ConnectorException; import org.thingsboard.server.common.msg.session.FeatureType; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -62,7 +61,7 @@ public class DeviceEmulator { this.attributesClient = new CoapClient(getFeatureTokenUrl(host, port, token, FeatureType.ATTRIBUTES)); this.telemetryClient = new CoapClient(getFeatureTokenUrl(host, port, token, FeatureType.TELEMETRY)); this.rpcClient = new CoapClient(getFeatureTokenUrl(host, port, token, FeatureType.RPC)); - this.keys = (keys != null && !keys.isEmpty()) ? keys.split(",") : null; + this.keys = keys.split(","); } public void start() { @@ -73,8 +72,11 @@ public class DeviceEmulator { try { sendObserveRequest(rpcClient); while (!Thread.interrupted()) { + + sendRequest(attributesClient, createAttributesRequest()); sendRequest(telemetryClient, createTelemetryRequest()); + Thread.sleep(1000); } } catch (Exception e) { @@ -82,8 +84,8 @@ public class DeviceEmulator { } } - private void sendRequest(CoapClient client, JsonNode request) throws IOException, ConnectorException { - CoapResponse telemetryResponse = client.setTimeout((long) 60000).post(mapper.writeValueAsString(request), + private void sendRequest(CoapClient client, JsonNode request) throws JsonProcessingException { + CoapResponse telemetryResponse = client.setTimeout(60000).post(mapper.writeValueAsString(request), MediaTypeRegistry.APPLICATION_JSON); log.info("Response: {}, {}", telemetryResponse.getCode(), telemetryResponse.getResponseText()); } @@ -111,7 +113,6 @@ public class DeviceEmulator { @Override public void onError() { - log.info("Command Response Ack Error, No connect"); //Do nothing } }, mapper.writeValueAsString(response), MediaTypeRegistry.APPLICATION_JSON); @@ -156,15 +157,6 @@ public class DeviceEmulator { if (args.length != 4) { System.out.println("Usage: java -jar " + DeviceEmulator.class.getSimpleName() + ".jar host port device_token keys"); } - /** - * DeviceEmulator(String host, int port, String token, String keys) - * args[]: - * host = "localhost", - * port = 0, - * token = "{Tokrn device from thingboard}"), kSzbDRGwaZqZ6Y25gTLF - * keys = "{Telemetry}" - * - */ final DeviceEmulator emulator = new DeviceEmulator(args[0], Integer.parseInt(args[1]), args[2], args[3]); emulator.start(); Runtime.getRuntime().addShutdownHook(new Thread() { @@ -175,6 +167,7 @@ public class DeviceEmulator { }); } + private String getFeatureTokenUrl(String host, int port, String token, FeatureType featureType) { return getBaseUrl(host, port) + token + "/" + featureType.name().toLowerCase(); } diff --git a/common/transport/http/src/main/java/org/thingsboard/server/transport/http/DeviceApiController.java b/common/transport/http/src/main/java/org/thingsboard/server/transport/http/DeviceApiController.java index 600e7033ab..cdc2791839 100644 --- a/common/transport/http/src/main/java/org/thingsboard/server/transport/http/DeviceApiController.java +++ b/common/transport/http/src/main/java/org/thingsboard/server/transport/http/DeviceApiController.java @@ -327,7 +327,6 @@ public class DeviceApiController { public void onToServerRpcResponse(ToServerRpcResponseMsg msg) { responseWriter.setResult(new ResponseEntity<>(JsonConverter.toJson(msg).toString(), HttpStatus.OK)); } - } private void reportActivity(SessionInfoProto sessionInfo) { diff --git a/common/transport/lwm2m/pom.xml b/common/transport/lwm2m/pom.xml deleted file mode 100644 index 0e9d3d58cd..0000000000 --- a/common/transport/lwm2m/pom.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - - 4.0.0 - - org.thingsboard.common - 3.2.0-SNAPSHOT - transport - - org.thingsboard.common.transport - lwm2m - jar - - Thingsboard LwM2M Transport Common - https://thingsboard.io - - - UTF-8 - ${basedir}/../../.. - - - - - org.thingsboard.common.transport - transport-api - - - org.springframework - spring-context-support - - - org.springframework - spring-context - - - org.slf4j - slf4j-api - - - org.slf4j - log4j-over-slf4j - - - ch.qos.logback - logback-core - - - ch.qos.logback - logback-classic - - - - org.eclipse.leshan - leshan-server-cf - - - - - - - org.eclipse.leshan - leshan-client-cf - - - - org.eclipse.leshan - leshan-server-redis - - - - - - - - - org.springframework.boot - spring-boot-starter-test - test - - - junit - junit - test - - - org.mockito - mockito-all - test - - - org.eclipse.californium - californium-core - ${californium.version} - test-jar - test - - - org.eclipse.californium - element-connector - ${californium.version} - test-jar - test - - - - diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerConfiguration.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerConfiguration.java deleted file mode 100644 index a1f056ff30..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerConfiguration.java +++ /dev/null @@ -1,101 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.californium.scandium.config.DtlsConnectorConfig; -import org.eclipse.leshan.core.model.StaticModel; -import org.eclipse.leshan.server.bootstrap.BootstrapSessionManager; -import org.eclipse.leshan.server.californium.bootstrap.LeshanBootstrapServer; -import org.eclipse.leshan.server.californium.bootstrap.LeshanBootstrapServerBuilder; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.Primary; -import org.springframework.stereotype.Component; -import org.thingsboard.server.transport.lwm2m.bootstrap.secure.LwM2MBootstrapSecurityStore; -import org.thingsboard.server.transport.lwm2m.bootstrap.secure.LwM2MInMemoryBootstrapConfigStore; -import org.thingsboard.server.transport.lwm2m.bootstrap.secure.LwM2MSetSecurityStoreBootstrap; -import org.thingsboard.server.transport.lwm2m.bootstrap.secure.LwM2mDefaultBootstrapSessionManager; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; -import org.thingsboard.server.transport.lwm2m.server.LwM2MTransportContextServer; -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.X509; -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.RPK; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.getCoapConfig; - -@Slf4j -@Component -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true'&& '${transport.lwm2m.bootstrap.enable:false}'=='true') || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true'&& '${transport.lwm2m.bootstrap.enable}'=='true')") -public class LwM2MTransportBootstrapServerConfiguration { - - @Autowired - private LwM2MTransportContextBootstrap contextBs; - - @Autowired - private LwM2MTransportContextServer contextS; - - @Autowired - private LwM2MBootstrapSecurityStore lwM2MBootstrapSecurityStore; - - @Autowired - private LwM2MInMemoryBootstrapConfigStore lwM2MInMemoryBootstrapConfigStore; - - - @Primary - @Bean(name = "leshanBootstrapCert") - public LeshanBootstrapServer getLeshanBootstrapServerCert() { - log.info("Prepare and start BootstrapServerCert... PostConstruct"); - return getLeshanBootstrapServer(this.contextBs.getCtxBootStrap().getBootstrapPortCert(), this.contextBs.getCtxBootStrap().getBootstrapSecurePortCert(), X509); - } - - @Bean(name = "leshanBootstrapRPK") - public LeshanBootstrapServer getLeshanBootstrapServerRPK() { - log.info("Prepare and start BootstrapServerRPK... PostConstruct"); - return getLeshanBootstrapServer(this.contextBs.getCtxBootStrap().getBootstrapPort(), this.contextBs.getCtxBootStrap().getBootstrapSecurePort(), RPK); - } - - public LeshanBootstrapServer getLeshanBootstrapServer(Integer bootstrapPort, Integer bootstrapSecurePort, LwM2MSecurityMode dtlsMode) { - LeshanBootstrapServerBuilder builder = new LeshanBootstrapServerBuilder(); - builder.setLocalAddress(this.contextBs.getCtxBootStrap().getBootstrapHost(), bootstrapPort); - builder.setLocalSecureAddress(this.contextBs.getCtxBootStrap().getBootstrapSecureHost(), bootstrapSecurePort); - - /** Create CoAP Config */ - builder.setCoapConfig(getCoapConfig ()); - - /** ConfigStore */ - builder.setConfigStore(lwM2MInMemoryBootstrapConfigStore); - - /** SecurityStore */ - builder.setSecurityStore(lwM2MBootstrapSecurityStore); - - /** Define model provider (Create Models )*/ - builder.setModel(new StaticModel(contextS.getCtxServer().getModelsValue())); - - /** Create and Set DTLS Config */ - DtlsConnectorConfig.Builder dtlsConfig = new DtlsConnectorConfig.Builder(); - dtlsConfig.setRecommendedCipherSuitesOnly(contextS.getCtxServer().isSupportDeprecatedCiphersEnable()); - builder.setDtlsConfig(dtlsConfig); - - /** Create credentials */ - new LwM2MSetSecurityStoreBootstrap(builder, contextBs, contextS, dtlsMode); - - BootstrapSessionManager sessionManager = new LwM2mDefaultBootstrapSessionManager(lwM2MBootstrapSecurityStore); - builder.setSessionManager(sessionManager); - - /** Create BootstrapServer */ - return builder.build(); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerInitializer.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerInitializer.java deleted file mode 100644 index cb927a76b9..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportBootstrapServerInitializer.java +++ /dev/null @@ -1,70 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.server.californium.bootstrap.LeshanBootstrapServer; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.beans.factory.annotation.Qualifier; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Service; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; - -import javax.annotation.PostConstruct; -import javax.annotation.PreDestroy; - -@Slf4j -@Service -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled}'=='true'&& '${transport.lwm2m.bootstrap.enable}'=='true') || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true'&& '${transport.lwm2m.bootstrap.enable}'=='true')") -public class LwM2MTransportBootstrapServerInitializer { - - @Autowired - @Qualifier("leshanBootstrapCert") - private LeshanBootstrapServer lhBServerCert; - - @Autowired - @Qualifier("leshanBootstrapRPK") - private LeshanBootstrapServer lhBServerRPK; - - @Autowired - private LwM2MTransportContextBootstrap contextBS; - - @PostConstruct - public void init() { - if (this.contextBS.getCtxBootStrap().isBootstrapStartAll()) { - this.lhBServerCert.start(); - this.lhBServerRPK.start(); - } - else { - if (this.contextBS.getCtxBootStrap().getBootStrapDtlsMode() == LwM2MSecurityMode.X509.code) { - this.lhBServerCert.start(); - } - else { - this.lhBServerRPK.start(); - } - } - } - - @PreDestroy - public void shutdown() throws InterruptedException { - log.info("Stopping LwM2M transport Bootstrap Server!"); - try { - lhBServerCert.destroy(); - lhBServerRPK.destroy(); - } finally { - } - log.info("LwM2M transport Bootstrap Server stopped!"); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportContextBootstrap.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportContextBootstrap.java deleted file mode 100644 index 041a6f2040..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/LwM2MTransportContextBootstrap.java +++ /dev/null @@ -1,60 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap; -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import lombok.extern.slf4j.Slf4j; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.common.transport.TransportContext; -import org.thingsboard.server.common.transport.lwm2m.LwM2MTransportConfigBootstrap; - -import javax.annotation.PostConstruct; - - -@Slf4j -@Component -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true') || '${service.type:null}'=='monolith'") -public class LwM2MTransportContextBootstrap extends TransportContext { - - private LwM2MTransportConfigBootstrap ctxBootStrap; - @Autowired - LwM2MTransportConfigBootstrap lwM2MTransportConfigBootstarp; - - @PostConstruct - public void init() { - this.ctxBootStrap = lwM2MTransportConfigBootstarp; - } - - public LwM2MTransportConfigBootstrap getCtxBootStrap() { - return this.ctxBootStrap; - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapConfig.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapConfig.java deleted file mode 100644 index 51d37ad90e..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapConfig.java +++ /dev/null @@ -1,102 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap.secure; - -import lombok.Builder; -import lombok.Data; -import org.eclipse.leshan.core.SecurityMode; -import org.eclipse.leshan.core.request.BindingMode; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.server.bootstrap.BootstrapConfig; - -import java.nio.charset.StandardCharsets; - -@Data -public class LwM2MBootstrapConfig { - /** - * interface BootstrapSecurityConfig - * servers: BootstrapServersSecurityConfig, - * bootstrapServer: ServerSecurityConfig, - * lwm2mServer: ServerSecurityConfig - * } - */ - /** -servers - * shortId: number, - * lifetime: number, - * defaultMinPeriod: number, - * notifIfDisabled: boolean, - * binding: string - * */ - @Builder.Default - LwM2MBootstrapServers servers; - - /** -bootstrapServer, lwm2mServer - * interface ServerSecurityConfig - * host?: string, - * port?: number, - * isBootstrapServer?: boolean, - * securityMode: string, - * clientPublicKeyOrId?: string, - * clientSecretKey?: string, - * serverPublicKey?: string; - * clientHoldOffTime?: number, - * serverId?: number, - * bootstrapServerAccountTimeout: number - * */ - LwM2MServerBootstrap bootstrapServer; - - LwM2MServerBootstrap lwm2mServer; - - public BootstrapConfig getLwM2MBootstrapConfig() { - BootstrapConfig configBs = new BootstrapConfig(); - /** Delete old security objects */ - configBs.toDelete.add("/0"); - configBs.toDelete.add("/1"); - /** Server Configuration (object 1) as defined in LWM2M 1.0.x TS. */ - BootstrapConfig.ServerConfig server0 = new BootstrapConfig.ServerConfig(); - server0.shortId = servers.getShortId(); - server0.lifetime = servers.getLifetime(); - server0.defaultMinPeriod = servers.getDefaultMinPeriod(); - server0.notifIfDisabled = servers.isNotifIfDisabled(); - server0.binding = BindingMode.valueOf(servers.getBinding()); - configBs.servers.put(0, server0); - /** Security Configuration (object 0) as defined in LWM2M 1.0.x TS. Bootstrap instance = 0 */ - this.bootstrapServer.setBootstrapServerIs(true); - configBs.security.put(0, setServerSecuruty(this.bootstrapServer.getHost(), this.bootstrapServer.getPort(), this.bootstrapServer.isBootstrapServerIs(), this.bootstrapServer.getSecurityMode(), this.bootstrapServer.getClientPublicKeyOrId(), this.bootstrapServer.getServerPublicKey(), this.bootstrapServer.getClientSecretKey(), this.bootstrapServer.getServerId())); - /** Security Configuration (object 0) as defined in LWM2M 1.0.x TS. Server instance = 1 */ - configBs.security.put(1, setServerSecuruty(this.lwm2mServer.getHost(), this.lwm2mServer.getPort(), this.lwm2mServer.isBootstrapServerIs(), this.lwm2mServer.getSecurityMode(), this.lwm2mServer.getClientPublicKeyOrId(), this.lwm2mServer.getServerPublicKey(), this.lwm2mServer.getClientSecretKey(), this.lwm2mServer.getServerId())); - return configBs; - } - - private BootstrapConfig.ServerSecurity setServerSecuruty(String host, Integer port, boolean bootstrapServer, String securityMode, String clientPublicKey, String serverPublicKey, String secretKey, int serverId) { - BootstrapConfig.ServerSecurity serverSecurity = new BootstrapConfig.ServerSecurity(); - serverSecurity.uri = "coaps://" + host + ":" + Integer.toString(port); - serverSecurity.bootstrapServer = bootstrapServer; - serverSecurity.securityMode = SecurityMode.valueOf(securityMode); - serverSecurity.publicKeyOrId = setPublicKeyOrId(clientPublicKey, securityMode); - serverSecurity.serverPublicKey = (serverPublicKey != null && !serverPublicKey.isEmpty()) ? Hex.decodeHex(serverPublicKey.toCharArray()) : new byte[]{}; - serverSecurity.secretKey = (secretKey != null && !secretKey.isEmpty()) ? Hex.decodeHex(secretKey.toCharArray()) : new byte[]{}; - serverSecurity.serverId = serverId; - return serverSecurity; - } - - private byte[] setPublicKeyOrId(String publicKeyOrIdStr, String securityMode) { - byte[] publicKey = (publicKeyOrIdStr == null || publicKeyOrIdStr.isEmpty()) ? new byte[]{} : - SecurityMode.valueOf(securityMode).equals(SecurityMode.PSK) ? publicKeyOrIdStr.getBytes(StandardCharsets.UTF_8) : - Hex.decodeHex(publicKeyOrIdStr.toCharArray()); - return publicKey; - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapSecurityStore.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapSecurityStore.java deleted file mode 100644 index 0b06f02547..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapSecurityStore.java +++ /dev/null @@ -1,181 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap.secure; - -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.ObjectMapper; -import com.google.gson.JsonObject; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.SecurityMode; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.core.util.SecurityUtil; -import org.eclipse.leshan.server.bootstrap.BootstrapConfig; -import org.eclipse.leshan.server.bootstrap.EditableBootstrapConfigStore; -import org.eclipse.leshan.server.bootstrap.InvalidConfigurationException; -import org.eclipse.leshan.server.security.BootstrapSecurityStore; -import org.eclipse.leshan.server.security.SecurityInfo; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MGetSecurityInfo; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; -import org.thingsboard.server.transport.lwm2m.secure.ReadResultSecurityStore; -import org.thingsboard.server.transport.lwm2m.utils.TypeServer; - -import java.io.IOException; -import java.security.GeneralSecurityException; -import java.util.Arrays; -import java.util.List; - -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.*; - -@Slf4j -@Component("LwM2MBootstrapSecurityStore") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' && '${transport.lwm2m.bootstrap.enable:false}'=='true') || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true' && '${transport.lwm2m.bootstrap.enable}'=='true')") -public class LwM2MBootstrapSecurityStore implements BootstrapSecurityStore { - - private final EditableBootstrapConfigStore bootstrapConfigStore; - - @Autowired - LwM2MGetSecurityInfo lwM2MGetSecurityInfo; - - public LwM2MBootstrapSecurityStore(EditableBootstrapConfigStore bootstrapConfigStore) { - this.bootstrapConfigStore = bootstrapConfigStore; - } - - @Override - public List getAllByEndpoint(String endPoint) { - String endPointKey = endPoint; - ReadResultSecurityStore store = lwM2MGetSecurityInfo.getSecurityInfo(endPointKey, TypeServer.BOOTSTRAP); - if (store.getBootstrapJsonCredential() != null) { - /** add value to store from BootstrapJson */ - this.setBootstrapConfigScurityInfo(store); - BootstrapConfig bsConfigNew = store.getBootstrapConfig(); - if (bsConfigNew != null) { - try { - for (String config : bootstrapConfigStore.getAll().keySet()) { - if (config.equals(endPoint)) { - bootstrapConfigStore.remove(config); - } - } - bootstrapConfigStore.add(endPoint, bsConfigNew); - } catch (InvalidConfigurationException e) { - e.printStackTrace(); - } - return store.getSecurityInfo() == null ? null : Arrays.asList(store.getSecurityInfo()); - } - } - return null; - } - - @Override - public SecurityInfo getByIdentity(String identity) { - ReadResultSecurityStore store = lwM2MGetSecurityInfo.getSecurityInfo(identity, TypeServer.BOOTSTRAP); - /** add value to store from BootstrapJson */ - this.setBootstrapConfigScurityInfo(store); - - if (store.getSecurityMode() < LwM2MSecurityMode.DEFAULT_MODE.code) { - BootstrapConfig bsConfig = store.getBootstrapConfig(); - if (bsConfig.security != null) { - try { - bootstrapConfigStore.add(store.getEndPoint(), bsConfig); - } catch (InvalidConfigurationException e) { - e.printStackTrace(); - } - return store.getSecurityInfo(); - } - } - return null; - } - - private void setBootstrapConfigScurityInfo(ReadResultSecurityStore store) { - /** BootstrapConfig */ - LwM2MBootstrapConfig lwM2MBootstrapConfig = this.getParametersBootstrap(store); - if (lwM2MBootstrapConfig != null) { - /** Security info */ - switch (SecurityMode.valueOf(lwM2MBootstrapConfig.getBootstrapServer().getSecurityMode())) { - /** Use RPK only */ - case PSK: - store.setSecurityInfo(SecurityInfo.newPreSharedKeyInfo(store.getEndPoint(), - lwM2MBootstrapConfig.getBootstrapServer().getClientPublicKeyOrId(), - Hex.decodeHex(lwM2MBootstrapConfig.getBootstrapServer().getClientSecretKey().toCharArray()))); - store.setSecurityMode(SecurityMode.PSK.code); - break; - case RPK: - try { - store.setSecurityInfo(SecurityInfo.newRawPublicKeyInfo(store.getEndPoint(), - SecurityUtil.publicKey.decode(Hex.decodeHex(lwM2MBootstrapConfig.getBootstrapServer().getClientPublicKeyOrId().toCharArray())))); - store.setSecurityMode(SecurityMode.RPK.code); - break; - } catch (IOException | GeneralSecurityException e) { - log.error("Unable to decode Client public key for [{}] [{}]", store.getEndPoint(), e.getMessage()); - } - case X509: - store.setSecurityInfo(SecurityInfo.newX509CertInfo(store.getEndPoint())); - store.setSecurityMode(SecurityMode.X509.code); - break; - case NO_SEC: - store.setSecurityMode(SecurityMode.NO_SEC.code); - store.setSecurityInfo(null); - break; - default: - } - BootstrapConfig bootstrapConfig = lwM2MBootstrapConfig.getLwM2MBootstrapConfig(); - store.setBootstrapConfig(bootstrapConfig); - } - } - - private LwM2MBootstrapConfig getParametersBootstrap(ReadResultSecurityStore store) { - try { - JsonObject bootstrapJsonCredential = store.getBootstrapJsonCredential(); - ObjectMapper mapper = new ObjectMapper(); - LwM2MBootstrapConfig lwM2MBootstrapConfig = mapper.readValue(bootstrapJsonCredential.toString(), LwM2MBootstrapConfig.class); - JsonObject bootstrapObject = getBootstrapParametersFromThingsboard(store.getDeviceProfile()); - lwM2MBootstrapConfig.servers = mapper.readValue(bootstrapObject.get(SERVERS).toString(), LwM2MBootstrapServers.class); - LwM2MServerBootstrap profileServerBootstrap = mapper.readValue(bootstrapObject.get(BOOTSTRAP_SERVER).toString(), LwM2MServerBootstrap.class); - LwM2MServerBootstrap profileLwm2mServer = mapper.readValue(bootstrapObject.get(LWM2M_SERVER).toString(), LwM2MServerBootstrap.class); - if (getValidatedSecurityMode(lwM2MBootstrapConfig.bootstrapServer, profileServerBootstrap, lwM2MBootstrapConfig.lwm2mServer, profileLwm2mServer)) { - lwM2MBootstrapConfig.bootstrapServer = new LwM2MServerBootstrap(lwM2MBootstrapConfig.bootstrapServer, profileServerBootstrap); - lwM2MBootstrapConfig.lwm2mServer = new LwM2MServerBootstrap(lwM2MBootstrapConfig.lwm2mServer, profileLwm2mServer); - return lwM2MBootstrapConfig; - } - else { - log.error(" [{}] Different values SecurityMode between of client and profile.", store.getEndPoint()); - log.error(LOG_LW2M_ERROR + " getParametersBootstrap: [{}] Different values SecurityMode between of client and profile.", store.getEndPoint()); - String logMsg = String.format(LOG_LW2M_ERROR + " getParametersBootstrap: %s Different values SecurityMode between of client and profile.", store.getEndPoint()); -// sentLogsToThingsboard(logMsg, store.getEndPoint()); - return null; - } - } catch (JsonProcessingException e) { - log.error("Unable to decode Json or Certificate for [{}] [{}]", store.getEndPoint(), e.getMessage()); - return null; - } - } - - /** - * Bootstrap security have to sync between (bootstrapServer in credential and bootstrapServer in profile) - * and (lwm2mServer in credential and lwm2mServer in profile - * @param bootstrapFromCredential - Bootstrap -> Security of bootstrapServer in credential - * @param profileServerBootstrap - Bootstrap -> Security of bootstrapServer in profile - * @param lwm2mFromCredential - Bootstrap -> Security of lwm2mServer in credential - * @param profileLwm2mServer - Bootstrap -> Security of lwm2mServer in profile - * @return false if not sync between SecurityMode of Bootstrap credential and profile - */ - private boolean getValidatedSecurityMode(LwM2MServerBootstrap bootstrapFromCredential, LwM2MServerBootstrap profileServerBootstrap, LwM2MServerBootstrap lwm2mFromCredential, LwM2MServerBootstrap profileLwm2mServer) { - return (bootstrapFromCredential.getSecurityMode().equals(profileServerBootstrap.getSecurityMode()) && - lwm2mFromCredential.getSecurityMode().equals(profileLwm2mServer.getSecurityMode())); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapServers.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapServers.java deleted file mode 100644 index ab5bf3eed2..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MBootstrapServers.java +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap.secure; - -import lombok.Builder; -import lombok.Data; - -@Data -public class LwM2MBootstrapServers { - @Builder.Default - private Integer shortId = 123; - @Builder.Default - private Integer lifetime = 300; - @Builder.Default - private Integer defaultMinPeriod = 1; - @Builder.Default - private boolean notifIfDisabled = true; - @Builder.Default - private String binding = "U"; -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MInMemoryBootstrapConfigStore.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MInMemoryBootstrapConfigStore.java deleted file mode 100644 index d4cbfe48f0..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MInMemoryBootstrapConfigStore.java +++ /dev/null @@ -1,71 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap.secure; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.server.bootstrap.BootstrapConfig; -import org.eclipse.leshan.server.bootstrap.InMemoryBootstrapConfigStore; -import org.eclipse.leshan.server.bootstrap.InvalidConfigurationException; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import java.util.Map; -import java.util.concurrent.locks.Lock; -import java.util.concurrent.locks.ReadWriteLock; -import java.util.concurrent.locks.ReentrantReadWriteLock; - -@Slf4j -@Component("LwM2MInMemoryBootstrapConfigStore") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' && '${transport.lwm2m.bootstrap.enable:false}'=='true') || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true'&& '${transport.lwm2m.bootstrap.enable}'=='true')") -public class LwM2MInMemoryBootstrapConfigStore extends InMemoryBootstrapConfigStore { - private final ReadWriteLock readWriteLock = new ReentrantReadWriteLock(); - private final Lock readLock = readWriteLock.readLock(); - private final Lock writeLock = readWriteLock.writeLock(); - - @Override - public Map getAll() { - readLock.lock(); - try { - return super.getAll(); - } finally { - readLock.unlock(); - } - } - - @Override - public void add(String endpoint, BootstrapConfig config) throws InvalidConfigurationException { - writeLock.lock(); - try { - addToStore(endpoint, config); - } finally { - writeLock.unlock(); - } - } - - @Override - public BootstrapConfig remove(String enpoint) { - writeLock.lock(); - try { - BootstrapConfig res = super.remove(enpoint); - return res; - } finally { - writeLock.unlock(); - } - } - - public void addToStore(String endpoint, BootstrapConfig config) throws InvalidConfigurationException { - super.add(endpoint, config); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MServerBootstrap.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MServerBootstrap.java deleted file mode 100644 index fbd3a7e0a2..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MServerBootstrap.java +++ /dev/null @@ -1,65 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap.secure; - -import lombok.Builder; -import lombok.Data; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.SecurityMode; - -@Slf4j -@Data -public class LwM2MServerBootstrap { - - @Builder.Default - String clientPublicKeyOrId = ""; - @Builder.Default - String clientSecretKey = ""; - @Builder.Default - String serverPublicKey = ""; - @Builder.Default - Integer clientHoldOffTime = 1; - @Builder.Default - Integer bootstrapServerAccountTimeout = 0; - - @Builder.Default - String host = "0.0.0.0"; - @Builder.Default - Integer port = 0; - - @Builder.Default - String securityMode = SecurityMode.NO_SEC.name(); - - @Builder.Default - Integer serverId = 123; - @Builder.Default - boolean bootstrapServerIs = false; - - public LwM2MServerBootstrap(){}; - - public LwM2MServerBootstrap(LwM2MServerBootstrap bootstrapFromCredential, LwM2MServerBootstrap profileServerBootstrap) { - this.clientPublicKeyOrId = bootstrapFromCredential.getClientPublicKeyOrId(); - this.clientSecretKey = bootstrapFromCredential.getClientSecretKey(); - this.serverPublicKey = profileServerBootstrap.getServerPublicKey(); - this.clientHoldOffTime = profileServerBootstrap.getClientHoldOffTime(); - this.bootstrapServerAccountTimeout = profileServerBootstrap.getBootstrapServerAccountTimeout(); - this.host = (profileServerBootstrap.getHost().equals("0.0.0.0")) ? "localhost" : profileServerBootstrap.getHost(); - this.port = profileServerBootstrap.getPort(); - this.securityMode = profileServerBootstrap.getSecurityMode(); - this.serverId = profileServerBootstrap.getServerId(); - this.bootstrapServerIs = profileServerBootstrap.bootstrapServerIs; - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MSetSecurityStoreBootstrap.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MSetSecurityStoreBootstrap.java deleted file mode 100644 index f648799204..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2MSetSecurityStoreBootstrap.java +++ /dev/null @@ -1,205 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap.secure; - -import lombok.Data; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.server.californium.bootstrap.LeshanBootstrapServerBuilder; -import org.eclipse.leshan.server.security.EditableSecurityStore; -import org.thingsboard.server.transport.lwm2m.bootstrap.LwM2MTransportContextBootstrap; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; -import org.thingsboard.server.transport.lwm2m.server.LwM2MTransportContextServer; - -import java.math.BigInteger; -import java.security.AlgorithmParameters; -import java.security.KeyStore; -import java.security.PublicKey; -import java.security.PrivateKey; -import java.security.KeyFactory; -import java.security.GeneralSecurityException; -import java.security.KeyStoreException; -import java.security.cert.X509Certificate; -import java.security.interfaces.ECPublicKey; -import java.security.spec.ECGenParameterSpec; -import java.security.spec.ECParameterSpec; -import java.security.spec.ECPublicKeySpec; -import java.security.spec.ECPoint; -import java.security.spec.KeySpec; -import java.security.spec.ECPrivateKeySpec; -import java.util.Arrays; - -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.NO_SEC; -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.X509; - -@Slf4j -@Data -public class LwM2MSetSecurityStoreBootstrap { - - private KeyStore keyStore; - private PublicKey publicKey; - private PrivateKey privateKey; - private LwM2MTransportContextBootstrap contextBs; - private LwM2MTransportContextServer contextS; - private LeshanBootstrapServerBuilder builder; - EditableSecurityStore securityStore; - - public LwM2MSetSecurityStoreBootstrap(LeshanBootstrapServerBuilder builder, LwM2MTransportContextBootstrap contextBs, LwM2MTransportContextServer contextS, LwM2MSecurityMode dtlsMode) { - this.builder = builder; - this.contextBs = contextBs; - this.contextS = contextS; - /** Set securityStore with new registrationStore */ - - switch (dtlsMode) { - /** Use No_Sec only */ - case NO_SEC: - setServerWithX509Cert(NO_SEC.code); - break; - /** Use PSK/RPK */ - case PSK: - case RPK: - setRPK(); - break; - case X509: - setServerWithX509Cert(X509.code); - break; - /** Use X509_EST only */ - case X509_EST: - // TODO support sentinel pool and make pool configurable - break; - /** Use ather X509, PSK, No_Sec ?? */ - default: - break; - } - } - - private void setRPK() { - try { - /** Get Elliptic Curve Parameter spec for secp256r1 */ - AlgorithmParameters algoParameters = AlgorithmParameters.getInstance("EC"); - algoParameters.init(new ECGenParameterSpec("secp256r1")); - ECParameterSpec parameterSpec = algoParameters.getParameterSpec(ECParameterSpec.class); - if (this.contextBs.getCtxBootStrap().getBootstrapPublicX() != null && !this.contextBs.getCtxBootStrap().getBootstrapPublicX().isEmpty() && this.contextBs.getCtxBootStrap().getBootstrapPublicY() != null && !this.contextBs.getCtxBootStrap().getBootstrapPublicY().isEmpty()) { - /** Get point values */ - byte[] publicX = Hex.decodeHex(this.contextBs.getCtxBootStrap().getBootstrapPublicX().toCharArray()); - byte[] publicY = Hex.decodeHex(this.contextBs.getCtxBootStrap().getBootstrapPublicY().toCharArray()); - /** Create key specs */ - KeySpec publicKeySpec = new ECPublicKeySpec(new ECPoint(new BigInteger(publicX), new BigInteger(publicY)), - parameterSpec); - /** Get keys */ - this.publicKey = KeyFactory.getInstance("EC").generatePublic(publicKeySpec); - } - if (this.contextBs.getCtxBootStrap().getBootstrapPrivateS() != null && !this.contextBs.getCtxBootStrap().getBootstrapPrivateS().isEmpty()) { - /** Get point values */ - byte[] privateS = Hex.decodeHex(this.contextBs.getCtxBootStrap().getBootstrapPrivateS().toCharArray()); - /** Create key specs */ - KeySpec privateKeySpec = new ECPrivateKeySpec(new BigInteger(privateS), parameterSpec); - /** Get keys */ - this.privateKey = KeyFactory.getInstance("EC").generatePrivate(privateKeySpec); - } - if (this.publicKey != null && this.publicKey.getEncoded().length > 0 && - this.privateKey != null && this.privateKey.getEncoded().length > 0) { - this.builder.setPublicKey(this.publicKey); - this.builder.setPrivateKey(this.privateKey); - this.contextBs.getCtxBootStrap().setBootstrapPublicKey(this.publicKey); - getParamsRPK(); - } - } catch (GeneralSecurityException | IllegalArgumentException e) { - log.error("[{}] Failed generate Server PSK/RPK", e.getMessage()); - throw new RuntimeException(e); - } - } - - private void setServerWithX509Cert(int securityModeCode) { - try { - if (this.contextS.getCtxServer().getKeyStoreValue() != null) { - KeyStore keyStoreServer = this.contextS.getCtxServer().getKeyStoreValue(); - setBuilderX509(); - X509Certificate rootCAX509Cert = (X509Certificate) keyStoreServer.getCertificate(this.contextS.getCtxServer().getRootAlias()); - if (rootCAX509Cert != null && securityModeCode == X509.code) { - X509Certificate[] trustedCertificates = new X509Certificate[1]; - trustedCertificates[0] = rootCAX509Cert; - this.builder.setTrustedCertificates(trustedCertificates); - } else { - /** by default trust all */ - this.builder.setTrustedCertificates(new X509Certificate[0]); - } - } - else { - /** by default trust all */ - this.builder.setTrustedCertificates(new X509Certificate[0]); - log.error("Unable to load X509 files for BootStrapServer"); - } - } catch (KeyStoreException ex) { - log.error("[{}] Unable to load X509 files server", ex.getMessage()); - } - - } - - private void setBuilderX509() { - /** - * For deb => KeyStorePathFile == yml or commandline: KEY_STORE_PATH_FILE - * For idea => KeyStorePathResource == common/transport/lwm2m/src/main/resources/credentials: in LwM2MTransportContextServer: credentials/serverKeyStore.jks - */ - try { - X509Certificate serverCertificate = (X509Certificate) this.contextS.getCtxServer().getKeyStoreValue().getCertificate(this.contextBs.getCtxBootStrap().getBootstrapAlias()); - this.privateKey = (PrivateKey) this.contextS.getCtxServer().getKeyStoreValue().getKey(this.contextBs.getCtxBootStrap().getBootstrapAlias(), this.contextS.getCtxServer().getKeyStorePasswordServer() == null ? null : this.contextS.getCtxServer().getKeyStorePasswordServer().toCharArray()); - if (this.privateKey != null && this.privateKey.getEncoded().length > 0) { - this.builder.setPrivateKey(this.privateKey); - } - if (serverCertificate != null) { - this.builder.setCertificateChain(new X509Certificate[]{serverCertificate}); - this.contextBs.getCtxBootStrap().setBootstrapCertificate(serverCertificate); - } - } catch (Exception ex) { - log.error("[{}] Unable to load KeyStore files server", ex.getMessage()); - } - } - - private void getParamsRPK() { - if (this.publicKey instanceof ECPublicKey) { - /** Get x coordinate */ - byte[] x = ((ECPublicKey) this.publicKey).getW().getAffineX().toByteArray(); - if (x[0] == 0) - x = Arrays.copyOfRange(x, 1, x.length); - - /** Get Y coordinate */ - byte[] y = ((ECPublicKey) this.publicKey).getW().getAffineY().toByteArray(); - if (y[0] == 0) - y = Arrays.copyOfRange(y, 1, y.length); - - /** Get Curves params */ - String params = ((ECPublicKey) this.publicKey).getParams().toString(); - log.info( - " \nBootstrap uses RPK : \n Elliptic Curve parameters : [{}] \n Public x coord : [{}] \n Public y coord : [{}] \n Public Key (Hex): [{}] \n Private Key (Hex): [{}]", - params, Hex.encodeHexString(x), Hex.encodeHexString(y), - Hex.encodeHexString(this.publicKey.getEncoded()), - Hex.encodeHexString(this.privateKey.getEncoded())); - } else { - throw new IllegalStateException("Unsupported Public Key Format (only ECPublicKey supported)."); - } - } - -// private void getParamsX509() { -// try { -// log.info("BootStrap uses X509 : \n X509 Certificate (Hex): [{}] \n Private Key (Hex): [{}]", -// Hex.encodeHexString(this.certificate.getEncoded()), -// Hex.encodeHexString(this.privateKey.getEncoded())); -// } catch (CertificateEncodingException e) { -// e.printStackTrace(); -// } -// } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2mDefaultBootstrapSessionManager.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2mDefaultBootstrapSessionManager.java deleted file mode 100644 index db8a520266..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/bootstrap/secure/LwM2mDefaultBootstrapSessionManager.java +++ /dev/null @@ -1,66 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.bootstrap.secure; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.request.Identity; -import org.eclipse.leshan.server.bootstrap.BootstrapSession; -import org.eclipse.leshan.server.bootstrap.DefaultBootstrapSession; -import org.eclipse.leshan.server.bootstrap.DefaultBootstrapSessionManager; -import org.eclipse.leshan.server.security.BootstrapSecurityStore; -import org.eclipse.leshan.server.security.SecurityChecker; -import org.eclipse.leshan.server.security.SecurityInfo; - -import java.util.Arrays; -import java.util.List; - -@Slf4j -public class LwM2mDefaultBootstrapSessionManager extends DefaultBootstrapSessionManager { - - private BootstrapSecurityStore bsSecurityStore; - private SecurityChecker securityChecker; - - /** - * Create a {@link DefaultBootstrapSessionManager} using a default {@link SecurityChecker} to accept or refuse new - * {@link BootstrapSession}. - * - * @param bsSecurityStore the {@link BootstrapSecurityStore} used by default {@link SecurityChecker}. - */ - public LwM2mDefaultBootstrapSessionManager(BootstrapSecurityStore bsSecurityStore) { - this(bsSecurityStore, new SecurityChecker()); - } - - public LwM2mDefaultBootstrapSessionManager(BootstrapSecurityStore bsSecurityStore, SecurityChecker securityChecker) { - super(bsSecurityStore); - this.bsSecurityStore = bsSecurityStore; - this.securityChecker = securityChecker; - } - - @Override - public BootstrapSession begin(String endpoint, Identity clientIdentity) { - boolean authorized; - if (bsSecurityStore != null) { - List securityInfos = (clientIdentity.getPskIdentity() != null && !clientIdentity.getPskIdentity().isEmpty()) ? Arrays.asList(bsSecurityStore.getByIdentity(clientIdentity.getPskIdentity())) : bsSecurityStore.getAllByEndpoint(endpoint); - log.info("Bootstrap session started securityInfos: [{}]", securityInfos); - authorized = securityChecker.checkSecurityInfos(endpoint, clientIdentity, securityInfos); - } else { - authorized = true; - } - DefaultBootstrapSession session = new DefaultBootstrapSession(endpoint, clientIdentity, authorized); - log.info("Bootstrap session started : {}", session); - return session; - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LWM2MGenerationPSkRPkECC.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LWM2MGenerationPSkRPkECC.java deleted file mode 100644 index 1d70ae2d83..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LWM2MGenerationPSkRPkECC.java +++ /dev/null @@ -1,121 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.secure; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.util.Hex; -import java.security.SecureRandom; -import java.security.KeyPairGenerator; -import java.security.KeyPair; -import java.security.PrivateKey; -import java.security.PublicKey; -import java.security.NoSuchAlgorithmException; -import java.security.NoSuchProviderException; -import java.security.InvalidAlgorithmParameterException; -import java.security.interfaces.ECPublicKey; -import java.security.spec.ECGenParameterSpec; -import java.util.Arrays; - -@Slf4j -public class LWM2MGenerationPSkRPkECC { - - public LWM2MGenerationPSkRPkECC(Integer dtlsMode) { - switch (LwM2MSecurityMode.fromSecurityMode(dtlsMode)) { - case PSK: - generationPSkKey(); - break; - case RPK: - generationRPKECCKey(); - } - } - - public LWM2MGenerationPSkRPkECC() { - generationPSkKey(); - generationRPKECCKey(); - } - - private void generationPSkKey() { - /** PSK */ - int lenPSkKey = 32; - /** Start PSK - * Clients and Servers MUST support PSK keys of up to 64 bytes in length, as required by [RFC7925] - * SecureRandom object must be unpredictable, and all SecureRandom output sequences must be cryptographically strong, as described in [RFC4086] - * */ - SecureRandom randomPSK = new SecureRandom(); - byte bytesPSK[] = new byte[lenPSkKey]; - randomPSK.nextBytes(bytesPSK); - log.info("\nCreating new PSK: \n for the next start PSK -> security key: [{}]", Hex.encodeHexString(bytesPSK)); - } - - private void generationRPKECCKey() { - /** RPK */ - String algorithm = "EC"; - String provider = "SunEC"; - String nameParameterSpec = "secp256r1"; - - /** Start RPK - * Elliptic Curve parameters : [secp256r1 [NIST P-256, X9.62 prime256v1] (1.2.840.10045.3.1.7)] - * */ - KeyPairGenerator kpg = null; - try { - kpg = KeyPairGenerator.getInstance(algorithm, provider); - } catch (NoSuchAlgorithmException e) { - e.printStackTrace(); - } catch (NoSuchProviderException e) { - e.printStackTrace(); - } - ECGenParameterSpec ecsp = new ECGenParameterSpec(nameParameterSpec); - try { - kpg.initialize(ecsp); - } catch (InvalidAlgorithmParameterException e) { - e.printStackTrace(); - } - - KeyPair kp = kpg.genKeyPair(); - PrivateKey privKey = kp.getPrivate(); - PublicKey pubKey = kp.getPublic(); - - if (pubKey instanceof ECPublicKey) { - ECPublicKey ecPublicKey = (ECPublicKey) pubKey; - /** Get x coordinate */ - byte[] x = ecPublicKey.getW().getAffineX().toByteArray(); - if (x[0] == 0) - x = Arrays.copyOfRange(x, 1, x.length); - - /** Get Y coordinate */ - byte[] y = ecPublicKey.getW().getAffineY().toByteArray(); - if (y[0] == 0) - y = Arrays.copyOfRange(y, 1, y.length); - - /** Get Curves params */ - String privHex = Hex.encodeHexString(privKey.getEncoded()); - log.info("\nCreating new RPK for the next start... \n" + - " Elliptic Curve parameters : [{}] \n" + - " public_x : [{}] \n" + - " public_y : [{}] \n" + - " private_s : [{}] \n" + - " Public Key (Hex): [{}]\n" + - " Private Key (Hex): [{}]", - ecPublicKey.getParams().toString(), - Hex.encodeHexString(x), - Hex.encodeHexString(y), - privHex.substring(privHex.length() - 64), - Hex.encodeHexString(pubKey.getEncoded()), - Hex.encodeHexString(privKey.getEncoded())); - } - } -} - diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MGetSecurityInfo.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MGetSecurityInfo.java deleted file mode 100644 index ad63e21633..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MGetSecurityInfo.java +++ /dev/null @@ -1,170 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.secure; - -import com.google.gson.JsonObject; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.core.util.SecurityUtil; -import org.eclipse.leshan.server.security.SecurityInfo; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.common.data.DeviceProfile; -import org.thingsboard.server.common.transport.TransportServiceCallback; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceLwM2MCredentialsRequestMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceCredentialsResponseMsg; -import org.thingsboard.server.transport.lwm2m.bootstrap.LwM2MTransportContextBootstrap; -import org.thingsboard.server.transport.lwm2m.server.LwM2MTransportContextServer; -import org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler; -import org.thingsboard.server.transport.lwm2m.utils.TypeServer; - -import java.io.IOException; -import java.security.GeneralSecurityException; -import java.security.PublicKey; -import java.util.Optional; -import java.util.concurrent.CountDownLatch; -import java.util.concurrent.TimeUnit; - -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.*; - -@Slf4j -@Component("LwM2MGetSecurityInfo") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' ) || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MGetSecurityInfo { - - @Autowired - public LwM2MTransportContextServer contextS; - - @Autowired - public LwM2MTransportContextBootstrap contextBS; - - - public ReadResultSecurityStore getSecurityInfo(String endPoint, TypeServer keyValue) { - CountDownLatch latch = new CountDownLatch(1); - final ReadResultSecurityStore[] resultSecurityStore = new ReadResultSecurityStore[1]; - contextS.getTransportService().process(ValidateDeviceLwM2MCredentialsRequestMsg.newBuilder().setCredentialsId(endPoint).build(), - new TransportServiceCallback() { - @Override - public void onSuccess(ValidateDeviceCredentialsResponseMsg msg) { - String credentialsBody = msg.getCredentialsBody(); - resultSecurityStore[0] = putSecurityInfo(endPoint, msg.getDeviceInfo().getDeviceName(), credentialsBody, keyValue); - resultSecurityStore[0].setMsg(msg); - Optional deviceProfileOpt = LwM2MTransportHandler.decode(msg.getProfileBody().toByteArray()); - deviceProfileOpt.ifPresent(profile -> resultSecurityStore[0].setDeviceProfile(profile)); - latch.countDown(); - } - - @Override - public void onError(Throwable e) { - log.trace("[{}] Failed to process credentials PSK: {}", endPoint, e); - resultSecurityStore[0] = putSecurityInfo(endPoint, null, null, null); - latch.countDown(); - } - }); - try { - latch.await(contextS.getCtxServer().getTimeout(), TimeUnit.MILLISECONDS); - } catch (InterruptedException e) { - e.printStackTrace(); - } - return resultSecurityStore[0]; - } - - private ReadResultSecurityStore putSecurityInfo(String endPoint, String deviceName, String jsonStr, TypeServer keyValue) { - ReadResultSecurityStore result = new ReadResultSecurityStore(); - JsonObject objectMsg = LwM2MTransportHandler.validateJson(jsonStr); - if (objectMsg != null && !objectMsg.isJsonNull()) { - JsonObject object = (objectMsg.has(keyValue.type) && !objectMsg.get(keyValue.type).isJsonNull()) ? objectMsg.get(keyValue.type).getAsJsonObject() : null; - /** - * Only PSK - */ - String endPointPsk = (objectMsg.has("client") - && objectMsg.get("client").getAsJsonObject().has("endpoint") - && objectMsg.get("client").getAsJsonObject().get("endpoint").isJsonPrimitive()) ? objectMsg.get("client").getAsJsonObject().get("endpoint").getAsString() : null; - endPoint = (endPointPsk == null || endPointPsk.isEmpty()) ? endPoint : endPointPsk; - if (object != null && !object.isJsonNull()) { - if (keyValue.equals(TypeServer.BOOTSTRAP)) { - result.setBootstrapJsonCredential(object); - result.setEndPoint(endPoint); - } else { - LwM2MSecurityMode lwM2MSecurityMode = LwM2MSecurityMode.fromSecurityMode(object.get("securityConfigClientMode").getAsString().toLowerCase()); - switch (lwM2MSecurityMode) { - case NO_SEC: - getClientSecurityInfoNoSec(result); - break; - case PSK: - getClientSecurityInfoPSK(result, endPoint, object); - break; - case RPK: - getClientSecurityInfoRPK(result, endPoint, object); - break; - case X509: - getClientSecurityInfoX509(result, endPoint); - break; - default: - break; - } - } - } - } - return result; - } - - private void getClientSecurityInfoNoSec(ReadResultSecurityStore result) { - result.setSecurityInfo(null); - result.setSecurityMode(NO_SEC.code); - } - - private void getClientSecurityInfoPSK(ReadResultSecurityStore result, String endPoint, JsonObject object) { - /** PSK Deserialization */ - String identity = (object.has("identity") && object.get("identity").isJsonPrimitive()) ? object.get("identity").getAsString() : null; - if (identity != null && !identity.isEmpty()) { - try { - byte[] key = (object.has("key") && object.get("key").isJsonPrimitive()) ? Hex.decodeHex(object.get("key").getAsString().toCharArray()) : null; - if (key != null && key.length > 0) { - if (endPoint != null && !endPoint.isEmpty()) { - result.setSecurityInfo(SecurityInfo.newPreSharedKeyInfo(endPoint, identity, key)); - result.setSecurityMode(PSK.code); - } - } - } catch (IllegalArgumentException e) { - log.error("Missing PSK key: " + e.getMessage()); - } - } else { - log.error("Missing PSK identity"); - } - } - - private void getClientSecurityInfoRPK(ReadResultSecurityStore result, String endpoint, JsonObject object) { - try { - if (object.has("key") && object.get("key").isJsonPrimitive()) { - byte[] rpkkey = Hex.decodeHex(object.get("key").getAsString().toLowerCase().toCharArray()); - PublicKey key = SecurityUtil.publicKey.decode(rpkkey); - result.setSecurityInfo(SecurityInfo.newRawPublicKeyInfo(endpoint, key)); - result.setSecurityMode(RPK.code); - } else { - log.error("Missing RPK key"); - } - } catch (IllegalArgumentException | IOException | GeneralSecurityException e) { - log.error("RPK: Invalid security info content: " + e.getMessage()); - } - } - - private void getClientSecurityInfoX509(ReadResultSecurityStore result, String endpoint) { - result.setSecurityInfo(SecurityInfo.newX509CertInfo(endpoint)); - result.setSecurityMode(X509.code); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MSecurityMode.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MSecurityMode.java deleted file mode 100644 index 2e045b153c..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2MSecurityMode.java +++ /dev/null @@ -1,58 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.secure; - -public enum LwM2MSecurityMode { - - PSK(0, "psk"), - RPK(1, "rpk"), - X509(2, "x509"), - NO_SEC(3, "no_sec"), - X509_EST(4, "x509_est"), - REDIS(7, "redis"), - DEFAULT_MODE(255, "default_mode"); - - public int code; - public String subEndpoint; - - LwM2MSecurityMode(int code, String subEndpoint) { - this.code = code; - this.subEndpoint = subEndpoint; - } - - public static LwM2MSecurityMode fromSecurityMode(long code) { - return fromSecurityMode((int) code); - } - - public static LwM2MSecurityMode fromSecurityMode(int code) { - for (LwM2MSecurityMode sm : LwM2MSecurityMode.values()) { - if (sm.code == code) { - return sm; - } - } - throw new IllegalArgumentException(String.format("Unsupported security code : %d", code)); - } - - - public static LwM2MSecurityMode fromSecurityMode(String subEndpoint) { - for (LwM2MSecurityMode sm : LwM2MSecurityMode.values()) { - if (sm.subEndpoint.equals(subEndpoint)) { - return sm; - } - } - throw new IllegalArgumentException(String.format("Unsupported security subEndpoint : %d", subEndpoint)); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2mRPkCredentials.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2mRPkCredentials.java deleted file mode 100644 index 44d6cfb5b1..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/LwM2mRPkCredentials.java +++ /dev/null @@ -1,84 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.secure; - -import lombok.Data; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.util.Hex; -import java.math.BigInteger; -import java.security.PrivateKey; -import java.security.PublicKey; -import java.security.AlgorithmParameters; -import java.security.KeyFactory; -import java.security.GeneralSecurityException; -import java.security.cert.Certificate; -import java.security.cert.X509Certificate; -import java.security.spec.ECGenParameterSpec; -import java.security.spec.ECParameterSpec; -import java.security.spec.ECPublicKeySpec; -import java.security.spec.KeySpec; -import java.security.spec.ECPrivateKeySpec; -import java.security.spec.ECPoint; -import java.util.List; - -@Slf4j -@Data -public class LwM2mRPkCredentials { - private PublicKey serverPublicKey; - private PrivateKey serverPrivateKey; - private X509Certificate certificate; - private List trustStore; - - /** - * create All key RPK credentials - * @param publX - * @param publY - * @param privS - */ - public LwM2mRPkCredentials(String publX, String publY, String privS) { - generatePublicKeyRPK(publX, publY, privS); - } - - private void generatePublicKeyRPK(String publX, String publY, String privS) { - try { - /**Get Elliptic Curve Parameter spec for secp256r1 */ - AlgorithmParameters algoParameters = AlgorithmParameters.getInstance("EC"); - algoParameters.init(new ECGenParameterSpec("secp256r1")); - ECParameterSpec parameterSpec = algoParameters.getParameterSpec(ECParameterSpec.class); - if (publX != null && !publX.isEmpty() && publY != null && !publY.isEmpty()) { - // Get point values - byte[] publicX = Hex.decodeHex(publX.toCharArray()); - byte[] publicY = Hex.decodeHex(publY.toCharArray()); - /** Create key specs */ - KeySpec publicKeySpec = new ECPublicKeySpec(new ECPoint(new BigInteger(publicX), new BigInteger(publicY)), - parameterSpec); - /** Get keys */ - this.serverPublicKey = KeyFactory.getInstance("EC").generatePublic(publicKeySpec); - } - if (privS != null && !privS.isEmpty()) { - /** Get point values */ - byte[] privateS = Hex.decodeHex(privS.toCharArray()); - /** Create key specs */ - KeySpec privateKeySpec = new ECPrivateKeySpec(new BigInteger(privateS), parameterSpec); - /** Get keys */ - this.serverPrivateKey = KeyFactory.getInstance("EC").generatePrivate(privateKeySpec); - } - } catch (GeneralSecurityException | IllegalArgumentException e) { - log.error("[{}] Failed generate Server KeyRPK", e.getMessage()); - throw new RuntimeException(e); - } - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/ReadResultSecurityStore.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/ReadResultSecurityStore.java deleted file mode 100644 index 28cfbfb244..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/secure/ReadResultSecurityStore.java +++ /dev/null @@ -1,40 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.secure; - -import com.google.gson.JsonObject; -import lombok.Builder; -import lombok.Data; -import org.eclipse.leshan.server.bootstrap.BootstrapConfig; -import org.eclipse.leshan.server.security.SecurityInfo; -import org.thingsboard.server.common.data.DeviceProfile; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceCredentialsResponseMsg; - -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.DEFAULT_MODE; - -@Data -public class ReadResultSecurityStore { - private ValidateDeviceCredentialsResponseMsg msg; - private SecurityInfo securityInfo; - @Builder.Default - private int securityMode = DEFAULT_MODE.code; - - /** bootstrap */ - DeviceProfile deviceProfile; - JsonObject bootstrapJsonCredential; - String endPoint; - BootstrapConfig bootstrapConfig; -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MSessionMsgListener.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MSessionMsgListener.java deleted file mode 100644 index bf88427879..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MSessionMsgListener.java +++ /dev/null @@ -1,88 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import io.netty.util.concurrent.Future; -import io.netty.util.concurrent.GenericFutureListener; -import lombok.extern.slf4j.Slf4j; -import org.thingsboard.server.common.data.Device; -import org.thingsboard.server.common.data.DeviceProfile; -import org.thingsboard.server.common.transport.SessionMsgListener; -import org.thingsboard.server.gen.transport.TransportProtos; -import org.thingsboard.server.gen.transport.TransportProtos.GetAttributeResponseMsg; -import org.thingsboard.server.gen.transport.TransportProtos.AttributeUpdateNotificationMsg; -import org.thingsboard.server.gen.transport.TransportProtos.SessionCloseNotificationProto; -import org.thingsboard.server.gen.transport.TransportProtos.ToDeviceRpcRequestMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ToServerRpcResponseMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ToTransportUpdateCredentialsProto; - -import java.util.Optional; - -@Slf4j -public class LwM2MSessionMsgListener implements GenericFutureListener>, SessionMsgListener { - private LwM2MTransportService service; - private TransportProtos.SessionInfoProto sessionInfo; - - LwM2MSessionMsgListener(LwM2MTransportService service, TransportProtos.SessionInfoProto sessionInfo) { - this.service = service; - this.sessionInfo = sessionInfo; - } - - @Override - public void onGetAttributesResponse(GetAttributeResponseMsg getAttributesResponse) { - log.info("[{}] attributesResponse", getAttributesResponse); - } - - @Override - public void onAttributeUpdate(AttributeUpdateNotificationMsg attributeUpdateNotification) { - this.service.onAttributeUpdate(attributeUpdateNotification, this.sessionInfo); - } - - @Override - public void onRemoteSessionCloseCommand(SessionCloseNotificationProto sessionCloseNotification) { - log.info("[{}] sessionCloseNotification", sessionCloseNotification); - } - - @Override - public void onToTransportUpdateCredentials(ToTransportUpdateCredentialsProto updateCredentials) { - this.service.onToTransportUpdateCredentials(updateCredentials); - } - - @Override - public void onDeviceProfileUpdate(TransportProtos.SessionInfoProto sessionInfo, DeviceProfile deviceProfile) { - this.service.onDeviceProfileUpdate(sessionInfo, deviceProfile); - } - - @Override - public void onDeviceUpdate(TransportProtos.SessionInfoProto sessionInfo, Device device, Optional deviceProfileOpt) { - this.service.onDeviceUpdate(sessionInfo, device, deviceProfileOpt); - } - - @Override - public void onToDeviceRpcRequest(ToDeviceRpcRequestMsg toDeviceRequest) { - log.info("[{}] toDeviceRpcRequest", toDeviceRequest); - } - - @Override - public void onToServerRpcResponse(ToServerRpcResponseMsg toServerResponse) { - log.info("[{}] toServerRpcResponse", toServerResponse); - } - - @Override - public void operationComplete(Future future) throws Exception { - log.info("[{}] operationComplete", future); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportContextServer.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportContextServer.java deleted file mode 100644 index 4bddd9a481..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportContextServer.java +++ /dev/null @@ -1,60 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import lombok.extern.slf4j.Slf4j; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.common.transport.TransportContext; -import org.thingsboard.server.common.transport.lwm2m.LwM2MTransportConfigServer; - -import javax.annotation.PostConstruct; - -@Slf4j -@Component -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true') || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MTransportContextServer extends TransportContext { - - private LwM2MTransportConfigServer ctxServer; - - @Autowired - LwM2MTransportConfigServer lwM2MTransportConfigServer; - - @PostConstruct - public void init() { - this.ctxServer = lwM2MTransportConfigServer; - } - - public LwM2MTransportConfigServer getCtxServer () { - return this.ctxServer; - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportHandler.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportHandler.java deleted file mode 100644 index d922f2b1c5..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportHandler.java +++ /dev/null @@ -1,333 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import com.fasterxml.jackson.databind.ObjectMapper; -import com.google.gson.Gson; -import com.google.gson.JsonObject; -import com.google.gson.JsonParser; -import com.google.gson.JsonSyntaxException; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.lang3.StringUtils; -import org.eclipse.californium.core.network.config.NetworkConfig; -import org.eclipse.leshan.core.model.ResourceModel; -import org.eclipse.leshan.core.node.LwM2mNode; -import org.eclipse.leshan.core.node.LwM2mObject; -import org.eclipse.leshan.core.node.LwM2mObjectInstance; -import org.eclipse.leshan.core.node.LwM2mSingleResource; -import org.eclipse.leshan.core.node.LwM2mMultipleResource; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.eclipse.leshan.server.californium.LeshanServerBuilder; -import org.nustaq.serialization.FSTConfiguration; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.beans.factory.annotation.Qualifier; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.common.data.DeviceProfile; -import org.thingsboard.server.common.data.device.profile.Lwm2mDeviceProfileTransportConfiguration; -import org.thingsboard.server.transport.lwm2m.server.client.AttrTelemetryObserveValue; - -import javax.annotation.PostConstruct; -import java.io.File; -import java.io.IOException; -import java.text.DateFormat; -import java.text.SimpleDateFormat; -import java.util.Date; -import java.util.Optional; -import java.util.Map; -import java.util.Arrays; -import java.util.List; -import java.util.ArrayList; -import java.util.LinkedList; -import java.util.Collections; - -@Slf4j -@Component("LwM2MTransportHandler") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' )|| ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MTransportHandler{ - - // We choose a default timeout a bit higher to the MAX_TRANSMIT_WAIT(62-93s) which is the time from starting to - // send a Confirmable message to the time when an acknowledgement is no longer expected. - public static final long DEFAULT_TIMEOUT = 2 * 60 * 1000l; // 2min in ms - public static final String OBSERVE_ATTRIBUTE_TELEMETRY = "observeAttr"; - public static final String KEYNAME = "keyName"; - public static final String ATTRIBUTE = "attribute"; - public static final String TELEMETRY = "telemetry"; - public static final String OBSERVE = "observe"; - public static final String BOOTSTRAP = "bootstrap"; - public static final String SERVERS = "servers"; - public static final String LWM2M_SERVER = "lwm2mServer"; - public static final String BOOTSTRAP_SERVER = "bootstrapServer"; - public static final String BASE_DEVICE_API_TOPIC = "v1/devices/me"; - public static final String DEVICE_ATTRIBUTES_TOPIC = BASE_DEVICE_API_TOPIC + "/attributes"; - public static final String DEVICE_TELEMETRY_TOPIC = BASE_DEVICE_API_TOPIC + "/telemetry"; - public static final String LOG_LW2M_TELEMETRY = "logLwm2m"; - public static final String LOG_LW2M_INFO = "info"; - public static final String LOG_LW2M_ERROR = "error"; - public static final String LOG_LW2M_WARN = "warn"; - - - public static final String CLIENT_NOT_AUTHORIZED = "Client not authorized"; - - public static final String GET_TYPE_OPER_READ = "read"; - public static final String GET_TYPE_OPER_DISCOVER = "discover"; - public static final String GET_TYPE_OPER_OBSERVE = "observe"; - public static final String POST_TYPE_OPER_OBSERVE_CANCEL = "observeCancel"; - public static final String POST_TYPE_OPER_EXECUTE = "execute"; - /** - * Replaces the Object Instance or the Resource(s) with the new value provided in the “Write” operation. (see - * section 5.3.3 of the LW M2M spec). - */ - public static final String POST_TYPE_OPER_WRITE_REPLACE = "replace"; - /** - * Adds or updates Resources provided in the new value and leaves other existing Resources unchanged. (see section - * 5.3.3 of the LW M2M spec). - */ - public static final String PUT_TYPE_OPER_WRITE_UPDATE = "update"; - public static final String PUT_TYPE_OPER_WRITE_ATTRIBUTES = "wright-attributes"; - - public static final String EVENT_AWAKE = "AWAKE"; - - private static Gson gson = null; - - @Autowired - @Qualifier("LeshanServerCert") - private LeshanServer lhServerCert; - - @Autowired - @Qualifier("leshanServerNoSecPskRpk") - private LeshanServer lhServerNoSecPskRpk; - - @Autowired - private LwM2MTransportService service; - - - @PostConstruct - public void init() { - LwM2mServerListener lwM2mServerListener = new LwM2mServerListener(lhServerCert, service); - this.lhServerCert.getRegistrationService().addListener(lwM2mServerListener.registrationListener); - this.lhServerCert.getPresenceService().addListener(lwM2mServerListener.presenceListener); - this.lhServerCert.getObservationService().addListener(lwM2mServerListener.observationListener); - lwM2mServerListener = new LwM2mServerListener(lhServerNoSecPskRpk, service); - this.lhServerNoSecPskRpk.getRegistrationService().addListener(lwM2mServerListener.registrationListener); - this.lhServerNoSecPskRpk.getPresenceService().addListener(lwM2mServerListener.presenceListener); - this.lhServerNoSecPskRpk.getObservationService().addListener(lwM2mServerListener.observationListener); - } - - public static NetworkConfig getCoapConfig() { - NetworkConfig coapConfig; - File configFile = new File(NetworkConfig.DEFAULT_FILE_NAME); - if (configFile.isFile()) { - coapConfig = new NetworkConfig(); - coapConfig.load(configFile); - } else { - coapConfig = LeshanServerBuilder.createDefaultNetworkConfig(); - coapConfig.store(configFile); - } - return coapConfig; - } - - public static String getValueTypeToString (Object value, ResourceModel.Type type) { - switch (type) { - case STRING: // String - case OBJLNK: // ObjectLink - return value.toString(); - case INTEGER: // Long - return Long.toString((long) value); - case BOOLEAN: // Boolean - return Boolean.toString((Boolean) value); - case FLOAT: // Double - return Double.toString((Float)value); - case TIME: // Date - String DATE_FORMAT = "MMM d, yyyy HH:mm a"; - DateFormat formatter = new SimpleDateFormat(DATE_FORMAT); - return formatter.format(new Date((Long) Integer.toUnsignedLong(Integer.valueOf((Integer) value)))); - case OPAQUE: // byte[] value, base64 - return Hex.encodeHexString((byte[])value); - default: - return null; - } - } - - public static LwM2mNode getLvM2mNodeToObject(LwM2mNode content) { - if (content instanceof LwM2mObject) { - return (LwM2mObject) content; - } else if (content instanceof LwM2mObjectInstance) { - return (LwM2mObjectInstance) content; - } else if (content instanceof LwM2mSingleResource) { - return (LwM2mSingleResource) content; - } else if (content instanceof LwM2mMultipleResource) { - return (LwM2mMultipleResource) content; - } - return null; - } - - public static AttrTelemetryObserveValue getNewProfileParameters(JsonObject profilesConfigData) { - AttrTelemetryObserveValue attrTelemetryObserveValue = new AttrTelemetryObserveValue(); - attrTelemetryObserveValue.setPostKeyNameProfile(profilesConfigData.get(KEYNAME).getAsJsonObject()); - attrTelemetryObserveValue.setPostAttributeProfile(profilesConfigData.get(ATTRIBUTE).getAsJsonArray()); - attrTelemetryObserveValue.setPostTelemetryProfile(profilesConfigData.get(TELEMETRY).getAsJsonArray()); - attrTelemetryObserveValue.setPostObserveProfile(profilesConfigData.get(OBSERVE).getAsJsonArray()); - return attrTelemetryObserveValue; - } - - /** - - * @return deviceProfileBody with Observe&Attribute&Telemetry From Thingsboard - * Example: with pathResource (use only pathResource) - * property: "observeAttr" - * {"keyName": { - * "/3/0/1": "modelNumber", - * "/3/0/0": "manufacturer", - * "/3/0/2": "serialNumber" - * }, - * "attribute":["/2/0/1","/3/0/9"], - * "telemetry":["/1/0/1","/2/0/1","/6/0/1"], - * "observe":["/2/0","/2/0/0","/4/0/2"]} - */ - public static JsonObject getObserveAttrTelemetryFromThingsboard(DeviceProfile deviceProfile) { - if (deviceProfile != null && ((Lwm2mDeviceProfileTransportConfiguration) deviceProfile.getProfileData().getTransportConfiguration()).getProperties().size() > 0) { - Lwm2mDeviceProfileTransportConfiguration lwm2mDeviceProfileTransportConfiguration = (Lwm2mDeviceProfileTransportConfiguration) deviceProfile.getProfileData().getTransportConfiguration(); - Object observeAttr = ((Lwm2mDeviceProfileTransportConfiguration) deviceProfile.getProfileData().getTransportConfiguration()).getProperties(); - try { - ObjectMapper mapper = new ObjectMapper(); - String observeAttrStr = mapper.writeValueAsString(observeAttr); - JsonObject objectMsg = (observeAttrStr != null) ? validateJson(observeAttrStr) : null; - return (getValidateCredentialsBodyFromThingsboard(objectMsg)) ? objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject() : null; - } catch (IOException e) { - e.printStackTrace(); - } - } - return null; - } - - public static JsonObject getBootstrapParametersFromThingsboard(DeviceProfile deviceProfile) { - if (deviceProfile != null && ((Lwm2mDeviceProfileTransportConfiguration) deviceProfile.getProfileData().getTransportConfiguration()).getProperties().size() > 0) { - Lwm2mDeviceProfileTransportConfiguration lwm2mDeviceProfileTransportConfiguration = (Lwm2mDeviceProfileTransportConfiguration) deviceProfile.getProfileData().getTransportConfiguration(); - Object bootstrap = ((Lwm2mDeviceProfileTransportConfiguration) deviceProfile.getProfileData().getTransportConfiguration()).getProperties(); - try { - ObjectMapper mapper = new ObjectMapper(); - String bootstrapStr = mapper.writeValueAsString(bootstrap); - JsonObject objectMsg = (bootstrapStr != null) ? validateJson(bootstrapStr) : null; - return (getValidateBootstrapProfileFromThingsboard(objectMsg)) ? objectMsg.get(BOOTSTRAP).getAsJsonObject() : null; - } catch (IOException e) { - e.printStackTrace(); - } - } - return null; - } - - private static boolean getValidateCredentialsBodyFromThingsboard(JsonObject objectMsg) { - return (objectMsg != null && - !objectMsg.isJsonNull() && - objectMsg.has(OBSERVE_ATTRIBUTE_TELEMETRY) && - !objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).isJsonNull() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).isJsonObject() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().has(KEYNAME) && - !objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(KEYNAME).isJsonNull() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(KEYNAME).isJsonObject() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().has(ATTRIBUTE) && - !objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(ATTRIBUTE).isJsonNull() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(ATTRIBUTE).isJsonArray() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().has(TELEMETRY) && - !objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(TELEMETRY).isJsonNull() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(TELEMETRY).isJsonArray() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().has(OBSERVE) && - !objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(OBSERVE).isJsonNull() && - objectMsg.get(OBSERVE_ATTRIBUTE_TELEMETRY).getAsJsonObject().get(OBSERVE).isJsonArray()); - } - - private static boolean getValidateBootstrapProfileFromThingsboard(JsonObject objectMsg) { - return (objectMsg != null && - !objectMsg.isJsonNull() && - objectMsg.has(BOOTSTRAP) && - objectMsg.get(BOOTSTRAP).isJsonObject() && - !objectMsg.get(BOOTSTRAP).isJsonNull() && - objectMsg.get(BOOTSTRAP).getAsJsonObject().has(SERVERS) && - !objectMsg.get(BOOTSTRAP).getAsJsonObject().get(SERVERS).isJsonNull() && - objectMsg.get(BOOTSTRAP).getAsJsonObject().get(SERVERS).isJsonObject() && - objectMsg.get(BOOTSTRAP).getAsJsonObject().has(BOOTSTRAP_SERVER) && - !objectMsg.get(BOOTSTRAP).getAsJsonObject().get(BOOTSTRAP_SERVER).isJsonNull() && - objectMsg.get(BOOTSTRAP).getAsJsonObject().get(BOOTSTRAP_SERVER).isJsonObject() && - objectMsg.get(BOOTSTRAP).getAsJsonObject().has(LWM2M_SERVER) && - !objectMsg.get(BOOTSTRAP).getAsJsonObject().get(LWM2M_SERVER).isJsonNull() && - objectMsg.get(BOOTSTRAP).getAsJsonObject().get(LWM2M_SERVER).isJsonObject()); - } - - - public static JsonObject validateJson(String jsonStr) { - JsonObject object = null; - if (jsonStr != null && !jsonStr.isEmpty()) { - String jsonValidFlesh = jsonStr.replaceAll("\\\\", ""); - jsonValidFlesh = jsonValidFlesh.replaceAll("\n", ""); - jsonValidFlesh = jsonValidFlesh.replaceAll("\t", ""); - jsonValidFlesh = jsonValidFlesh.replaceAll(" ", ""); - String jsonValid = (jsonValidFlesh.substring(0, 1).equals("\"") && jsonValidFlesh.substring(jsonValidFlesh.length() - 1).equals("\"")) ? jsonValidFlesh.substring(1, jsonValidFlesh.length() - 1) : jsonValidFlesh; - try { - object = new JsonParser().parse(jsonValid).getAsJsonObject(); - } catch (JsonSyntaxException e) { - log.error("[{}] Fail validateJson [{}]", jsonStr, e.getMessage()); - } - } - return object; - } - - public static Optional decode(byte[] byteArray) { - try { - FSTConfiguration config = FSTConfiguration.createDefaultConfiguration();; - T msg = (T) config.asObject(byteArray); - return Optional.ofNullable(msg); - } catch (IllegalArgumentException e) { - log.error("Error during deserialization message, [{}]", e.getMessage()); - return Optional.empty(); - } - } - - /** - * Equals to Map for values - * @param map1 - * @param map2 - * @param - * @return - */ - public static > boolean mapsEquals(Map map1, Map map2) { - List values1 = new ArrayList(map1.values()); - List values2 = new ArrayList(map2.values()); - Collections.sort(values1); - Collections.sort(values2); - return values1.equals(values2); - } - - public static String convertCamelCase (String str) { - str = str.toLowerCase().replace("/[^a-z ]+/g", " "); - str = str.replace("/^(.)|\\s(.)/g", "$1"); - str = str.replace("/[^a-zA-Z]+/g", ""); - return str; - } - - public static String splitCamelCaseString(String s){ - LinkedList linkedListOut = new LinkedList(); - LinkedList linkedList = new LinkedList((Arrays.asList(s.split(" ")))); - linkedList.stream().forEach(str-> { - String strOut = str.replaceAll("\\W", "").replaceAll("_", "").toUpperCase(); - if (strOut.length()>1) linkedListOut.add(strOut.substring(0, 1) + strOut.substring(1).toLowerCase()); - else linkedListOut.add(strOut); - }); - linkedListOut.set(0, (linkedListOut.get(0).substring(0, 1).toLowerCase() + linkedListOut.get(0).substring(1))); - return StringUtils.join(linkedListOut, ""); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportRequest.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportRequest.java deleted file mode 100644 index 45a85b16bb..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportRequest.java +++ /dev/null @@ -1,335 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.californium.core.coap.Response; -import org.eclipse.leshan.core.attributes.Attribute; -import org.eclipse.leshan.core.attributes.AttributeSet; -import org.eclipse.leshan.core.model.ResourceModel; -import org.eclipse.leshan.core.node.LwM2mSingleResource; -import org.eclipse.leshan.core.node.ObjectLink; -import org.eclipse.leshan.core.observation.Observation; -import org.eclipse.leshan.core.request.ContentFormat; -import org.eclipse.leshan.core.request.WriteRequest; -import org.eclipse.leshan.core.request.DiscoverRequest; -import org.eclipse.leshan.core.request.DownlinkRequest; -import org.eclipse.leshan.core.request.ObserveRequest; -import org.eclipse.leshan.core.request.CancelObservationRequest; -import org.eclipse.leshan.core.request.ReadRequest; -import org.eclipse.leshan.core.request.ExecuteRequest; -import org.eclipse.leshan.core.request.WriteAttributesRequest; -import org.eclipse.leshan.core.response.ResponseCallback; -import org.eclipse.leshan.core.response.LwM2mResponse; -import org.eclipse.leshan.core.response.ObserveResponse; -import org.eclipse.leshan.core.response.ReadResponse; -import org.eclipse.leshan.core.response.CancelObservationResponse; -import org.eclipse.leshan.core.response.DeleteResponse; -import org.eclipse.leshan.core.response.ExecuteResponse; -import org.eclipse.leshan.core.response.DiscoverResponse; -import org.eclipse.leshan.core.response.WriteAttributesResponse; -import org.eclipse.leshan.core.response.WriteResponse; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.core.util.NamedThreadFactory; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.eclipse.leshan.server.registration.Registration; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Service; -import org.thingsboard.server.transport.lwm2m.server.client.LwM2MClient; - -import javax.annotation.PostConstruct; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Date; -import java.util.Iterator; -import java.util.concurrent.ExecutorService; -import java.util.concurrent.Executors; - -import static org.eclipse.californium.core.coap.CoAP.ResponseCode.isSuccess; -import static org.eclipse.leshan.core.attributes.Attribute.MINIMUM_PERIOD; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.DEFAULT_TIMEOUT; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.GET_TYPE_OPER_DISCOVER; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.GET_TYPE_OPER_OBSERVE; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.GET_TYPE_OPER_READ; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.PUT_TYPE_OPER_WRITE_ATTRIBUTES; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.PUT_TYPE_OPER_WRITE_UPDATE; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.POST_TYPE_OPER_EXECUTE; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.POST_TYPE_OPER_OBSERVE_CANCEL; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.POST_TYPE_OPER_WRITE_REPLACE; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.LOG_LW2M_ERROR; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.LOG_LW2M_INFO; - -@Slf4j -@Service("LwM2MTransportRequest") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' ) || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MTransportRequest { - private final ExecutorService executorService; - private static final String RESPONSE_CHANNEL = "THINGSBOARD_RESP"; - - @Autowired - LwM2MTransportService service; - - public LwM2MTransportRequest() { - executorService = Executors.newCachedThreadPool( - new NamedThreadFactory(String.format("LwM2M %s channel response", RESPONSE_CHANNEL))); - } - - - @PostConstruct - public void init() { - } - - public Collection doGetRegistrations(LeshanServer lwServer) { - Collection registrations = new ArrayList<>(); - for (Iterator iterator = lwServer.getRegistrationService().getAllRegistrations(); iterator - .hasNext(); ) { - registrations.add(iterator.next()); - } - return registrations; - } - - /** - * Device management and service enablement, including Read, Write, Execute, Discover, Create, Delete and Write-Attributes - * - * @param lwServer - * @param registration - * @param target - * @param typeOper - * @param contentFormatParam - * @param lwM2MClient - * @param observation - */ - public void sendAllRequest(LeshanServer lwServer, Registration registration, String target, String typeOper, - String contentFormatParam, LwM2MClient lwM2MClient, Observation observation, Object params, long timeoutInMs) { - ResultIds resultIds = new ResultIds(target); - if (registration != null && resultIds.getObjectId() >= 0) { - DownlinkRequest request = null; - ContentFormat contentFormat = contentFormatParam != null ? ContentFormat.fromName(contentFormatParam.toUpperCase()) : null; - ResourceModel resource = (resultIds.resourceId >= 0) ? (lwM2MClient != null) ? - lwM2MClient.getModelObjects().get(resultIds.getObjectId()).getObjectModel().resources.get(resultIds.resourceId) : null : null; - ResourceModel.Type resType = (resource == null) ? null : resource.type; - boolean resMultiple = (resource == null) ? false : resource.multiple; - timeoutInMs = timeoutInMs > 0 ? timeoutInMs : DEFAULT_TIMEOUT; - switch (typeOper) { - case GET_TYPE_OPER_READ: - request = new ReadRequest(contentFormat, target); - break; - case GET_TYPE_OPER_DISCOVER: - request = new DiscoverRequest(target); - break; - case GET_TYPE_OPER_OBSERVE: - if (resultIds.getResourceId() >= 0) { - request = new ObserveRequest(resultIds.getObjectId(), resultIds.getInstanceId(), resultIds.getResourceId()); - } else if (resultIds.getInstanceId() >= 0) { - request = new ObserveRequest(resultIds.getObjectId(), resultIds.getInstanceId()); - } else if (resultIds.getObjectId() >= 0) { - request = new ObserveRequest(resultIds.getObjectId()); - } - break; - case POST_TYPE_OPER_OBSERVE_CANCEL: - request = new CancelObservationRequest(observation); - break; - case POST_TYPE_OPER_EXECUTE: - if (params != null && !resMultiple) { - request = new ExecuteRequest(target, LwM2MTransportHandler.getValueTypeToString(params, resType)); - } else { - request = new ExecuteRequest(target); - } - break; - case POST_TYPE_OPER_WRITE_REPLACE: - // Request to write a String Single-Instance Resource using the TLV content format. - if (contentFormat.equals(ContentFormat.TLV) && !resMultiple) { - request = this.getWriteRequestSingleResource(null, resultIds.getObjectId(), resultIds.getInstanceId(), resultIds.getResourceId(), params, resType); - } - // Mode.REPLACE && Request to write a String Single-Instance Resource using the given content format (TEXT, TLV, JSON) - else if (!contentFormat.equals(ContentFormat.TLV) && !resMultiple) { - request = this.getWriteRequestSingleResource(contentFormat, resultIds.getObjectId(), resultIds.getInstanceId(), resultIds.getResourceId(), params, resType); - } - break; - case PUT_TYPE_OPER_WRITE_UPDATE: - if (resultIds.getResourceId() >= 0) { - ResourceModel resourceModel = lwServer.getModelProvider().getObjectModel(registration).getObjectModel(resultIds.getObjectId()).resources.get(resultIds.getResourceId()); - ResourceModel.Type typeRes = resourceModel.type; -// request = getWriteRequestResource(resultIds.getObjectId(), resultIds.getInstanceId(), resultIds.getResourceId(), params, typeRes); - } - break; - case PUT_TYPE_OPER_WRITE_ATTRIBUTES: - /** - * As example: - * a)Write-Attributes/3/0/9?pmin=1 means the Battery Level value will be notified - * to the Server with a minimum interval of 1sec; - * this value is set at theResource level. - * b)Write-Attributes/3/0/9?pmin means the Battery Level will be notified - * to the Server with a minimum value (pmin) given by the default one - * (resource 2 of Object Server ID=1), - * or with another value if this Attribute has been set at another level - * (Object or Object Instance: see section5.1.1). - * c)Write-Attributes/3/0?pmin=10 means that all Resources of Instance 0 of the Object ‘Device (ID:3)’ - * will be notified to the Server with a minimum interval of 10 sec; - * this value is set at the Object Instance level. - * d)Write-Attributes /3/0/9?gt=45&st=10 means the Battery Level will be notified to the Server - * when: - * a.old value is 20 and new value is 35 due to step condition - * b.old value is 45 and new value is 50 due to gt condition - * c.old value is 50 and new value is 40 due to both gt and step conditions - * d.old value is 35 and new value is 20 due to step conditione) - * Write-Attributes /3/0/9?lt=20>=85&st=10 means the Battery Level will be notified to the Server - * when: - * a.old value is 17 and new value is 24 due to lt condition - * b.old value is 75 and new value is 90 due to both gt and step conditions - * String uriQueries = "pmin=10&pmax=60"; - * AttributeSet attributes = AttributeSet.parse(uriQueries); - * WriteAttributesRequest request = new WriteAttributesRequest(target, attributes); - * Attribute gt = new Attribute(GREATER_THAN, Double.valueOf("45")); - * Attribute st = new Attribute(LESSER_THAN, Double.valueOf("10")); - * Attribute pmax = new Attribute(MAXIMUM_PERIOD, "60"); - * Attribute [] attrs = {gt, st}; - */ - Attribute pmin = new Attribute(MINIMUM_PERIOD, Integer.toUnsignedLong(Integer.valueOf("1"))); - Attribute[] attrs = {pmin}; - AttributeSet attrSet = new AttributeSet(attrs); - if (resultIds.getResourceId() >= 0) { - request = new WriteAttributesRequest(resultIds.getObjectId(), resultIds.getInstanceId(), resultIds.getResourceId(), attrSet); - } else if (resultIds.getInstanceId() >= 0) { - request = new WriteAttributesRequest(resultIds.getObjectId(), resultIds.getInstanceId(), attrSet); - } else if (resultIds.getObjectId() >= 0) { - request = new WriteAttributesRequest(resultIds.getObjectId(), attrSet); - } - break; - default: - } - if (request != null) sendRequest(lwServer, registration, request, lwM2MClient, timeoutInMs); - } - } - - /** - * - * @param lwServer - * @param registration - * @param request - * @param lwM2MClient - * @param timeoutInMs - */ - private void sendRequest(LeshanServer lwServer, Registration registration, DownlinkRequest request, LwM2MClient lwM2MClient, long timeoutInMs) { - lwServer.send(registration, request, timeoutInMs, (ResponseCallback) response -> { - if (isSuccess(((Response)response.getCoapResponse()).getCode())) { - this.handleResponse(registration, request.getPath().toString(), response, request, lwM2MClient); - if (request instanceof WriteRequest && ((WriteRequest) request).isReplaceRequest()) { - String msg = String.format(LOG_LW2M_INFO + " sendRequest Replace: CoapCde - %s Lwm2m code - %d name - %s Resource path - %s value - %s SendRequest to Client", - ((Response)response.getCoapResponse()).getCode(), response.getCode().getCode(), response.getCode().getName(), request.getPath().toString(), - ((LwM2mSingleResource)((WriteRequest) request).getNode()).getValue().toString()); - service.sentLogsToThingsboard(msg, registration.getId()); - log.info("[{}] - [{}] [{}] [{}] Update SendRequest", ((Response)response.getCoapResponse()).getCode(), response.getCode(), request.getPath().toString(), ((LwM2mSingleResource)((WriteRequest) request).getNode()).getValue()); - } - } - else { - String msg = String.format(LOG_LW2M_ERROR + " sendRequest: CoapCde - %s Lwm2m code - %d name - %s Resource path - %s SendRequest to Client", - ((Response)response.getCoapResponse()).getCode(), response.getCode().getCode(), response.getCode().getName(), request.getPath().toString()); - service.sentLogsToThingsboard(msg, registration.getId()); - log.error("[{}] - [{}] [{}] error SendRequest", ((Response)response.getCoapResponse()).getCode(), response.getCode(), request.getPath().toString()); - } - }, e -> { - String msg = String.format(LOG_LW2M_ERROR + " sendRequest: Resource path - %s msg error - %s SendRequest to Client", - request.getPath().toString(), e.toString()); - service.sentLogsToThingsboard(msg, registration.getId()); - log.error("[{}] - [{}] error SendRequest", request.getPath().toString(), e.toString()); - }); - } - - private WriteRequest getWriteRequestSingleResource(ContentFormat contentFormat, Integer objectId, Integer instanceId, Integer resourceId, Object value, ResourceModel.Type type) { - try { - switch (type) { - case STRING: // String - return (contentFormat == null) ? new WriteRequest(objectId, instanceId, resourceId, value.toString()) : new WriteRequest(contentFormat, objectId, instanceId, resourceId, value.toString()); - case INTEGER: // Long - return (contentFormat == null) ? new WriteRequest(objectId, instanceId, resourceId, Integer.toUnsignedLong(Integer.valueOf(value.toString()))) : new WriteRequest(contentFormat, objectId, instanceId, resourceId, Integer.toUnsignedLong(Integer.valueOf(value.toString()))); - case OBJLNK: // ObjectLink - return (contentFormat == null) ? new WriteRequest(objectId, instanceId, resourceId, ObjectLink.fromPath(value.toString())) : new WriteRequest(contentFormat, objectId, instanceId, resourceId, ObjectLink.fromPath(value.toString())); - case BOOLEAN: // Boolean - return (contentFormat == null) ? new WriteRequest(objectId, instanceId, resourceId, Boolean.valueOf(value.toString())) : new WriteRequest(contentFormat, objectId, instanceId, resourceId, Boolean.valueOf(value.toString())); - case FLOAT: // Double - return (contentFormat == null) ? new WriteRequest(objectId, instanceId, resourceId, Double.valueOf(value.toString())) : new WriteRequest(contentFormat, objectId, instanceId, resourceId, Double.valueOf(value.toString())); - case TIME: // Date - return (contentFormat == null) ? new WriteRequest(objectId, instanceId, resourceId, new Date((Long) Integer.toUnsignedLong(Integer.valueOf(value.toString())))) : new WriteRequest(contentFormat, objectId, instanceId, resourceId, new Date((Long) Integer.toUnsignedLong(Integer.valueOf(value.toString())))); - case OPAQUE: // byte[] value, base64 - return (contentFormat == null) ? new WriteRequest(objectId, instanceId, resourceId, Hex.decodeHex(value.toString().toCharArray())) : new WriteRequest(contentFormat, objectId, instanceId, resourceId, Hex.decodeHex(value.toString().toCharArray())); - default: - } - return null; - } catch (NumberFormatException e) { - String patn = "/" + objectId + "/" + instanceId + "/" + resourceId; - log.error("Path: [{}] type: [{}] value: [{}] errorMsg: [{}]]", patn, type, value, e.toString()); - return null; - } - } - - private void handleResponse(Registration registration, final String path, LwM2mResponse response, DownlinkRequest request, LwM2MClient lwM2MClient) { - executorService.submit(new Runnable() { - @Override - public void run() { - - try { - sendResponse(registration, path, response, request, lwM2MClient); - } catch (RuntimeException t) { - log.error("[{}] endpoint [{}] path [{}] error Unable to after send response.", registration.getEndpoint(), path, t.toString()); - } - } - }); - } - - /** - * processing a response from a client - * @param registration - - * @param path - - * @param response - - * @param lwM2MClient - - */ - private void sendResponse(Registration registration, String path, LwM2mResponse response, DownlinkRequest request, LwM2MClient lwM2MClient) { - if (response instanceof ObserveResponse) { - service.onObservationResponse(registration, path, (ReadResponse) response); - } else if (response instanceof CancelObservationResponse) { - log.info("[{}] Path [{}] CancelObservationResponse 3_Send", path, response); - } else if (response instanceof ReadResponse) { - /** - * Use only at the first start after registration - * Fill with data -> Model client - */ - if (lwM2MClient != null) { - if (lwM2MClient.getPendingRequests().size() > 0) { - lwM2MClient.onSuccessHandler(path, response); - } - } - /** - * Use after registration on request - */ - else { - service.onObservationResponse(registration, path, (ReadResponse) response); - } - } else if (response instanceof DeleteResponse) { - log.info("[{}] Path [{}] DeleteResponse 5_Send", path, response); - } else if (response instanceof DiscoverResponse) { - log.info("[{}] Path [{}] DiscoverResponse 6_Send", path, response); - } else if (response instanceof ExecuteResponse) { - log.info("[{}] Path [{}] ExecuteResponse 7_Send", path, response); - } else if (response instanceof WriteAttributesResponse) { - log.info("[{}] Path [{}] WriteAttributesResponse 8_Send", path, response); - } else if (response instanceof WriteResponse) { - log.info("[{}] Path [{}] WriteAttributesResponse 9_Send", path, response); - service.onAttributeUpdateOk(registration, path, (WriteRequest) request); - } - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerConfiguration.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerConfiguration.java deleted file mode 100644 index 2725e80e2b..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerConfiguration.java +++ /dev/null @@ -1,102 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.californium.scandium.config.DtlsConnectorConfig; -import org.eclipse.leshan.core.node.codec.DefaultLwM2mNodeDecoder; -import org.eclipse.leshan.core.node.codec.DefaultLwM2mNodeEncoder; -import org.eclipse.leshan.core.node.codec.LwM2mNodeDecoder; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.eclipse.leshan.server.californium.LeshanServerBuilder; -import org.eclipse.leshan.server.model.LwM2mModelProvider; -import org.eclipse.leshan.server.model.VersionedModelProvider; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.ComponentScan; -import org.springframework.context.annotation.Configuration; -import org.springframework.context.annotation.Primary; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; -import org.thingsboard.server.transport.lwm2m.server.secure.LwM2MSetSecurityStoreServer; -import org.thingsboard.server.transport.lwm2m.server.secure.LwM2mInMemorySecurityStore; -import org.thingsboard.server.transport.lwm2m.utils.LwM2mValueConverterImpl; -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.X509; -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.RPK; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.getCoapConfig; - - -@Slf4j -@ComponentScan("org.thingsboard.server.transport.lwm2m.server") -@ComponentScan("org.thingsboard.server.transport.lwm2m.utils") -@Configuration("LwM2MTransportServerConfiguration") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' ) || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MTransportServerConfiguration { - - @Autowired - private LwM2MTransportContextServer context; - - @Autowired - private LwM2mInMemorySecurityStore lwM2mInMemorySecurityStore; - - @Primary - @Bean(name = "LeshanServerCert") - public LeshanServer getLeshanServerCert() { - log.info("Starting LwM2M transport ServerCert... PostConstruct"); - return getLeshanServer(this.context.getCtxServer().getServerPortCert(), this.context.getCtxServer().getServerSecurePortCert(), X509); - } - - @Bean(name = "leshanServerNoSecPskRpk") - public LeshanServer getLeshanServerNoSecPskRpk() { - log.info("Starting LwM2M transport ServerNoSecPskRpk... PostConstruct"); - return getLeshanServer(this.context.getCtxServer().getServerPort(), this.context.getCtxServer().getServerSecurePort(), RPK); - } - - private LeshanServer getLeshanServer(Integer serverPort, Integer serverSecurePort, LwM2MSecurityMode dtlsMode) { - - LeshanServerBuilder builder = new LeshanServerBuilder(); - builder.setLocalAddress(this.context.getCtxServer().getServerHost(), serverPort); - builder.setLocalSecureAddress(this.context.getCtxServer().getServerSecureHost(), serverSecurePort); - builder.setEncoder(new DefaultLwM2mNodeEncoder()); - LwM2mNodeDecoder decoder = new DefaultLwM2mNodeDecoder(); - builder.setDecoder(decoder); - builder.setEncoder(new DefaultLwM2mNodeEncoder(new LwM2mValueConverterImpl())); - - /** Create CoAP Config */ - builder.setCoapConfig(getCoapConfig()); - - /** Define model provider (Create Models )*/ - LwM2mModelProvider modelProvider = new VersionedModelProvider(this.context.getCtxServer().getModelsValue()); - builder.setObjectModelProvider(modelProvider); - - /** Create DTLS Config */ - DtlsConnectorConfig.Builder dtlsConfig = new DtlsConnectorConfig.Builder(); - dtlsConfig.setRecommendedCipherSuitesOnly(this.context.getCtxServer().isSupportDeprecatedCiphersEnable()); - /** Set DTLS Config */ - builder.setDtlsConfig(dtlsConfig); - - /** Use a magic converter to support bad type send by the UI. */ - builder.setEncoder(new DefaultLwM2mNodeEncoder(new LwM2mValueConverterImpl())); - - /** Create DTLS security mode - * There can be only one DTLS security mode - */ - new LwM2MSetSecurityStoreServer(builder, context, lwM2mInMemorySecurityStore, dtlsMode); - - /** Create LWM2M server */ - return builder.build(); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerInitializer.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerInitializer.java deleted file mode 100644 index 4a43407a73..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportServerInitializer.java +++ /dev/null @@ -1,72 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.beans.factory.annotation.Qualifier; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Service; -import org.thingsboard.server.transport.lwm2m.secure.LWM2MGenerationPSkRPkECC; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; -import javax.annotation.PostConstruct; -import javax.annotation.PreDestroy; - -@Slf4j -@Service("LwM2MTransportServerInitializer") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' ) || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MTransportServerInitializer { - - @Autowired - @Qualifier("LeshanServerCert") - private LeshanServer lhServerCert; - - @Autowired - @Qualifier("leshanServerNoSecPskRpk") - private LeshanServer lhServerNoSecPskRpk; - - @Autowired - private LwM2MTransportContextServer context; - - @PostConstruct - public void init() { - if (this.context.getCtxServer().getEnableGenPskRpk()) new LWM2MGenerationPSkRPkECC(); - if (this.context.getCtxServer().isServerStartAll()) { - this.lhServerCert.start(); - this.lhServerNoSecPskRpk.start(); - } - else { - if (this.context.getCtxServer().getServerDtlsMode() == LwM2MSecurityMode.X509.code) { - this.lhServerCert.start(); - } - else { - this.lhServerNoSecPskRpk.start(); - } - } - } - - @PreDestroy - public void shutdown() { - log.info("Stopping LwM2M transport Server!"); - try { - lhServerCert.destroy(); - lhServerNoSecPskRpk.destroy(); - } finally { - } - log.info("LwM2M transport Server stopped!"); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportService.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportService.java deleted file mode 100644 index 7ff68b928c..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2MTransportService.java +++ /dev/null @@ -1,999 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import com.google.gson.*; -import lombok.SneakyThrows; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.model.ResourceModel; -import org.eclipse.leshan.core.node.LwM2mMultipleResource; -import org.eclipse.leshan.core.node.LwM2mObject; -import org.eclipse.leshan.core.node.LwM2mObjectInstance; -import org.eclipse.leshan.core.node.LwM2mSingleResource; -import org.eclipse.leshan.core.node.LwM2mResource; -import org.eclipse.leshan.core.node.LwM2mPath; -import org.eclipse.leshan.core.observation.Observation; -import org.eclipse.leshan.core.request.ContentFormat; -import org.eclipse.leshan.core.request.WriteRequest; -import org.eclipse.leshan.core.response.ReadResponse; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.eclipse.leshan.server.registration.Registration; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Service; -import org.thingsboard.server.common.data.Device; -import org.thingsboard.server.common.data.DeviceProfile; -import org.thingsboard.server.common.transport.TransportService; -import org.thingsboard.server.common.transport.TransportServiceCallback; -import org.thingsboard.server.common.transport.adaptor.AdaptorException; -import org.thingsboard.server.common.transport.adaptor.JsonConverter; -import org.thingsboard.server.common.transport.service.DefaultTransportService; -import org.thingsboard.server.gen.transport.TransportProtos; -import org.thingsboard.server.gen.transport.TransportProtos.ToTransportUpdateCredentialsProto; -import org.thingsboard.server.gen.transport.TransportProtos.SessionEvent; -import org.thingsboard.server.gen.transport.TransportProtos.SessionInfoProto; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceCredentialsResponseMsg; -import org.thingsboard.server.gen.transport.TransportProtos.PostTelemetryMsg; -import org.thingsboard.server.gen.transport.TransportProtos.PostAttributeMsg; -import org.thingsboard.server.transport.lwm2m.server.adaptors.LwM2MJsonAdaptor; -import org.thingsboard.server.transport.lwm2m.server.client.AttrTelemetryObserveValue; -import org.thingsboard.server.transport.lwm2m.server.client.LwM2MClient; -import org.thingsboard.server.transport.lwm2m.server.client.ModelObject; -import org.thingsboard.server.transport.lwm2m.server.client.ResultsAnalyzerParameters; -import org.thingsboard.server.transport.lwm2m.server.client.ResourceValue; -import org.thingsboard.server.transport.lwm2m.server.secure.LwM2mInMemorySecurityStore; - -import javax.annotation.PostConstruct; -import java.util.Collection; -import java.util.UUID; -import java.util.Random; -import java.util.Map; -import java.util.HashMap; -import java.util.Arrays; -import java.util.Set; -import java.util.HashSet; -import java.util.NoSuchElementException; -import java.util.Optional; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.CountDownLatch; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.function.Predicate; -import java.util.stream.Collectors; -import java.util.stream.Stream; - -import static org.eclipse.leshan.core.model.ResourceModel.Type.OPAQUE; -import static org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler.*; - -@Slf4j -@Service("LwM2MTransportService") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' ) || ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MTransportService { - - @Autowired - private LwM2MJsonAdaptor adaptor; - - @Autowired - private TransportService transportService; - - @Autowired - public LwM2MTransportContextServer context; - - @Autowired - private LwM2MTransportRequest lwM2MTransportRequest; - - @Autowired - LwM2mInMemorySecurityStore lwM2mInMemorySecurityStore; - - - @PostConstruct - public void init() { - context.getScheduler().scheduleAtFixedRate(() -> checkInactivityAndReportActivity(), new Random().nextInt((int) context.getCtxServer().getSessionReportTimeout()), context.getCtxServer().getSessionReportTimeout(), TimeUnit.MILLISECONDS); - } - - /** - * Start registration device - * Create session: Map, LwM2MClient> - * 1. replaceNewRegistration -> (solving the problem of incorrect termination of the previous session with this endpoint) - * 1.1 When we initialize the registration, we register the session by endpoint. - * 1.2 If the server has incomplete requests (canceling the registration of the previous session), - * delete the previous session only by the previous registration.getId - * 1.2 Add Model (Entity) for client (from registration & observe) by registration.getId - * 1.2 Remove from sessions Model by enpPoint - * Next -> Create new LwM2MClient for current session -> setModelClient... - * - * @param lwServer - LeshanServer - * @param registration - Registration LwM2M Client - * @param previousObsersations - may be null - */ - public void onRegistered(LeshanServer lwServer, Registration registration, Collection previousObsersations) { - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getlwM2MClient(lwServer, registration); - if (lwM2MClient != null) { - lwM2MClient.setLwM2MTransportService(this); - lwM2MClient.setLwM2MTransportService(this); - lwM2MClient.setSessionUuid(UUID.randomUUID()); - this.setLwM2MClient(lwServer, registration, lwM2MClient); - SessionInfoProto sessionInfo = this.getValidateSessionInfo(registration.getId()); - if (sessionInfo != null) { - lwM2MClient.setDeviceUuid(new UUID(sessionInfo.getDeviceIdMSB(), sessionInfo.getDeviceIdLSB())); - lwM2MClient.setProfileUuid(new UUID(sessionInfo.getDeviceProfileIdMSB(), sessionInfo.getDeviceProfileIdLSB())); - lwM2MClient.setDeviceName(sessionInfo.getDeviceName()); - lwM2MClient.setDeviceProfileName(sessionInfo.getDeviceType()); - transportService.registerAsyncSession(sessionInfo, new LwM2MSessionMsgListener(this, sessionInfo)); - transportService.process(sessionInfo, DefaultTransportService.getSessionEventMsg(SessionEvent.OPEN), null); - transportService.process(sessionInfo, TransportProtos.SubscribeToAttributeUpdatesMsg.newBuilder().build(), null); - this.sentLogsToThingsboard(LOG_LW2M_INFO + ": Client registration", registration.getId()); - } else { - log.error("Client: [{}] onRegistered [{}] name [{}] sessionInfo ", registration.getId(), registration.getEndpoint(), sessionInfo); - } - } else { - log.error("Client: [{}] onRegistered [{}] name [{}] lwM2MClient ", registration.getId(), registration.getEndpoint(), lwM2MClient); - } - } - - /** - * @param lwServer - LeshanServer - * @param registration - Registration LwM2M Client - */ - public void updatedReg(LeshanServer lwServer, Registration registration) { - SessionInfoProto sessionInfo = this.getValidateSessionInfo(registration.getId()); - if (sessionInfo != null) { - log.info("Client: [{}] updatedReg [{}] name [{}] profile ", registration.getId(), registration.getEndpoint(), sessionInfo.getDeviceType()); - } else { - log.error("Client: [{}] updatedReg [{}] name [{}] sessionInfo ", registration.getId(), registration.getEndpoint(), sessionInfo); - } - } - - /** - * @param registration - Registration LwM2M Client - * @param observations - All paths observations before unReg - * !!! Warn: if have not finishing unReg, then this operation will be finished on next Client`s connect - */ - public void unReg(Registration registration, Collection observations) { - this.sentLogsToThingsboard(LOG_LW2M_INFO + ": Client unRegistration", registration.getId()); - this.closeClientSession(registration); - } - - private void closeClientSession(Registration registration) { - SessionInfoProto sessionInfo = this.getValidateSessionInfo(registration.getId()); - if (sessionInfo != null) { - transportService.deregisterSession(sessionInfo); - this.doCloseSession(sessionInfo); - lwM2mInMemorySecurityStore.delRemoveSessionAndListener(registration.getId()); - if (lwM2mInMemorySecurityStore.getProfiles().size() > 0) { - this.syncSessionsAndProfiles(); - } - log.info("Client: [{}] unReg [{}] name [{}] profile ", registration.getId(), registration.getEndpoint(), sessionInfo.getDeviceType()); - } else { - log.error("Client: [{}] unReg [{}] name [{}] sessionInfo ", registration.getId(), registration.getEndpoint(), sessionInfo); - } - } - - public void onSleepingDev(Registration registration) { - log.info("[{}] [{}] Received endpoint Sleeping version event", registration.getId(), registration.getEndpoint()); - //TODO: associate endpointId with device information. - } - - /** - * Those methods are called by the protocol stage thread pool, this means that execution MUST be done in a short delay, - * * if you need to do long time processing use a dedicated thread pool. - * - * @param registration - */ - - public void onAwakeDev(Registration registration) { - log.info("[{}] [{}] Received endpoint Awake version event", registration.getId(), registration.getEndpoint()); - //TODO: associate endpointId with device information. - } - - /** - * This method is used to sync with sessions - * Removes a profile if not used in sessions - */ - private void syncSessionsAndProfiles() { - Map profilesClone = lwM2mInMemorySecurityStore.getProfiles().entrySet() - .stream() - .collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue)); - profilesClone.forEach((k, v) -> { - String registrationId = lwM2mInMemorySecurityStore.getSessions().entrySet() - .stream() - .filter(e -> e.getValue().getProfileUuid().equals(k)) - .findFirst() - .map(Map.Entry::getKey) // return the key of the matching entry if found - .orElse(""); - if (registrationId.isEmpty()) { - lwM2mInMemorySecurityStore.getProfiles().remove(k); - } - }); - } - - /** - * Create new LwM2MClient for current session -> setModelClient... - * #1 Add all ObjectLinks (instance) to control the process of executing requests to the client - * to get the client model with current values - * #2 Get the client model with current values. Analyze the response in -> lwM2MTransportRequest.sendResponse - * - * @param lwServer - LeshanServer - * @param registration - Registration LwM2M Client - * @param lwM2MClient - object with All parameters off client - */ - private void setLwM2MClient(LeshanServer lwServer, Registration registration, LwM2MClient lwM2MClient) { - // #1 - Arrays.stream(registration.getObjectLinks()).forEach(url -> { - ResultIds pathIds = new ResultIds(url.getUrl()); - if (pathIds.instanceId > -1 && pathIds.resourceId == -1) { - lwM2MClient.getPendingRequests().add(url.getUrl()); - } - }); - // #2 - Arrays.stream(registration.getObjectLinks()).forEach(url -> { - ResultIds pathIds = new ResultIds(url.getUrl()); - if (pathIds.instanceId > -1 && pathIds.resourceId == -1) { - lwM2MTransportRequest.sendAllRequest(lwServer, registration, url.getUrl(), GET_TYPE_OPER_READ, - ContentFormat.TLV.getName(), lwM2MClient, null, null, this.context.getCtxServer().getTimeout()); - } - }); - } - - /** - * @param registrationId - Id of Registration LwM2M Client - * @return - sessionInfo after access connect client - */ - private SessionInfoProto getValidateSessionInfo(String registrationId) { - SessionInfoProto sessionInfo = null; - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getlwM2MClient(registrationId); - if (lwM2MClient != null) { - ValidateDeviceCredentialsResponseMsg msg = lwM2MClient.getCredentialsResponse(); - if (msg == null || msg.getDeviceInfo() == null) { - log.error("[{}] [{}]", lwM2MClient.getEndPoint(), CLIENT_NOT_AUTHORIZED); - this.closeClientSession(lwM2MClient.getRegistration()); - } else { - sessionInfo = SessionInfoProto.newBuilder() - .setNodeId(this.context.getNodeId()) - .setSessionIdMSB(lwM2MClient.getSessionUuid().getMostSignificantBits()) - .setSessionIdLSB(lwM2MClient.getSessionUuid().getLeastSignificantBits()) - .setDeviceIdMSB(msg.getDeviceInfo().getDeviceIdMSB()) - .setDeviceIdLSB(msg.getDeviceInfo().getDeviceIdLSB()) - .setTenantIdMSB(msg.getDeviceInfo().getTenantIdMSB()) - .setTenantIdLSB(msg.getDeviceInfo().getTenantIdLSB()) - .setDeviceName(msg.getDeviceInfo().getDeviceName()) - .setDeviceType(msg.getDeviceInfo().getDeviceType()) - .setDeviceProfileIdLSB(msg.getDeviceInfo().getDeviceProfileIdLSB()) - .setDeviceProfileIdMSB(msg.getDeviceInfo().getDeviceProfileIdMSB()) - .build(); - } - } - return sessionInfo; - } - - /** - * Add attribute/telemetry information from Client and credentials/Profile to client model and start observe - * !!! if the resource has an observation, but no telemetry or attribute - the observation will not use - * #1 Client`s starting info to send to thingsboard - * #2 Sending Attribute Telemetry with value to thingsboard only once at the start of the connection - * #3 Start observe - * - * @param lwServer - LeshanServer - * @param registration - Registration LwM2M Client - */ - - public void updatesAndSentModelParameter(LeshanServer lwServer, Registration registration) { - // #1 -// this.setParametersToModelClient(registration, modelClient, deviceProfile); - // #2 - this.updateAttrTelemetry(registration, true, null); - // #3 - this.onSentObserveToClient(lwServer, registration); - } - - - /** - * Sent Attribute and Telemetry to Thingsboard - * #1 - get AttrName/TelemetryName with value: - * #1.1 from Client - * #1.2 from LwM2MClient: - * -- resourceId == path from AttrTelemetryObserveValue.postAttributeProfile/postTelemetryProfile/postObserveProfile - * -- AttrName/TelemetryName == resourceName from ModelObject.objectModel, value from ModelObject.instance.resource(resourceId) - * #2 - set Attribute/Telemetry - * - * @param registration - Registration LwM2M Client - */ - private void updateAttrTelemetry(Registration registration, boolean start, Set paths) { - JsonObject attributes = new JsonObject(); - JsonObject telemetrys = new JsonObject(); - if (start) { - // #1.1 - JsonObject attributeClient = this.getAttributeClient(registration); - if (attributeClient != null) { - attributeClient.entrySet().forEach(p -> { - attributes.add(p.getKey(), p.getValue()); - }); - } - } - // #1.2 - CountDownLatch cancelLatch = new CountDownLatch(1); - this.getParametersFromProfile(attributes, telemetrys, registration, paths); - cancelLatch.countDown(); - try { - cancelLatch.await(DEFAULT_TIMEOUT, TimeUnit.MILLISECONDS); - } catch (InterruptedException e) { - log.error("[{}] updateAttrTelemetry", e.toString()); - } - if (attributes.getAsJsonObject().entrySet().size() > 0) - this.updateParametersOnThingsboard(attributes, DEVICE_ATTRIBUTES_TOPIC, registration.getId()); - if (telemetrys.getAsJsonObject().entrySet().size() > 0) - this.updateParametersOnThingsboard(telemetrys, DEVICE_TELEMETRY_TOPIC, registration.getId()); - } - - /** - * get AttrName/TelemetryName with value from Client - * - * @param registration - - * @return - JsonObject, format: {name: value}} - */ - private JsonObject getAttributeClient(Registration registration) { - if (registration.getAdditionalRegistrationAttributes().size() > 0) { - JsonObject resNameValues = new JsonObject(); - registration.getAdditionalRegistrationAttributes().entrySet().forEach(entry -> { - resNameValues.addProperty(entry.getKey(), entry.getValue()); - }); - return resNameValues; - } - return null; - } - - /** - * @param attributes - new JsonObject - * @param telemetry - new JsonObject - * @param registration - Registration LwM2M Client - * result: add to JsonObject those resources to which the user is subscribed and they have a value - * if path==null add All resources else only one - * (attributes/telemetry): new {name(Attr/Telemetry):value} - */ - private void getParametersFromProfile(JsonObject attributes, JsonObject telemetry, Registration registration, Set path) { - AttrTelemetryObserveValue attrTelemetryObserveValue = lwM2mInMemorySecurityStore.getProfiles().get(lwM2mInMemorySecurityStore.getSessions().get(registration.getId()).getProfileUuid()); - attrTelemetryObserveValue.getPostAttributeProfile().forEach(p -> { - ResultIds pathIds = new ResultIds(p.getAsString().toString()); - if (pathIds.getResourceId() > -1) { - if (path == null || path.contains(p.getAsString())) { - this.addParameters(pathIds, p.getAsString().toString(), attributes, registration); - } - } - }); - attrTelemetryObserveValue.getPostTelemetryProfile().forEach(p -> { - ResultIds pathIds = new ResultIds(p.getAsString().toString()); - if (pathIds.getResourceId() > -1) { - if (path == null || path.contains(p.getAsString())) { - this.addParameters(pathIds, p.getAsString().toString(), telemetry, registration); - } - } - }); - } - - /** - * @param pathIds - path resource - * @param parameters - JsonObject attributes/telemetry - * @param registration - Registration LwM2M Client - */ - private void addParameters(ResultIds pathIds, String path, JsonObject parameters, Registration registration) { - ModelObject modelObject = lwM2mInMemorySecurityStore.getSessions().get(registration.getId()).getModelObjects().get(pathIds.getObjectId()); - JsonObject names = lwM2mInMemorySecurityStore.getProfiles().get(lwM2mInMemorySecurityStore.getSessions().get(registration.getId()).getProfileUuid()).getPostKeyNameProfile(); - String resName = String.valueOf(names.get(path)); - if (modelObject != null && resName != null && !resName.isEmpty()) { - String resValue = this.getResourceValue(modelObject, pathIds); - if (resValue != null) { - parameters.addProperty(resName, resValue); - } - } - } - - /** - * @param modelObject - ModelObject of Client - * @param pathIds - path resource - * @return - value of Resource or null - */ - private String getResourceValue(ModelObject modelObject, ResultIds pathIds) { - String resValue = null; - if (modelObject.getInstances().get(pathIds.getInstanceId()) != null) { - LwM2mObjectInstance instance = modelObject.getInstances().get(pathIds.getInstanceId()); - if (instance.getResource(pathIds.getResourceId()) != null) { - resValue = instance.getResource(pathIds.getResourceId()).getType() == OPAQUE ? - Hex.encodeHexString((byte[]) instance.getResource(pathIds.getResourceId()).getValue()).toLowerCase() : - (instance.getResource(pathIds.getResourceId()).isMultiInstances()) ? - instance.getResource(pathIds.getResourceId()).getValues().toString() : - instance.getResource(pathIds.getResourceId()).getValue().toString(); - } - } - return resValue; - } - - /** - * Prepare Sent to Thigsboard callback - Attribute or Telemetry - * - * @param msg - JsonArray: [{name: value}] - * @param topicName - Api Attribute or Telemetry - * @param registrationId - Id of Registration LwM2M Client - */ - public void updateParametersOnThingsboard(JsonElement msg, String topicName, String registrationId) { - SessionInfoProto sessionInfo = this.getValidateSessionInfo(registrationId); - if (sessionInfo != null) { - try { - if (topicName.equals(LwM2MTransportHandler.DEVICE_ATTRIBUTES_TOPIC)) { - PostAttributeMsg postAttributeMsg = adaptor.convertToPostAttributes(msg); - TransportServiceCallback call = this.getPubAckCallbackSentAttrTelemetry(-1, postAttributeMsg); - transportService.process(sessionInfo, postAttributeMsg, call); - } else if (topicName.equals(LwM2MTransportHandler.DEVICE_TELEMETRY_TOPIC)) { - PostTelemetryMsg postTelemetryMsg = adaptor.convertToPostTelemetry(msg); - TransportServiceCallback call = this.getPubAckCallbackSentAttrTelemetry(-1, postTelemetryMsg); - transportService.process(sessionInfo, postTelemetryMsg, this.getPubAckCallbackSentAttrTelemetry(-1, call)); - } - } catch (AdaptorException e) { - log.error("[{}] Failed to process publish msg [{}]", topicName, e); - log.info("[{}] Closing current session due to invalid publish", topicName); - } - } else { - log.error("Client: [{}] updateParametersOnThingsboard [{}] sessionInfo ", registrationId, sessionInfo); - } - } - - /** - * Sent to Thingsboard Attribute || Telemetry - * - * @param msgId - always == -1 - * @param msg - JsonObject: [{name: value}] - * @return - dummy - */ - private TransportServiceCallback getPubAckCallbackSentAttrTelemetry(final int msgId, final T msg) { - return new TransportServiceCallback() { - @Override - public void onSuccess(Void dummy) { - log.trace("Success to publish msg: {}, dummy: {}", msg, dummy); - } - - @Override - public void onError(Throwable e) { - log.trace("[{}] Failed to publish msg: {}", msg, e); - } - }; - } - - - /** - * Start observe - * #1 - Analyze: - * #1.1 path in observe == (attribute or telemetry) - * #1.2 recourseValue notNull - * #2 Analyze after sent request (response): - * #2.1 First: lwM2MTransportRequest.sendResponse -> ObservationListener.newObservation - * #2.2 Next: ObservationListener.onResponse * - * - * @param lwServer - LeshanServer - * @param registration - Registration LwM2M Client - */ - private void onSentObserveToClient(LeshanServer lwServer, Registration registration) { - if (lwServer.getObservationService().getObservations(registration).size() > 0) { - this.setCancelObservations(lwServer, registration); - } - UUID profileUUid = lwM2mInMemorySecurityStore.getSessions().get(registration.getId()).getProfileUuid(); - AttrTelemetryObserveValue attrTelemetryObserveValue = lwM2mInMemorySecurityStore.getProfiles().get(profileUUid); - attrTelemetryObserveValue.getPostObserveProfile().forEach(p -> { - // #1.1 - String target = (getValidateObserve(attrTelemetryObserveValue.getPostAttributeProfile(), p.getAsString().toString())) ? - p.getAsString().toString() : (getValidateObserve(attrTelemetryObserveValue.getPostTelemetryProfile(), p.getAsString().toString())) ? - p.getAsString().toString() : null; - if (target != null) { - // #1.2 - ResultIds pathIds = new ResultIds(target); - ModelObject modelObject = lwM2mInMemorySecurityStore.getSessions().get(registration.getId()).getModelObjects().get(pathIds.getObjectId()); - // #2 - if (modelObject != null) { - if (getResourceValue(modelObject, pathIds) != null) { - lwM2MTransportRequest.sendAllRequest(lwServer, registration, target, GET_TYPE_OPER_OBSERVE, - null, null, null, null, this.context.getCtxServer().getTimeout()); - } - } - } - }); - } - - public void setCancelObservations(LeshanServer lwServer, Registration registration) { - if (registration != null) { - Set observations = lwServer.getObservationService().getObservations(registration); - observations.forEach(observation -> { - this.setCancelObservationRecourse(lwServer, registration, observation.getPath().toString()); - }); - } - } - - /** - * lwM2MTransportRequest.sendAllRequest(lwServer, registration, path, POST_TYPE_OPER_OBSERVE_CANCEL, null, null, null, null, context.getTimeout()); - * At server side this will not remove the observation from the observation store, to do it you need to use - * {@code ObservationService#cancelObservation()} - */ - public void setCancelObservationRecourse(LeshanServer lwServer, Registration registration, String path) { - CountDownLatch cancelLatch = new CountDownLatch(1); - lwServer.getObservationService().cancelObservations(registration, path); - cancelLatch.countDown(); - try { - cancelLatch.await(DEFAULT_TIMEOUT, TimeUnit.MILLISECONDS); - } catch (InterruptedException e) { - } - } - - /** - * @param parameters - JsonArray postAttributeProfile/postTelemetryProfile - * @param path - recourse from postObserveProfile - * @return rez - true if path observe is in attribute/telemetry - */ - private boolean getValidateObserve(JsonElement parameters, String path) { - AtomicBoolean rez = new AtomicBoolean(false); - if (parameters.isJsonArray()) { - parameters.getAsJsonArray().forEach(p -> { - if (p.getAsString().toString().equals(path)) rez.set(true); - } - ); - } else if (parameters.isJsonObject()) { - rez.set((parameters.getAsJsonObject().entrySet()).stream().map(json -> json.toString()) - .filter(path::equals).findAny().orElse(null) != null); - } - return rez.get(); - } - - /** - * Sending observe value to thingsboard from ObservationListener.onResponse: object, instance, SingleResource or MultipleResource - * - * @param registration - Registration LwM2M Client - * @param path - observe - * @param response - observe - */ - @SneakyThrows - public void onObservationResponse(Registration registration, String path, ReadResponse response) { - if (response.getContent() != null) { - if (response.getContent() instanceof LwM2mObject) { - LwM2mObject content = (LwM2mObject) response.getContent(); - String target = "/" + content.getId(); - } else if (response.getContent() instanceof LwM2mObjectInstance) { - LwM2mObjectInstance content = (LwM2mObjectInstance) response.getContent(); - } else if (response.getContent() instanceof LwM2mSingleResource) { - LwM2mSingleResource content = (LwM2mSingleResource) response.getContent(); - this.onObservationSetResourcesValue(registration, content.getValue(), null, path); - } else if (response.getContent() instanceof LwM2mMultipleResource) { - LwM2mSingleResource content = (LwM2mSingleResource) response.getContent(); - this.onObservationSetResourcesValue(registration, null, content.getValues(), path); - } - } - } - - /** - * Sending observe value of resources to thingsboard - * #1 Return old Resource from ModelObject - * #2 Create new Resource with value from observation - * #3 Create new Resources from old Resources - * #4 Update new Resources (replace old Resource on new Resource) - * #5 Remove old Instance from modelClient - * #6 Create new Instance with new Resources values - * #7 Update modelClient.getModelObjects(idObject) (replace old Instance on new Instance) - * - * @param registration - Registration LwM2M Client - * @param value - LwM2mSingleResource response.getContent() - * @param values - LwM2mSingleResource response.getContent() - * @param path - resource - */ - private void onObservationSetResourcesValue(Registration registration, Object value, Map values, String path) { - ResultIds resultIds = new ResultIds(path); - // #1 - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getlwM2MClient(registration.getId()); - ModelObject modelObject = lwM2MClient.getModelObjects().get(resultIds.getObjectId()); - Map instancesModelObject = modelObject.getInstances(); - LwM2mObjectInstance instanceOld = (instancesModelObject.get(resultIds.instanceId) != null) ? instancesModelObject.get(resultIds.instanceId) : null; - Map resourcesOld = (instanceOld != null) ? instanceOld.getResources() : null; - LwM2mResource resourceOld = (resourcesOld != null && resourcesOld.get(resultIds.getResourceId()) != null) ? resourcesOld.get(resultIds.getResourceId()) : null; - // #2 - LwM2mResource resourceNew; - if (resourceOld.isMultiInstances()) { - resourceNew = LwM2mMultipleResource.newResource(resultIds.getResourceId(), values, resourceOld.getType()); - } else { - resourceNew = LwM2mSingleResource.newResource(resultIds.getResourceId(), value, resourceOld.getType()); - } - //#3 - Map resourcesNew = new HashMap<>(resourcesOld); - // #4 - resourcesNew.remove(resourceOld); - // #5 - resourcesNew.put(resultIds.getResourceId(), resourceNew); - // #6 - LwM2mObjectInstance instanceNew = new LwM2mObjectInstance(resultIds.instanceId, resourcesNew.values()); - // #7 - CountDownLatch respLatch = new CountDownLatch(1); - lwM2MClient.getModelObjects().get(resultIds.getObjectId()).removeInstance(resultIds.instanceId); - instancesModelObject.put(resultIds.instanceId, instanceNew); - respLatch.countDown(); - try { - respLatch.await(DEFAULT_TIMEOUT, TimeUnit.MILLISECONDS); - } catch (InterruptedException ex) { - } - Set paths = new HashSet(); - paths.add(path); - this.updateAttrTelemetry(registration, false, paths); - } - - /** - * @param updateCredentials - Credentials include config only security Client (without config attr/telemetry...) - * config attr/telemetry... in profile - */ - public void onToTransportUpdateCredentials(ToTransportUpdateCredentialsProto updateCredentials) { - log.info("[{}] idList [{}] valueList updateCredentials", updateCredentials.getCredentialsIdList(), updateCredentials.getCredentialsValueList()); - } - - /** - * Update - sent request in change value resources in Client (path to resources from profile by keyName) - * Only fo resources W - * Delete - nothing - * - * @param msg - - * @param sessionInfo - - */ - public void onAttributeUpdate(TransportProtos.AttributeUpdateNotificationMsg msg, SessionInfoProto sessionInfo) { - if (msg.getSharedUpdatedCount() > 0) { - JsonElement el = JsonConverter.toJson(msg); - el.getAsJsonObject().entrySet().forEach(de -> { - String profilePath = lwM2mInMemorySecurityStore.getProfiles().get(new UUID(sessionInfo.getDeviceProfileIdMSB(), sessionInfo.getDeviceProfileIdLSB())) - .getPostKeyNameProfile().getAsJsonObject().entrySet().stream() - .filter(e -> e.getValue().getAsString().equals(de.getKey())).findFirst().map(Map.Entry::getKey) - .orElse(""); - String path = !profilePath.isEmpty() ? profilePath : this.getPathAttributeUpdate(sessionInfo, de.getKey()); - if (path != null) { - ResultIds resultIds = new ResultIds(path); - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getSession(new UUID(sessionInfo.getSessionIdMSB(), sessionInfo.getSessionIdLSB())).entrySet().iterator().next().getValue(); - ResourceModel.Operations operations = lwM2MClient.getModelObjects().get(resultIds.getObjectId()).getObjectModel().resources.get(resultIds.getResourceId()).operations; - String value = ((JsonPrimitive) de.getValue()).getAsString(); - if (operations.isWritable()) { - lwM2MTransportRequest.sendAllRequest(lwM2MClient.getLwServer(), lwM2MClient.getRegistration(), path, POST_TYPE_OPER_WRITE_REPLACE, - ContentFormat.TLV.getName(), lwM2MClient, null, value, this.context.getCtxServer().getTimeout()); - log.info("[{}] path onAttributeUpdate", path); - } - else { - log.error(LOG_LW2M_ERROR + ": Resource path - [{}] value - [{}] is not Writable and cannot be updated", path, value); - String logMsg = String.format(LOG_LW2M_ERROR + " attributeUpdate: Resource path - %s value - %s is not Writable and cannot be updated", path, value); - this.sentLogsToThingsboard(logMsg, lwM2MClient.getRegistration().getId()); - } - } - }); - } else if (msg.getSharedDeletedCount() > 0) { - log.info("[{}] delete [{}] onAttributeUpdate", msg.getSharedDeletedList(), sessionInfo); - } - } - - private String getPathAttributeUpdate(SessionInfoProto sessionInfo, String keyName) { - try { - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getSession(new UUID(sessionInfo.getSessionIdMSB(), sessionInfo.getSessionIdLSB())).entrySet().iterator().next().getValue(); - Predicate> predicateRes = res -> keyName.equals(splitCamelCaseString(res.getValue().name)); - Predicate> predicateObj = (obj -> { - return obj.getValue().getObjectModel().resources.entrySet().stream().filter(predicateRes).findFirst().isPresent(); - }); - Stream> objectStream = lwM2MClient.getModelObjects().entrySet().stream().filter(predicateObj); - Predicate> predicateResFinal = (objectStream.count() > 0) ? predicateRes : res -> keyName.equals(res.getValue().name); - Predicate> predicateObjFinal = (obj -> { - return obj.getValue().getObjectModel().resources.entrySet().stream().filter(predicateResFinal).findFirst().isPresent(); - }); - Map.Entry object = lwM2MClient.getModelObjects().entrySet().stream().filter(predicateObjFinal).findFirst().get(); - ModelObject modelObject = object.getValue(); - LwM2mObjectInstance instance = modelObject.getInstances().entrySet().stream().findFirst().get().getValue(); - ResourceModel resource = modelObject.getObjectModel().resources.entrySet().stream().filter(predicateResFinal).findFirst().get().getValue(); - return new LwM2mPath(object.getKey(), instance.getId(), resource.id).toString(); - } catch (NoSuchElementException e) { - log.error("[{}] keyName [{}]", keyName, e.toString()); - return null; - } - } - - public void onAttributeUpdateOk(Registration registration, String path, WriteRequest request) { - ResultIds resultIds = new ResultIds(path); - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getlwM2MClient(registration.getId()); - LwM2mResource resource = lwM2MClient.getModelObjects().get(resultIds.getObjectId()).getInstances().get(resultIds.getInstanceId()).getResource(resultIds.getResourceId()); - if (resource.isMultiInstances()) { - this.onObservationSetResourcesValue(registration, null, ((LwM2mSingleResource) request.getNode()).getValues(), path); - } else { - this.onObservationSetResourcesValue(registration, ((LwM2mSingleResource) request.getNode()).getValue(), null, path); - } - } - - /** - * @param sessionInfo - - * @param deviceProfile - - */ - public void onDeviceProfileUpdate(TransportProtos.SessionInfoProto sessionInfo, DeviceProfile deviceProfile) { - String registrationId = lwM2mInMemorySecurityStore.getSessions().entrySet() - .stream() - .filter(e -> e.getValue().getDeviceUuid().equals(new UUID(sessionInfo.getDeviceIdMSB(), sessionInfo.getDeviceIdLSB()))) - .findFirst() - .map(Map.Entry::getKey) - .orElse(""); - if (!registrationId.isEmpty()) { - this.onDeviceUpdateChangeProfile(registrationId, deviceProfile); - } - } - - /** - * @param sessionInfo - - * @param device - - * @param deviceProfileOpt - - */ - public void onDeviceUpdate(TransportProtos.SessionInfoProto sessionInfo, Device device, Optional deviceProfileOpt) { - Optional registrationIdOpt = lwM2mInMemorySecurityStore.getSessions().entrySet().stream() - .filter(e -> device.getUuidId().equals(e.getValue().getDeviceUuid())) - .map(Map.Entry::getKey) - .findFirst(); - registrationIdOpt.ifPresent(registrationId -> this.onDeviceUpdateLwM2MClient(registrationId, device, deviceProfileOpt)); - } - - /** - * Update parameters device in LwM2MClient - * If new deviceProfile != old deviceProfile => update deviceProfile - * - * @param registrationId - - * @param device - - */ - private void onDeviceUpdateLwM2MClient(String registrationId, Device device, Optional deviceProfileOpt) { - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getSessions().get(registrationId); - lwM2MClient.setDeviceName(device.getName()); - if (!lwM2MClient.getProfileUuid().equals(device.getDeviceProfileId().getId())) { - deviceProfileOpt.ifPresent(deviceProfile -> this.onDeviceUpdateChangeProfile(registrationId, deviceProfile)); - } - } - - /** - * #1 Read new, old Value (Attribute, Telemetry, Observe, KeyName) - * #2 Update in lwM2MClient: ...Profile - * #3 Equivalence test: old <> new Value (Attribute, Telemetry, Observe, KeyName) - * #3.1 Attribute isChange (add&del) - * #3.2 Telemetry isChange (add&del) - * #3.3 KeyName isChange (add) - * #4 update - * #4.1 add If #3 isChange, then analyze and update Value in Transport form Client and sent Value ti thingsboard - * #4.2 del - * -- if add attributes includes del telemetry - result del for observe - * #5 - * #5.1 Observe isChange (add&del) - * #5.2 Observe.add - * -- path Attr/Telemetry includes newObserve and does not include oldObserve: sent Request observe to Client - * #5.3 Observe.del - * -- different between newObserve and oldObserve: sent Request cancel observe to client - * - * @param registrationId - - * @param deviceProfile - - */ - public void onDeviceUpdateChangeProfile(String registrationId, DeviceProfile deviceProfile) { - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getlwM2MClient(registrationId); - AttrTelemetryObserveValue attrTelemetryObserveValueOld = lwM2mInMemorySecurityStore.getProfiles().get(lwM2MClient.getProfileUuid()); - if (lwM2mInMemorySecurityStore.addUpdateProfileParameters(deviceProfile)) { - LeshanServer lwServer = lwM2MClient.getLwServer(); - Registration registration = lwM2mInMemorySecurityStore.getByRegistration(registrationId); - // #1 - JsonArray attributeOld = attrTelemetryObserveValueOld.getPostAttributeProfile(); - Set attributeSetOld = new Gson().fromJson(attributeOld, Set.class); - JsonArray telemetryOld = attrTelemetryObserveValueOld.getPostTelemetryProfile(); - Set telemetrySetOld = new Gson().fromJson(telemetryOld, Set.class); - JsonArray observeOld = attrTelemetryObserveValueOld.getPostObserveProfile(); - JsonObject keyNameOld = attrTelemetryObserveValueOld.getPostKeyNameProfile(); - - AttrTelemetryObserveValue attrTelemetryObserveValueNew = lwM2mInMemorySecurityStore.getProfiles().get(deviceProfile.getUuidId()); - JsonArray attributeNew = attrTelemetryObserveValueNew.getPostAttributeProfile(); - Set attributeSetNew = new Gson().fromJson(attributeNew, Set.class); - JsonArray telemetryNew = attrTelemetryObserveValueNew.getPostTelemetryProfile(); - Set telemetrySetNew = new Gson().fromJson(telemetryNew, Set.class); - JsonArray observeNew = attrTelemetryObserveValueNew.getPostObserveProfile(); - JsonObject keyNameNew = attrTelemetryObserveValueNew.getPostKeyNameProfile(); - // #2 - lwM2MClient.setDeviceProfileName(deviceProfile.getName()); - lwM2MClient.setProfileUuid(deviceProfile.getUuidId()); - - // #3 - ResultsAnalyzerParameters sentAttrToThingsboard = new ResultsAnalyzerParameters(); - // #3.1 - if (!attributeOld.equals(attributeNew)) { - ResultsAnalyzerParameters postAttributeAnalyzer = this.getAnalyzerParameters(new Gson().fromJson(attributeOld, Set.class), attributeSetNew); - sentAttrToThingsboard.getPathPostParametersAdd().addAll(postAttributeAnalyzer.getPathPostParametersAdd()); - sentAttrToThingsboard.getPathPostParametersDel().addAll(postAttributeAnalyzer.getPathPostParametersDel()); - } - // #3.2 - if (!attributeOld.equals(attributeNew)) { - ResultsAnalyzerParameters postTelemetryAnalyzer = this.getAnalyzerParameters(new Gson().fromJson(telemetryOld, Set.class), telemetrySetNew); - sentAttrToThingsboard.getPathPostParametersAdd().addAll(postTelemetryAnalyzer.getPathPostParametersAdd()); - sentAttrToThingsboard.getPathPostParametersDel().addAll(postTelemetryAnalyzer.getPathPostParametersDel()); - } - // #3.3 - if (!keyNameOld.equals(keyNameNew)) { - ResultsAnalyzerParameters keyNameChange = this.getAnalyzerKeyName(new Gson().fromJson(keyNameOld.toString(), ConcurrentHashMap.class), - new Gson().fromJson(keyNameNew.toString(), ConcurrentHashMap.class)); - sentAttrToThingsboard.getPathPostParametersAdd().addAll(keyNameChange.getPathPostParametersAdd()); - } - - // #4.1 add - if (sentAttrToThingsboard.getPathPostParametersAdd().size() > 0) { - // update value in Resources - this.updateResourceValueObserve(lwServer, registration, lwM2MClient, sentAttrToThingsboard.getPathPostParametersAdd(), GET_TYPE_OPER_READ); - // sent attr/telemetry to tingsboard for new path - this.updateAttrTelemetry(registration, false, sentAttrToThingsboard.getPathPostParametersAdd()); - } - // #4.2 del - if (sentAttrToThingsboard.getPathPostParametersDel().size() > 0) { - ResultsAnalyzerParameters sentAttrToThingsboardDel = this.getAnalyzerParameters(sentAttrToThingsboard.getPathPostParametersAdd(), sentAttrToThingsboard.getPathPostParametersDel()); - sentAttrToThingsboard.setPathPostParametersDel(sentAttrToThingsboardDel.getPathPostParametersDel()); - } - - // #5.1 - if (!observeOld.equals(observeNew)) { - Set observeSetOld = new Gson().fromJson(observeOld, Set.class); - Set observeSetNew = new Gson().fromJson(observeNew, Set.class); - //#5.2 add - // path Attr/Telemetry includes newObserve - attributeSetOld.addAll(telemetrySetOld); - ResultsAnalyzerParameters sentObserveToClientOld = this.getAnalyzerParametersIn(attributeSetOld, observeSetOld); // add observe - attributeSetNew.addAll(telemetrySetNew); - ResultsAnalyzerParameters sentObserveToClientNew = this.getAnalyzerParametersIn(attributeSetNew, observeSetNew); // add observe - // does not include oldObserve - ResultsAnalyzerParameters postObserveAnalyzer = this.getAnalyzerParameters(sentObserveToClientOld.getPathPostParametersAdd(), sentObserveToClientNew.getPathPostParametersAdd()); - // sent Request observe to Client - this.updateResourceValueObserve(lwServer, registration, lwM2MClient, postObserveAnalyzer.getPathPostParametersAdd(), GET_TYPE_OPER_OBSERVE); - // 5.3 del - // sent Request cancel observe to Client - this.cancelObserveIsValue(lwServer, registration, postObserveAnalyzer.getPathPostParametersDel()); - } - } - } - - /** - * Compare old list with new list after change AttrTelemetryObserve in config Profile - * - * @param parametersOld - - * @param parametersNew - - * @return ResultsAnalyzerParameters: add && new - */ - private ResultsAnalyzerParameters getAnalyzerParameters(Set parametersOld, Set parametersNew) { - ResultsAnalyzerParameters analyzerParameters = null; - if (!parametersOld.equals(parametersNew)) { - analyzerParameters = new ResultsAnalyzerParameters(); - analyzerParameters.setPathPostParametersAdd(parametersNew - .stream().filter(p -> !parametersOld.contains(p)).collect(Collectors.toSet())); - analyzerParameters.setPathPostParametersDel(parametersOld - .stream().filter(p -> !parametersNew.contains(p)).collect(Collectors.toSet())); - } - return analyzerParameters; - } - - private ResultsAnalyzerParameters getAnalyzerKeyName(ConcurrentMap keyNameOld, ConcurrentMap keyNameNew) { - ResultsAnalyzerParameters analyzerParameters = new ResultsAnalyzerParameters(); - Set paths = keyNameNew.entrySet() - .stream() - .filter(e -> !e.getValue().equals(keyNameOld.get(e.getKey()))) - .collect(Collectors.toMap(map -> map.getKey(), map -> map.getValue())).keySet(); - analyzerParameters.setPathPostParametersAdd(paths); - return analyzerParameters; - } - - private ResultsAnalyzerParameters getAnalyzerParametersIn(Set parametersObserve, Set parameters) { - ResultsAnalyzerParameters analyzerParameters = new ResultsAnalyzerParameters(); - analyzerParameters.setPathPostParametersAdd(parametersObserve - .stream().filter(p -> parameters.contains(p)).collect(Collectors.toSet())); - return analyzerParameters; - } - - /** - * Update Resource value after change RezAttrTelemetry in config Profile - * sent response Read to Client and add path to pathResAttrTelemetry in LwM2MClient.getAttrTelemetryObserveValue() - * - * @param lwServer - LeshanServer - * @param registration - Registration LwM2M Client - * @param lwM2MClient - object with All parameters off client - * @param targets - path Resources == [ "/2/0/0", "/2/0/1"] - */ - private void updateResourceValueObserve(LeshanServer lwServer, Registration registration, LwM2MClient lwM2MClient, Set targets, String typeOper) { - targets.stream().forEach(target -> { - ResultIds pathIds = new ResultIds(target); - if (pathIds.resourceId >= 0 && lwM2MClient.getModelObjects().get(pathIds.getObjectId()) - .getInstances().get(pathIds.getInstanceId()).getResource(pathIds.getResourceId()).getValue() != null) { - if (GET_TYPE_OPER_READ.equals(typeOper)) { - lwM2MTransportRequest.sendAllRequest(lwServer, registration, target, typeOper, - ContentFormat.TLV.getName(), null, null, null, this.context.getCtxServer().getTimeout()); - } else if (GET_TYPE_OPER_OBSERVE.equals(typeOper)) { - lwM2MTransportRequest.sendAllRequest(lwServer, registration, target, typeOper, - null, null, null, null, this.context.getCtxServer().getTimeout()); - } - } - }); - } - - private void cancelObserveIsValue(LeshanServer lwServer, Registration registration, Set paramAnallyzer) { - LwM2MClient lwM2MClient = lwM2mInMemorySecurityStore.getlwM2MClient(registration.getId()); - paramAnallyzer.forEach(p -> { - if (this.getResourceValue(lwM2MClient, p) != null) { - this.setCancelObservationRecourse(lwServer, registration, p); - } - } - ); - } - - private ResourceValue getResourceValue(LwM2MClient lwM2MClient, String path) { - ResourceValue resourceValue = null; - ResultIds pathIds = new ResultIds(path); - if (pathIds.getResourceId() > -1) { - LwM2mResource resource = lwM2MClient.getModelObjects().get(pathIds.getObjectId()).getInstances().get(pathIds.getInstanceId()).getResource(pathIds.getResourceId()); - if (resource.isMultiInstances()) { - Map values = resource.getValues(); - if (resource.getValues().size() > 0) { - resourceValue = new ResourceValue(); - resourceValue.setMultiInstances(resource.isMultiInstances()); - resourceValue.setValues(resource.getValues()); - } - } else { - if (resource.getValue() != null) { - resourceValue = new ResourceValue(); - resourceValue.setMultiInstances(resource.isMultiInstances()); - resourceValue.setValue(resource.getValue()); - } - } - } - return resourceValue; - } - - /** - * Trigger Server path = "/1/0/8" - * - * Trigger bootStrap path = "/1/0/9" - have to implemented on client - */ - public void doTrigger(LeshanServer lwServer, Registration registration, String path) { - lwM2MTransportRequest.sendAllRequest(lwServer, registration, path, POST_TYPE_OPER_EXECUTE, - ContentFormat.TLV.getName(), null, null, null, this.context.getCtxServer().getTimeout()); - } - - /** - * Session device in thingsboard is closed - * - * @param sessionInfo - lwm2m client - */ - private void doCloseSession(SessionInfoProto sessionInfo) { - TransportProtos.SessionEvent event = SessionEvent.CLOSED; - TransportProtos.SessionEventMsg msg = TransportProtos.SessionEventMsg.newBuilder() - .setSessionType(TransportProtos.SessionType.ASYNC) - .setEvent(event).build(); - transportService.process(sessionInfo, msg, null); - } - - /** - * Deregister session in transport - * @param sessionInfo - lwm2m client - */ - private void doDisconnect(SessionInfoProto sessionInfo) { - transportService.process(sessionInfo, DefaultTransportService.getSessionEventMsg(SessionEvent.CLOSED), null); - transportService.deregisterSession(sessionInfo); - } - - private void checkInactivityAndReportActivity() { - lwM2mInMemorySecurityStore.getSessions().forEach((key, value) -> transportService.reportActivity(this.getValidateSessionInfo(key))); - } - - public void sentLogsToThingsboard(String msg, String registrationId) { - if (msg != null) { - JsonObject telemetrys = new JsonObject(); - telemetrys.addProperty(LOG_LW2M_TELEMETRY, msg); - this.updateParametersOnThingsboard(telemetrys, LwM2MTransportHandler.DEVICE_TELEMETRY_TOPIC, registrationId); - } - } - -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2mServerListener.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2mServerListener.java deleted file mode 100644 index 4d63da3580..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/LwM2mServerListener.java +++ /dev/null @@ -1,111 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.observation.Observation; -import org.eclipse.leshan.core.response.ObserveResponse; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.eclipse.leshan.server.observation.ObservationListener; -import org.eclipse.leshan.server.queue.PresenceListener; -import org.eclipse.leshan.server.registration.Registration; -import org.eclipse.leshan.server.registration.RegistrationListener; -import org.eclipse.leshan.server.registration.RegistrationUpdate; - -import java.util.Collection; - -@Slf4j -public class LwM2mServerListener { - private LeshanServer lhServer; - private LwM2MTransportService service; - - public LwM2mServerListener(LeshanServer lhServer, LwM2MTransportService service) { - this.lhServer = lhServer; - this.service = service; - } - - public final RegistrationListener registrationListener = new RegistrationListener() { - /** - * Register – запрос, представленный в виде POST /rd?… - */ - @Override - public void registered(Registration registration, Registration previousReg, - Collection previousObsersations) { - - service.onRegistered(lhServer, registration, previousObsersations); - } - - /** - * Update – представляет из себя CoAP POST запрос на URL, полученный в ответ на Register. - */ - @Override - public void updated(RegistrationUpdate update, Registration updatedRegistration, - Registration previousRegistration) { - service.updatedReg(lhServer, updatedRegistration); - } - - /** - * De-register (CoAP DELETE) – отправляется клиентом в случае инициирования процедуры выключения. - */ - @Override - public void unregistered(Registration registration, Collection observations, boolean expired, - Registration newReg) { - service.unReg(registration, observations); - } - - }; - - public final PresenceListener presenceListener = new PresenceListener() { - @Override - public void onSleeping(Registration registration) { - service.onSleepingDev(registration); - } - - @Override - public void onAwake(Registration registration) { - service.onAwakeDev(registration); - } - }; - - public final ObservationListener observationListener = new ObservationListener() { - - @Override - public void cancelled(Observation observation) { - log.info("Received notification cancelled from [{}] ", observation.getPath()); - } - - @Override - public void onResponse(Observation observation, Registration registration, ObserveResponse response) { - if (registration != null) { - try { - service.onObservationResponse(registration, observation.getPath().toString(), response); - } catch (java.lang.NullPointerException e) { - log.error(e.toString()); - } - } - } - - @Override - public void onError(Observation observation, Registration registration, Exception error) { - log.error(String.format("Unable to handle notification of [%s:%s]", observation.getRegistrationId(), observation.getPath()), error); - } - - @Override - public void newObservation(Observation observation, Registration registration) { - log.info("Received newObservation from [{}] endpoint [{}] ", observation.getPath(), registration.getEndpoint()); - } - }; -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/ResultIds.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/ResultIds.java deleted file mode 100644 index b5c2f6638e..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/ResultIds.java +++ /dev/null @@ -1,38 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server; - -import lombok.Builder; -import lombok.Data; - -@Data -public class ResultIds { - @Builder.Default - int objectId = -1; - @Builder.Default - int instanceId = -1; - @Builder.Default - int resourceId = -1; - - public ResultIds (String path) { - String[] paths = path.split("/"); - if (paths != null && paths.length > 1) { - this.objectId = (paths.length > 1) ? Integer.parseInt(paths[1]) : this.objectId; - this.instanceId = (paths.length > 2) ? Integer.parseInt(paths[2]) : this.instanceId; - this.resourceId = (paths.length > 3) ? Integer.parseInt(paths[3]) : this.resourceId; - } - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MJsonAdaptor.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MJsonAdaptor.java deleted file mode 100644 index 47dbe563a2..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MJsonAdaptor.java +++ /dev/null @@ -1,49 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.adaptors; - -import com.google.gson.JsonElement; -import com.google.gson.JsonSyntaxException; -import lombok.extern.slf4j.Slf4j; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.common.transport.adaptor.AdaptorException; -import org.thingsboard.server.common.transport.adaptor.JsonConverter; -import org.thingsboard.server.gen.transport.TransportProtos; - -@Slf4j -@Component("LwM2MJsonAdaptor") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' )|| ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2MJsonAdaptor implements LwM2MTransportAdaptor { - - @Override - public TransportProtos.PostTelemetryMsg convertToPostTelemetry(JsonElement jsonElement) throws AdaptorException { - try { - return JsonConverter.convertToTelemetryProto(jsonElement); - } catch (IllegalStateException | JsonSyntaxException ex) { - throw new AdaptorException(ex); - } - } - - @Override - public TransportProtos.PostAttributeMsg convertToPostAttributes(JsonElement jsonElement) throws AdaptorException { - try { - return JsonConverter.convertToAttributesProto(jsonElement); - } catch (IllegalStateException | JsonSyntaxException ex) { - throw new AdaptorException(ex); - } - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MTransportAdaptor.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MTransportAdaptor.java deleted file mode 100644 index d4d54f4df8..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/adaptors/LwM2MTransportAdaptor.java +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.adaptors; - -import com.google.gson.JsonElement; -import org.thingsboard.server.common.transport.adaptor.AdaptorException; -import org.thingsboard.server.gen.transport.TransportProtos; - -public interface LwM2MTransportAdaptor { - - TransportProtos.PostTelemetryMsg convertToPostTelemetry(JsonElement jsonElement) throws AdaptorException; - - TransportProtos.PostAttributeMsg convertToPostAttributes(JsonElement jsonElement) throws AdaptorException; -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/AttrTelemetryObserveValue.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/AttrTelemetryObserveValue.java deleted file mode 100644 index fb800c8197..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/AttrTelemetryObserveValue.java +++ /dev/null @@ -1,47 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.client; - -import com.google.gson.JsonArray; -import com.google.gson.JsonObject; -import lombok.Data; - -@Data -public class AttrTelemetryObserveValue { - /** - * {"keyName": { - * "/3/0/1": "modelNumber", - * "/3/0/0": "manufacturer", - * "/3/0/2": "serialNumber" - * } - **/ - JsonObject postKeyNameProfile; - - /** - * [ "/2/0/0", "/2/0/1"] - */ - JsonArray postAttributeProfile; - - /** - * [ "/2/0/0", "/2/0/1"] - */ - JsonArray postTelemetryProfile; - - /** - * [ "/2/0/0", "/2/0/1"] - */ - JsonArray postObserveProfile; -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/LwM2MClient.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/LwM2MClient.java deleted file mode 100644 index 3a84a637ac..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/LwM2MClient.java +++ /dev/null @@ -1,107 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.client; - -import lombok.Data; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.model.ObjectModel; -import org.eclipse.leshan.core.node.LwM2mObjectInstance; -import org.eclipse.leshan.core.response.LwM2mResponse; -import org.eclipse.leshan.core.response.ReadResponse; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.eclipse.leshan.server.registration.Registration; -import org.eclipse.leshan.server.security.SecurityInfo; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceCredentialsResponseMsg; -import org.thingsboard.server.transport.lwm2m.server.LwM2MTransportService; -import org.thingsboard.server.transport.lwm2m.server.ResultIds; - -import java.util.UUID; -import java.util.Map; -import java.util.Set; -import java.util.Collection; -import java.util.concurrent.ConcurrentHashMap; -import java.util.stream.Collectors; - -@Slf4j -@Data -public class LwM2MClient implements Cloneable { - private String deviceName; - private String deviceProfileName; - private String endPoint; - private String identity; - private SecurityInfo info; - private UUID deviceUuid; - private UUID sessionUuid; - private UUID profileUuid; - private LeshanServer lwServer; - private LwM2MTransportService lwM2MTransportService; - private Registration registration; - private ValidateDeviceCredentialsResponseMsg credentialsResponse; - private Map attributes; - private Map modelObjects; - private Set pendingRequests; - private Map responses; - - public Object clone() throws CloneNotSupportedException { - return super.clone(); - } - - public LwM2MClient(String endPoint, String identity, SecurityInfo info, ValidateDeviceCredentialsResponseMsg credentialsResponse, Map attributes, Map modelObjects, UUID profileUuid) { - this.endPoint = endPoint; - this.identity = identity; - this.info = info; - this.credentialsResponse = credentialsResponse; - this.attributes = (attributes != null && attributes.size() > 0) ? attributes : new ConcurrentHashMap(); - this.modelObjects = (modelObjects != null && modelObjects.size() > 0) ? modelObjects : new ConcurrentHashMap(); - this.pendingRequests = ConcurrentHashMap.newKeySet(); - this.profileUuid = profileUuid; - /** - * Key , response instance -> resources: value...> - */ - this.responses = new ConcurrentHashMap<>(); - } - - /** - * Fill with data -> Model client - * @param path - - * @param response - - */ - public void onSuccessHandler(String path, LwM2mResponse response) { - this.responses.put(path, response); - this.pendingRequests.remove(path); - if (this.pendingRequests.size() == 0) { - this.initValue(); - this.lwM2MTransportService.updatesAndSentModelParameter(this.lwServer, this.registration); - } - } - - private void initValue() { - this.responses.forEach((key, resp) -> { - ResultIds pathIds = new ResultIds(key); - if (pathIds.getObjectId() > -1) { - ObjectModel objectModel = ((Collection) this.lwServer.getModelProvider().getObjectModel(registration).getObjectModels()).stream().filter(v -> v.id == pathIds.getObjectId()).collect(Collectors.toList()).get(0); - if (this.modelObjects.get(pathIds.getObjectId()) != null) { - this.modelObjects.get(pathIds.getObjectId()).getInstances().put(((ReadResponse) resp).getContent().getId(), (LwM2mObjectInstance) ((ReadResponse) resp).getContent()); - } else { - Map instances = new ConcurrentHashMap<>(); - instances.put(((ReadResponse) resp).getContent().getId(), (LwM2mObjectInstance) ((ReadResponse) resp).getContent()); - ModelObject modelObject = new ModelObject(objectModel, instances); - this.modelObjects.put(pathIds.getObjectId(), modelObject); - } - } - }); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ModelObject.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ModelObject.java deleted file mode 100644 index 03dcc5013f..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ModelObject.java +++ /dev/null @@ -1,41 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.client; - -import lombok.Data; -import org.eclipse.leshan.core.model.ObjectModel; -import org.eclipse.leshan.core.node.LwM2mObjectInstance; -import java.util.Map; - -@Data -public class ModelObject { - /** - * model one on all instance - * for each instance only id resource with parameters of resources (observe, attr, telemetry) - */ - private ObjectModel objectModel; - private Map instances; - - public ModelObject(ObjectModel objectModel, Map instances) { - this.objectModel = objectModel; - this.instances = instances; - } - - public boolean removeInstance (int id ) { - LwM2mObjectInstance instance = this.instances.get(id); - return this.instances.remove(id, instance); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResourceValue.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResourceValue.java deleted file mode 100644 index 312973b9d0..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResourceValue.java +++ /dev/null @@ -1,26 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.client; - -import lombok.Data; -import java.util.Map; - -@Data -public class ResourceValue { - Map values; - Object value; - boolean multiInstances; -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResultsAnalyzerParameters.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResultsAnalyzerParameters.java deleted file mode 100644 index dcb561b699..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/client/ResultsAnalyzerParameters.java +++ /dev/null @@ -1,32 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.client; - -import lombok.Data; - -import java.util.Set; -import java.util.concurrent.ConcurrentHashMap; - -@Data -public class ResultsAnalyzerParameters { - Set pathPostParametersAdd; - Set pathPostParametersDel; - - public ResultsAnalyzerParameters() { - this.pathPostParametersAdd = ConcurrentHashMap.newKeySet(); - this.pathPostParametersDel = ConcurrentHashMap.newKeySet(); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2MSetSecurityStoreServer.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2MSetSecurityStoreServer.java deleted file mode 100644 index 7a37ac4005..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2MSetSecurityStoreServer.java +++ /dev/null @@ -1,234 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.secure; - -import lombok.Data; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.server.californium.LeshanServerBuilder; -import org.eclipse.leshan.server.redis.RedisRegistrationStore; -import org.eclipse.leshan.server.redis.RedisSecurityStore; -import org.eclipse.leshan.server.security.DefaultAuthorizer; -import org.eclipse.leshan.server.security.EditableSecurityStore; -import org.eclipse.leshan.server.security.SecurityChecker; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode; -import org.thingsboard.server.transport.lwm2m.server.LwM2MTransportContextServer; -import redis.clients.jedis.Jedis; -import redis.clients.jedis.JedisPool; -import redis.clients.jedis.util.Pool; - -import java.math.BigInteger; -import java.net.URI; -import java.net.URISyntaxException; -import java.security.KeyStore; -import java.security.PublicKey; -import java.security.PrivateKey; -import java.security.AlgorithmParameters; -import java.security.KeyFactory; -import java.security.GeneralSecurityException; -import java.security.KeyStoreException; -import java.security.cert.X509Certificate; -import java.security.interfaces.ECPublicKey; -import java.security.spec.*; -import java.util.Arrays; - -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.*; - -@Slf4j -@Data -public class LwM2MSetSecurityStoreServer { - - private KeyStore keyStore; - private X509Certificate certificate; - private PublicKey publicKey; - private PrivateKey privateKey; - private LwM2MTransportContextServer context; - private LwM2mInMemorySecurityStore lwM2mInMemorySecurityStore; - - private LeshanServerBuilder builder; - EditableSecurityStore securityStore; - - public LwM2MSetSecurityStoreServer(LeshanServerBuilder builder, LwM2MTransportContextServer context, LwM2mInMemorySecurityStore lwM2mInMemorySecurityStore, LwM2MSecurityMode dtlsMode) { - this.builder = builder; - this.context = context; - this.lwM2mInMemorySecurityStore = lwM2mInMemorySecurityStore; - /** Set securityStore with new registrationStore */ - switch (dtlsMode) { - /** Use PSK only */ - case PSK: - generatePSK_RPK(); - if (this.privateKey != null && this.privateKey.getEncoded().length > 0) { - builder.setPrivateKey(this.privateKey); - builder.setPublicKey(null); - getParamsPSK(); - } - break; - /** Use RPK only */ - case RPK: - generatePSK_RPK(); - if (this.publicKey != null && this.publicKey.getEncoded().length > 0 && - this.privateKey != null && this.privateKey.getEncoded().length > 0) { - builder.setPublicKey(this.publicKey); - builder.setPrivateKey(this.privateKey); - getParamsRPK(); - } - break; - /** Use x509 only */ - case X509: - setServerWithX509Cert(); - break; - /** No security */ - case NO_SEC: - builder.setTrustedCertificates(new X509Certificate[0]); - break; - /** Use x509 with EST */ - case X509_EST: - // TODO support sentinel pool and make pool configurable - break; - case REDIS: - /** - * Set securityStore with new registrationStore (if use redis store) - * Connect to redis - */ - Pool jedis = null; - try { - jedis = new JedisPool(new URI(this.context.getCtxServer().getRedisUrl())); - securityStore = new RedisSecurityStore(jedis); - builder.setRegistrationStore(new RedisRegistrationStore(jedis)); - } catch (URISyntaxException e) { - e.printStackTrace(); - } - break; - default: - } - - /** Set securityStore with new registrationStore (if not redis)*/ - if (dtlsMode.code < REDIS.code) { - securityStore = lwM2mInMemorySecurityStore; - if (dtlsMode == X509) { - builder.setAuthorizer(new DefaultAuthorizer(securityStore, new SecurityChecker() { - @Override - protected boolean matchX509Identity(String endpoint, String receivedX509CommonName, - String expectedX509CommonName) { - return endpoint.startsWith(expectedX509CommonName); - } - })); - } - } - - /** Set securityStore with new registrationStore */ - builder.setSecurityStore(securityStore); - } - - private void generatePSK_RPK() { - try { - /** Get Elliptic Curve Parameter spec for secp256r1 */ - AlgorithmParameters algoParameters = AlgorithmParameters.getInstance("EC"); - algoParameters.init(new ECGenParameterSpec("secp256r1")); - ECParameterSpec parameterSpec = algoParameters.getParameterSpec(ECParameterSpec.class); - if (this.context.getCtxServer().getServerPublicX() != null && !this.context.getCtxServer().getServerPublicX().isEmpty() && this.context.getCtxServer().getServerPublicY() != null && !this.context.getCtxServer().getServerPublicY().isEmpty()) { - /** Get point values */ - byte[] publicX = Hex.decodeHex(this.context.getCtxServer().getServerPublicX().toCharArray()); - byte[] publicY = Hex.decodeHex(this.context.getCtxServer().getServerPublicY().toCharArray()); - /** Create key specs */ - KeySpec publicKeySpec = new ECPublicKeySpec(new ECPoint(new BigInteger(publicX), new BigInteger(publicY)), - parameterSpec); - /** Get keys */ - this.publicKey = KeyFactory.getInstance("EC").generatePublic(publicKeySpec); - } - if (this.context.getCtxServer().getServerPrivateS() != null && !this.context.getCtxServer().getServerPrivateS().isEmpty()) { - /** Get point values */ - byte[] privateS = Hex.decodeHex(this.context.getCtxServer().getServerPrivateS().toCharArray()); - /** Create key specs */ - KeySpec privateKeySpec = new ECPrivateKeySpec(new BigInteger(privateS), parameterSpec); - /** Get keys */ - this.privateKey = KeyFactory.getInstance("EC").generatePrivate(privateKeySpec); - } - } catch (GeneralSecurityException | IllegalArgumentException e) { - log.error("[{}] Failed generate Server PSK/RPK", e.getMessage()); - throw new RuntimeException(e); - } - } - - private void setServerWithX509Cert() { - try { - if (this.context.getCtxServer().getKeyStoreValue() != null) { - setBuilderX509(); - X509Certificate rootCAX509Cert = (X509Certificate) this.context.getCtxServer().getKeyStoreValue().getCertificate(this.context.getCtxServer().getRootAlias()); - if (rootCAX509Cert != null) { - X509Certificate[] trustedCertificates = new X509Certificate[1]; - trustedCertificates[0] = rootCAX509Cert; - builder.setTrustedCertificates(trustedCertificates); - } else { - /** by default trust all */ - builder.setTrustedCertificates(new X509Certificate[0]); - } - } - else { - /** by default trust all */ - this.builder.setTrustedCertificates(new X509Certificate[0]); - log.error("Unable to load X509 files for LWM2MServer"); - } - } catch (KeyStoreException ex) { - log.error("[{}] Unable to load X509 files server", ex.getMessage()); - } - } - - private void setBuilderX509() { - /** - * For deb => KeyStorePathFile == yml or commandline: KEY_STORE_PATH_FILE - * For idea => KeyStorePathResource == common/transport/lwm2m/src/main/resources/credentials: in LwM2MTransportContextServer: credentials/serverKeyStore.jks - */ - try { - X509Certificate serverCertificate = (X509Certificate) this.context.getCtxServer().getKeyStoreValue().getCertificate(this.context.getCtxServer().getServerAlias()); - PrivateKey privateKey = (PrivateKey) this.context.getCtxServer().getKeyStoreValue().getKey(this.context.getCtxServer().getServerAlias(), this.context.getCtxServer().getKeyStorePasswordServer() == null ? null : this.context.getCtxServer().getKeyStorePasswordServer().toCharArray()); - this.builder.setPrivateKey(privateKey); - this.builder.setCertificateChain(new X509Certificate[]{serverCertificate}); - } catch (Exception ex) { - log.error("[{}] Unable to load KeyStore files server", ex.getMessage()); - } - } - - private void getParamsPSK() { - log.info("\nServer uses PSK -> private key : \n security key : [{}] \n serverSecureURI : [{}]", - Hex.encodeHexString(this.privateKey.getEncoded()), - this.context.getCtxServer().getServerSecureHost() + ":" + Integer.toString(this.context.getCtxServer().getServerSecurePort())); - } - - private void getParamsRPK() { - if (this.publicKey instanceof ECPublicKey) { - /** Get x coordinate */ - byte[] x = ((ECPublicKey) this.publicKey).getW().getAffineX().toByteArray(); - if (x[0] == 0) - x = Arrays.copyOfRange(x, 1, x.length); - - /** Get Y coordinate */ - byte[] y = ((ECPublicKey) this.publicKey).getW().getAffineY().toByteArray(); - if (y[0] == 0) - y = Arrays.copyOfRange(y, 1, y.length); - - /** Get Curves params */ - String params = ((ECPublicKey) this.publicKey).getParams().toString(); - log.info( - " \nServer uses RPK : \n Elliptic Curve parameters : [{}] \n Public x coord : [{}] \n Public y coord : [{}] \n Public Key (Hex): [{}] \n Private Key (Hex): [{}]", - params, Hex.encodeHexString(x), Hex.encodeHexString(y), - Hex.encodeHexString(this.publicKey.getEncoded()), - Hex.encodeHexString(this.privateKey.getEncoded())); - } else { - throw new IllegalStateException("Unsupported Public Key Format (only ECPublicKey supported)."); - } - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2mInMemorySecurityStore.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2mInMemorySecurityStore.java deleted file mode 100644 index 394e7ee5f1..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/server/secure/LwM2mInMemorySecurityStore.java +++ /dev/null @@ -1,212 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.server.secure; - -import com.google.gson.JsonObject; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.server.californium.LeshanServer; -import org.eclipse.leshan.server.registration.Registration; -import org.eclipse.leshan.server.security.InMemorySecurityStore; -import org.eclipse.leshan.server.security.SecurityInfo; -import org.eclipse.leshan.server.security.SecurityStoreListener; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.common.data.DeviceProfile; -import org.thingsboard.server.transport.lwm2m.secure.LwM2MGetSecurityInfo; -import org.thingsboard.server.transport.lwm2m.secure.ReadResultSecurityStore; -import org.thingsboard.server.transport.lwm2m.server.LwM2MTransportHandler; -import org.thingsboard.server.transport.lwm2m.server.client.AttrTelemetryObserveValue; -import org.thingsboard.server.transport.lwm2m.server.client.LwM2MClient; -import org.thingsboard.server.transport.lwm2m.utils.TypeServer; - -import java.util.Map; -import java.util.UUID; -import java.util.Collection; -import java.util.Collections; -import java.util.List; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.locks.Lock; -import java.util.concurrent.locks.ReadWriteLock; -import java.util.concurrent.locks.ReentrantReadWriteLock; -import java.util.stream.Collectors; - -import static org.thingsboard.server.transport.lwm2m.secure.LwM2MSecurityMode.*; - -@Slf4j -@Component("LwM2mInMemorySecurityStore") -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true' )|| ('${service.type:null}'=='monolith' && '${transport.lwm2m.enabled}'=='true')") -public class LwM2mInMemorySecurityStore extends InMemorySecurityStore { - // lock for the two maps - protected final ReadWriteLock readWriteLock = new ReentrantReadWriteLock(); - protected final Lock readLock = readWriteLock.readLock(); - protected final Lock writeLock = readWriteLock.writeLock(); - private final boolean infosAreCompromised = false; - protected Map sessions = new ConcurrentHashMap<>(); - protected Map profiles = new ConcurrentHashMap<>(); - private SecurityStoreListener listener; - - @Autowired - LwM2MGetSecurityInfo lwM2MGetSecurityInfo; - - @Override - public SecurityInfo getByEndpoint(String endPoint) { - readLock.lock(); - try { - String registrationId = this.getByRegistrationId(endPoint, null); - return (registrationId != null && sessions.size() > 0 && sessions.get(registrationId) != null) ? sessions.get(registrationId).getInfo() : this.add(endPoint); - } finally { - readLock.unlock(); - } - } - - @Override - public SecurityInfo getByIdentity(String identity) { - readLock.lock(); - try { - String integrationId = this.getByRegistrationId(null, identity); - return (integrationId != null) ? sessions.get(integrationId).getInfo() : add(identity); - } finally { - readLock.unlock(); - } - } - - @Override - public Collection getAll() { - readLock.lock(); - try { - return Collections.unmodifiableCollection(this.sessions.entrySet().stream().map(model -> model.getValue().getInfo()).collect(Collectors.toList())); - } finally { - readLock.unlock(); - } - } - - /** - * Removed registration Client from sessions and listener - * @param registrationId if Client - */ - public void delRemoveSessionAndListener(String registrationId) { - writeLock.lock(); - try { - LwM2MClient lwM2MClient = (sessions.get(registrationId) != null) ? sessions.get(registrationId) : null; - if (lwM2MClient != null) { - if (listener != null) { - listener.securityInfoRemoved(infosAreCompromised, lwM2MClient.getInfo()); - } - sessions.remove(registrationId); - } - } finally { - writeLock.unlock(); - } - } - - @Override - public void setListener(SecurityStoreListener listener) { - this.listener = listener; - } - - public LwM2MClient getlwM2MClient(String endPoint, String identity) { - Map.Entry modelClients = (endPoint != null) ? - this.sessions.entrySet().stream().filter(model -> endPoint.equals(model.getValue().getEndPoint())).findAny().orElse(null) : - this.sessions.entrySet().stream().filter(model -> identity.equals(model.getValue().getIdentity())).findAny().orElse(null); - return (modelClients != null) ? modelClients.getValue() : null; - } - - public LwM2MClient getlwM2MClient(String registrationId) { - return this.sessions.get(registrationId); - } - - public LwM2MClient getlwM2MClient(LeshanServer lwServer, Registration registration) { - writeLock.lock(); - try { - if (this.sessions.get(registration.getEndpoint()) == null) { - this.add(registration.getEndpoint()); - } - LwM2MClient lwM2MClient = this.sessions.get(registration.getEndpoint()); - lwM2MClient.setLwServer(lwServer); - lwM2MClient.setRegistration(registration); - lwM2MClient.setAttributes(registration.getAdditionalRegistrationAttributes()); - this.sessions.put(registration.getId(), lwM2MClient); - this.sessions.remove(registration.getEndpoint()); - return lwM2MClient; - } finally { - writeLock.unlock(); - } - } - - private String getByRegistrationId(String endPoint, String identity) { - List registrationIds = (endPoint != null) ? - this.sessions.entrySet().stream().filter(model -> endPoint.equals(model.getValue().getEndPoint())).map(model -> model.getKey()).collect(Collectors.toList()) : - this.sessions.entrySet().stream().filter(model -> identity.equals(model.getValue().getIdentity())).map(model -> model.getKey()).collect(Collectors.toList()); - return (registrationIds != null && registrationIds.size() > 0) ? registrationIds.get(0) : null; - } - - public String getByRegistrationId(String credentialsId) { - List registrationIds = (this.sessions.entrySet().stream().filter(model -> credentialsId.equals(model.getValue().getEndPoint())).map(model -> model.getKey()).collect(Collectors.toList()).size() > 0) ? - this.sessions.entrySet().stream().filter(model -> credentialsId.equals(model.getValue().getEndPoint())).map(model -> model.getKey()).collect(Collectors.toList()) : - this.sessions.entrySet().stream().filter(model -> credentialsId.equals(model.getValue().getIdentity())).map(model -> model.getKey()).collect(Collectors.toList()); - return (registrationIds != null && registrationIds.size() > 0) ? registrationIds.get(0) : null; - } - - public Registration getByRegistration(String registrationId) { - return this.sessions.get(registrationId).getRegistration(); - } - - private SecurityInfo add(String identity) { - ReadResultSecurityStore store = lwM2MGetSecurityInfo.getSecurityInfo(identity, TypeServer.CLIENT); - UUID profileUuid = (addUpdateProfileParameters(store.getDeviceProfile())) ? store.getDeviceProfile().getUuidId() : null; - if (store.getSecurityInfo() != null) { - if (store.getSecurityMode() < DEFAULT_MODE.code) { - String endpoint = store.getSecurityInfo().getEndpoint(); - sessions.put(endpoint, new LwM2MClient(endpoint, store.getSecurityInfo().getIdentity(), store.getSecurityInfo(), store.getMsg(), null, null, profileUuid)); - } - } else { - if (store.getSecurityMode() == NO_SEC.code) - sessions.put(identity, new LwM2MClient(identity, null, null, store.getMsg(), null, null, profileUuid)); - else log.error("Registration failed: FORBIDDEN, endpointId: [{}]", identity); - } - return store.getSecurityInfo(); - } - - public Map getSession (UUID sessionUuId){ - return this.sessions.entrySet().stream().filter(e -> e.getValue().getSessionUuid().equals(sessionUuId)).collect(Collectors.toMap(map -> map.getKey(), map -> map.getValue())); - } - - public Map getSessions() { - return this.sessions; - } - - public Map getProfiles() { - return this.profiles; - } - - public MapsetProfiles(Map profiles) { - return this.profiles = profiles; - } - - /** - * - * @param deviceProfile - */ - public boolean addUpdateProfileParameters(DeviceProfile deviceProfile) { - JsonObject profilesConfigData = LwM2MTransportHandler.getObserveAttrTelemetryFromThingsboard(deviceProfile); - if (profilesConfigData != null) { - profiles.put(deviceProfile.getUuidId(), LwM2MTransportHandler.getNewProfileParameters(profilesConfigData)); - } - return (profilesConfigData != null); - } - -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/LwM2mValueConverterImpl.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/LwM2mValueConverterImpl.java deleted file mode 100644 index d7cae734a2..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/LwM2mValueConverterImpl.java +++ /dev/null @@ -1,146 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.utils; - -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.model.ResourceModel.Type; -import org.eclipse.leshan.core.node.LwM2mPath; -import org.eclipse.leshan.core.node.codec.CodecException; -import org.eclipse.leshan.core.node.codec.LwM2mValueConverter; -import org.eclipse.leshan.core.util.Hex; -import org.eclipse.leshan.core.util.StringUtils; - -import javax.xml.datatype.DatatypeConfigurationException; -import javax.xml.datatype.DatatypeFactory; -import javax.xml.datatype.XMLGregorianCalendar; -import java.util.Date; - -@Slf4j -public class LwM2mValueConverterImpl implements LwM2mValueConverter { - - @Override - public Object convertValue(Object value, Type currentType, Type expectedType, LwM2mPath resourcePath) - throws CodecException { - if (expectedType == null) { - /** unknown resource, trusted value */ - return value; - } - - if (currentType == expectedType) { - /** expected type */ - return value; - } - - switch (expectedType) { - case INTEGER: - switch (currentType) { - case FLOAT: - log.debug("Trying to convert float value [{}] to integer", value); - Long longValue = ((Double) value).longValue(); - if ((double) value == longValue.doubleValue()) { - return longValue; - } - default: - break; - } - break; - case FLOAT: - switch (currentType) { - case INTEGER: - log.debug("Trying to convert integer value [{}] to float", value); - Double floatValue = ((Long) value).doubleValue(); - if ((long) value == floatValue.longValue()) { - return floatValue; - } - default: - break; - } - break; - case BOOLEAN: - switch (currentType) { - case STRING: - log.debug("Trying to convert string value {} to boolean", value); - if (StringUtils.equalsIgnoreCase((String) value, "true")) { - return true; - } else if (StringUtils.equalsIgnoreCase((String) value, "false")) { - return false; - } - break; - case INTEGER: - log.debug("Trying to convert int value {} to boolean", value); - Long val = (Long) value; - if (val == 1) { - return true; - } else if (val == 0) { - return false; - } - break; - default: - break; - } - break; - case TIME: - switch (currentType) { - case INTEGER: - log.debug("Trying to convert long value {} to date", value); - /** let's assume we received the millisecond since 1970/1/1 */ - return new Date((Long) value); - case STRING: - log.debug("Trying to convert string value {} to date", value); - /** let's assume we received an ISO 8601 format date */ - try { - DatatypeFactory datatypeFactory = DatatypeFactory.newInstance(); - XMLGregorianCalendar cal = datatypeFactory.newXMLGregorianCalendar((String) value); - return cal.toGregorianCalendar().getTime(); - } catch (DatatypeConfigurationException | IllegalArgumentException e) { - log.debug("Unable to convert string to date", e); - throw new CodecException("Unable to convert string (%s) to date for resource %s", value, - resourcePath); - } - default: - break; - } - break; - case STRING: - switch (currentType) { - case BOOLEAN: - case INTEGER: - case FLOAT: - return String.valueOf(value); - default: - break; - } - break; - case OPAQUE: - if (currentType == Type.STRING) { - /** let's assume we received an hexadecimal string */ - log.debug("Trying to convert hexadecimal string [{}] to byte array", value); - // TODO check if we shouldn't instead assume that the string contains Base64 encoded data - try { - return Hex.decodeHex(((String) value).toCharArray()); - } catch (IllegalArgumentException e) { - throw new CodecException("Unable to convert hexastring [%s] to byte array for resource %s", value, - resourcePath); - } - } - break; - default: - } - - throw new CodecException("Invalid value type for resource %s, expected %s, got %s", resourcePath, expectedType, - currentType); - } -} diff --git a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/TypeServer.java b/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/TypeServer.java deleted file mode 100644 index 8e1dde9693..0000000000 --- a/common/transport/lwm2m/src/main/java/org/thingsboard/server/transport/lwm2m/utils/TypeServer.java +++ /dev/null @@ -1,29 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.transport.lwm2m.utils; - -public enum TypeServer { - BOOTSTRAP(0, "bootstrap"), - CLIENT(1, "client"); - - public int code; - public String type; - - TypeServer(int code, String type) { - this.code = code; - this.type = type; - } -} diff --git a/common/transport/lwm2m/src/main/resources/credentials/serverKeyStore.jks b/common/transport/lwm2m/src/main/resources/credentials/serverKeyStore.jks deleted file mode 100644 index b5b6c9fa3c43118262f4c89b1ba319ef09b694d0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5716 zcma)qB?KfE>5`UM79>`>LrS_k1Z1TVP&x!r8kUe1VM&qhE)@w8Sh~AA zmi&2t^Sw25XYQRdbI#23ob%56ndklIKtidsv9WLo?xeTkAdo7uheNQdNgC*M#YWZ9C z8mtluT+B}uLJVIvNe`D=hTCtGC0g)8E|o0i_@b z<2`@}0RCrr0c-)*5SD+MU_nY;a=qs-?3o20i;F--p%6iF5g|cH$l(8gG9>n)%|!@z z`e~6E5#G>|r)1s2=wB!}k(R?oh60L<&#i@}v%BCdnBkr_vz`O3NxUnc)1(^JLQO`X zwV^mGbW}o64_&>?7Jy1|w}NaNo$EGd>HhAmm#N6Iv;_$&{cE?Bf|QKp0Gq#1JpbT$ z0IUHo|Mkj$0umJ!{@=3kibVTk`D@QL$9rwJ;V+EnGxGud0;;rg1_zNtQ=BRb2G*rk z1{WwmgJh<>=_BRh#8DPGxo=GRkn6h)S%ZV2IHFd4%w5-#$#p#yLTagW95m4%RqftYWhsK@*a6EN-rNBoq z+xux$aP8hQmpM^CsXSG5A!Q=@BOmD);TF?)bozM*K#acDrgh?^zPgoP6n-D@$nxW2P%Sa-k*uH}WFVH19iZtl0c zruOT#PpS#YiRmfbE6EO2WO!-9-Dn|>dN8?}^jKRKNU8zp05L%~o-&8Ib*McQ3BluF zNS`Xmx9fXAjca|+KA>!p;SK!rhu~b(a5}qnDj3**$$L%k<9X6nb_0xl%!F%5F*)% z<_%aH^l>CZbg$8fSNaY@62pK+K^dZ4)Wh}K@vU9T_-9Y)t3vFO`g#DU@-o7C7SFUn zcBV?R*Uj#}X0UWH7<0ZFCP8d6bA$IG%C=>5b_=m_^wX7267A#Nxci(>(hDVyJO0I* z7apu;$`x^!M`<-A+TnlVJ17L!9%Mu{sdB0SO)*^I&NMN6?z!U(Vza56>@uS-cP?9K z&0X!}gx7W?yAP^I(oI-Ew0CHJBQDSx962H{i&O1);>NWue0sx5Ds|ZG&l

t^Q*A zz2VM8H6^(VvE-u{#!Femel3CiPESCye(B!J&u9D^V`M zz$xC-NvsP}_BiwB(fc_NofT2Z4!P=CK_}{F-tF`>5R< z0@q0@4pHjD`*pRfU*h%?$!tnIh3B0J3qmQ`Dn&BL53X^0d@608MOLsDcM9d=aMI3? z&LfTUeC`$p(Zdv{5-u=YoU84x?)H6KWZVZG3UNV7B4pvsX9;3!>cU+`ik<~@5&gxw zP)H5EPJ?M zV5ndrZ&-|4@MGH=z1LgMU^-DgyUb>^MJFdH(OUDQ;Rp76!uOwMgPd`2Ij|SL4D{QX zNv<4r``x)@#4$Y4HSV_%$UCraFe1cRX!-T7+PbO%mD?ul9zd&eL)y3MYlZqolkSvA zVs(+}tI&#rm|v+Ky59JOxIL-U889}w@iZCp{W$@PSbZPV)y7DRV5qPab37rH>0fVR z>73o~$Vq)WFTQIU4Gz>IAiDW5j{h{BS7h3dSb+`nwu~%!os=)#jz;|9RY6v&Ov-!% zowQ)>2kbaR_&srS4&yINtZ7?%8jLw%K2vkmrcM5ChRpS{9LPhUUYsi+&sklq44Ztx zfU@kpDA$ElBu5H+Q8Bq`c(HDGSuMymJC3Bs2 z;OcTnnpOl*EoEQn!_S_Z!+@W|4sR}HDiH&(a3wP<&^~#yf+Y%&Ph0uH`j=bb!;!`B zu|UE#6H4#46F9fn3w)0g5FD>_WY%7bzI;n|_KUqEbxSYt&B13!QVL4!Rz+4c#kKln zrw&FqI6^#IN?kGf69&zHfkR+bO40DUpwDnw?F?Jl0=is00b+!^Q5zt+V42>mQ!cC? zMxhilcUgUlD;O-&h`883!Vr}J!IB;Wmd9y~d{(aqe* zCHp7^wEqkx3Qi`gwKsJsZQw`jPUwc?D*$C@DzSX-GlN7vkq+2mH+f23!2hrxn874? zv_2%k`|Fy!@ze*oZsun0oOpvMwCsGSPYI@1H=~z++p`+&)+Z=u49Z&V{?G}P*^yvh zfzihAOgY`kd0n{FFe{_CNOtH4NRG#|`K9=Sck{QyFSC@#!)n59hEm=y1#no-DAiR* zNcdH7nz}aNQzaA@IIh<{*A2*TbsryTC^TgoE)yJ7W$UUxDD{5CTOGQ~& zDLV(hxqS4(2nwSVMyef{4P>HUrWXu}fJlV>f;6mnVvz0?Je!G1_3(kNS z!!F9Nw#7@bc%&o0)qW5iywwP97rM@Cdgwu&JQ5ZttGVomP9TTv{&eF|9zv+=750Q+ zaQMcI3Cj$uyTUTJRw=yo@D8pDCpvo_N7vU0BJv1tibIEL!Xya7xT4y$YkaRh?eE@V zD=P2L%TwvqV*w11I%r~xfxvBo(n>8(#-xsIN!zX7{v0YJ3*{q&b-@Ajmt28&E4SB5 zC<|Dw2(6)}Smlj~u6$fy>;)@+WHD42K*s|SdQhda8Kica=@=^cZP37MLk$b_7_lKy zul6_}h(;l#UB!+FHhmV<#`exzS3^4N7_4t%l~?KM^*_8Uu1b1f3A18kblJt~bX0bn zl*|jd?m&Qe9+LXAc`kN#i3%{hRPThRWA0PDF}b~sAj535@g=6}_Gyk|z*B`PcXbRl zUm2A-fd=APyhAabdJV{q!O5E5#&H2q?aFvAKG#xAz5&PESE;lR3KNeoqG?P!)I7sC z{MeVDg#5CpGd*`;XIF!=zIaw)7$2XHOwP2aDyQ^gZuR@{7Npr=KV6;QDW?FjLnY_T zo5A6G8}kQ)Yb4j(rRB&n9_~|g_Dr+H>aeguZYU;(S6b=6JV_>)(6I0v1IHw zEf!ZOhm(~dI4o5w)JchDhGNo7IsXPPeg3LiCki1-Qhl)qMRQ#fcfO+38)tOk%8@lVP z#e=F)w3hNyvLaQj-I2dYX^$F{H{el=f~(SDy>c`akd)F`EiDX;slE`&ga_6wZ`O}; z`3P=I4C6~s@d7!-rH)kYUug$*%z-%>Hti*ijmBOY+Ss_3n2$gnv3p59$$+!rF9{7L z!0vQV71n|=5n=-<*NkkRx?jw!%|}KBkSU;Wt!2KJguTF=^|^=-T>zY$0Gx$Rjbp8U7(5g`R| z2lO0p>(ii*Mp5(y19wH!V0W1Fa&wi7Pola3$D<8O%Z{Mkc zsG#b2MeQ~i~8Cw1o4-og?YmTn?G$GzK*XrFzBRxh+d4=Xh}^Dk%GX%2M{jaD*g z9$Ul2u-m{L|LIo`K04$(oW3-cg9+)&XhamLHJr$E6yM~{z80M%rvz_ZZpBpl_>@=i zpo#4P9E;b9>D$%gy&B-xIKgYbi|apvWo8R(+wod=7gI9xc=> zOV4lE$|1n=%h|1c`dR7R5*nH-lDv! z%wu*K-U(bw4;U9q839}S4{lD(H!Ty);YQ#cC}L317bwMVQYktcD_q28q>y=u@5FCw zwfdC@Pkh%X%D;$^MlQKyOkq7qJzu9a;p6denhpE9ypwP^9~XFj_I}go5VwwP<&VAi z6VvqhC()mCel0ice({ob{W&Mx(z(v6Yuj(qYr=Jf>^b4(*|!`XGuXt5ta+=CTo=ko zN20d89d%B-n3OWC;YZ)Wv@zO`O)c)YjXTXSn>$U%T*{2CRj}tj!Z%ONCnANoryL{K zu!wwf+S<-{e*x?Yn$n8IORBZmGN@nNSR5kdJXxGYnj?z&SU+!zSF5e@Z?GE=3u5qh z(yQip6>xYtm`XFqQRbg=V=QY56+B}`E#u~yW6N#oXHpz##5TijonNIxW(#3j+EI)q z)M;$KGmXG*y8Bz@jyg`&@JiaIrh=$VLHZHdL@&CRxOyal4poNX`8h<1ILw&U#Y+~M zjbvrrHT{a$4)qJ4fvgx(Ieo`=0Yw{eCu_WMs}#U|SN6cq`jvzv-I2y|%vO_y?YeRS zXU!_oKf7)s4mRZ=D#0BS^xZ7yt%Oy;{WTY*y&)N`wvj&iSttKsx!>h@Z$4y3gb@|a z>BgTazbH_w%PGmF@tC_>4#v)cer&%K%VWWKNgX^5D;T8DXXfF_7Z<2TvGGsm~NuR zvqMUBqBr<=apnX6CWlEIoBl`{-G+xw;U+hrXUyG9`=POP$CIL^6v<}cI2q*9;`H|i zo!!sQ`zKz$_vheHlBMd*wCa}QdlB~_a~+Y`$aJa4S2F_Ph>ZgX0bjiX?uT zX&d7LyBF``a8Oe}?tf|bWg->|Bgj?lccoI@sTagXQy*CcSe5VYNo&xUe+#4RHl(uE zulHEdz}NfkcU&_3tj$;K0hgWj4PBLY-xq~OKhez2|4$C{SY1uUklvotUGZ?CGbDHDF;?N$gDt)i}$)dV=yaYEGI;coQc5P`K z`UPq^SJwI3ez~1(1y%Pbd#2>pD(fTBeCN;3fLQ)(N}K7vQvQ@z##LXlo+djeI!EiOu#@X2 z?(n#SKT8Rr3#}iSK&6^=o5Ecjl5bqHQ4mK?w0GBdcw7a$V8kDQ| qkcRm%4dLuH%rb{d=@zQVZ?hk0O%Ryaxn;x~P%wJagN=g~iTppw$f0Ne diff --git a/common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_credentials.sh b/common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_credentials.sh deleted file mode 100755 index fd07df3feb..0000000000 --- a/common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_credentials.sh +++ /dev/null @@ -1,208 +0,0 @@ -#!/bin/sh -# -# Copyright © 2016-2020 The Thingsboard Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# source the properties: -. ./lwM2M_keygen.properties - -# Generation of the keystore. -echo "${H0}====START========${RESET}" -echo "${H1}Server Keystore : ${RESET}" -echo "${H1}==================${RESET}" -echo "${H2}Creating the trusted root CA key and certificate...${RESET}" -# -keysize -# 1024 (when using -genkeypair) -keytool \ - -genkeypair \ - -alias $ROOT_KEY_ALIAS \ - -keyalg EC \ - -dname "CN=$ROOT_CN, OU=$ORGANIZATIONAL_UNIT, O=$ORGANIZATION, L=$CITY, ST=$STATE_OR_PROVINCE, C=$TWO_LETTER_COUNTRY_CODE" \ - -validity $VALIDITY \ - -storetype $STORETYPE \ - -keypass $SERVER_STORE_PWD \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD - -echo -echo "${H2}Creating server key and self-signed certificate ...${RESET}" -keytool \ - -genkeypair \ - -alias $SERVER_ALIAS \ - -keyalg EC \ - -dname "CN=$SERVER_SELF_CN, OU=$ORGANIZATIONAL_UNIT, O=$ORGANIZATION, L=$CITY, ST=$STATE_OR_PROVINCE, C=$TWO_LETTER_COUNTRY_CODE" \ - -validity $VALIDITY \ - -storetype $STORETYPE \ - -keypass $SERVER_STORE_PWD \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD -keytool \ - -exportcert \ - -alias $SERVER_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD | \ - keytool \ - -importcert \ - -alias $SERVER_SELF_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD \ - -noprompt - -echo -echo "${H2}Creating server certificate signed by root CA...${RESET}" -keytool \ - -certreq \ - -alias $SERVER_ALIAS \ - -dname "CN=$SERVER_CN, OU=$ORGANIZATIONAL_UNIT, O=$ORGANIZATION, L=$CITY, ST=$STATE_OR_PROVINCE, C=$TWO_LETTER_COUNTRY_CODE" \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD | \ - keytool \ - -gencert \ - -alias $ROOT_KEY_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD \ - -storetype $STORETYPE \ - -validity $VALIDITY | \ - keytool \ - -importcert \ - -alias $SERVER_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD - -echo -echo "${H2}Creating server key and self-signed certificate ...${RESET}" -keytool \ - -genkeypair \ - -alias $BOOTSTRAP_ALIAS \ - -keyalg EC \ - -dname "CN=$BOOTSTRAP_SELF_CN, OU=$ORGANIZATIONAL_UNIT, O=$ORGANIZATION, L=$CITY, ST=$STATE_OR_PROVINCE, C=$TWO_LETTER_COUNTRY_CODE" \ - -validity $VALIDITY \ - -storetype $STORETYPE \ - -keypass $SERVER_STORE_PWD \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD -keytool \ - -exportcert \ - -alias $BOOTSTRAP_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD | \ - keytool \ - -importcert \ - -alias $BOOTSTRAP_SELF_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD \ - -noprompt - -echo -echo "${H2}Creating bootstrap certificate signed by root CA...${RESET}" -keytool \ - -certreq \ - -alias $BOOTSTRAP_ALIAS \ - -dname "CN=$BOOTSTRAP_CN, OU=$ORGANIZATIONAL_UNIT, O=$ORGANIZATION, L=$CITY, ST=$STATE_OR_PROVINCE, C=$TWO_LETTER_COUNTRY_CODE" \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD | \ - keytool \ - -gencert \ - -alias $ROOT_KEY_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD \ - -storetype $STORETYPE \ - -validity $VALIDITY | \ - keytool \ - -importcert \ - -alias $BOOTSTRAP_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD - - -echo -echo "${H1}Client Keystore : ${RESET}" -echo "${H1}==================${RESET}" -echo "${H2}Creating client key and self-signed certificate with expected CN...${RESET}" -keytool \ - -genkeypair \ - -alias $CLIENT_ALIAS \ - -keyalg EC \ - -dname "CN=$CLIENT_SELF_CN, OU=$ORGANIZATIONAL_UNIT, O=$ORGANIZATION, L=$CITY, ST=$STATE_OR_PROVINCE, C=$TWO_LETTER_COUNTRY_CODE" \ - -validity $VALIDITY \ - -storetype $STORETYPE \ - -keypass $CLIENT_STORE_PWD \ - -keystore $CLIENT_STORE \ - -storepass $CLIENT_STORE_PWD -keytool \ - -exportcert \ - -alias $CLIENT_ALIAS \ - -keystore $CLIENT_STORE \ - -storepass $CLIENT_STORE_PWD | \ - keytool \ - -importcert \ - -alias $CLIENT_SELF_ALIAS \ - -keystore $CLIENT_STORE \ - -storepass $CLIENT_STORE_PWD \ - -noprompt - -echo -echo "${H2}Import root certificate just to be able to import ned by root CA with expected CN...${RESET}" -keytool \ - -exportcert \ - -alias $ROOT_KEY_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD | \ - keytool \ - -importcert \ - -alias $ROOT_KEY_ALIAS \ - -keystore $CLIENT_STORE \ - -storepass $CLIENT_STORE_PWD \ - -noprompt - -echo -echo "${H2}Creating client certificate signed by root CA with expected CN...${RESET}" -keytool \ - -certreq \ - -alias $CLIENT_ALIAS \ - -dname "CN=$CLIENT_CN, OU=$ORGANIZATIONAL_UNIT, O=$ORGANIZATION, L=$CITY, ST=$STATE_OR_PROVINCE, C=$TWO_LETTER_COUNTRY_CODE" \ - -keystore $CLIENT_STORE \ - -storepass $CLIENT_STORE_PWD | \ - keytool \ - -gencert \ - -alias $ROOT_KEY_ALIAS \ - -keystore $SERVER_STORE \ - -storepass $SERVER_STORE_PWD \ - -storetype $STORETYPE \ - -validity $VALIDITY | \ - keytool \ - -importcert \ - -alias $CLIENT_ALIAS \ - -keystore $CLIENT_STORE \ - -storepass $CLIENT_STORE_PWD \ - -noprompt - -echo -echo "${H0}!!! Warning ${H2}Migrate ${H1}${SERVER_STORE} ${H2}to ${H1}PKCS12 ${H2}which is an industry standard format..${RESET}" -keytool \ - -importkeystore \ - -srckeystore $SERVER_STORE \ - -destkeystore $SERVER_STORE \ - -deststoretype pkcs12 \ - -srcstorepass $SERVER_STORE_PWD - -echo -echo "${H0}!!! Warning ${H2}Migrate ${H1}${CLIENT_STORE} ${H2}to ${H1}PKCS12 ${H2}which is an industry standard format..${RESET}" -keytool \ - -importkeystore \ - -srckeystore $CLIENT_STORE \ - -destkeystore $CLIENT_STORE \ - -deststoretype pkcs12 \ - -srcstorepass $CLIENT_STORE_PWD diff --git a/common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_keygen.properties b/common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_keygen.properties deleted file mode 100644 index 8dd2c30a9a..0000000000 --- a/common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_keygen.properties +++ /dev/null @@ -1,58 +0,0 @@ -# -# Copyright © 2016-2017 The Thingsboard Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# Keystore common parameters -ROOT_KEY_ALIAS=rootCA -DOMAIN_SUFFIX="$(hostname)" -ROOT_CN="$DOMAIN_SUFFIX rootCA" -ORGANIZATIONAL_UNIT=Thingsboard -ORGANIZATION=Thingsboard -CITY=SF -STATE_OR_PROVINCE=CA -TWO_LETTER_COUNTRY_CODE=US -VALIDITY=36500 #days -STORETYPE="JKS" - -#Server -SERVER_STORE=serverKeyStore.jks -SERVER_STORE_PWD=server_ks_password -SERVER_ALIAS=server -SERVER_CN="$DOMAIN_SUFFIX server LwM2M signed by root CA" -SERVER_SELF_ALIAS=server_self_signed -SERVER_SELF_CN="$DOMAIN_SUFFIX server LwM2M self-signed" -BOOTSTRAP_ALIAS=bootstrap -BOOTSTRAP_CN="$DOMAIN_SUFFIX bootstrap server LwM2M signed by root CA" -BOOTSTRAP_SELF_ALIAS=bootstrap_self_signed -BOOTSTRAP_SELF_CN="$DOMAIN_SUFFIX bootstrap server LwM2M self-signed" - -# Client -CLIENT_STORE=clientKeyStore.jks -CLIENT_STORE_PWD=client_ks_password -CLIENT_ALIAS=client -#CLIENT_CN=client_lwm2m_x509 -CLIENT_CN=mobile_lwm2m_x509 -CLIENT_SELF_ALIAS=client_self_signed -CLIENT_SELF_CN="$DOMAIN_SUFFIX client LwM2M self-signed" - -# Color output stuff -red=`tput setaf 1` -green=`tput setaf 2` -blue=`tput setaf 4` -bold=`tput bold` -H0=${red}${bold} -H1=${green}${bold} -H2=${blue} -RESET=`tput sgr0` diff --git a/common/transport/lwm2m/src/main/resources/models/10241.xml b/common/transport/lwm2m/src/main/resources/models/10241.xml deleted file mode 100644 index 2b2af520e2..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10241.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - HostDeviceInfo - - 10241 - urn:oma:lwm2m:x:10241 - - - Multiple - Optional - - Host Device Manufacturer - R - Multiple - Mandatory - String - - - - - Host Device Model Number - R - Multiple - Mandatory - String - - - - - Host Device Unique ID - R - Multiple - Mandatory - String - - - - - Host Device Software Version - R - Multiple - Mandatory - String - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10242.xml b/common/transport/lwm2m/src/main/resources/models/10242.xml deleted file mode 100644 index 09a62806d3..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10242.xml +++ /dev/null @@ -1,659 +0,0 @@ - - - - - - - 3-Phase Power Meter - - - - 10242 - urn:oma:lwm2m:x:10242 - 1.0 - 1.0 - Multiple - Optional - - - Manufacturer - R - Single - Optional - String - - - - - - - - Model Number - R - Single - Optional - String - - - - - - - - Serial Number - R - Single - Optional - String - - - - - - - - Description - R - Single - Optional - String - - - - - - - - Tension R - R - Single - Mandatory - Float - - V - - - - - - Current R - R - Single - Mandatory - Float - - A - - - - - - Active Power R - R - Single - Optional - Float - - kW - - - - - - Reactive Power R - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power R - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power R - R - Single - Optional - Float - - kvar - - - - - - Apparent Power R - R - Single - Optional - Float - - kVA - - - - - - Power Factor R - R - Single - Optional - Float - -1..1 - - - - - - - THD-V R - R - Single - Optional - Float - - /100 - - - - - - THD-A R - R - Single - Optional - Float - - /100 - - - - - - Tension S - R - Single - Mandatory - Float - - V - - - - - - Current S - R - Single - Mandatory - Float - - A - - - - - - Active Power S - R - Single - Optional - Float - - kW - - - - - - Reactive Power S - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power S - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power S - R - Single - Optional - Float - - kvar - - - - - - Apparent Power S - R - Single - Optional - Float - - kVA - - - - - - Power Factor S - R - Single - Optional - Float - -1..1 - - - - - - - THD-V S - R - Single - Optional - Float - - /100 - - - - - - THD-A S - R - Single - Optional - Float - - /100 - - - - - - Tension T - R - Single - Mandatory - Float - - V - - - - - - Current T - R - Single - Mandatory - Float - - A - - - - - - Active Power T - R - Single - Optional - Float - - kW - - - - - - Reactive Power T - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power T - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power T - R - Single - Optional - Float - - kvar - - - - - - Apparent Power T - R - Single - Optional - Float - - kVA - - - - - - Power Factor T - R - Single - Optional - Float - -1..1 - - - - - - - THD-V T - R - Single - Optional - Float - - /100 - - - - - - THD-A T - R - Single - Optional - Float - - /100 - - - - - - 3-Phase Active Power - R - Single - Optional - Float - - kW - - - - - - 3-Phase Reactive Power - R - Single - Optional - Float - - kvar - - - - - - 3-Phase Inductive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - 3-Phase Capacitive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - 3-Phase Apparent Power - R - Single - Optional - Float - - kVA - - - - - - 3-Phase Power Factor - R - Single - Optional - Float - -1..1 - - - - - - - 3-Phase phi cosine - R - Single - Optional - Float - -1..1 - - - - - - - Active Energy - R - Single - Optional - Float - - kWh - - - - - - Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Inductive Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Capacitive Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Apparent Energy - R - Single - Optional - Float - - kVAh - - - - - - Tension R-S - R - Single - Optional - Float - - V - - - - - - Tension S-T - R - Single - Optional - Float - - V - - - - - - Tension T-R - R - Single - Optional - Float - - V - - - - - - Frequency - R - Single - Optional - Float - - Hz - - - - - - Neutral Current - R - Single - Optional - Float - - A - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10243.xml b/common/transport/lwm2m/src/main/resources/models/10243.xml deleted file mode 100644 index b506162174..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10243.xml +++ /dev/null @@ -1,263 +0,0 @@ - - - - - - - Single-Phase Power Meter - - - - 10243 - urn:oma:lwm2m:x:10243 - 1.0 - 1.0 - Multiple - Optional - - - Manufacturer - R - Single - Optional - String - - - - - - - - Model Number - R - Single - Optional - String - - - - - - - - Serial Number - R - Single - Optional - String - - - - - - - - Description - R - Single - Optional - String - - - - - - - - Tension - R - Single - Mandatory - String - - V - - - - - - Current - R - Single - Mandatory - Float - - A - - - - - - Active Power - R - Single - Optional - Float - - kW - - - - - - Reactive Power - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - Apparent Power - R - Single - Optional - Float - - kVA - - - - - - Power Factor - R - Single - Optional - Float - -1..1 - - - - - - - THD-V - R - Single - Optional - Float - - /100 - - - - - - THD-A - R - Single - Optional - Float - - /100 - - - - - - Active Energy - R - Single - Optional - Float - - kWh - - - - - - Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Apparent Energy - R - Single - Optional - Float - - kVAh - - - - - - Frequency - R - Single - Optional - Float - - Hz - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10244.xml b/common/transport/lwm2m/src/main/resources/models/10244.xml deleted file mode 100644 index d1ae9d911e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10244.xml +++ /dev/null @@ -1,301 +0,0 @@ - - - VehicleControlUnit - - 10244 - urn:oma:lwm2m:x:10244 - Single - Optional - - Vehicle UI State - R - Single - Mandatory - Integer - 0..15 - - - - Vehicle Speed - R - Single - Mandatory - Integer - - km/h - - - Vehicle Shift Status - R - Single - Mandatory - Integer - 0..3 - - - - Vehicle AP Position - R - Single - Mandatory - Integer - 0..100 - /100 - - - Vehicle Power - R - Single - Optional - Float - - kW - - - Vehicle Drive Energy - R - Single - Optional - Float - - Wh - - - Vehicle Energy Consumption Efficiency - R - Single - Optional - Float - - Wh/km - - - Vehicle Estimated Mileage - R - Single - Optional - Integer - - km - - - Vehicle Charge Cable Status - R - Single - Mandatory - Boolean - - - - - Vehicle Charge Status - R - Single - Mandatory - Integer - 0..15 - - - - Vehicle Charge Voltage - R - Single - Mandatory - Float - - V - - - Vehicle Charge Current - R - Single - Mandatory - Float - - A - - - Vehicle Charge Remaining Time - R - Single - Mandatory - Integer - - min - - - Battery Pack Voltage - R - Single - Mandatory - Float - - V - - - Battery Pack Current - R - Single - Mandatory - Float - - A - - - Battery Pack Remaining Capacity - R - Single - Mandatory - Integer - - Ah - - - Battery Pack SOC - R - Single - Mandatory - Integer - 0..100 - /100 - - - Battery Pack SOH - R - Single - Mandatory - Integer - 0..100 - /100 - - - Battery Cell MinVolt - R - Single - Mandatory - Integer - - mV - - - Battery Cell MaxVolt - R - Single - Mandatory - Integer - - mV - - - Battery Module MinTemp - R - Single - Mandatory - Integer - - Cel - - - Battery Module MaxTemp - R - Single - Mandatory - Integer - - Cel - - - Battery Connection Status - R - Single - Mandatory - Boolean - - - - - - MCU Voltage - R - Single - Mandatory - Integer - - V - - - MCU Temperature - R - Single - Mandatory - Integer - - Cel - - - Motor Speed - R - Single - Mandatory - Integer - - 1/min - - - Motor Temperature - R - Single - Mandatory - Integer - - Cel - - - Motor OT Warning - R - Single - Optional - Boolean - - - - - MCU OT Warning - R - Single - Optional - Boolean - - - - - Battery Pack OT Warning - R - Single - Optional - Boolean - - - - - MCU fault - R - Single - Optional - Boolean - - - - - Motor Error - R - Single - Optional - Boolean - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10245.xml b/common/transport/lwm2m/src/main/resources/models/10245.xml deleted file mode 100644 index ca8c9da9ae..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10245.xml +++ /dev/null @@ -1,217 +0,0 @@ - - - - - - Relay Management - This LWM2M Object provides a range of eNB related measurements and parameters of which several are changeable. Furthermore, it includes Resources to enable/disable the eNB. - 10245 - urn:oma:lwm2m:x:10245 - - - Single - Optional - - - eNB Availability - R - Single - Mandatory - Boolean - AVAILABLE; UNAVAILABLE - - This field indicates to the CCC whether or not the eNB of the CrowdBox is available for activation: AVAILABLE = TRUE; UNAVAILABLE = FALSE This is set by the CrowdBox itself using an algorithm specific to the use case and based on parameters known to the CrowdBox which may not necessarily be signalled to the network. In the absence of a more specific algorithm, this parameter should be set to AVAILABLE, unless a fault is detected which would prevent activation of the eNB, in which case it should be set to UNAVAILABLE. - - - GPS Status - R - Single - Mandatory - Boolean - UNSYNCHRONISED; SYNCHRONISED - - States whether the CrowdBox GPS receiver is synchronised to GPS time or not: UNSYCHRONISED = FALSE; SYNCHRONISED = TRUE If more than one GPS receiver is used by the CrowdBox, then SYNCHRONISED should be reported only if all receivers are synchronised. - - - Orientation - R - Single - Optional - Integer - -180..180 - deg - Orientation of CrowdBox with respect to magnetic north. The reference orientation of the CrowdBox shall be the pointing direction of the eNB antenna(s) or, in the case of an omni-directional CrowdBox antenna, as defined in the accompanying product documentation. - - - eNB EARFCN - RW - Single - Mandatory - Integer - 0..65535 - - EARFCN currently used by the eNB. Highest valid value in 3GPP is currently 46589. If the requested EARFCN is not supported by the eNB, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - eNB Bandwidth - RW - Single - Mandatory - Integer - 5, 10, 15, 20 - - Bandwidth of the currently used eNB carrier. If the requested bandwidth is not supported by the eNB, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Primary EARFCN - RW - Single - Mandatory - Integer - 0..65535 - - EARFCN of primary cell used for the backhaul. If the requested EARFCN is not supported by the CrowdBox UE, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Secondary EARFCN - RW - Multiple - Mandatory - Integer - 0..65535 - - EARFCN of any secondary cells used for the backhaul, in the event that carrier aggregation is being used. If the requested EARFCN is not supported by the CrowdBox UE, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Cumulative Measurement Window - RW - Single - Mandatory - Integer - 0..65535 - s - The current measurement interval over which cumulative statistics are collected for the following resources: Cumulative Number of Unique Users, Cumulative Downlink Throughput per Connected User, Cumulative Uplink Throughput per Connected User. Note that this measurement period is a sliding window rather than a granularity period. Measurements should never be reset, but rather old measurements should be removed from the cumulative total as they fall outside of the window. A value of 0 shall be interpreted as meaning only the current value should be reported. A value of 65535 shall be interpreted as an infinite window size (i.e. old measurements are never discarded). - - - eNB ECI - R - Single - Mandatory - Integer - 0..2^28-1 - - A 28 bit E-UTRAN Cell Identifier (ECI) - - - eNB Status - RW - Single - Mandatory - Boolean - - - This resource indicates the current status of the eNB and can be used by the CCC to change the state from enabled to disabled. TRUE = eNB enabled FALSE = eNB disabled - - - Enable eNB - E - Single - Mandatory - - - - Enables the eNB. In addition the CrowdBox shall also update its configuration to reflect the current state of other relevant parameters. This might require a reboot. - - - eNB Maximum Power - RW - Single - Mandatory - Integer - 0..63 - dBm - Maximum power for the eNB measured as the sum of input powers to all antenna connectors. The maximum power per antenna port is equal to the maximum eNB power divided by the number of antenna ports. If the requested power is above or below the maximum or minimum power levels of the eNB, then the power level should be set to the maximum or minimum respectively. The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Primary q-OffsetFreq - RW - Single - Mandatory - Integer - -24..24 - dB - q-OffsetFreq parameter for the backhaul primary EARFCN in SIB5 of the CrowdBox eNB BCCH. See TS 36.331 for details. Range: dB-24; dB-22 .. dB24 The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Secondary q-OffsetFreq - RW - Multiple - Mandatory - Integer - -24..24 - dB - q-OffsetFreq parameter for the backhaul secondary EARFCN in SIB5 of the CrowdBox eNB BCCH. See TS 36.331 for details Range: dB-24; dB-22 .. dB24 The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Neighbour CrowdBox EARFCN - RW - Multiple - Mandatory - Integer - 0..66635 - - EARFCN of a neighbour CrowdBox. Each instance of this resource relates to the same instance of resource ID 15. - - - Neighbour CrowdBox q-OffsetFreq - RW - Multiple - Mandatory - Integer - -24..24 - dB - q-OffsetFreq parameter of the Neighbour CrowdBox EARFCN in SIB5 of the Neighbour CrowdBox eNB BCCH. See TS 36.331 for details Range: dB-24; dB-22 .. dB24 Each instance of this resource relates to the same instance of resource ID 14. The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Serving Macro eNB cellIndividualOffset - RW - Single - Mandatory - Integer - -24..24 - dB - Specifies the value of the cellIndividualOffset parameter applicable to the CrowdBox macro serving cell that is to be signalled to connected UEs in their measurement configuration information . See TS 36.331 for details. The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10246.xml b/common/transport/lwm2m/src/main/resources/models/10246.xml deleted file mode 100644 index b1667af963..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10246.xml +++ /dev/null @@ -1,108 +0,0 @@ - - - - - - - CrowdBox Measurements - This LWM2M Object provides CrowdBox-related measurements such as serving cell parameters, backhaul timing advance, and neighbour cell reports. - 10246 - urn:oma:lwm2m:x:10246 - - - Single - Optional - - - Serving Cell ID - R - Single - Mandatory - Integer - 0..2^32-1 - - Serving cell ID as specified by the cellIdentity field broadcast in SIB1 of the serving cell (see TS 36.331). - - - Serving Cell RSRP - R - Single - Mandatory - Integer - 0..97 - - Serving cell RSRP, as defined in TS 36.133, Section 9.1.4. Range: RSRP_00; RSRP_01 .. RSRP_97 - - - Serving Cell RSRQ - R - Single - Mandatory - Integer - -30..46 - - Serving cell RSRQ, as defined in TS 36.133, Section 9.1.7. Range: RSRQ_-30; RSRQ_-29 .. RSRQ_46 - - - Serving Cell SINR - R - Single - Mandatory - Integer - -10..30 - dB - SINR of serving cell as estimated by the CrowdBox. Note that this is a proprietary measurement dependent on the UE chipset manufacturer. The UE chipset used should be stated in the accompanying product documentation. - - - Cumulative Backhaul Timing Advance - R - Single - Optional - Integer - 0..65535 - - The cumulative timing advance signalled by the current serving cell to the CrowdBox. This is the sum of the initial timing advance signalled in the MAC payload of the Random Access Response (11 bits, 0 .. 1282) and subsequent adjustments signalled in the MAC PDU of DL-SCH transmissions (6 bits, -31 .. 32). See TS 36.321 for details. - - - Neighbour Cell Report - R - Multiple - Mandatory - Objlnk - - - A link to the "Neighbour Cell Report" object for each neighbour cell of the CrowdBox. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10247.xml b/common/transport/lwm2m/src/main/resources/models/10247.xml deleted file mode 100644 index 17f2f51be2..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10247.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - - Neighbour Cell Report - This LWM2M Object provides the neighbour cell report. The CrowdBox Measurements Object and the Connected UE Report Object have both Objlnk Resources pointing to this Object. - 10247 - urn:oma:lwm2m:x:10247 - - - Multiple - Optional - - - Neighbour PCI - R - Single - Mandatory - Integer - 0..503 - - Physical Cell ID of neighbouring LTE cell, as defined in TS 36.211 - - - Neighbour Cell ID - R - Single - Optional - Integer - 0..2^32-1 - - Neighbour cell ID as specified by the cellIdentity field broadcast in SIB1 of the neighbour cell (see TS 36.331). - - - Neighbour Cell Rank - R - Single - Mandatory - Integer - 0..255 - - Current neighbour cell rank. Neighbour cells should be ordered (ranked) by the CrowdBox according to neighbour cell RSRP, with a higher RSRP corresponding to a lower index. Hence the neighbouring cell with the highest RSRP should be neighbour cell 0, the second neighbour cell 1, and so on. - - - Neighbour Cell RSRP - R - Single - Mandatory - Integer - 0..97 - - Neighbour cell RSRP, as defined in TS 36.133, Section 9.1.4. Range: RSRP_00; RSRP_01 .. RSRP_97 - - - Neighbour Cell RSRQ - R - Single - Mandatory - Integer - -30..46 - - Neighbour cell RSRQ, as defined in TS 36.133, Section 9.1.7. Range: RSRQ_-30; RSRQ_-29 .. RSRQ_46 - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10248.xml b/common/transport/lwm2m/src/main/resources/models/10248.xml deleted file mode 100644 index 92f2a0a284..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10248.xml +++ /dev/null @@ -1,78 +0,0 @@ - - - - - - - Connected UE Measurements - This LWM2M Object provides a range of measurements of connected UEs and provides an Object link to the Connected UE report. - 10248 - urn:oma:lwm2m:x:10248 - - - Single - Optional - - - Number of Connected Users - R - Single - Mandatory - Integer - 0..255 - - The number of different UEs currently connected to the eNB (i.e. in RRC_CONNECTED state). - - - Cumulative Number of Unique Users - R - Single - Mandatory - Integer - 0..65535 - - The number of different UEs that have connected to the eNB over the immediately preceding period specified by the "Cumulative Measurement Window" field. - - - Connected UE Report - R - Multiple - Mandatory - Objlnk - - - Provides an Object link to the Connected UE Report which provides a range of information related to the connected UEs. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10249.xml b/common/transport/lwm2m/src/main/resources/models/10249.xml deleted file mode 100644 index ee9e5a9d5a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10249.xml +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - - Connected UE Report - This LWM2M Object provides a range of information related to the connected UEs. - 10249 - urn:oma:lwm2m:x:10249 - - - Multiple - Optional - - - Connected User MMEC - R - Single - Mandatory - Integer - 0..255 - - MMEC signalled by the UE to the eNB in the RRCConnectionRequest message (see TS 36.331). - - - Connected User M-TMSI - R - Single - Mandatory - Integer - 0..2^32-1 - - M-TMSI signalled by the UE to the eNB in the RRCConnectionRequest message (see TS 36.331). - - - Serving Cell (CrowdBox) eNB RSRP - R - Single - Mandatory - Integer - 0..97 - - The RSRP of the CrowdBox eNB, as defined in TS 36.133, Section 9.1.4. Range: RSRP_00; RSRP_01 .. RSRP_97 - - - Serving Cell (CrowdBox) eNB RSRQ - R - Single - Mandatory - Integer - -30..46 - - The RSRQ of the CrowdBox eNB, as defined in TS 36.133, Section 9.1.7. Range: RSRQ_-30; RSRQ_-29 .. RSRQ_46 - - - Cumulative Timing Advance per Connected User - R - Single - Optional - Integer - 0..65535 - - The cumulative timing advance signalled by the eNB to each currently connected UE. This is the sum of the initial timing advance signalled in the MAC payload of the Random Access Response (11 bits, 0 .. 1282) and subsequent adjustments signalled in the MAC PDU of DL-SCH transmissions (6 bits, -31 .. 32). See TS 36.321 for details. - - - Last downlink CQI report per Connected User - R - Single - Mandatory - Integer - 0..255 - - The last downlink wideband CQI reported by a connected user the eNB. The CQI format is defined in Table 7.2.3-1 of TS 36.213. - - - Cumulative Downlink Throughput per Connected User - R - Single - Mandatory - Integer - 0..2^32-1 - B - The total number of MAC bytes sent to the connected user over the immediately preceding period specified by the "Cumulative Measurement Window" field. - - - Cumulative Uplink Throughput per Connected User - R - Single - Mandatory - Integer - 0..2^32-1 - B - The total number of MAC bytes received from the connected user over the immediately preceding period specified by the "Cumulative Measurement Window" field. - - - Neighbour Cell Report - R - Multiple - Mandatory - Objlnk - - - A link to the "Neighbour Cell Report" object for each neighbour cell reported to the CrowdBox by the connected UE - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10250.xml b/common/transport/lwm2m/src/main/resources/models/10250.xml deleted file mode 100644 index a29eda5005..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10250.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - App Data Container - - 10250 - urn:oma:lwm2m:x:10250 - 1.0 - 1.0 - Single - Optional - - - UL data - R - Single - Mandatory - Opaque - - - - - - - - DL data - W - Single - Mandatory - Opaque - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10251.xml b/common/transport/lwm2m/src/main/resources/models/10251.xml deleted file mode 100644 index 3fb1c00154..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10251.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - AT Command - - 10251 - urn:oma:lwm2m:x:10251 - 1.0 - 1.0 - Multiple - Optional - - - Command - RW - Single - Mandatory - String - - - - - - Response - R - Multiple - Mandatory - String - - - - - - Status - R - Multiple - Mandatory - String - - - - - - Timeout - RW - Single - Optional - Integer - - - - - - Run - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10252.xml b/common/transport/lwm2m/src/main/resources/models/10252.xml deleted file mode 100644 index ddaf7cb1f2..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10252.xml +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Manifest - - 10252 - urn:oma:lwm2m:x:10252 - 1.0 - 1.0 - Single - Optional - - - Manifest - W - Single - Mandatory - Opaque - - - - - - - - State - R - Single - Mandatory - Integer - 0..8 - - - - - - Manifest Result - R - Single - Mandatory - Integer - 0..19 - - - - - - Payload Result - R - Single - Mandatory - Opaque - - - - - - - - Asset Hash - R - Single - Mandatory - Opaque - - - - - - - - Manifest version - R - Single - Mandatory - Integer - - - - - - - - Asset Installation Progress - R - Single - Mandatory - Integer - - - - - - - - Campaign Id - RW - Single - Mandatory - String - - - - - - - - Manual Trigger - E - Single - Mandatory - - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10253.xml b/common/transport/lwm2m/src/main/resources/models/10253.xml deleted file mode 100644 index 27da37d16a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10253.xml +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - - Confidential Data - - 10253 - urn:oma:lwm2m:x:10253 - 1.0 - 1.0 - Single - Optional - - - Public Key - RW - Single - Mandatory - Opaque - - - - - - - - Application Data - R - Single - Mandatory - Opaque - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10254.xml b/common/transport/lwm2m/src/main/resources/models/10254.xml deleted file mode 100644 index 706e1470aa..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10254.xml +++ /dev/null @@ -1,119 +0,0 @@ - - - - - Current Loop Input - - 10254 - urn:oma:lwm2m:x:10254:1.0 - 1.0 - 1.0 - Multiple - Optional - - - Current Loop Input Current Value - R - Single - Mandatory - Float - 0; 3.8-20.5 - mA - - - - Min Measured Value - R - Single - Optional - Float - - - - - - Max Measured Value - R - Single - Optional - Float - - - - - - Min Range Value - R - Single - Optional - Float - - - - - - Max Range Value - R - Single - Optional - Float - - - - - - Reset Min and Max Measured Values - E - Single - Optional - - - - - - - Sensor Units - R - Single - Optional - String - - - - - - Application Type - RW - Single - Optional - String - - - - - - Current Calibration - RW - Single - Optional - Float - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10255.xml b/common/transport/lwm2m/src/main/resources/models/10255.xml deleted file mode 100644 index fd63016952..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10255.xml +++ /dev/null @@ -1,165 +0,0 @@ - - - - - Device Metadata - - 10255 - urn:oma:lwm2m:x:10255 - 1.0 - 1.0 - Single - Optional - - - Protocol supported - R - Single - Mandatory - Integer - - - - - - - - Bootloader hash - R - Single - Mandatory - Opaque - - - - - - - - OEM bootloader hash - R - Single - Mandatory - Opaque - - - - - - - - Vendor - R - Single - Mandatory - String - - - - - - - - Class - R - Single - Mandatory - String - - - - - - - - Device - R - Single - Mandatory - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10256.xml b/common/transport/lwm2m/src/main/resources/models/10256.xml deleted file mode 100644 index 77d49f223e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10256.xml +++ /dev/null @@ -1,117 +0,0 @@ - - - - ECID-Signal Measurement Information - - 10256 - urn:oma:lwm2m:x:10256 - 1.0 - 1.0 - Multiple - Optional - - - physCellId - R - Single - Mandatory - Integer - - - - - - - - ECGI - R - Single - Optional - Integer - - - - - - - - arfcnEUTRA - R - Single - Mandatory - Integer - - - - - - - - rsrp-Result - R - Single - Mandatory - Integer - - - - - - - - rsrq-Result - R - Single - Optional - Integer - - - - - - - - ue-RxTxTimeDiff - R - Single - Optional - Integer - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10257.xml b/common/transport/lwm2m/src/main/resources/models/10257.xml deleted file mode 100644 index 64c26f5908..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10257.xml +++ /dev/null @@ -1,275 +0,0 @@ - - - - Heat / Cooling meter - - 10257 - urn:oma:lwm2m:x:10257 - 1.0 - 1.0 - Multiple - Optional - - - Manufacturer - R - Single - Optional - String - - - - - - Model Number - R - Single - Optional - String - - - - - - Serial Number - R - Single - Optional - String - - - - - - Description - R - Single - Optional - String - - - - - - Error code - R - Multiple - Optional - Integer - - - - - - - Instantaneous active power - R - Single - Optional - Float - - W - - - - Max Measured active power - R - Multiple - Mandatory - Float - - W - - - - Cumulative active power - R - Single - Optional - Float - - Wh - - - - Flow temperature - R - Single - Optional - Float - - Cel - - - - Max Measured flow temperature - R - Single - Optional - Float - - Cel - - - - Return temperature - R - Single - Optional - Float - - Cel - - - - Max Measured return temperature - R - Single - Optional - Float - - Cel - - - - Temperature difference - R - Single - Optional - Float - - K - - - - Flow rate - R - Single - Optional - Float - - m3/s - - - - Max Measured flow - R - Single - Optional - Float - - m3/s - - - - Flow volume - R - Single - Optional - Float - - m3 - - - - Return volume - R - Single - Optional - Float - - m3 - - - - Current Time - RW - Single - Optional - Time - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10258.xml b/common/transport/lwm2m/src/main/resources/models/10258.xml deleted file mode 100644 index 3fbf7c7c54..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10258.xml +++ /dev/null @@ -1,89 +0,0 @@ - - - - - Current Loop Output - - 10258 - urn:oma:lwm2m:x:10258 - 1.0 - 1.0 - Multiple - Optional - - - Current Loop Output Current Value - RW - Single - Mandatory - Float - 3.8-20.5 - mA - - - - Min Range Value - R - Single - Optional - Float - - - - - - Max Range Value - R - Single - Optional - Float - - - - - - Sensor Units - R - Single - Optional - String - - - - - - Application Type - RW - Single - Optional - String - - - - - - Current Calibration - RW - Single - Optional - Float - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10259.xml b/common/transport/lwm2m/src/main/resources/models/10259.xml deleted file mode 100644 index d75869a122..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10259.xml +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - - System Log - - 10259 - urn:oma:lwm2m:x:10259 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - Read All - R - Single - Mandatory - String - - - - - - - - Read - R - Single - Optional - String - - - - - - - - Enabled - RW - Single - Optional - Boolean - - - - - - - - Capture Level - RW - Single - Optional - Integer - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10260-2_0.xml b/common/transport/lwm2m/src/main/resources/models/10260-2_0.xml deleted file mode 100644 index 5cd084af73..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10260-2_0.xml +++ /dev/null @@ -1,95 +0,0 @@ - - - - - - RDB - - 10260 - urn:oma:lwm2m:x:10260:2.0 - 1.0 - 2.0 - Multiple - Optional - - - Key - RW - Single - Mandatory - String - - - - - - - - Value - RW - Single - Optional - String - - - - - - - - Exists - RW - Single - Optional - Boolean - - - - - - - - Persistent - RW - Single - Optional - Boolean - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10262.xml b/common/transport/lwm2m/src/main/resources/models/10262.xml deleted file mode 100644 index 7b2e170c9b..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10262.xml +++ /dev/null @@ -1,87 +0,0 @@ - - - - - - - Interval Data Delivery - - 10262 - urn:oma:lwm2m:x:10262 - Multiple - Optional - - - Name - RW - Single - Mandatory - String - - - - - - Interval Data Links - RW - Multiple - Mandatory - Objlnk - - - - - - Latest Payload - R - Multiple - Mandatory - Opaque - - - - - - Schedule - RW - Single - Optional - Objlnk - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10263.xml b/common/transport/lwm2m/src/main/resources/models/10263.xml deleted file mode 100644 index 5e18f44244..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10263.xml +++ /dev/null @@ -1,90 +0,0 @@ - - - - - - - Event Data Delivery - - 10263 - urn:oma:lwm2m:x:10263 - Multiple - Optional - - - Name - RW - Single - Mandatory - String - - - - - - Event Data Links - RW - Multiple - Mandatory - Objlnk - - - - - - Latest Eventlog - R - Multiple - Mandatory - Opaque - - - - - - Schedule - RW - Single - Mandatory - Objlnk - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10264.xml b/common/transport/lwm2m/src/main/resources/models/10264.xml deleted file mode 100644 index eeaad07447..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10264.xml +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - Delivery Schedule - - 10264 - urn:oma:lwm2m:x:10264 - Multiple - Optional - - - Schedule Start Time - RW - Single - Mandatory - Integer - - - - - - Schedule UTC Offset - RW - Single - Mandatory - String - - - - - - Delivery Frequency - RW - Single - Mandatory - Integer - - - - - - Randomised Delivery Window - RW - Single - Optional - Integer - - - - - - Number of Retries - RW - Single - Optional - Integer - - - - - - Retry Period - RW - Single - Optional - Integer - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10265.xml b/common/transport/lwm2m/src/main/resources/models/10265.xml deleted file mode 100644 index 26657bb754..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10265.xml +++ /dev/null @@ -1,136 +0,0 @@ - - - - - - - Leakage Detection Configuration - - 10265 - urn:oma:lwm2m:x:10265 - Single - Optional - - - Sample Times - RW - Multiple - Mandatory - Integer - - - - - - Sample UTC Offset - RW - Single - Optional - String - - - - - - Detection Mode - RW - Single - Mandatory - Integer - 0..3 - - - - - Top Frequency Count - RW - Single - Optional - Integer - - - - - - Frequency Thresholds - RW - Multiple - Optional - Integer - 0..999 - - - - - Frequency Values - R - Multiple - Optional - Integer - - - - - - Firmware Version - R - Single - Mandatory - String - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10266.xml b/common/transport/lwm2m/src/main/resources/models/10266.xml deleted file mode 100644 index 57f7285b84..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10266.xml +++ /dev/null @@ -1,244 +0,0 @@ - - - - - - - Water Flow Readings - - 10266 - urn:oma:lwm2m:x:10266 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10267.xml b/common/transport/lwm2m/src/main/resources/models/10267.xml deleted file mode 100644 index 3c6734723f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10267.xml +++ /dev/null @@ -1,244 +0,0 @@ - - - - - - - Daily Maximum Flow Rate Readings - - 10267 - urn:oma:lwm2m:x:10267 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10268.xml b/common/transport/lwm2m/src/main/resources/models/10268.xml deleted file mode 100644 index 9a6d06262e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10268.xml +++ /dev/null @@ -1,244 +0,0 @@ - - - - - - - Temperature Readings - - 10268 - urn:oma:lwm2m:x:10268 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10269.xml b/common/transport/lwm2m/src/main/resources/models/10269.xml deleted file mode 100644 index 648227a7d7..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10269.xml +++ /dev/null @@ -1,244 +0,0 @@ - - - - - - - Pressure Readings - - 10269 - urn:oma:lwm2m:x:10269 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10270.xml b/common/transport/lwm2m/src/main/resources/models/10270.xml deleted file mode 100644 index 69e3e7e5f3..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10270.xml +++ /dev/null @@ -1,244 +0,0 @@ - - - - - - - Battery Level Readings - - 10270 - urn:oma:lwm2m:x:10270 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10271.xml b/common/transport/lwm2m/src/main/resources/models/10271.xml deleted file mode 100644 index f33a3d27e6..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10271.xml +++ /dev/null @@ -1,244 +0,0 @@ - - - - - - - Communications Activity Time Readings - - 10271 - urn:oma:lwm2m:x:10271 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10272.xml b/common/transport/lwm2m/src/main/resources/models/10272.xml deleted file mode 100644 index d70236947b..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10272.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Water Meter Customer Leakage Alarm - - 10272 - urn:oma:lwm2m:x:10272 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10273.xml b/common/transport/lwm2m/src/main/resources/models/10273.xml deleted file mode 100644 index 55404b38d5..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10273.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Water Meter Reverse Flow Alarm - - 10273 - urn:oma:lwm2m:x:10273 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10274.xml b/common/transport/lwm2m/src/main/resources/models/10274.xml deleted file mode 100644 index e0f9de62dc..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10274.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Water Meter Empty Pipe Alarm - - 10274 - urn:oma:lwm2m:x:10274 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10275.xml b/common/transport/lwm2m/src/main/resources/models/10275.xml deleted file mode 100644 index d0bc4dd350..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10275.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Water Meter Tamper Alarm - - 10275 - urn:oma:lwm2m:x:10275 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10276.xml b/common/transport/lwm2m/src/main/resources/models/10276.xml deleted file mode 100644 index 24f0e0056a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10276.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Water Meter High Pressure Alarm - - 10276 - urn:oma:lwm2m:x:10276 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10277.xml b/common/transport/lwm2m/src/main/resources/models/10277.xml deleted file mode 100644 index 07e431b9da..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10277.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Water Meter Low Pressure Alarm - - 10277 - urn:oma:lwm2m:x:10277 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10278.xml b/common/transport/lwm2m/src/main/resources/models/10278.xml deleted file mode 100644 index 9070e1c70e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10278.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - High Temperature Alarm - - 10278 - urn:oma:lwm2m:x:10278 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10279.xml b/common/transport/lwm2m/src/main/resources/models/10279.xml deleted file mode 100644 index 6eef195800..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10279.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Low Temperature Alarm - - 10279 - urn:oma:lwm2m:x:10279 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10280.xml b/common/transport/lwm2m/src/main/resources/models/10280.xml deleted file mode 100644 index 0fe4976077..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10280.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Water Network Leak Alarm - - 10280 - urn:oma:lwm2m:x:10280 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10281.xml b/common/transport/lwm2m/src/main/resources/models/10281.xml deleted file mode 100644 index a02a83e348..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10281.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Low Battery Alarm - - 10281 - urn:oma:lwm2m:x:10281 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10282.xml b/common/transport/lwm2m/src/main/resources/models/10282.xml deleted file mode 100644 index d7c97729b8..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10282.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Daughter Board Failure Alarm - - 10282 - urn:oma:lwm2m:x:10282 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10283.xml b/common/transport/lwm2m/src/main/resources/models/10283.xml deleted file mode 100644 index 6e4df48342..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10283.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Device Reboot Event - - 10283 - urn:oma:lwm2m:x:10283 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10284.xml b/common/transport/lwm2m/src/main/resources/models/10284.xml deleted file mode 100644 index 964df21df9..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10284.xml +++ /dev/null @@ -1,230 +0,0 @@ - - - - - - - Time Synchronisation Event - - 10284 - urn:oma:lwm2m:x:10284 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10286.xml b/common/transport/lwm2m/src/main/resources/models/10286.xml deleted file mode 100644 index 39e0809788..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10286.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - App Fota Container - - 10286 - urn:oma:lwm2m:x:10286 - 1.0 - 1.0 - Single - Optional - - - UL data - R - Single - Mandatory - Opaque - - - - - - - - DL data - W - Single - Mandatory - Opaque - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10290.xml b/common/transport/lwm2m/src/main/resources/models/10290.xml deleted file mode 100644 index 7b89cc06c0..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10290.xml +++ /dev/null @@ -1,198 +0,0 @@ - - - - - - - Voltage Logging - - 10290 - urn:oma:lwm2m:x:10290 - 1.0 - 1.0 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10291.xml b/common/transport/lwm2m/src/main/resources/models/10291.xml deleted file mode 100644 index a232ed02f9..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10291.xml +++ /dev/null @@ -1,208 +0,0 @@ - - - - - - - Voltage Transient - - 10291 - urn:oma:lwm2m:x:10291 - 1.0 - 1.0 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Mandatory - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Mandatory - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - Sample Frequency - RW - Single - Mandatory - Float - 0.0..86400.0 - s - How often the inputs are read/sampled.This value can be changed by doing a write command - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10292.xml b/common/transport/lwm2m/src/main/resources/models/10292.xml deleted file mode 100644 index 00fe33e320..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10292.xml +++ /dev/null @@ -1,208 +0,0 @@ - - - - - - - Pressure Transient - - 10292 - urn:oma:lwm2m:x:10292 - 1.0 - 1.0 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Mandatory - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Mandatory - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - Sample Frequency - RW - Single - Mandatory - Float - 0.0..86400.0 - s - How often the inputs are read/sampled.This value can be changed by doing a write command - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10299.xml b/common/transport/lwm2m/src/main/resources/models/10299.xml deleted file mode 100644 index 2c4ea4d2db..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10299.xml +++ /dev/null @@ -1,113 +0,0 @@ - - - - - - - HostDevice - This LWM2M Object provides a range of host device related information which can be queried by the LWM2M Server. The host device is any integrated device with an embedded cellular radio module. - 10299 - urn:oma:lwm2m:x:10299 - 1.0 - 1.0 - Single - Optional - - - Manufacturer - R - Single - Mandatory - String - - - Host device manufacturers name (OEM). - - - Model - R - Single - Mandatory - String - - Identifier of the model name or number determined by device manufacturer. - UniqueID - R - Single - Mandatory - String - - - Unique ID assigned by an manufacturer or other body. Used to uniquely identify a host device. Examples include serial # or UUID. - - - FirmwareVersion - R - Single - Mandatory - String - - - Current Firmware version of the host device. (manufacturer specified string). - - SoftwareVersion - R - Single - Optional - String - - - Current software version of the host device. (manufacturer specified string). - - HardwareVersion - R - Single - Optional - String - - - Current hardware version of the host device. (manufacturer specified string). - - - DateStamp - R - Single - Optional - String - - - UTC value of the time and date of the last Firmware or Software update. Format:MM:DD:YYYY HH:MM:SS - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10300.xml b/common/transport/lwm2m/src/main/resources/models/10300.xml deleted file mode 100644 index b290057806..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10300.xml +++ /dev/null @@ -1,142 +0,0 @@ - - - - - - - LWM2M Meta Object - - - - 10300 - urn:oma:lwm2m:x:10300 - 1.0 - 1.0 - Multiple - Optional - - - ObjectID - R - Single - Mandatory - Integer - - - - - - - - ObjectURN - R - Single - Mandatory - String - - - - - - - - ObjectInstanceHandle - R - Single - Optional - Objlnk - - - - - - - - URI - R - Multiple - Mandatory - String - - - - - - - - SHAType - R - Single - Optional - Integer - 0..8 - - - - - - - ChecksumValue - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10308-2_0.xml b/common/transport/lwm2m/src/main/resources/models/10308-2_0.xml deleted file mode 100644 index 0ed1a6ea30..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10308-2_0.xml +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - - AT&T Connectivity Extension - - 10308 - urn:oma:lwm2m:x:10308:2.0 - 1.0 - 2.0 - Multiple - Optional - - - ICCID - R - Single - Mandatory - String - - - - - - - IMSI - R - Single - Mandatory - String - - - - - - - MSISDN - RW - Single - Mandatory - String - - - - - - - APN Retries - RW - Single - Mandatory - Integer - - - - - - - APN Retry Period - RW - Single - Mandatory - Integer - - - s - - - - APN Retry Back-Off Period - RW - Single - Mandatory - Integer - - - s - - - - SINR - R - Single - Mandatory - Integer - <7 to >12.5 - - - - - SRXLEV - R - Single - Mandatory - Integer - - - - - - - CE_LEVEL - R - Single - Mandatory - Integer - 0,1,2 - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10309.xml b/common/transport/lwm2m/src/main/resources/models/10309.xml deleted file mode 100644 index 333580200e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10309.xml +++ /dev/null @@ -1,115 +0,0 @@ - - - - - Shareparkinglot - - 10309 - urn:oma:lwm2m:x:10309 - 1.0 - 1.0 - Multiple - Optional - - - LockID - R - Single - Mandatory - Integer - - - - - - LockType - R - Single - Optional - String - - - - - - LightSwitchState - R - Multiple - Optional - Boolean - - - - - - RSSI - R - Multiple - Mandatory - Integer - -30..-120 - dBm - - - - BatteryCapacity - R - Multiple - Optional - Float - 0..100 - %EL - - - - DataUpTime - R - Multiple - Mandatory - Time - - - - - - Latitude - R - Multiple - Optional - String - - - - - - Longitude - R - Multiple - Optional - String - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10311.xml b/common/transport/lwm2m/src/main/resources/models/10311.xml deleted file mode 100644 index e622197164..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10311.xml +++ /dev/null @@ -1,164 +0,0 @@ - - - - - - - Solar Radiation - - This object is used to report solar irradiance (SI), i.e. power per unit area received from the Sun in the form of electromagnetic radiation, on a planar surface measured by a pyranometer or similar instrument. A pyranometer measures solar irradiance from the hemisphere above within a wavelength range 0.3 μm to 3 μm. For example, the application of solar radiation measurement can be meteorological networks and solar energy applications. - - 10311 - urn:oma:lwm2m:x:10311 - 1.0 - 1.0 - Multiple - Optional - - - Min Measured Value - R - Single - Optional - Float - - - - The minimum value measured by the sensor since it is ON or Reset, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Max Measured Value - R - Single - Optional - Float - - - - The maximum value measured by the sensor since it is ON or Reset, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Min Range Value - R - Single - Optional - Float - - - - The minimum value that can be measured by the sensor, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Max Range Value - R - Single - Optional - Float - - - - The maximum value that can be measured by the sensor, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Reset Min and Max Measured Values - E - Single - Optional - - - - - Reset the Min and Max Measured Values to current value. - - - - Timestamp - R - Single - Optional - Time - - - The timestamp of when the measurement was performed. - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor expressed in the unit defined by the "Sensor Units" resource if present. - - - Sensor Units - R - Single - Optional - String - - - - Measurement Units Definition. - - - - Application Type - RW - Single - Optional - String - - - - The application type of the sensor or actuator as a string, for instance "Air Pressure". - - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10313.xml b/common/transport/lwm2m/src/main/resources/models/10313.xml deleted file mode 100644 index 4875e5d6b0..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10313.xml +++ /dev/null @@ -1,253 +0,0 @@ - - - - - - - Gas Readings - - 10313 - urn:oma:lwm2m:x:103131.0 - 1.0Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - Sensor Warm-up Time - RW - Single - Optional - Integer - 0..86400 - s - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10314.xml b/common/transport/lwm2m/src/main/resources/models/10314.xml deleted file mode 100644 index 69f344ea34..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10314.xml +++ /dev/null @@ -1,106 +0,0 @@ - - - - - - - Particulates - - 10314 - urn:oma:lwm2m:x:10314 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - - - - Min Measured Value - R - Single - Optional - Float - - - - - - Max Measured Value - R - Single - Optional - Float - - - - - - Max Range Value - R - Single - Optional - Float - - - - - - Sensor Units - R - Single - Optional - String - - - - - - Application Type - RW - Single - Optional - String - - - The Application type of the device, for example “Particulate Sensor”. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - - - - Measured Particle Size - R - Single - Mandatory - Float - - m - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10315.xml b/common/transport/lwm2m/src/main/resources/models/10315.xml deleted file mode 100644 index fcca456342..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10315.xml +++ /dev/null @@ -1,129 +0,0 @@ - - - - - - Robot - - 10315 - urn:oma:lwm2m:x:10315 - 1.0 - 1.0 - Single - Mandatory - - - Robot ID - R - Single - Mandatory - String - 0..255 - - - - - Robot Type - R - Single - Mandatory - String - 0..63 - - - - - Robot Serial Number - R - Single - Mandatory - String - 0..63 - - - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - % - - - - Charging - R - Single - Mandatory - Boolean - - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - Positioning - R - Single - Optional - Boolean - - - - - - Location - R - Single - Optional - Objlnk - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10316.xml b/common/transport/lwm2m/src/main/resources/models/10316.xml deleted file mode 100644 index 011055fde3..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10316.xml +++ /dev/null @@ -1,233 +0,0 @@ - - - - - - RCU - - 10316 - urn:oma:lwm2m:x:10316 - 1.0 - 1.0 - Single - Mandatory - - - RCU ID - R - Single - Mandatory - String - 0..127 - - - - - RCU Serial Number - R - Single - Mandatory - String - 0..63 - - - - - RCU Software Version - R - Single - Mandatory - String - 0..63 - - - - - RCU OS Version - R - Single - Mandatory - String - 0..127 - - - - - RCU CPU Info - R - Single - Mandatory - String - 64 - - - - - RCU RAM Info - R - Single - Mandatory - String - 64 - - - - - RCU ROM Size - R - Single - Mandatory - Integer - - GB - - - - RCU ROM Available Size - R - Single - Mandatory - Integer - - GB - - - - SD Storage - R - Single - Mandatory - Integer - - GB - - - - SD Available Storage - R - Single - Mandatory - Integer - - GB - - - - RCU GPS Location - R - Single - Optional - Objlnk - - - - - - Wi-Fi MAC - R - Single - Optional - String - 12 - - - - - Bluetooth MAC - R - Single - Optional - String - 12 - - - - - Camera Info - R - Single - Optional - String - 64 - - - - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - /100 - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - - Downloaded APP Packages - R - Multiple - Mandatory - String - - - - - - - RCU APPs - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10318.xml b/common/transport/lwm2m/src/main/resources/models/10318.xml deleted file mode 100644 index 989db0de7e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10318.xml +++ /dev/null @@ -1,189 +0,0 @@ - - - - - - RCU PM - - 10318 - urn:oma:lwm2m:x:10318 - 1.0 - 1.0 - Single - Mandatory - - - CPU Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Max CPU Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Memory Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Storage Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Network Bandwidth - R - Single - Mandatory - Float - - Mbit/s - - - - Mobile Signal - R - Single - Mandatory - Integer - - - - - - GPS Signal - R - Single - Optional - Integer - - - - - - Wi-Fi Signal - R - Single - Mandatory - Integer - - - - - - UpLink Rate - R - Single - Mandatory - Float - - Mbit/s - - - - DownLink Rate - R - Single - Mandatory - Float - - Mbit/s - - - - Packet Loss Rate - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Network Latency - R - Single - Mandatory - Integer - - ms - - - - - Battery Temperature - R - Single - Mandatory - Float - - Cel - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10319.xml b/common/transport/lwm2m/src/main/resources/models/10319.xml deleted file mode 100644 index b8ebcef6fb..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10319.xml +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - RCU Control - - 10319 - urn:oma:lwm2m:x:10319 - 1.0 - 1.0 - Single - Mandatory - - - RCU Diagnostics Mode - R - Single - Optional - Boolean - - - - - - RCU Log Recording - R - Single - Optional - Boolean - - - - - - - RCU Shutdown - E - Single - Mandatory - - - - - - - RCU Restart - E - Single - Mandatory - - - - - - - RCU Deactivate - E - Single - Mandatory - - - - - - - RCU Reset - E - Single - Mandatory - - - - - - - RCU Diagnostics Mode Control - E - Single - Mandatory - - - - - - - RCU Log Recording Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10320.xml b/common/transport/lwm2m/src/main/resources/models/10320.xml deleted file mode 100644 index 2b46d7c920..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10320.xml +++ /dev/null @@ -1,141 +0,0 @@ - - - - - - CCU - - 10320 - urn:oma:lwm2m:x:10320 - 1.0 - 1.0 - Multiple - Optional - - - CCU ID - R - Single - Mandatory - String - - - - - - CCU FM Version - R - Single - Mandatory - String - - - - - - CCU SW Version - R - Single - Mandatory - String - - - - - - CCU Memory Size - R - Single - Mandatory - Integer - - GB - - - - CCU Storage - R - Single - Mandatory - Integer - - GB - - - - CCU Available Storage - R - Single - Mandatory - Integer - - GB - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - - Downloaded APP Packages - R - Multiple - Optional - String - - - - - - CCU APPs - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10322.xml b/common/transport/lwm2m/src/main/resources/models/10322.xml deleted file mode 100644 index 98822e0efe..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10322.xml +++ /dev/null @@ -1,87 +0,0 @@ - - - - - - CCU PM - - 10322 - urn:oma:lwm2m:x:10322 - 1.0 - 1.0 - Multiple - Optional - - - CPU Usage - R - Single - Optional - Integer - 0..100 - % - - - - Max CPU Usage - R - Single - Optional - Integer - 0..100 - % - - - - Memory Usage - R - Single - Optional - Integer - 0..100 - % - - - - Storage Usage - R - Single - Optional - Integer - 0..100 - % - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10323.xml b/common/transport/lwm2m/src/main/resources/models/10323.xml deleted file mode 100644 index dcbdaeb91d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10323.xml +++ /dev/null @@ -1,90 +0,0 @@ - - - - - - CCU Control - - 10323 - urn:oma:lwm2m:x:10323 - 1.0 - 1.0 - Multiple - Optional - - - - CCU Restart - E - Single - Mandatory - - - - - - - CCU Reset - E - Single - Mandatory - - - - - - - CCU Self-checking - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10324.xml b/common/transport/lwm2m/src/main/resources/models/10324.xml deleted file mode 100644 index e78bb099de..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10324.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - - - ECU - - 10324 - urn:oma:lwm2m:x:10324 - 1.0 - 1.0 - Multiple - Optional - - - ECU ID - R - Single - Mandatory - String - - - - - - ECU FM Version - R - Single - Mandatory - String - - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10326.xml b/common/transport/lwm2m/src/main/resources/models/10326.xml deleted file mode 100644 index 353e549829..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10326.xml +++ /dev/null @@ -1,722 +0,0 @@ - - - - - - Robot PM - - 10326 - urn:oma:lwm2m:x:10326 - 1.0 - 1.0 - Single - Mandatory - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - /100 - - - - - Battery Temperature - R - Single - Mandatory - Integer - - Cel - - - - Temperature - R - Single - Optional - Float - - Cel - - - - Humidity - R - Single - Optional - Integer - 0..100 - /100 - - - - PM2.5 - R - Single - Optional - Integer - - ug/m3 - - - - Smog - R - Single - Optional - Float - - ug/m3 - - - - CO - R - Single - Optional - Float - - ppm - - - - CO2 - R - Single - Optional - Float - - ppm - - - - PM10 - R - Single - Optional - Integer - - ug/m3 - - - - Speed - R - Single - Optional - Float - - m/h - - - - Water Used - R - Single - Optional - Integer - 0..100 - /100 - - - - Dust Box Used - R - Single - Optional - Integer - 0..100 - /100 - - - - Obstacle Distance - R - Single - Optional - Integer - - cm - - - - - Robot Temperate - R - Single - Optional - Float - - Cel - - - - Confidence Index - R - Single - Optional - Integer - 0..100 - /100 - - - - - Data Traffic Used - R - Single - Mandatory - Float - - Mbit/s - - - - Images Handled - R - Single - Optional - Integer - - - - - - HARI S-Voice Requests - R - Single - Optional - Integer - - - - - - HARI S-Vision Requests - R - Single - Optional - Integer - - - - - - HARI S-Motion Requests - R - Single - Optional - Integer - - - - - - HARI S-Map Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Voice Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Vision Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Motion Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Map Requests - R - Single - Optional - Integer - - - - - - Questions Answered - R - Single - Optional - Integer - - - - - - Unknown Questions - R - Single - Optional - Integer - - - - - - Mileage - R - Single - Optional - Integer - - m - - - - Cleaned Times - R - Single - Optional - Integer - - - - - - Cleaned Area - R - Single - Optional - Float - - m2 - - - - Cleaned Time - R - Single - Optional - Integer - - s - - - - ASR Recognized - R - Single - Optional - Integer - - B - - - - Incorrect ASR Recognitions - R - Single - Optional - Integer - - B - - - - Tried TTS Texts - R - Single - Optional - Integer - - B - - - - Successful TTS Texts - R - Single - Optional - Integer - - B - - - - ASR Recognized (CH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (CH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (CH) - R - Single - Optional - Integer - - B - - - - ASR Recognized (EN) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (EN) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (EN) - R - Single - Optional - Integer - - B - - - - ASR Recognized (ES) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (ES) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (ES) - R - Single - Optional - Integer - - B - - - - ASR Recognized (JA) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (JA) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (JA) - R - Single - Optional - Integer - - B - - - - ASR Recognized (SCCH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (SCCH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (SCCH) - R - Single - Optional - Integer - - B - - - - ASR Recognized (GDCH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (GDCH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (GDCH) - R - Single - Optional - Integer - - B - - - - ASR Recognized (TCH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (TCH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (TCH) - R - Single - Optional - Integer - - B - - - - - Objects Recognition Tries - R - Single - Optional - Integer - - - - - - Successful Object Recognition - R - Single - Optional - Integer - - - - - - Face Recognition Tries - R - Single - Optional - Integer - - - - - - Successful Face Recognitions - R - Single - Optional - Integer - - - - - - Vehicle Plate Recognition Tries - R - Single - Optional - Integer - - - - - - Successful Vehicle Plate Recognitions - R - Single - Optional - Integer - - - - - - Tasks Assigned - R - Single - Mandatory - Integer - - - - - - Successful Tasks Executed - R - Single - Mandatory - Integer - - - - - - Images Uploaded - R - Single - Optional - Integer - - - - - - Videos Uploaded - R - Single - Optional - Integer - - - - - - Images Matted - R - Single - Optional - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10327.xml b/common/transport/lwm2m/src/main/resources/models/10327.xml deleted file mode 100644 index 5f0e232a22..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10327.xml +++ /dev/null @@ -1,68 +0,0 @@ - - - - - - Compressor - - 10327 - urn:oma:lwm2m:x:10327 - 1.0 - 1.0 - Multiple - Optional - - - Compressor Name - R - Single - Mandatory - String - - - - - - - Compressor Status - R - Single - Mandatory - Boolean - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10328.xml b/common/transport/lwm2m/src/main/resources/models/10328.xml deleted file mode 100644 index fdf39d5dc1..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10328.xml +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - SCA PM - - 10328 - urn:oma:lwm2m:x:10328 - 1.0 - 1.0 - Multiple - Optional - - - SCA Name - R - Single - Mandatory - String - - - - - - - - - SCA Current - R - Single - Mandatory - Float - - A - - - - SCA Temperate - R - Single - Mandatory - Float - - Cel - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10329.xml b/common/transport/lwm2m/src/main/resources/models/10329.xml deleted file mode 100644 index 7470bec6e1..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10329.xml +++ /dev/null @@ -1,433 +0,0 @@ - - - - - - Robot Control - - 10329 - urn:oma:lwm2m:x:10329 - 1.0 - 1.0 - Single - Mandatory - - - Collision Detection - R - Single - Optional - Boolean - - - - - - Drop Detection - R - Single - Optional - Boolean - - - - - - Automatic Navigation - R - Single - Optional - Boolean - - - - - - Robot Shutdown - E - Single - Mandatory - - - - - - - Robot Reboot - E - Single - Mandatory - - - - - - - Robot Reset - E - Single - Mandatory - - - - - - - Robot Wakeup - E - Single - Mandatory - - - - - - - Robot Sleep - E - Single - Mandatory - - - - - - - Robot Self-checking - E - Single - Mandatory - - - - - - - Emergency Braking - E - Single - Mandatory - - - - - - - Emergency Braking Release - E - Single - Mandatory - - - - - - - Action Execution - E - Single - Optional - - - - - - - Action List Upload - E - Single - Optional - - - - - - - Action List Download - E - Single - Optional - - - - - - - Group Dancing Program Control - E - Single - Optional - - - - - - - Navigation Map Upload - E - Single - Optional - - - - - - - Group Dancing Program Control - E - Single - Optional - - - - - - - Navigation Map Download - E - Single - Optional - - - - - - - Route list Execution - E - Single - Optional - - - - - - - Route list Upload - E - Single - Optional - - - - - - - Route list Download - E - Single - Optional - - - - - - - Automatic Navigation Control - E - Single - Optional - - - - - - - Manual Navigation - E - Single - Optional - - - - - - - Moving to Charging Station - E - Single - Optional - - - - - - - Moving to Specified location - E - Single - Optional - - - - - - - Low Frequency Patrol Broadcasting - E - Single - Optional - - - - - - - Task Start - E - Single - Optional - - - - - - - Task Stop - E - Single - Optional - - - - - - - Task Suspend - E - Single - Optional - - - - - - - Task Resume - E - Single - Optional - - - - - - - Video Upload - E - Single - Optional - - - - - - - Picture Upload - E - Single - Optional - - - - - - - Default Language Switching - E - Single - Optional - - - - - - - Intonation Change - E - Single - Optional - - - - - - - Intonation Change - E - Single - Optional - - - - - - - Speaking with Action - E - Single - Optional - - - - - - - Collision Detection Control - E - Single - Mandatory - - - - - - - Drop Detection Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10330.xml b/common/transport/lwm2m/src/main/resources/models/10330.xml deleted file mode 100644 index 75c5a2ecdd..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10330.xml +++ /dev/null @@ -1,120 +0,0 @@ - - - - - - Network Info - - 10330 - urn:oma:lwm2m:x:10330 - 1.0 - 1.0 - Single - Mandatory - - - IMEI - R - Single - Mandatory - String - 15 - - - - - IMSI - R - Single - Mandatory - String - 15 - - - - - Radio Connectivity - R - Single - Mandatory - Objlnk - - - - - - - - GPS Signal Status - R - Single - Optional - Integer - 1..4 - - - - - VBN Connection Status - R - Single - Mandatory - Integer - 0..1 - - - - - HARI Connection Status - R - Single - Mandatory - Integer - 0..1 - - - - - CCU Connection Status - R - Multiple - Optional - Integer - 0..1 - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10331.xml b/common/transport/lwm2m/src/main/resources/models/10331.xml deleted file mode 100644 index ca555cc0d9..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10331.xml +++ /dev/null @@ -1,221 +0,0 @@ - - - - - - Robot Service Info - - 10331 - urn:oma:lwm2m:x:10331 - 1.0 - 1.0 - Single - Mandatory - - - Current status - R - Single - Mandatory - String - 0..127 - - - - - Services Providing - R - Single - Optional - String - 0..127 - - - - - Advertising Contents - R - Single - Mandatory - String - - - - - - Current Language - R - Single - Optional - String - 0..127 - - - - - Volume - R - Single - Optional - String - 0..100 - /100 - - - - Moving Status - R - Single - Optional - Integer - 0..2 - - - - - Moving Speed - R - Single - Optional - Float - - m/h - - - - Location - R - Single - Optional - Objlnk - - - - - - - - Map List - R - Single - Optional - String - - - - - - Planned Route list - R - Single - Optional - String - - - - - - Current Route - R - Single - Optional - String - - - - - - Route to-do List - R - Single - Optional - String - - - - - - Synchronous Whistle - R - Single - Mandatory - Boolean - - - - - - Current Actions - R - Single - Optional - String - - - - - - ASR Type - R - Single - Optional - Integer - 0..2 - - - - - - TTS Vendor - R - Single - Optional - String - - - - - - TTS Speaker - R - Single - Optional - String - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10332.xml b/common/transport/lwm2m/src/main/resources/models/10332.xml deleted file mode 100644 index 6bda413092..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10332.xml +++ /dev/null @@ -1,69 +0,0 @@ - - - - - - Robot Selfcheck Info - - 10332 - urn:oma:lwm2m:x:10332 - 1.0 - 1.0 - Multiple - Optional - - - Entity - R - Single - Mandatory - String - 4..63 - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10333.xml b/common/transport/lwm2m/src/main/resources/models/10333.xml deleted file mode 100644 index 3a1f1f6dfa..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10333.xml +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - PM Threshold - - 10333 - urn:oma:lwm2m:x:10333 - 1.0 - 1.0 - Single - Optional - - - Entity - RW - Multiple - Mandatory - String - 4..63 - - - - - Performance Type - RW - Multiple - Mandatory - String - - - - - - High Threshold - RW - Multiple - Mandatory - Float - - - - - - Low Threshold - RW - Multiple - Mandatory - Float - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10334.xml b/common/transport/lwm2m/src/main/resources/models/10334.xml deleted file mode 100644 index 547fb7a0d5..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10334.xml +++ /dev/null @@ -1,129 +0,0 @@ - - - - - - Robot Alarm - - 10334 - urn:oma:lwm2m:x:10334 - 1.0 - 1.0 - Multiple - Optional - - - Entity - R - Single - Mandatory - String - 4..63 - - - - - Probable Cause - R - Single - Mandatory - Integer - 0..65535 - - - - - Specific Problem - R - Single - Mandatory - String - - - - - - Alarm Type - R - Single - Mandatory - Integer - 2..6 - - - - - Severity - R - Single - Mandatory - Integer - 1..5 - - - - - Report Time - R - Single - Mandatory - Time - - - - - - Sequence No - R - Single - Mandatory - Integer - 0..2^63-1 - - - - - Additional Info - R - Single - Optional - String - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10335.xml b/common/transport/lwm2m/src/main/resources/models/10335.xml deleted file mode 100644 index 49640154e8..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10335.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - - - - Event - - 10335 - urn:oma:lwm2m:x:10335 - 1.0 - 1.0 - Multiple - Optional - - - Entity - R - Single - Mandatory - String - 4..63 - - - - - Event Type - R - Single - Mandatory - Integer - 0..65535 - - - - - Time - R - Single - Mandatory - Time - - - - - - Sequence No - R - Single - Mandatory - Integer - 0..2^63-1 - - - - - Additional Info - R - Single - Optional - String - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10336.xml b/common/transport/lwm2m/src/main/resources/models/10336.xml deleted file mode 100644 index 74fae1916a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10336.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - - MIC - - 10336 - urn:oma:lwm2m:x:10336 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10337.xml b/common/transport/lwm2m/src/main/resources/models/10337.xml deleted file mode 100644 index 3220c8e3e0..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10337.xml +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - SCA - - 10337 - urn:oma:lwm2m:x:10337 - 1.0 - 1.0 - Multiple - Optional - - - SCA Name - R - Single - Mandatory - String - - - - - - - - - - SCA Motion Status - R - Single - Optional - Integer - 0..2 - - - - - - SCA Motion Control - E - Single - Optional - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10338.xml b/common/transport/lwm2m/src/main/resources/models/10338.xml deleted file mode 100644 index 48213fe176..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10338.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - Speaker - - 10338 - urn:oma:lwm2m:x:10338 - 1.0 - 1.0 - Single - Optional - - - Speaker status - R - Single - Mandatory - Boolean - - - - - - Voice Warning - R - Single - Mandatory - Boolean - - - - - - - Voice Control - E - Single - Mandatory - - - - - - - Voice Warning Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10339.xml b/common/transport/lwm2m/src/main/resources/models/10339.xml deleted file mode 100644 index d93e5fd778..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10339.xml +++ /dev/null @@ -1,114 +0,0 @@ - - - - - - Tripod Head - - 10339 - urn:oma:lwm2m:x:10339 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - Tripod Direction Control - E - Single - Optional - - - - - - - Tripod Automatic Control - E - Single - Optional - - - - - - - Tripod Reset - E - Single - Optional - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10340.xml b/common/transport/lwm2m/src/main/resources/models/10340.xml deleted file mode 100644 index 30123ba665..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10340.xml +++ /dev/null @@ -1,218 +0,0 @@ - - - - - - Camera - - 10340 - urn:oma:lwm2m:x:10340 - 1.0 - 1.0 - Multiple - Optional - - - Camera Name - R - Single - Mandatory - String - - - - - - - - Camera Status - R - Single - Mandatory - Boolean - - - - - - Connection Status - R - Single - Mandatory - Boolean - - - - - - Working Status - R - Single - Mandatory - Integer - 0..15 - - - - - Local Recording - R - Single - Mandatory - Boolean - - - - - - Image Matting - R - Single - Mandatory - Boolean - - - - - - Camera Snapshot - R - Single - Mandatory - Boolean - - - - - - Camera Recording - R - Single - Mandatory - Boolean - - - - - - - Camera Control - E - Single - Mandatory - - - - - - - Local Recording Control - E - Single - Mandatory - - - - - - - Image Matting Control - E - Single - Mandatory - - - - - - - Camera Snapshot Control - E - Single - Mandatory - - - - - - - Camera Recording Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10341.xml b/common/transport/lwm2m/src/main/resources/models/10341.xml deleted file mode 100644 index ca00c3ab0c..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10341.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - - GPS - - 10341 - urn:oma:lwm2m:x:10341 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10342.xml b/common/transport/lwm2m/src/main/resources/models/10342.xml deleted file mode 100644 index 5a2c0d1982..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10342.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - - IMU - - 10342 - urn:oma:lwm2m:x:10342 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10343.xml b/common/transport/lwm2m/src/main/resources/models/10343.xml deleted file mode 100644 index 309c80884d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10343.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - LiDAR - - 10343 - urn:oma:lwm2m:x:10343 - 1.0 - 1.0 - Multiple - Optional - - - LiDAR Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10344.xml b/common/transport/lwm2m/src/main/resources/models/10344.xml deleted file mode 100644 index 9e3f80a491..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10344.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - Arm - - 10344 - urn:oma:lwm2m:x:10344 - 1.0 - 1.0 - Multiple - Optional - - - Arm Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10345.xml b/common/transport/lwm2m/src/main/resources/models/10345.xml deleted file mode 100644 index 488ada316f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10345.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - Leg - - 10345 - urn:oma:lwm2m:x:10345 - 1.0 - 1.0 - Multiple - Optional - - - Leg Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10346.xml b/common/transport/lwm2m/src/main/resources/models/10346.xml deleted file mode 100644 index f5b22f8763..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10346.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - Servomotor - - 10346 - urn:oma:lwm2m:x:10346 - 1.0 - 1.0 - Multiple - Optional - - - Servomotor Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10347.xml b/common/transport/lwm2m/src/main/resources/models/10347.xml deleted file mode 100644 index 7c20b00a40..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10347.xml +++ /dev/null @@ -1,154 +0,0 @@ - - - - - - Screen - - 10347 - urn:oma:lwm2m:x:10347 - 1.0 - 1.0 - Single - Optional - - - Screen Status - R - Single - Mandatory - Boolean - - - - - - Startup Page - R - Single - Optional - String - - - The Startup Page of the screen. - - - Current Displaying Page or Current Screen Play List - R - Single - Optional - String - - - Current Displaying Page or Current Screen Play List. - - - - Screen Control - E - Single - Mandatory - - - - - - - Startup Page Set - E - Single - Mandatory - - - - - - - Screen Page Set - E - Single - Mandatory - - - - - - - Screen Play List Set - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10348.xml b/common/transport/lwm2m/src/main/resources/models/10348.xml deleted file mode 100644 index 3d8a2d460f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10348.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - Wheel - - 10348 - urn:oma:lwm2m:x:10348 - 1.0 - 1.0 - Multiple - Optional - - - Wheel Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10349.xml b/common/transport/lwm2m/src/main/resources/models/10349.xml deleted file mode 100644 index 8eb7d27ecf..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10349.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - - Chassis - - 10349 - urn:oma:lwm2m:x:10349 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10350.xml b/common/transport/lwm2m/src/main/resources/models/10350.xml deleted file mode 100644 index 64295e65bc..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10350.xml +++ /dev/null @@ -1,116 +0,0 @@ - - - - - - Light - - 10350 - urn:oma:lwm2m:x:10350 - 1.0 - 1.0 - Multiple - Optional - - - Light Name - R - Single - Mandatory - String - - - - - - - - Light Status - R - Single - Mandatory - Boolean - - - - - - - Light Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10351.xml b/common/transport/lwm2m/src/main/resources/models/10351.xml deleted file mode 100644 index 473b440b02..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10351.xml +++ /dev/null @@ -1,79 +0,0 @@ - - - - - - Door - - 10351 - urn:oma:lwm2m:x:10351 - 1.0 - 1.0 - Multiple - Optional - - - Door Name - R - Single - Mandatory - String - - - - - - - Door Status - R - Single - Mandatory - Boolean - - - - - - - Door Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10352.xml b/common/transport/lwm2m/src/main/resources/models/10352.xml deleted file mode 100644 index da1dac5834..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10352.xml +++ /dev/null @@ -1,114 +0,0 @@ - - - - - - Thermal Imager - - 10352 - urn:oma:lwm2m:x:10352 - 1.0 - 1.0 - Single - Optional - - - - Highest Temperature - R - Single - Mandatory - Float - -100.0..100.0 - Cel - The Highest Temperature of the thermal imager. - - - Lowest Temperature - R - Single - Mandatory - Float - -100.0..100.0 - Cel - The Lowest Temperature of the thermal imager. - - - Average Temperature - R - Single - Mandatory - Float - -100.0..100.0 - Cel - The Average Temperature of the thermal imager. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10353.xml b/common/transport/lwm2m/src/main/resources/models/10353.xml deleted file mode 100644 index 0b6bb56cc4..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10353.xml +++ /dev/null @@ -1,87 +0,0 @@ - - - - - - Warning Light - - 10353 - urn:oma:lwm2m:x:10353 - 1.0 - 1.0 - Single - Optional - - - Light Status - R - Single - Mandatory - Boolean - - - - - - Light Warning - R - Single - Mandatory - Boolean - - - - - - Light Control - E - Single - Mandatory - - - - - - - Light Warning Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10354.xml b/common/transport/lwm2m/src/main/resources/models/10354.xml deleted file mode 100644 index 3459409720..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10354.xml +++ /dev/null @@ -1,217 +0,0 @@ - - - - - - APP - - 10354 - urn:oma:lwm2m:x:10354 - 1.0 - 1.0 - Multiple - Mandatory - - - APP Name - RW - Single - Mandatory - String - - - The name of the APP, human readable string. - - - APP Version - RW - Single - Mandatory - String - - - The version of the APP, human readable string. - - - APP Build No - RW - Single - Optional - String - - - The Build No of the APP, human readable string. - - - APP Patch No - RW - Single - Optional - String - - - The Patch No of the APP, human readable string. - - - Package URI - W - Single - Optional - String - 0-255 bytes - - - - - Vendor Name - RW - Single - Optional - String - - - The vendor of the package. - - - Installation Target - RW - Single - Mandatory - Objlnk - - - - - - APP Status - R - Single - Mandatory - Integer - 0..5 - - The Status of the APP, 0:Downloading, 1:Downloaded, 2:Installed, 3:Verified, 4:Activated, 5:Stopped. - - - APP Restart - E - Single - Mandatory - - - - - - - APP Start - E - Single - Mandatory - - - - - - - APP Stop - E - Single - Mandatory - - - - - - - APP Download - E - Single - Mandatory - - - - - - - APP Install - E - Single - Mandatory - - - - - - - APP Uninstall - E - Single - Mandatory - - - - - - - APP Activate - E - Single - Mandatory - - - - - - - APP Deactivate - E - Single - Mandatory - - - - - - - APP Verify - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10355.xml b/common/transport/lwm2m/src/main/resources/models/10355.xml deleted file mode 100644 index fb38ee2767..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10355.xml +++ /dev/null @@ -1,95 +0,0 @@ - - - - - - General Info - - 10355 - urn:oma:lwm2m:x:10355 - 1.0 - 1.0 - Single - Optional - - - Robot General Info - R - Single - Mandatory - Objlnk - - - - - - - - RCU General Info - R - Single - Mandatory - Objlnk - - - - - - - - CCU General Info - R - Multiple - Optional - Objlnk - - - - - - - - ECU General Info - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10356.xml b/common/transport/lwm2m/src/main/resources/models/10356.xml deleted file mode 100644 index 2e362ce052..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10356.xml +++ /dev/null @@ -1,203 +0,0 @@ - - - - - - Service Info - - 10356 - urn:oma:lwm2m:x:10356 - 1.0 - 1.0 - Single - Optional - - - Robot Service Info - R - Single - Mandatory - Objlnk - - - - - - - - SCA Info - R - Multiple - Optional - Objlnk - - - - - - - - Speaker Info - R - Single - Optional - Objlnk - - - - - - - - Camera Info - R - Multiple - Optional - Objlnk - - - - - - - - Screen Info - R - Single - Optional - Objlnk - - - - - - - - Light Info - R - Multiple - Optional - Objlnk - - - - - - - - Warning Light Info - R - Single - Optional - Objlnk - - - - - - - - Door Info - R - Multiple - Optional - Objlnk - - - - - - - - Thermal Imager Info - R - Single - Optional - Objlnk - - - - - - - - Compressor Info - R - Multiple - Optional - Objlnk - - - - - - - - Lock Info - R - Multiple - Optional - Objlnk - - - - - - - - Collision Sensor Info - R - Multiple - Optional - Objlnk - - - - - - - - Drop Sensor Info - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10357.xml b/common/transport/lwm2m/src/main/resources/models/10357.xml deleted file mode 100644 index 9487b2813d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10357.xml +++ /dev/null @@ -1,95 +0,0 @@ - - - - - - PM - - 10357 - urn:oma:lwm2m:x:10357 - 1.0 - 1.0 - Single - Optional - - - Robot PM - R - Single - Mandatory - Objlnk - - - - - - - - RCU PM - R - Single - Mandatory - Objlnk - - - - - - - - CCU PM - R - Multiple - Optional - Objlnk - - - - - - - - SCA PM - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10358.xml b/common/transport/lwm2m/src/main/resources/models/10358.xml deleted file mode 100644 index 27a3684b22..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10358.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - - Fan PM - - 10358 - urn:oma:lwm2m:x:10358 - 1.0 - 1.0 - Multiple - Optional - - - Fan Name - R - Single - Mandatory - String - - - - - - - - - Fan Speed - R - Single - Optional - Integer - - 1/min - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10359.xml b/common/transport/lwm2m/src/main/resources/models/10359.xml deleted file mode 100644 index 2fc8af9677..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10359.xml +++ /dev/null @@ -1,78 +0,0 @@ - - - - - - Lock - - 10359 - urn:oma:lwm2m:x:10359 - 1.0 - 1.0 - Multiple - Optional - - - Lock Name - R - Single - Mandatory - String - - - - - - Lock Status - R - Single - Optional - Boolean - - - - - - - Lock Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10360.xml b/common/transport/lwm2m/src/main/resources/models/10360.xml deleted file mode 100644 index 935fea848c..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10360.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - - Ultrasonic Sensor - - 10360 - urn:oma:lwm2m:x:10360 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10361.xml b/common/transport/lwm2m/src/main/resources/models/10361.xml deleted file mode 100644 index 3525647afd..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10361.xml +++ /dev/null @@ -1,92 +0,0 @@ - - - - - - Collision Sensor - - 10361 - urn:oma:lwm2m:x:10361 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - - Collision Detection - R - Single - Optional - Boolean - - - - - - - Collision Detection Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10362.xml b/common/transport/lwm2m/src/main/resources/models/10362.xml deleted file mode 100644 index 8a928e4425..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10362.xml +++ /dev/null @@ -1,91 +0,0 @@ - - - - - - Drop Sensor - - 10362 - urn:oma:lwm2m:x:10362 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - Drop Detection - R - Single - Optional - Boolean - - - - - - - Drop Detection Control - E - Single - Mandatory - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10363.xml b/common/transport/lwm2m/src/main/resources/models/10363.xml deleted file mode 100644 index ca9d064f2f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10363.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - Temperature Sensor - - 10363 - urn:oma:lwm2m:x:10363 - 1.0 - 1.0 - Single - Optional - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10364.xml b/common/transport/lwm2m/src/main/resources/models/10364.xml deleted file mode 100644 index 3519665e62..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10364.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - Humidity Sensor - - 10364 - urn:oma:lwm2m:x:10364 - 1.0 - 1.0 - Single - Optional - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10365.xml b/common/transport/lwm2m/src/main/resources/models/10365.xml deleted file mode 100644 index 792844271e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10365.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - Gas-Dust Sensor - - 10365 - urn:oma:lwm2m:x:10365 - 1.0 - 1.0 - Single - Optional - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10366.xml b/common/transport/lwm2m/src/main/resources/models/10366.xml deleted file mode 100644 index 44e94ae51d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10366.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - Fan - - 10366 - urn:oma:lwm2m:x:10366 - 1.0 - 1.0 - Multiple - Optional - - - Fan Name - R - Single - Mandatory - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10368.xml b/common/transport/lwm2m/src/main/resources/models/10368.xml deleted file mode 100644 index f063e010fe..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10368.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - SpringMotor - - 10368 - urn:oma:lwm2m:x:10368 - 1.0 - 1.0 - Multiple - Optional - - - SpringMotor Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/10369.xml b/common/transport/lwm2m/src/main/resources/models/10369.xml deleted file mode 100644 index 68c345beaf..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/10369.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - - MCU - - 10369 - urn:oma:lwm2m:x:10369 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2048.xml b/common/transport/lwm2m/src/main/resources/models/2048.xml deleted file mode 100644 index 0bc99cffd1..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2048.xml +++ /dev/null @@ -1,90 +0,0 @@ - - - - - - - CmdhPolicy - - 2048 - urn:oma:lwm2m:ext:20481.0 - 1.0Multiple - Optional - - Name - RW - Single - Mandatory - String - - - - - DefaultRule - RW - Single - Mandatory - Objlnk - - - - - LimiRules - RW - Multiple - Mandatory - Objlnk - - - - - NetworkAccessECRules - RW - Multiple - Mandatory - Objlnk - - - - - BufferRules - RW - Multiple - Mandatory - Objlnk - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2049.xml b/common/transport/lwm2m/src/main/resources/models/2049.xml deleted file mode 100644 index 7509b22160..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2049.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - - ActiveCmdhPolicy - - 2049 - urn:oma:lwm2m:ext:20491.0 - 1.0Single - Optional - - ActiveLink - RW - Single - Mandatory - Objlnk - - - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2050.xml b/common/transport/lwm2m/src/main/resources/models/2050.xml deleted file mode 100644 index da27a90de0..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2050.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - - - CmdhDefaults - - 2050 - urn:oma:lwm2m:ext:20501.0 - 1.0Multiple - Optional - - DefaultEcRules - RW - Multiple - Mandatory - Objlnk - - - - - - DefaultEcParamRules - RW - Multiple - Mandatory - Objlnk - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2051.xml b/common/transport/lwm2m/src/main/resources/models/2051.xml deleted file mode 100644 index f3904e8a2c..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2051.xml +++ /dev/null @@ -1,99 +0,0 @@ - - - - - - - CmdhDefEcValues - - 2051 - urn:oma:lwm2m:ext:20511.0 - 1.0Multiple - Optional - - Order - RW - Single - Mandatory - Integer - - - - - DefEcValue - RW - Single - Mandatory - String - - - - - RequestOrigin - RW - Multiple - Mandatory - String - - - - - RequestContext - RW - Single - Optional - String - - - - - RequestContextNotification - RW - Single - Optional - Boolean - - - - - RequestCharacteristics - RW - Single - Optional - String - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2052.xml b/common/transport/lwm2m/src/main/resources/models/2052.xml deleted file mode 100644 index abaae1b54e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2052.xml +++ /dev/null @@ -1,111 +0,0 @@ - - - - - - - CmdhEcDefParamValues - - 2052 - urn:oma:lwm2m:ext:20521.0 - 1.0Multiple - Optional - - ApplicableEventCategory - RW - Multiple - Mandatory - Integer - - - - - DefaultRequestExpTime - RW - Single - Mandatory - Integer - - ms - - - - - - - - - DefaultResultExpTime - RW - Single - Mandatory - Integer - - ms - - - - DefaultOpExecTime - RW - Single - Mandatory - Integer - - ms - - - DefaultRespPersistence - RW - Single - Mandatory - Integer - - ms - - - DefaultDelAggregation - RW - Single - Mandatory - Integer - - ms - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2053.xml b/common/transport/lwm2m/src/main/resources/models/2053.xml deleted file mode 100644 index 0b119c70fc..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2053.xml +++ /dev/null @@ -1,165 +0,0 @@ - - - - - - - CmdhLimits - - 2053 - urn:oma:lwm2m:ext:20531.0 - 1.0Multiple - Optional - - Order - RW - Single - Mandatory - Integer - - - - - RequestOrigin - RW - Multiple - Mandatory - String - - - - - - - - - - - RequestContext - RW - Single - Optional - String - - - - - - RequestContextNotificatio - RW - Single - Optional - Boolean - - - - - RequestCharacteristics - RW - Single - Optional - String - - - - - LimitsEventCategory - RW - Multiple - Mandatory - Integer - - - - - LimitsRequestExpTime - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsResultExpTime - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsOptExpTime - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsRespPersistence - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsDelAggregation - RW - Multiple - Mandatory - String - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2054.xml b/common/transport/lwm2m/src/main/resources/models/2054.xml deleted file mode 100644 index 3935fb7253..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2054.xml +++ /dev/null @@ -1,69 +0,0 @@ - - - - - - - CmdhNetworkAccessRules - - 2054 - urn:oma:lwm2m:ext:20541.0 - 1.0Multiple - Optional - - ApplicableEventCategories - RW - Multiple - Mandatory - Integer - - - - - NetworkAccessRule - RW - Multiple - Optional - Objlnk - - - - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2055.xml b/common/transport/lwm2m/src/main/resources/models/2055.xml deleted file mode 100644 index cbd0dc5796..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2055.xml +++ /dev/null @@ -1,100 +0,0 @@ - - - - - - - CmdhNwAccessRule - - 2055 - urn:oma:lwm2m:ext:20551.0 - 1.0Multiple - Optional - - TargetNetwork - RW - Multiple - Mandatory - String - - - - - SpreadingWaitTime - RW - Single - Mandatory - Integer - - ms - - - MinReqVolume - RW - Single - Mandatory - Integer - - B - - - BackOffParameters - RW - Single - Mandatory - Objlnk - - - - - OtherConditions - RW - Single - Mandatory - String - - - - - AllowedSchedule - RW - Multiple - Mandatory - String - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2056.xml b/common/transport/lwm2m/src/main/resources/models/2056.xml deleted file mode 100644 index ddd50e269a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2056.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - - - - CmdhBuffer - - 2056 - urn:oma:lwm2m:ext:20561.0 - 1.0Multiple - Optional - - ApplicableEventCategory - RW - Multiple - Mandatory - Integer - - - - - MaxBufferSize - RW - Single - Mandatory - Integer - - B - - - StoragePriority - RW - Single - Mandatory - Integer - 1..10 - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/2057.xml b/common/transport/lwm2m/src/main/resources/models/2057.xml deleted file mode 100644 index 68d4bcd135..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/2057.xml +++ /dev/null @@ -1,92 +0,0 @@ - - - - - - - CmdhBackOffParametersSet - - 2057 - urn:oma:lwm2m:ext:2057 - 1.0 - 1.0 - Multiple - Optional - - NetworkAction - RW - Single - Optional - Integer - 1..5 - - - - InitialBackoffTime - RW - Single - Mandatory - Integer - - ms - - - AdditionalBackoffTime - RW - Single - Mandatory - Integer - - ms - - - MaximumBackoffTime - RW - Single - Mandatory - Integer - - ms - - - OptionalRandomBackoffTime - RW - Multiple - Optional - Integer - - ms - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/31024.xml b/common/transport/lwm2m/src/main/resources/models/31024.xml deleted file mode 100644 index 85ba52a79d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/31024.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - Test - A Wakaama object for testing purpose. - - 31024 - urn:oma:lwm2m:x:31024 - Multiple - Optional - - - test - RW - Single - Mandatory - Integer - 0-255 - - - - exec - E - Single - Mandatory - - - - dec - RW - Single - Mandatory - Float - - - - - - sig - RW - Single - Optional - Integer - - - 16-bit signed integer - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3200.xml b/common/transport/lwm2m/src/main/resources/models/3200.xml deleted file mode 100644 index 5a0dce0378..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3200.xml +++ /dev/null @@ -1,129 +0,0 @@ - - - - - - - - Digital Input - Generic digital input for non-specific sensors - 3200 - urn:oma:lwm2m:ext:3200 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The cumulative value of active state detected. - - - Digital Input Polarity - RW - Single - Optional - Boolean - - - The polarity of the digital input as a Boolean (False = Normal, True = Reversed). - - - Digital Input Debounce - RW - Single - Optional - Integer - - ms - The debounce period in ms. - - - Digital Input Edge Selection - RW - Single - Optional - Integer - 1..3 - - The edge selection as an integer (1 = Falling edge, 2 = Rising edge, 3 = Both Rising and Falling edge). - - - Digital Input Counter Reset - E - Single - Optional - - - - Reset the Counter value. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor (for instance PIR type) - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3201.xml b/common/transport/lwm2m/src/main/resources/models/3201.xml deleted file mode 100644 index 0920d9b030..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3201.xml +++ /dev/null @@ -1,78 +0,0 @@ - - - - - - - Digital Output - Generic digital output for non-specific actuators - 3201 - urn:oma:lwm2m:ext:3201 - 1.0 - 1.0 - Multiple - Optional - - - Digital Output State - RW - Single - Mandatory - Boolean - - - The current state of a digital output. - - - Digital Output Polarity - RW - Single - Optional - Boolean - - - The polarity of the digital output as a Boolean (False = Normal, True = Reversed). - - - Application Type - RW - Single - Optional - String - - - The application type of the output as a string, for instance, "LED" - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3202.xml b/common/transport/lwm2m/src/main/resources/models/3202.xml deleted file mode 100644 index 413ba0103b..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3202.xml +++ /dev/null @@ -1,128 +0,0 @@ - - - - - - - Analog Input - Generic analog input for non-specific sensors - 3202 - urn:oma:lwm2m:ext:3202 - 1.0 - 1.0 - Multiple - Optional - - - Analog Input Current Value - R - Single - Mandatory - Float - - - The current value of the analog input. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor, for instance PIR type - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3203.xml b/common/transport/lwm2m/src/main/resources/models/3203.xml deleted file mode 100644 index e807aca00a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3203.xml +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - - Analog Output - This IPSO object is a generic object that can be used with any kind of analog output interface. - 3203 - urn:oma:lwm2m:ext:3203 - 1.0 - 1.0 - Multiple - Optional - - - Analog Output Current Value - RW - Single - Mandatory - Float - 0..1 - - The current state of the analogue output. - - - Application Type - RW - Single - Optional - String - - - If present, the application type of the actuator as a string, for instance, "Valve" - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be set for the output - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be set for the output - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3300.xml b/common/transport/lwm2m/src/main/resources/models/3300.xml deleted file mode 100644 index 58cf4f67cb..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3300.xml +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - - Generic Sensor - This IPSO object allows the description of a generic sensor. It is based on the description of a value and a unit according to the SenML specification. Thus, any type of value defined within this specification can be reported using this object. This object may be used as a generic object if a dedicated one does not exist. - 3300 - urn:oma:lwm2m:ext:3300 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Application Type - RW - Single - Optional - String - - - If present, the application type of the sensor as a string, for instance, "CO2" - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor (for instance PIR type) - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3301.xml b/common/transport/lwm2m/src/main/resources/models/3301.xml deleted file mode 100644 index 7dfb81d230..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3301.xml +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - - Illuminance - Illuminance sensor, example units = lx - 3301 - urn:oma:lwm2m:ext:3301 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - The current value of the luminosity sensor. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3302.xml b/common/transport/lwm2m/src/main/resources/models/3302.xml deleted file mode 100644 index 0223d2f772..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3302.xml +++ /dev/null @@ -1,108 +0,0 @@ - - - - - - - Presence - Presence sensor with digital sensing, optional delay parameters - 3302 - urn:oma:lwm2m:ext:3302 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of the presence sensor - - - Digital Input Counter - R - Single - Optional - Integer - - - The cumulative value of active state detected. - - - Digital Input Counter Reset - E - Single - Optional - - - - Reset the Counter value - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor (for instance PIR type) - - - Busy to Clear delay - RW - Single - Optional - Integer - - ms - Delay from the detection state to the clear state in ms - - - Clear to Busy delay - RW - Single - Optional - Integer - - ms - Delay from the clear state to the busy state in ms - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3303.xml b/common/transport/lwm2m/src/main/resources/models/3303.xml deleted file mode 100644 index b638c932a8..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3303.xml +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - - Temperature - This IPSO object should be used with a temperature sensor to report a temperature measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range that can be measured by the temperature sensor. An example measurement unit is degrees Celsius. - 3303 - urn:oma:lwm2m:ext:3303 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3304.xml b/common/transport/lwm2m/src/main/resources/models/3304.xml deleted file mode 100644 index 61d65c998b..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3304.xml +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - - Humidity - This IPSO object should be used with a humidity sensor to report a humidity measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range that can be measured by the humidity sensor. An example measurement unit is relative humidity as a percentage. - 3304 - urn:oma:lwm2m:ext:3304 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3305.xml b/common/transport/lwm2m/src/main/resources/models/3305.xml deleted file mode 100644 index cd50b18907..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3305.xml +++ /dev/null @@ -1,228 +0,0 @@ - - - - - - - Power Measurement - This IPSO object should be used over a power measurement sensor to report a remote power measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range for both active and reactive power. It also provides resources for cumulative energy, calibration, and the power factor. - 3305 - urn:oma:lwm2m:ext:3305 - 1.0 - 1.0 - Multiple - Optional - - - Instantaneous active power - R - Single - Mandatory - Float - - W - The current active power - - - Min Measured active power - R - Single - Optional - Float - - W - The minimum active power measured by the sensor since it is ON - - - Max Measured active power - R - Single - Optional - Float - - W - The maximum active power measured by the sensor since it is ON - - - Min Range active power - R - Single - Optional - Float - - W - The minimum active power that can be measured by the sensor - - - Max Range active power - R - Single - Optional - Float - - W - The maximum active power that can be measured by the sensor - - - Cumulative active power - R - Single - Optional - Float - - Wh - The cumulative active power since the last cumulative energy reset or device start - - - Active Power Calibration - W - Single - Optional - Float - - W - Request an active power calibration by writing the value of a calibrated load. - - - Instantaneous reactive power - R - Single - Optional - Float - - var - The current reactive power - - - Min Measured reactive power - R - Single - Optional - Float - - var - The minimum reactive power measured by the sensor since it is ON - - - Max Measured reactive power - R - Single - Optional - Float - - var - The maximum reactive power measured by the sensor since it is ON - - - Min Range reactive power - R - Single - Optional - Float - - var - The minimum active power that can be measured by the sensor - - - Max Range reactive power - R - Single - Optional - Float - - var - The maximum reactive power that can be measured by the sensor - - - Cumulative reactive power - R - Single - Optional - Float - - varh - The cumulative reactive power since the last cumulative energy reset or device start - - - Reactive Power Calibration - W - Single - Optional - Float - - var - Request a reactive power calibration by writing the value of a calibrated load. - - - Power factor - R - Single - Optional - Float - - - If applicable, the power factor of the current consumption. - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Reset Cumulative energy - E - Single - Optional - - - - Reset both cumulative active/reactive power - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3306.xml b/common/transport/lwm2m/src/main/resources/models/3306.xml deleted file mode 100644 index 6e76808d96..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3306.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - - Actuation - This IPSO object is dedicated to remote actuation such as ON/OFF action or dimming. A multi-state output can also be described as a string. This is useful to send pilot wire orders for instance. It also provides a resource to reflect the time that the device has been switched on. - 3306 - urn:oma:lwm2m:ext:3306 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Dimmer - RW - Single - Optional - Integer - 0..100 - /100 - This resource represents a light dimmer setting, which has an Integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the device has been on. Writing a value of 0 resets the counter. - - - Muti-state Output - RW - Single - Optional - String - - - A string describing a state for multiple level output such as Pilot Wire - - - Application Type - RW - Single - Optional - String - - - The Application type of the device, for example "Motion Closure". - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3308.xml b/common/transport/lwm2m/src/main/resources/models/3308.xml deleted file mode 100644 index 865df6235f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3308.xml +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - - Set Point - This IPSO object should be used to set a desired value to a controller, such as a thermostat. A special resource is added to set the colour of an object. - 3308 - urn:oma:lwm2m:ext:3308 - 1.0 - 1.0 - Multiple - Optional - - - Set Point Value - RW - Single - Mandatory - Float - - - The setpoint value. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Colour - RW - Single - Optional - String - - - A string representing a value in some color space - - - Application Type - RW - Single - Optional - String - - - The Application type of the device, for example "Motion Closure". - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3310.xml b/common/transport/lwm2m/src/main/resources/models/3310.xml deleted file mode 100644 index 75e381f488..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3310.xml +++ /dev/null @@ -1,108 +0,0 @@ - - - - - - - Load Control - This Object is used for demand-response load control and other load control in automation application (not limited to power). - 3310 - urn:oma:lwm2m:ext:3310 - 1.0 - 1.0 - Multiple - Optional - - - Event Identifier - RW - Single - Mandatory - String - - - The event identifier as a string. - - - Start Time - RW - Single - Mandatory - Time - - - Time when the event started. - - - Duration In Min - RW - Single - Mandatory - Integer - - min - The duration of the event in minutes. - - - Criticality Level - RW - Single - Optional - Integer - 0..3 - - The criticality of the event. The device receiving the event will react in an appropriate fashion for the device. - - - Avg Load AdjPct - RW - Single - Optional - Integer - 0..100 - /100 - Defines the maximum energy usage of the receiving device, as a percentage of the device's normal maximum energy usage. - - - Duty Cycle - RW - Single - Optional - Integer - 0..100 - /100 - Defines the duty cycle for the load control event, i.e, what percentage of time the receiving device is allowed to be on. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3311.xml b/common/transport/lwm2m/src/main/resources/models/3311.xml deleted file mode 100644 index 2e7b3977b6..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3311.xml +++ /dev/null @@ -1,127 +0,0 @@ - - - - - - Light Control - This Object is used to control a light source, such as a LED or other light. It allows a light to be turned on or off and its dimmer setting to be control as a % between 0 and 100. An optional colour setting enables a string to be used to indicate the desired colour. - 3311 - urn:oma:lwm2m:ext:3311 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Dimmer - RW - Single - Optional - Integer - 0..100 - /100 - This resource represents a light dimmer setting, which has an Integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the light has been on. Writing a value of 0 resets the counter. - - - Cumulative active power - R - Single - Optional - Float - - Wh - The total power in Wh that the light has used. - - - Power factor - R - Single - Optional - Float - - - The power factor of the light. - - - Colour - RW - Single - Optional - String - - - A string representing a value in some color space - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3312.xml b/common/transport/lwm2m/src/main/resources/models/3312.xml deleted file mode 100644 index fca6d7926a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3312.xml +++ /dev/null @@ -1,107 +0,0 @@ - - - - - - Power Control - This Object is used to control a power source, such as a Smart Plug. It allows a power relay to be turned on or off and its dimmer setting to be control as a % between 0 and 100. - 3312 - urn:oma:lwm2m:ext:3312 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Dimmer - RW - Single - Optional - Integer - 0..100 - /100 - This resource represents a power dimmer setting, which has an Integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the power relay has been on. Writing a value of 0 resets the counter. - - - Cumulative active power - R - Single - Optional - Float - - Wh - The total power in Wh that has been used by the load. - - - Power factor - R - Single - Optional - Float - - - The power factor of the load. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3313.xml b/common/transport/lwm2m/src/main/resources/models/3313.xml deleted file mode 100644 index df8dd8b573..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3313.xml +++ /dev/null @@ -1,107 +0,0 @@ - - - - - - Accelerometer - This IPSO object can be used to represent a 1-3 axis accelerometer. - 3313 - urn:oma:lwm2m:ext:3313 - 1.0 - 1.0 - Multiple - Optional - - - X Value - R - Single - Mandatory - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3314.xml b/common/transport/lwm2m/src/main/resources/models/3314.xml deleted file mode 100644 index 0dcd28e625..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3314.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - - - - Magnetometer - This IPSO object can be used to represent a 1-3 axis magnetometer with optional compass direction. - 3314 - urn:oma:lwm2m:ext:3314 - 1.0 - 1.0 - Multiple - Optional - - - X Value - R - Single - Mandatory - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Compass Direction - R - Single - Optional - Float - 0..360 - deg - The measured compass direction. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3315.xml b/common/transport/lwm2m/src/main/resources/models/3315.xml deleted file mode 100644 index 1e010d3186..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3315.xml +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - - Barometer - This IPSO object should be used with an air pressure sensor to report a barometer measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range that can be measured by the barometer sensor. An example measurement unit is pascals. - 3315 - urn:oma:lwm2m:ext:3315 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3316.xml b/common/transport/lwm2m/src/main/resources/models/3316.xml deleted file mode 100644 index 63a769bea2..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3316.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Voltage - This IPSO object should be used with voltmeter sensor to report measured voltage between two points. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is volts. - - 3316 - urn:oma:lwm2m:ext:3316 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3317.xml b/common/transport/lwm2m/src/main/resources/models/3317.xml deleted file mode 100644 index f3c0303438..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3317.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Current - This IPSO object should be used with an ammeter to report measured electric current in amperes. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is ampere. - - 3317 - urn:oma:lwm2m:ext:3317 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3318.xml b/common/transport/lwm2m/src/main/resources/models/3318.xml deleted file mode 100644 index e7b69cd460..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3318.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Frequency - This IPSO object should be used to report frequency measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is hertz. - - 3318 - urn:oma:lwm2m:ext:3318 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3319.xml b/common/transport/lwm2m/src/main/resources/models/3319.xml deleted file mode 100644 index 19d074a6eb..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3319.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Depth - This IPSO object should be used to report depth measurements. It can, for example, be used to describe a generic rain gauge that measures the accumulated rainfall in millimetres (mm). - - 3319 - urn:oma:lwm2m:ext:3319 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3320.xml b/common/transport/lwm2m/src/main/resources/models/3320.xml deleted file mode 100644 index d43fe7f315..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3320.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Percentage - This IPSO object should can be used to report measurements relative to a 0-100% scale. For example it could be used to measure the level of a liquid in a vessel or container in units of %. - - 3320 - urn:oma:lwm2m:ext:3320 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3321.xml b/common/transport/lwm2m/src/main/resources/models/3321.xml deleted file mode 100644 index 0e57a8917b..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3321.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Altitude - This IPSO object should be used with an altitude sensor to report altitude above sea level in meters. Note that Altitude can be calculated from the measured pressure given the local sea level pressure. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is meters. - - 3321 - urn:oma:lwm2m:ext:3321 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3322.xml b/common/transport/lwm2m/src/main/resources/models/3322.xml deleted file mode 100644 index c1eb6557c7..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3322.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Load - This IPSO object should be used with a load sensor (as in a scale) to report the applied weight or force. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is kilograms. - - 3322 - urn:oma:lwm2m:ext:3322 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3323.xml b/common/transport/lwm2m/src/main/resources/models/3323.xml deleted file mode 100644 index 16c409931d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3323.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Pressure - This IPSO object should be used to report pressure measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is pascals. - - 3323 - urn:oma:lwm2m:ext:3323 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3324.xml b/common/transport/lwm2m/src/main/resources/models/3324.xml deleted file mode 100644 index e23c76b5dc..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3324.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Loudness - This IPSO object should be used to report loudness or noise level measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is decibels. - - 3324 - urn:oma:lwm2m:ext:3324 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3325.xml b/common/transport/lwm2m/src/main/resources/models/3325.xml deleted file mode 100644 index 2defd9af1e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3325.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Concentration - This IPSO object should be used to the particle concentration measurement of a medium. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is parts per million. - - 3325 - urn:oma:lwm2m:ext:3325 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3326.xml b/common/transport/lwm2m/src/main/resources/models/3326.xml deleted file mode 100644 index 7d3f940649..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3326.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Acidity - This IPSO object should be used to report an acidity measurement of a liquid. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is pH. - - 3326 - urn:oma:lwm2m:ext:3326 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3327.xml b/common/transport/lwm2m/src/main/resources/models/3327.xml deleted file mode 100644 index 32498aba39..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3327.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Conductivity - This IPSO object should be used to report a measurement of the electric conductivity of a medium or sample. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is Siemens. - - 3327 - urn:oma:lwm2m:ext:3327 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3328.xml b/common/transport/lwm2m/src/main/resources/models/3328.xml deleted file mode 100644 index 4c920b05ae..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3328.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Power - This IPSO object should be used to report power measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is Watts. This object may be used for either real power or apparent power measurements. - - 3328 - urn:oma:lwm2m:ext:3328 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3329.xml b/common/transport/lwm2m/src/main/resources/models/3329.xml deleted file mode 100644 index ba96e5bf9d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3329.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Power Factor - This IPSO object should be used to report a measurement or calculation of the power factor of a reactive electrical load. Power Factor is normally the ratio of non-reactive power to total power. This object also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. - - 3329 - urn:oma:lwm2m:ext:3329 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3330.xml b/common/transport/lwm2m/src/main/resources/models/3330.xml deleted file mode 100644 index 5583596aa8..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3330.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Distance - This IPSO object should be used to report a distance measurement. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is Meters. - - 3330 - urn:oma:lwm2m:ext:3330 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3331.xml b/common/transport/lwm2m/src/main/resources/models/3331.xml deleted file mode 100644 index 8933e75c69..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3331.xml +++ /dev/null @@ -1,89 +0,0 @@ - - - - - - - Energy - This IPSO object should be used to report energy consumption (Cumulative Power) of an electrical load. An example measurement unit is Watt Hours. - - 3331 - urn:oma:lwm2m:ext:3331 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Cumulative energy - E - Single - Optional - - - - Reset both cumulative active/reactive power. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3332.xml b/common/transport/lwm2m/src/main/resources/models/3332.xml deleted file mode 100644 index e39fb6f182..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3332.xml +++ /dev/null @@ -1,99 +0,0 @@ - - - - - - - Direction - This IPSO object is used to report the direction indicated by a compass, wind vane, or other directional indicator. The units of measure is plane angle degrees. - - 3332 - urn:oma:lwm2m:ext:3332 - 1.0 - 1.0 - Multiple - Optional - - - Compass Direction - R - Single - Mandatory - Float - 0..360 - deg - The measured compass direction. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset. - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3333.xml b/common/transport/lwm2m/src/main/resources/models/3333.xml deleted file mode 100644 index 7282e2670a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3333.xml +++ /dev/null @@ -1,78 +0,0 @@ - - - - - - Time - This IPSO object is used to report the current time in seconds since January 1, 1970 UTC. There is also a fractional time counter that has a range of less than one second. - - 3333 - urn:oma:lwm2m:ext:3333 - 1.0 - 1.0 - Multiple - Optional - - - Current Time - RW - Single - Mandatory - Time - - - Unix Time. A signed integer representing the number of seconds since Jan 1st, 1970 in the UTC time zone. - - - Fractional Time - RW - Single - Optional - Float - 0..1 - s - Fractional part of the time when sub-second precision is used (e.g., 0.23 for 230 ms). - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3334.xml b/common/transport/lwm2m/src/main/resources/models/3334.xml deleted file mode 100644 index 8fb30e0164..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3334.xml +++ /dev/null @@ -1,189 +0,0 @@ - - - - - - - Gyrometer - This IPSO Object is used to report the current reading of a gyrometer sensor in 3 axes. It provides tracking of the minimum and maximum angular rate in all 3 axes. An example unit of measure is radians per second. - - 3334 - urn:oma:lwm2m:ext:3334 - 1.0 - 1.0 - Multiple - Optional - - - X Value - R - Single - Mandatory - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min X Value - R - Single - Optional - Float - - - The minimum measured value along the X axis - - - Max X Value - R - Single - Optional - Float - - - The maximum measured value along the X axis - - - Min Y Value - R - Single - Optional - Float - - - The minimum measured value along the Y axis - - - Max Y Value - R - Single - Optional - Float - - - The maximum measured value along the Y axis - - - Min Z Value - R - Single - Optional - Float - - - The minimum measured value along the Z axis - - - Max Z Value - R - Single - Optional - Float - - - The maximum measured value along the Z axis - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value. - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3335.xml b/common/transport/lwm2m/src/main/resources/models/3335.xml deleted file mode 100644 index 8d48093231..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3335.xml +++ /dev/null @@ -1,79 +0,0 @@ - - - - - - - Colour - This IPSO object should be used to report the measured value of a colour sensor in some colour space described by the units resource. - - 3335 - urn:oma:lwm2m:ext:3335 - 1.0 - 1.0 - Multiple - Optional - - - Colour - RW - Single - Mandatory - String - - - A string representing a value in some colour space. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3336.xml b/common/transport/lwm2m/src/main/resources/models/3336.xml deleted file mode 100644 index 30aba24708..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3336.xml +++ /dev/null @@ -1,119 +0,0 @@ - - - - - - - Location - This IPSO object represents GPS coordinates. This object is compatible with the LWM2M management object for location, but uses reusable resources. - - 3336 - urn:oma:lwm2m:ext:3336 - 1.0 - 1.0 - Multiple - Optional - - - Latitude - R - Single - Mandatory - String - - - The decimal notation of latitude, e.g. -43.5723 (World Geodetic System 1984). - - - Longitude - R - Single - Mandatory - String - - - The decimal notation of longitude, e.g. 153.21760 (World Geodetic System 1984). - - - Uncertainty - R - Single - Optional - String - - - The accuracy of the position in meters. - - - Compass Direction - R - Single - Optional - Float - 0..360 - deg - The measured compass direction. - - - Velocity - R - Single - Optional - Opaque - - - The velocity of the device as defined in 3GPP 23.032 GAD specification. This set of values may not be available if the device is static. - - - Timestamp - R - Single - Optional - Time - - - The timestamp of when the measurement was performed. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3337.xml b/common/transport/lwm2m/src/main/resources/models/3337.xml deleted file mode 100644 index 54f3d19d54..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3337.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Positioner - This IPSO object should be used with a generic position actuator with range from 0 to 100%. This object optionally allows setting the transition time for an operation that changes the position of the actuator, and for reading the remaining time of the currently active transition. - - 3337 - urn:oma:lwm2m:ext:3337 - 1.0 - 1.0 - Multiple - Optional - - - Current Position - RW - Single - Mandatory - Float - 0..100 - /100 - Current position or desired position of a positioner actuator. - - - Transition Time - RW - Single - Optional - Float - - s - The time expected to move the actuator to the new position. - - - Remaining Time - R - Single - Optional - Float - - s - The time remaining in an operation. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value set on the actuator since power ON or reset. - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value set on the actuator since power ON or reset. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value. - - - Min Limit - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor. - - - Max Limit - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3338.xml b/common/transport/lwm2m/src/main/resources/models/3338.xml deleted file mode 100644 index 1437a62c65..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3338.xml +++ /dev/null @@ -1,99 +0,0 @@ - - - - - - - Buzzer - This IPSO object should be used to actuate an audible alarm such as a buzzer, beeper, or vibration alarm. There is a dimmer control for setting the relative loudness of the alarm, and an optional duration control to limit the length of time the alarm sounds when turned on. Each time "true" is written to the On/Off resource, the alarm will sound again for the configured duration. If no duration is programmed or the setting is "false", writing a "true" to the On/Off resource will result in the alarm sounding continuously until a "false" is written to the On/Off resource. - - 3338 - urn:oma:lwm2m:ext:3338 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Level - RW - Single - Optional - Float - 0..100 - /100 - Audio volume control, float value between 0 and 100 as a percentage. - - - Delay Duration - RW - Single - Optional - Float - - s - The duration of the time delay. - - - Minimum Off-time - RW - Single - Mandatory - Float - - s - The off time when On/Off control remains on. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3339.xml b/common/transport/lwm2m/src/main/resources/models/3339.xml deleted file mode 100644 index edd11709e8..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3339.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - - Audio Clip - This IPSO object should be used for a speaker that plays a pre-recorded audio clip or an audio output that is sent elsewhere. For example, an elevator which announces the floor of the building. A resource is provided to store the clip, a dimmer resource controls the relative sound level of the playback, and a duration resource limits the maximum playback time. After the duration time is reached, any remaining samples in the clip are ignored, and the clip player will be ready to play another clip. - 3339 - urn:oma:lwm2m:ext:3339 - 1.0 - 1.0 - Multiple - Optional - - - Clip - RW - Single - Mandatory - Opaque - - - Audio clip that is playable (e.g., a short audio recording indicating the floor in an elevator). - - - Trigger - E - Single - Optional - - - - Trigger initiating actuation. - - - Level - RW - Single - Optional - Float - 0..100 - /100 - Audio volume control, float value between 0 and 100 as a percentage. - - - Duration - RW - Single - Optional - Float - - s - The duration of the sound once trigger. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3340.xml b/common/transport/lwm2m/src/main/resources/models/3340.xml deleted file mode 100644 index 16585224fa..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3340.xml +++ /dev/null @@ -1,159 +0,0 @@ - - - - - - - Timer - This IPSO object is used to time events and actions, using patterns common to industrial timers. A write to the trigger resource or On/Off input state change starts the timing operation, and the timer remaining time shows zero when the operation is complete. The patterns supported are One-Shot (mode 1), On-Time or Interval (mode 2), Time delay on pick-up or TDPU (mode 3), and Time Delay on Drop-Out or TDDO (mode 4). Mode 0 disables the timer, so the output follows the input with no delay. A counter is provided to count occurrences of the timer output changing from 0 to 1. Writing a value of zero resets the counter. The Digital Input State resource reports the state of the timer output. - - 3340 - urn:oma:lwm2m:ext:3340 - 1.0 - 1.0 - Multiple - Optional - - - Delay Duration - RW - Single - Mandatory - Float - - s - The duration of the time delay. - - - Remaining Time - R - Single - Optional - Float - - s - The time remaining in an operation. - - - Minimum Off-time - RW - Single - Optional - Float - - s - The duration of the rearm delay (i.e. the delay from the end of one cycle until the beginning of the next, the inhibit time). - - - Trigger - E - Single - Optional - - - - Trigger initiating actuation. - - - On/Off - RW - Single - Optional - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input. - - - Cumulative Time - RW - Single - Optional - Float - - s - The total time in seconds that the timer input is true. Writing a 0 resets the time. - - - Digital State - R - Single - Optional - Boolean - - - The current state of the timer output. - - - Counter - RW - Single - Optional - Integer - - - Counts the number of times the timer output transitions from 0 to 1. - - - Timer Mode - RW - Single - Optional - Integer - 0..4 - - Type of timer pattern used by the patterns. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3341.xml b/common/transport/lwm2m/src/main/resources/models/3341.xml deleted file mode 100644 index 55865d0f32..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3341.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Addressable Text Display - This IPSO object is used to send text to a text-only or text mode graphics display. Writing a string of text to the text resource causes it to be displayed at the selected X and Y locations on the display. If X or Y are set to a value greater than the size of the display, the position "wraps around" to the modulus of the setting and the display size. Likewise, if the text string overflows the display size, the text "wraps around" and displays on the next line down or, if the last line has been written, wraps around to the top of the display. Brightness and Contrast controls are provided to allow control of various display types including STN and DSTN type LCD character displays. Writing an empty payload to the Clear Display resource causes the display to be erased. - - 3341 - urn:oma:lwm2m:ext:3341 - 1.0 - 1.0 - Multiple - Optional - - - Text - RW - Single - Mandatory - String - - - A string of text. - - - X Coordinate - RW - Single - Optional - Integer - - - X Coordinate. - - - Y Coordinate - RW - Single - Optional - Integer - - - Y Coordinate. - - - Max X Coordinate - R - Single - Optional - Integer - - - The highest X coordinate the display supports before wrapping to the next line. - - - Max Y Coordinate - R - Single - Optional - Integer - - - The highest Y coordinate the display supports before wrapping to the next line. - - - Clear Display - E - Single - Optional - - - - Command to clear the display. - - - Level - RW - Single - Optional - Float - 0..100 - /100 - Brightness control, integer value between 0 and 100 as a percentage. - - - Contrast - RW - Single - Optional - Float - 0..100 - /100 - Proportional control, integer value between 0 and 100 as a percentage. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3342.xml b/common/transport/lwm2m/src/main/resources/models/3342.xml deleted file mode 100644 index b88ebab9d4..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3342.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - - On/Off switch - This IPSO object should be used with an On/Off switch to report the state of the switch. - 3342 - urn:oma:lwm2m:ext:3342 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from 0 to 1. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds since the On command was sent. Writing a value of 0 resets the counter. - - - Off Time - RW - Single - Optional - Integer - - s - The time in seconds since the Off command was sent. Writing a value of 0 resets the counter. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3343.xml b/common/transport/lwm2m/src/main/resources/models/3343.xml deleted file mode 100644 index 63b77c3e91..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3343.xml +++ /dev/null @@ -1,89 +0,0 @@ - - - - - - - Dimmer - This IPSO object should be used with a dimmer or level control to report the state of the control. - - 3343 - urn:oma:lwm2m:ext:3343 - 1.0 - 1.0 - Multiple - Optional - - - Level - RW - Single - Mandatory - Float - 0..100 - /100 - Proportional control, integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the dimmer has been on (Dimmer value has to be > 0). Writing a value of 0 resets the counter. - - - Off Time - RW - Single - Optional - Integer - - s - The time in seconds that the dimmer has been off (dimmer value less or equal to 0) Writing a value of 0 resets the counter. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3344.xml b/common/transport/lwm2m/src/main/resources/models/3344.xml deleted file mode 100644 index 2dd8648a19..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3344.xml +++ /dev/null @@ -1,99 +0,0 @@ - - - - - - - Up/Down Control - This IPSO object is used to report the state of an up/down control element like a pair of push buttons or a rotary encoder. Counters for increase and decrease operations are provided for counting pulses from a quadrature encoder. - - 3344 - urn:oma:lwm2m:ext:3344 - 1.0 - 1.0 - Multiple - Optional - - - Increase Input State - R - Single - Mandatory - Boolean - - - Indicates an increase control action. - - - Decrease Input State - R - Single - Mandatory - Boolean - - - Indicates a decrease control action. - - - Up Counter - RW - Single - Optional - Integer - - - Counts the number of times the increase control has been operated. Writing a 0 resets the counter. - - - Down Counter - RW - Single - Optional - Integer - - - Counts the times the decrease control has been operated. Writing a 0 resets the counter. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3345.xml b/common/transport/lwm2m/src/main/resources/models/3345.xml deleted file mode 100644 index a5355c94ca..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3345.xml +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - - Multiple Axis Joystick - This IPSO object can be used to report the position of a shuttle or joystick control. A digital input is provided to report the state of an associated push button. - - 3345 - urn:oma:lwm2m:ext:3345 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Optional - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from 0 to 1. - - - X Value - R - Single - Optional - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3346.xml b/common/transport/lwm2m/src/main/resources/models/3346.xml deleted file mode 100644 index 8c68054c39..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3346.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - Rate - This object type should be used to report a rate measurement, for example the speed of a vehicle, or the rotational speed of a drive shaft. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is meters per second (m/s). - - 3346 - urn:oma:lwm2m:ext:3346 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3347.xml b/common/transport/lwm2m/src/main/resources/models/3347.xml deleted file mode 100644 index f86a986f0a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3347.xml +++ /dev/null @@ -1,79 +0,0 @@ - - - - - - - Push button - This IPSO object is used to report the state of a momentary action push button control and to count the number of times the control has been operated since the last observation. - - 3347 - urn:oma:lwm2m:ext:3347 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from 0 to 1. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3348.xml b/common/transport/lwm2m/src/main/resources/models/3348.xml deleted file mode 100644 index a2de51f6af..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3348.xml +++ /dev/null @@ -1,69 +0,0 @@ - - - - - - - Multi-state Selector - This IPSO object is used to represent the state of a Multi-state selector switch with a number of fixed positions. - - 3348 - urn:oma:lwm2m:ext:3348 - 1.0 - 1.0 - Multiple - Optional - - - Multi-state Input - R - Single - Mandatory - Integer - - - The current state of a Multi-state input or selector. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3349.xml b/common/transport/lwm2m/src/main/resources/models/3349.xml deleted file mode 100644 index 9a77820703..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3349.xml +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - - Bitmap - Summarize several digital inputs to one value by mapping each bit to a digital input. - 3349 - urn:oma:lwm2m:ext:3349 - 1.0 - 1.0 - Multiple - Optional - - - Bitmap Input - R - Single - Mandatory - Integer - - - Integer in which each of the bits are associated with specific digital input value. Represented as a binary signed integer in network byte order, and in two's complement representation. Using values in range 0-127 is recommended to avoid ambiguities with byte order and negative values. - - - Bitmap Input Reset - E - Single - Optional - - - - Reset the Bitmap Input value. - - - Element Description - RW - Multiple - Optional - String - - - The description of each bit as a string. First instance describes the least significant bit, second instance the second least significant bit. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3350.xml b/common/transport/lwm2m/src/main/resources/models/3350.xml deleted file mode 100644 index dc1313cd83..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3350.xml +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - - Stopwatch - An ascending timer that counts how long time has passed since the timer was started after reset. - 3350 - urn:oma:lwm2m:ext:3350 - 1.0 - 1.0 - Multiple - Optional - - - Cumulative Time - RW - Single - Mandatory - Float - - s - The total time in seconds that the stopwatch has been on. Writing a 0 resets the time. - - - On/Off - RW - Single - Optional - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from off to on. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3351.xml b/common/transport/lwm2m/src/main/resources/models/3351.xml deleted file mode 100644 index 9219a765df..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3351.xml +++ /dev/null @@ -1,131 +0,0 @@ - - - powerupLog - - 3351 - urn:oma:lwm2m:ext:3351 - 1.0 - 1.0 - Single - Optional - - deviceName - R - Single - Mandatory - String - - - - - toolVersion - R - Single - Mandatory - String - - - - - IMEI - R - Single - Mandatory - String - - - - - IMSI - R - Single - Mandatory - String - - - - - MSISDN - R - Single - Mandatory - String - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3352.xml b/common/transport/lwm2m/src/main/resources/models/3352.xml deleted file mode 100644 index 260daa033a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3352.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - plmnSearchEvent - - 3352 - urn:oma:lwm2m:ext:3352 - 1.0 - 1.0 - Multiple - Optional - - timeScanStart - R - Single - Mandatory - Integer - - - - - plmnID - R - Single - Mandatory - Integer - - - - - BandIndicator - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3353.xml b/common/transport/lwm2m/src/main/resources/models/3353.xml deleted file mode 100644 index 95b87e40b7..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3353.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - scellID - - 3353 - urn:oma:lwm2m:ext:3353 - 1.0 - 1.0 - Single - Optional - - plmnID - R - Single - Mandatory - Integer - - - - - BandIndicator - R - Single - Mandatory - Integer - - - - - TrackingAreaCode - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3354.xml b/common/transport/lwm2m/src/main/resources/models/3354.xml deleted file mode 100644 index 065a330d38..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3354.xml +++ /dev/null @@ -1,134 +0,0 @@ - - - cellReselectionEvent - - 3354 - urn:oma:lwm2m:ext:3354 - 1.0 - 1.0 - Single - Optional - - timeReselectionStart - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - failureType - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3355.xml b/common/transport/lwm2m/src/main/resources/models/3355.xml deleted file mode 100644 index 627d67b68e..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3355.xml +++ /dev/null @@ -1,156 +0,0 @@ - - - handoverEvent - - 3355 - urn:oma:lwm2m:ext:3355 - 1.0 - 1.0 - Single - Optional - - timeHandoverStart - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - handoverResult - R - Single - Mandatory - Integer - - - - - - TargetEarfcn - R - Single - Mandatory - Integer - - - - - TargetPhysicalCellID - R - Single - Mandatory - Integer - - - - - targetCellRsrp - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3356.xml b/common/transport/lwm2m/src/main/resources/models/3356.xml deleted file mode 100644 index 95c7fc7835..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3356.xml +++ /dev/null @@ -1,120 +0,0 @@ - - - radioLinkFailureEvent - - 3356 - urn:oma:lwm2m:ext:3356 - 1.0 - 1.0 - Single - Optional - - timeRLF - R - Single - Mandatory - Integer - - - - - rlfCause - R - Single - Mandatory - Integer - - - - - - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3357.xml b/common/transport/lwm2m/src/main/resources/models/3357.xml deleted file mode 100644 index 935b7c4ba7..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3357.xml +++ /dev/null @@ -1,131 +0,0 @@ - - - rrcStateChangeEvent - - 3357 - urn:oma:lwm2m:ext:3357 - 1.0 - 1.0 - Single - Optional - - rrcState - R - Single - Mandatory - Integer - - - - - rrcStateChangeCause - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3358.xml b/common/transport/lwm2m/src/main/resources/models/3358.xml deleted file mode 100644 index 2784d6a990..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3358.xml +++ /dev/null @@ -1,106 +0,0 @@ - - - rrcTimerExpiryEvent - - 3358 - urn:oma:lwm2m:ext:3358 - 1.0 - 1.0 - Single - Optional - - RrcTimerExpiryEvent - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3359.xml b/common/transport/lwm2m/src/main/resources/models/3359.xml deleted file mode 100644 index 630e52ce8f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3359.xml +++ /dev/null @@ -1,105 +0,0 @@ - - - cellBlacklistEvent - - 3359 - urn:oma:lwm2m:ext:3359 - 1.0 - 1.0 - Single - Optional - - dlEarfcn - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3360.xml b/common/transport/lwm2m/src/main/resources/models/3360.xml deleted file mode 100644 index 12b2302854..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3360.xml +++ /dev/null @@ -1,128 +0,0 @@ - - - esmContextInfo - - 3360 - urn:oma:lwm2m:ext:3360 - 1.0 - 1.0 - Single - Optional - - contextType - R - Single - Mandatory - Integer - - - - - bearerState - R - Single - Mandatory - Integer - - - - - radioBearerId - R - Single - Mandatory - Integer - - - - - qci - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3361.xml b/common/transport/lwm2m/src/main/resources/models/3361.xml deleted file mode 100644 index 3d354bffac..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3361.xml +++ /dev/null @@ -1,130 +0,0 @@ - - - emmStateValue - - 3361 - urn:oma:lwm2m:ext:3361 - 1.0 - 1.0 - Single - Optional - - EmmState - R - Single - Mandatory - Integer - - - - - emmSubstate - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3362.xml b/common/transport/lwm2m/src/main/resources/models/3362.xml deleted file mode 100644 index 3cb73eb79a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3362.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - nasEmmTimerExpiryEvent - - 3362 - urn:oma:lwm2m:ext:3362 - 1.0 - 1.0 - Single - Optional - - NasEmmTimerExpiryEvent - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3363.xml b/common/transport/lwm2m/src/main/resources/models/3363.xml deleted file mode 100644 index 3b44b91f26..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3363.xml +++ /dev/null @@ -1,100 +0,0 @@ - - - nasEsmExpiryEvent - - 3363 - urn:oma:lwm2m:ext:3363 - 1.0 - 1.0 - Single - Optional - - NasEsmExpiryEvent - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3364.xml b/common/transport/lwm2m/src/main/resources/models/3364.xml deleted file mode 100644 index 0a042d12d2..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3364.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - emmFailureCauseEvent - - 3364 - urn:oma:lwm2m:ext:3364 - 1.0 - 1.0 - Single - Optional - - EMMCause - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3365.xml b/common/transport/lwm2m/src/main/resources/models/3365.xml deleted file mode 100644 index 99f1b3885c..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3365.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - rachLatency_delay - - 3365 - urn:oma:lwm2m:ext:3365 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - rachLatencyVal - R - Single - Mandatory - Integer - - - - - delay - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3366.xml b/common/transport/lwm2m/src/main/resources/models/3366.xml deleted file mode 100644 index 5498af2a3d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3366.xml +++ /dev/null @@ -1,176 +0,0 @@ - - - macRachAttemptEvent - - 3366 - urn:oma:lwm2m:ext:3366 - 1.0 - 1.0 - Single - Optional - - rachAttemptCounter - R - Single - Mandatory - Integer - - - - - MacRachAttemptEventType - R - Single - Mandatory - Integer - - - - - contentionBased - R - Single - Mandatory - Boolean - - - - - rachMessage - R - Single - Mandatory - Integer - - - - - preambleIndex - R - Single - Mandatory - Integer - - - - - preamblePowerOffset - R - Single - Mandatory - Integer - - - - - backoffTime - R - Single - Mandatory - Integer - - - - - msg2Result - R - Single - Mandatory - Boolean - - - - - timingAdjustmentValue - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3367.xml b/common/transport/lwm2m/src/main/resources/models/3367.xml deleted file mode 100644 index 1f35cf4cc5..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3367.xml +++ /dev/null @@ -1,138 +0,0 @@ - - - macRachAttemptReasonEvent - - 3367 - urn:oma:lwm2m:ext:3367 - 1.0 - 1.0 - Single - Optional - - MacRachAttemptReasonType - R - Single - Mandatory - Integer - - - - - ueID - R - Single - Mandatory - Integer - - - - - contentionBased - R - Single - Mandatory - Boolean - - - - - preamble - R - Single - Mandatory - Integer - - - - - preambleGroupChosen - R - Single - Mandatory - Boolean - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3368.xml b/common/transport/lwm2m/src/main/resources/models/3368.xml deleted file mode 100644 index 40c17bfd37..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3368.xml +++ /dev/null @@ -1,100 +0,0 @@ - - - macTimerStatusEvent - - 3368 - urn:oma:lwm2m:ext:3368 - 1.0 - 1.0 - Single - Optional - - macTimerName - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3369.xml b/common/transport/lwm2m/src/main/resources/models/3369.xml deleted file mode 100644 index b93bb86644..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3369.xml +++ /dev/null @@ -1,105 +0,0 @@ - - - macTimingAdvanceEvent - - 3369 - urn:oma:lwm2m:ext:3369 - 1.0 - 1.0 - Single - Optional - - timerValue - R - Single - Mandatory - Integer - - - - - timingAdvance - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3370.xml b/common/transport/lwm2m/src/main/resources/models/3370.xml deleted file mode 100644 index c79ff32a75..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3370.xml +++ /dev/null @@ -1,141 +0,0 @@ - - - ServingCellMeasurement - - 3370 - urn:oma:lwm2m:ext:3370 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - pci - R - Single - Mandatory - Integer - - - - - rsrp - R - Single - Mandatory - Integer - - - - - rsrq - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3371.xml b/common/transport/lwm2m/src/main/resources/models/3371.xml deleted file mode 100644 index 8267b8ed81..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3371.xml +++ /dev/null @@ -1,141 +0,0 @@ - - - NeighborCellMeasurements - - 3371 - urn:oma:lwm2m:ext:3371 - 1.0 - 1.0 - Multiple - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - pci - R - Single - Mandatory - Integer - - - - - rsrp - R - Single - Mandatory - Integer - - - - - rsrq - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3372.xml b/common/transport/lwm2m/src/main/resources/models/3372.xml deleted file mode 100644 index d08c1dad3a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3372.xml +++ /dev/null @@ -1,115 +0,0 @@ - - - TimingAdvance - - 3372 - urn:oma:lwm2m:ext:3372 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - timingAdvance - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3373.xml b/common/transport/lwm2m/src/main/resources/models/3373.xml deleted file mode 100644 index 9a4191787f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3373.xml +++ /dev/null @@ -1,115 +0,0 @@ - - - txPowerHeadroomEvent - - 3373 - urn:oma:lwm2m:ext:3373 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - headroom-value - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3374.xml b/common/transport/lwm2m/src/main/resources/models/3374.xml deleted file mode 100644 index abc9cc926f..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3374.xml +++ /dev/null @@ -1,132 +0,0 @@ - - - radioLinkMonitoring - - 3374 - urn:oma:lwm2m:ext:3374 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - outOfSyncCount - R - Single - Mandatory - Integer - - - - - inSyncCount - R - Single - Mandatory - Integer - - - - - t310Timer - R - Single - Mandatory - Boolean - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3375.xml b/common/transport/lwm2m/src/main/resources/models/3375.xml deleted file mode 100644 index e1df9f4851..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3375.xml +++ /dev/null @@ -1,150 +0,0 @@ - - - PagingDRX - - 3375 - urn:oma:lwm2m:ext:3375 - 1.0 - 1.0 - Single - Optional - - dlEarfcn - R - Single - Mandatory - Integer - - - - - pci - R - Single - Mandatory - Integer - - - - - pagingCycle - R - Single - Mandatory - Integer - - - - - DrxNb - R - Single - Mandatory - Integer - - - - - ueID - R - Single - Mandatory - Integer - - - - - drxSysFrameNumOffset - R - Single - Mandatory - Integer - - - - - drxSubFrameNumOffset - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3376.xml b/common/transport/lwm2m/src/main/resources/models/3376.xml deleted file mode 100644 index 542f816da0..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3376.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - txPowerBackOffEvent - - 3376 - urn:oma:lwm2m:ext:3376 - 1.0 - 1.0 - Single - Optional - - TxPowerBackoff - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3377.xml b/common/transport/lwm2m/src/main/resources/models/3377.xml deleted file mode 100644 index 515eb36439..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3377.xml +++ /dev/null @@ -1,168 +0,0 @@ - - - Message3Report - - 3377 - urn:oma:lwm2m:ext:3377 - 1.0 - 1.0 - Single - Optional - - tpc - R - Single - Mandatory - Integer - - - - - resourceIndicatorValue - R - Single - Mandatory - Integer - - - - - cqi - R - Single - Mandatory - Integer - - - - - uplinkDelay - R - Single - Mandatory - Boolean - - - - - hoppingEnabled - R - Single - Mandatory - Boolean - - - - - numRb - R - Single - Mandatory - Integer - - - - - transportBlockSizeIndex - R - Single - Mandatory - Integer - - - - - ModulationType - R - Single - Mandatory - Integer - - - - - redundancyVersionIndex - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3378.xml b/common/transport/lwm2m/src/main/resources/models/3378.xml deleted file mode 100644 index 0855f5798a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3378.xml +++ /dev/null @@ -1,115 +0,0 @@ - - - PbchDecodingResults - - 3378 - urn:oma:lwm2m:ext:3378 - 1.0 - 1.0 - Single - Optional - - servingCellID - R - Single - Mandatory - Integer - - - - - crcResult - R - Single - Mandatory - Boolean - - - - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3379.xml b/common/transport/lwm2m/src/main/resources/models/3379.xml deleted file mode 100644 index 0ac1648961..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3379.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - pucchPowerControl - - 3379 - urn:oma:lwm2m:ext:3379 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - pucchTxPowerValue - - Single - Mandatory - Integer - - - - - dlPathLoss - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3380-2_0.xml b/common/transport/lwm2m/src/main/resources/models/3380-2_0.xml deleted file mode 100644 index 27545a6345..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3380-2_0.xml +++ /dev/null @@ -1,204 +0,0 @@ - - - PrachReport - - 3380 - urn:oma:lwm2m:ext:3380:2.0 - 1.0 - 2.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - rachTxPower - R - Single - Mandatory - Integer - - - - - zadOffSeqNum - R - Single - Mandatory - Integer - - - - - prachConfig - R - Single - Mandatory - Integer - - - - - preambleFormat - R - Single - Mandatory - Integer - - - - - maxTransmissionMsg3 - R - Single - Mandatory - Integer - - - - - raResponseWindowSize - R - Single - Mandatory - Integer - - - - - RachRequestResult - R - Single - Mandatory - Boolean - - - - - ce_mode - R - Single - Mandatory - Integer - - - - - ce_level - R - Single - Mandatory - Integer - - - - - num_prach_repetition - R - Single - Mandatory - Integer - - - - - prach_repetition_seq - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3381.xml b/common/transport/lwm2m/src/main/resources/models/3381.xml deleted file mode 100644 index db2e4d52e8..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3381.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - VolteCallEvent - - 3381 - urn:oma:lwm2m:ext:3381 - 1.0 - 1.0 - Single - Optional - - callStatus - R - Single - Mandatory - Integer - - - - - callType - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3382.xml b/common/transport/lwm2m/src/main/resources/models/3382.xml deleted file mode 100644 index 8f066837c8..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3382.xml +++ /dev/null @@ -1,108 +0,0 @@ - - - SipRegistrationEvent - - 3382 - urn:oma:lwm2m:ext:3382 - 1.0 - 1.0 - Single - Optional - - registrationType - R - Single - Mandatory - Integer - - - - - registrationResult - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3383.xml b/common/transport/lwm2m/src/main/resources/models/3383.xml deleted file mode 100644 index 663ac45faa..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3383.xml +++ /dev/null @@ -1,99 +0,0 @@ - - - sipPublishEvent - - 3383 - urn:oma:lwm2m:ext:3383 - 1.0 - 1.0 - Single - Optional - - publishResult - R - Single - Mandatory - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3384.xml b/common/transport/lwm2m/src/main/resources/models/3384.xml deleted file mode 100644 index a18c6b910b..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3384.xml +++ /dev/null @@ -1,112 +0,0 @@ - - - sipSubscriptionEvent - - 3384 - urn:oma:lwm2m:ext:3384 - 1.0 - 1.0 - Single - Optional - - eventType - R - Single - Mandatory - Integer - - - - - subscriptionResult - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3385.xml b/common/transport/lwm2m/src/main/resources/models/3385.xml deleted file mode 100644 index cc0a99182a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3385.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - volteCallStateChangeEvent - - 3385 - urn:oma:lwm2m:ext:3385 - 1.0 - 1.0 - Single - Optional - - callStatus - R - Single - Mandatory - Integer - - - - - VolteCallStateChangeCause - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/3386.xml b/common/transport/lwm2m/src/main/resources/models/3386.xml deleted file mode 100644 index 43937efadb..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/3386.xml +++ /dev/null @@ -1,105 +0,0 @@ - - - VoLTErtpPacketLoss - 1]]> - 3386 - urn:oma:lwm2m:ext:3386 - 1.0 - 1.0 - Single - Optional - - ssrc - R - Single - Mandatory - Integer - - - - - packetsLost - R - Single - Mandatory - Integer - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_APN_Connection_Profile-v1_0_1.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_APN_Connection_Profile-v1_0_1.xml deleted file mode 100644 index 924e822fc6..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_APN_Connection_Profile-v1_0_1.xml +++ /dev/null @@ -1,324 +0,0 @@ - - - - - LWM2M APN Connection Profile - - 11 - - urn:oma:lwm2m:oma:11 - 1.0 - 1.0 - Multiple - Optional - - Profile name - RW - Single - Mandatory - String - - - - - APN - RW - Single - Optional - String - - - - - Auto select APN by device - RW - Single - Optional - Boolean - - - - - Enable status - RW - Single - Optional - Boolean - - - - - Authentication Type - RW - Single - Mandatory - Integer - - - - - User Name - RW - Single - Optional - String - - - - - Secret - RW - Single - Optional - String - - - - - Reconnect Schedule - RW - Single - Optional - String - - - - - Validity (MCC, MNC) - RW - Multiple - Optional - String - - - - - Connection establishment time (1) - R - Multiple - Optional - Time - - - - - Connection establishment result (1) - R - Multiple - Optional - Integer - - - - - - Connection establishment reject cause (1) - R - Multiple - Optional - Integer - 0..111 - - - - Connection end time (1) - R - Multiple - Optional - Time - - - - - TotalBytesSent - R - Single - Optional - Integer - - - - - TotalBytesReceived - R - Single - Optional - Integer - - - - - IP address (2) - RW - Multiple - Optional - String - - - - - Prefix length(2) - RW - Multiple - Optional - String - - - - - Subnet mask (2) - RW - Multiple - Optional - String - - - - - Gateway (2) - RW - Multiple - Optional - String - - - - - Primary DNS address (2) - RW - Multiple - Optional - String - - - - - Secondary DNS address (2) - RW - Multiple - Optional - String - - - - - QCI (3) - R - Single - Optional - Integer - 1..9 - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - TotalPacketsSent - R - Single - Optional - Integer - - - - - PDN Type - RW - Single - Optional - Integer - - - - - - APN Rate Control - R - Single - Optional - Integer - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_Bearer_Selection-v1_0_1.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_Bearer_Selection-v1_0_1.xml deleted file mode 100644 index 307df73553..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_Bearer_Selection-v1_0_1.xml +++ /dev/null @@ -1,211 +0,0 @@ - - - - - LWM2M Bearer Selection - - 13 - urn:oma:lwm2m:oma:13 - 1.0 - 1.0 - Single - Optional - - Preferred Communications Bearer - RW - Multiple - Optional - Integer - 8 bit - - - - Acceptable RSSI (GSM) - RW - Single - Optional - Integer - - - - - Acceptable RSCP (UMTS) - RW - Single - Optional - Integer - - - - - Acceptable RSRP (LTE) - RW - Single - Optional - Integer - - - - - Acceptable RSSI (1xEV-DO) - RW - Single - Optional - Integer - - - - - Cell lock list - RW - Single - Optional - String - - - - - Operator list - RW - Single - Optional - String - - - - - Operator list mode - RW - Single - Optional - Boolean - - - - - List of available PLMNs - R - Single - Optional - String - - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - Acceptable RSRP (NB-IoT) - RW - Single - Optional - Integer - - - - - Higher Priority PLMN Search Timer - RW - Single - Optional - Integer - - - - - Attach without PDN connection - RW - Single - Optional - Boolean - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_Cellular_Connectivity-v1_0_1.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_Cellular_Connectivity-v1_0_1.xml deleted file mode 100644 index 45499202ba..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_Cellular_Connectivity-v1_0_1.xml +++ /dev/null @@ -1,185 +0,0 @@ - - - - - - LWM2M Cellular Connectivity - - 10 - urn:oma:lwm2m:oma:10 - 1.0 - 1.0 - Single - Optional - - SMSC address - RW - Single - Optional - String - - - - - Disable radio period - RW - Single - Optional - Integer - 0..65535 - - 0 the device SHALL disconnect. When the period has elapsed the device MAY reconnect.]]> - - Module activation code - RW - Single - Optional - String - - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - PSM Timer (1) - RW - Single - Optional - Integer - - s - - - Active Timer (1) - RW - Single - Optional - Integer - - s - - - Serving PLMN Rate control - R - Single - Optional - Integer - - - - - eDRX parameters for Iu mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - eDRX parameters for WB-S1 mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - eDRX parameters for NB-S1 mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - eDRX parameters for A/Gb mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - Activated Profile Names - R - Multiple - Mandatory - Objlnk - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml deleted file mode 100644 index 28957f5a5d..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml +++ /dev/null @@ -1,208 +0,0 @@ - - - - - Connectivity Monitoring - - This LwM2M Object enables monitoring of parameters related to network connectivity. In this general connectivity Object, the Resources are limited to the most general cases common to most network bearers. It is recommended to read the description, which refers to relevant standard development organizations (e.g. 3GPP, IEEE). The goal of the Connectivity Monitoring Object is to carry information reflecting the more up to date values of the current connection for monitoring purposes. Resources such as Link Quality, Radio Signal Strength, Cell ID are retrieved during connected mode at least for cellular networks. - - 4 - urn:oma:lwm2m:oma:4 - 1.0 - 1.0 - Single - Optional - - - Network Bearer - R - Single - Mandatory - Integer - 0-50 - - - Indicates the network bearer used for the current LwM2M communication session from the network bearer list below. The number range is split into three categories: 0 - 20 are Cellular Bearers 21 - 40 are Wireless Bearers 41 - 50 are Wireline Bearers More specifically: 0: GSM cellular network 1: TD-SCDMA cellular network 2: WCDMA cellular network 3: CDMA2000 cellular network 4: WiMAX cellular network 5: LTE-TDD cellular network 6: LTE-FDD cellular network 7: NB-IoT 8 - 20: Reserved for other types of cellular network 21: WLAN network 22: Bluetooth network 23: IEEE 802.15.4 network 24 - 40: Reserved for other types of local wireless network 41: Ethernet 42: DSL 43: PLC 44 - 50: reserved for other types of wireline networks. - - - - Available Network Bearer - R - Multiple - Mandatory - Integer - 0-50 - - - Indicates a list of current available network bearer. Each Resource Instance has a value from the network bearer list. - - - - Radio Signal Strength - R - Single - Mandatory - Integer - - dBm - - Indicates the average value of the received signal strength indication used in the current network bearer (as indicated by Resource 0 of this Object). For the following network bearers the signal strength parameters indicated below are represented by this resource: GSM: RSSI UMTS: RSCP LTE: RSRP NB-IoT: NRSRP For more details on Network Measurement Report, refer to the appropriate Cellular or Wireless Network standards, (e.g. for LTE Cellular Network refer to 3GPP TS 36.133 specification). - - - - Link Quality - R - Single - Optional - Integer - - - - This contains received link quality e.g. LQI for IEEE 802.15.4 (range 0...255), RxQual Downlink for GSM (range 0...7, refer to [3GPP 44.018] for more details on Network Measurement Report encoding), RSRQ for LTE, (refer to [3GPP 36.214]), NRSRQ for NB-IoT (refer to [3GPP 36.214]). - - - - IP Addresses - R - Multiple - Mandatory - String - - - - The IP addresses assigned to the connectivity interface. (e.g. IPv4, IPv6, etc.) - - - - Router IP Addresses - R - Multiple - Optional - String - - - - The IP address of the next-hop IP router, on each of the interfaces specified in resource 4 (IP Addresses). Note: This IP Address doesn’t indicate the Server IP address. - - - - Link Utilization - R - Single - Optional - Integer - 0-100 - % - - The percentage indicating the average utilization of the link to the next-hop IP router. - - - - APN - R - Multiple - Optional - String - - - - Access Point Name in case Network Bearer Resource is a Cellular Network. - - - - Cell ID - R - Single - Optional - Integer - - - - Serving Cell ID in case Network Bearer Resource is a Cellular Network. As specified in TS [3GPP 23.003] and in [3GPP. 24.008]. Range (0...65535) in GSM/EDGE UTRAN Cell ID has a length of 28 bits. Cell Identity in WCDMA/TD-SCDMA. Range: (0...268435455). LTE Cell ID has a length of 28 bits. Parameter definitions in [3GPP 25.331]. - - - - SMNC - R - Single - Optional - Integer - 0-999 - % - - Serving Mobile Network Code. This is applicable when the Network Bearer Resource value is referring to a cellular network. As specified in TS [3GPP 23.003]. - - - - SMCC - R - Single - Optional - Integer - 0-999 - - - Serving Mobile Country Code. This is applicable when the Network Bearer Resource value is referring to a cellular network. As specified in TS [3GPP 23.003]. - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_DevCapMgmt-v1_0.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_DevCapMgmt-v1_0.xml deleted file mode 100644 index 6569894e18..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_DevCapMgmt-v1_0.xml +++ /dev/null @@ -1,174 +0,0 @@ - - - - - - - DevCapMgmt - - 15 - urn:oma:lwm2m:oma:15 - Multiple - Optional - - Property - R - Single - Mandatory - String - - - - - Group - R - Single - Mandatory - Integer - 0-15 - - - - Description - R - Single - Optional - String - - - - - Attached - R - Single - Optional - Boolean - - - - - Enabled - R - Single - Mandatory - Boolean - - - - - opEnable - E - Single - Mandatory - - - - - - opDisable - E - Multiple - Mandatory - - - - - - NotifyEn - RW - Single - Optional - Boolean - - - - - - - \ No newline at end of file diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_LOCKWIPE-v1_0_1.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_LOCKWIPE-v1_0_1.xml deleted file mode 100644 index 912add1a0a..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_LOCKWIPE-v1_0_1.xml +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - - Lock and Wipe - - 8 - urn:oma:lwm2m:oma:8 - Single - Optional - - State - RW - Single - Mandatory - Integer - 0-2 - - - - Lock target - W - Multiple - Mandatory - String - - - - - Wipe item - R - Multiple - Optional - String - - - - - Wipe - E - Single - Mandatory - - - - - - - Wipe target - W - Multiple - Mandatory - String - - - - Lock or Wipe Operation Result - R - Single - Mandatory - Integer - 0-8 - - - - - - \ No newline at end of file diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_Portfolio-v1_0.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_Portfolio-v1_0.xml deleted file mode 100644 index 8147fc64a2..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_Portfolio-v1_0.xml +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - - Portfolio - - 16 - urn:oma:lwm2m:oma:161.0 - 1.0Multiple - Optional - - Identity - RW - Multiple - Mandatory - String - - - - - GetAuthData - E - Single - Optional - - - - - - AuthData - R - Multiple - Optional - Opaque - - - - - AuthStatus - R - Single - Optional - Integer - [0-2] - - - - - - \ No newline at end of file diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Component-v1_0.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Component-v1_0.xml deleted file mode 100644 index 2cbdc8b76b..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Component-v1_0.xml +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - - LWM2M Software Component - - 14 - urn:oma:lwm2m:oma:14 - Multiple - Optional - - - Component Identity - R - Single - Optional - String - 0-255 bytes - - - - - Component Pack - R - Single - Optional - Opaque - - - - - - Component Version - R - Single - Optional - String - 0-255 bytes - - - - - Activate - E - Single - Optional - - - - - - - Deactivate - E - Single - Optional - - - - - - Activation State - R - Single - Optional - Boolean - - - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Management-v1_0.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Management-v1_0.xml deleted file mode 100644 index 33d9a62f4c..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_Software_Management-v1_0.xml +++ /dev/null @@ -1,279 +0,0 @@ - - - - - - - LWM2M Software Management - - 9 - urn:oma:lwm2m:oma:9 - Multiple - Optional - - - PkgName - R - Single - Mandatory - String - 0-255 bytes - - - - - PkgVersion - R - Single - Mandatory - String - 0-255 bytes - - - - - Package - W - Single - Optional - Opaque - - - - - - Package URI - W - Single - Optional - String - 0-255 bytes - - - - - Install - E - Single - Mandatory - - - - - - Checkpoint - R - Single - Optional - Objlnk - - - - - Uninstall - E - Single - Mandatory - - - - - - Update State - R - Single - Mandatory - Integer - 0-4 - - - - Update Supported Objects - RW - Single - Optional - Boolean - - - - - Update Result - R - Single - Mandatory - Integer - 0-200 - - - - Activate - E - Single - Mandatory - - - - - - Deactivate - E - Single - Mandatory - - - - - - Activation State - R - Single - Mandatory - Boolean - - - - - Package Settings - RW - Single - Optional - Objlnk - - - - - User Name - W - Single - Optional - String - 0-255 bytes - - - - Password - W - Single - Optional - String - 0-255 bytes - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LWM2M_WLAN_connectivity4-v1_0.xml b/common/transport/lwm2m/src/main/resources/models/LWM2M_WLAN_connectivity4-v1_0.xml deleted file mode 100644 index 71252b2b5c..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LWM2M_WLAN_connectivity4-v1_0.xml +++ /dev/null @@ -1,572 +0,0 @@ - - - - - - - WLAN connectivity - - 12 - urn:oma:lwm2m:oma:12 - - - Multiple - Optional - - Interface name - RW - Single - Mandatory - String - - - - - Enable - RW - Single - Mandatory - Boolean - - - - - Radio Enabled - RW - Single - Optional - Integer - - - - - Status - R - Single - Mandatory - Integer - - - - - BSSID - R - Single - Mandatory - String - 12 bytes - - - - SSID - RW - Single - Mandatory - String - 1-32 Bytes - - - - Broadcast SSID - RW - Single - Optional - Boolean - - - - - Beacon Enabled - RW - Single - Optional - Boolean - - - - - Mode - RW - Single - Mandatory - Integer - - - - - Channel - RW - Single - Mandatory - Integer - 0-255 - - - - Auto Channel - RW - Single - Optional - Boolean - - - - - Supported Channels - RW - Multiple - Optional - Integer - - - - - Channels In Use - RW - Multiple - Optional - Integer - - - - - Regulatory Domain - RW - Single - Optional - String - 3 Bytes - - - - Standard - RW - Single - Mandatory - Integer - - - - - Authentication Mode - RW - Single - Mandatory - Integer - - - - - Encryption Mode - RW - Single - Optional - Integer - - - - - WPA Pre Shared Key - W - Single - Optional - String - 64 Bytes - - - - WPA Key Phrase - W - Single - Optional - String - 1-64 Bytes - - - - WEP Encryption Type - RW - Single - Optional - Integer - - - - - WEP Key Index - RW - Single - Optional - Integer - [1:4] - - - - WEP Key Phrase - W - Single - Optional - String - 1-64 Bytes - - - - WEP Key 1 - W - Single - Optional - String - 0 or 26 Bytes - - - - WEP Key 2 - W - Single - Optional - String - 0 or 26 Bytes - - - - WEP Key 3 - W - Single - Optional - String - 10 or 26 Bytes - - - - WEP Key 4 - W - Single - Optional - String - 10 or 26 Bytes - - - - RADIUS Server - RW - Single - Optional - String - 1-256 Bytes - - - - RADIUS Server Port - RW - Single - Optional - Integer - - - - - RADIUS Secret - W - Single - Optional - String - 1-256 Bytes - - - - WMM Supported - R - Single - Optional - Boolean - - - - - WMM Enabled - RW - Single - Optional - Boolean - - - - - MAC Control Enabled - RW - Single - Optional - Boolean - - - - - MAC Address List - RW - Multiple - Optional - String - 12 Bytes - - - - Total Bytes Sent - R - Single - Optional - Integer - - - - - Total Bytes Received - R - Single - Optional - Integer - - - - - Total Packets Sent - R - Single - Optional - Integer - - - - - Total Packets Received - R - Single - Optional - Integer - - - - - Transmit Errors - R - Single - Optional - Integer - - - - - Receive Errors - R - Single - Optional - Integer - - - - - Unicast Packets Sent - R - Single - Optional - Integer - - - - - Unicast Packets Received - R - Single - Optional - Integer - - - - - Multicast Packets Received - R - Single - Optional - Integer - - - - - Multicast Packets Received - R - Single - Optional - Integer - - - - - Broadcast Packets Sent - R - Single - Optional - Integer - - - - - 44 Broadcast Packets Received - R - Single - Optional - Integer - - - - - Discard Packets Sent - R - Single - Optional - Integer - - - - - Discard Packets Received - R - Single - Optional - Integer - - - - - Unknown Packets Received - R - Single - Optional - Integer - - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - - - \ No newline at end of file diff --git a/common/transport/lwm2m/src/main/resources/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml b/common/transport/lwm2m/src/main/resources/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml deleted file mode 100644 index b111d3b321..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml +++ /dev/null @@ -1,147 +0,0 @@ - - - - - BinaryAppDataContainer - - 19 - urn:oma:lwm2m:oma:19 - 1.0 - 1.0 - Multiple - Optional - - Data - RW - - - - Multiple - Mandatory - Opaque - - - - - Data Priority - RW - Single - Optional - Integer - 1 bytes - - - - Data Creation Time - RW - Single - Optional - Time - - - - - Data Description - RW - Single - Optional - String - 32 bytes - - - - Data Format - RW - Single - Optional - String - 32 bytes - - - - App ID - RW - Single - Optional - Integer - 2 bytes - - - - - - diff --git a/common/transport/lwm2m/src/main/resources/models/LwM2M_EventLog-V1_0.xml b/common/transport/lwm2m/src/main/resources/models/LwM2M_EventLog-V1_0.xml deleted file mode 100644 index 7cc3f918b2..0000000000 --- a/common/transport/lwm2m/src/main/resources/models/LwM2M_EventLog-V1_0.xml +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - - - Event Log - - 20 - urn:oma:lwm2m:oma:20 - 1.0 - 1.0 - Single - Optional - - LogClass - RW - Single - Optional - Integer - 255 - - - - LogStart - E - Single - Optional - - - - - - LogStop - E - Single - Optional - - - - - - LogStatus - R - Single - Optional - Integer - 8-Bits - - - - LogData - R - Single - Mandatory - Opaque - - - - - LogDataFormat - RW - Single - Optional - Integer - 255 - - - - - - \ No newline at end of file diff --git a/common/transport/mqtt/src/main/java/org/thingsboard/server/transport/mqtt/session/GatewayDeviceSessionCtx.java b/common/transport/mqtt/src/main/java/org/thingsboard/server/transport/mqtt/session/GatewayDeviceSessionCtx.java index 7ef9fd0ac2..da93405e63 100644 --- a/common/transport/mqtt/src/main/java/org/thingsboard/server/transport/mqtt/session/GatewayDeviceSessionCtx.java +++ b/common/transport/mqtt/src/main/java/org/thingsboard/server/transport/mqtt/session/GatewayDeviceSessionCtx.java @@ -102,5 +102,4 @@ public class GatewayDeviceSessionCtx extends MqttDeviceAwareSessionContext imple public void onToServerRpcResponse(TransportProtos.ToServerRpcResponseMsg toServerResponse) { // This feature is not supported in the TB IoT Gateway yet. } - } diff --git a/common/transport/pom.xml b/common/transport/pom.xml index e4d8272742..22b17989c9 100644 --- a/common/transport/pom.xml +++ b/common/transport/pom.xml @@ -39,7 +39,6 @@ mqtt http coap - lwm2m diff --git a/common/transport/transport-api/pom.xml b/common/transport/transport-api/pom.xml index 2f49201538..d61963053e 100644 --- a/common/transport/transport-api/pom.xml +++ b/common/transport/transport-api/pom.xml @@ -111,12 +111,6 @@ com.google.protobuf protobuf-java - - org.eclipse.leshan - leshan-core - 1.0.1 - compile - diff --git a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/SessionMsgListener.java b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/SessionMsgListener.java index ecafecadc4..9eb0fbcd6c 100644 --- a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/SessionMsgListener.java +++ b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/SessionMsgListener.java @@ -23,7 +23,6 @@ import org.thingsboard.server.gen.transport.TransportProtos.AttributeUpdateNotif import org.thingsboard.server.gen.transport.TransportProtos.GetAttributeResponseMsg; import org.thingsboard.server.gen.transport.TransportProtos.SessionCloseNotificationProto; import org.thingsboard.server.gen.transport.TransportProtos.ToDeviceRpcRequestMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ToTransportUpdateCredentialsProto; import java.util.Optional; @@ -42,8 +41,6 @@ public interface SessionMsgListener { void onToServerRpcResponse(ToServerRpcResponseMsg toServerResponse); - default void onToTransportUpdateCredentials(ToTransportUpdateCredentialsProto toTransportUpdateCredentials){} - default void onDeviceProfileUpdate(TransportProtos.SessionInfoProto newSessionInfo, DeviceProfile deviceProfile) { } diff --git a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/TransportService.java b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/TransportService.java index cec9eba5a1..980aa33221 100644 --- a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/TransportService.java +++ b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/TransportService.java @@ -19,14 +19,11 @@ import org.thingsboard.server.common.data.DeviceProfile; import org.thingsboard.server.common.data.DeviceTransportType; import org.thingsboard.server.common.transport.auth.GetOrCreateDeviceFromGatewayResponse; import org.thingsboard.server.common.transport.auth.ValidateDeviceCredentialsResponse; -import org.thingsboard.server.gen.transport.TransportProtos; import org.thingsboard.server.gen.transport.TransportProtos.ClaimDeviceMsg; import org.thingsboard.server.gen.transport.TransportProtos.GetAttributeRequestMsg; import org.thingsboard.server.gen.transport.TransportProtos.GetEntityProfileRequestMsg; import org.thingsboard.server.gen.transport.TransportProtos.GetEntityProfileResponseMsg; import org.thingsboard.server.gen.transport.TransportProtos.GetOrCreateDeviceFromGatewayRequestMsg; -import org.thingsboard.server.gen.transport.TransportProtos.LwM2MRequestMsg; -import org.thingsboard.server.gen.transport.TransportProtos.LwM2MResponseMsg; import org.thingsboard.server.gen.transport.TransportProtos.PostAttributeMsg; import org.thingsboard.server.gen.transport.TransportProtos.PostTelemetryMsg; import org.thingsboard.server.gen.transport.TransportProtos.ProvisionDeviceRequestMsg; @@ -39,8 +36,6 @@ import org.thingsboard.server.gen.transport.TransportProtos.SubscriptionInfoProt import org.thingsboard.server.gen.transport.TransportProtos.ToDeviceRpcResponseMsg; import org.thingsboard.server.gen.transport.TransportProtos.ToServerRpcRequestMsg; import org.thingsboard.server.gen.transport.TransportProtos.ValidateBasicMqttCredRequestMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceCredentialsResponseMsg; -import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceLwM2MCredentialsRequestMsg; import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceTokenRequestMsg; import org.thingsboard.server.gen.transport.TransportProtos.ValidateDeviceX509CertRequestMsg; @@ -60,20 +55,12 @@ public interface TransportService { void process(DeviceTransportType transportType, ValidateDeviceX509CertRequestMsg msg, TransportServiceCallback callback); - void process(ValidateDeviceLwM2MCredentialsRequestMsg msg, - TransportServiceCallback callback); - void process(GetOrCreateDeviceFromGatewayRequestMsg msg, TransportServiceCallback callback); void process(ProvisionDeviceRequestMsg msg, TransportServiceCallback callback); - void onProfileUpdate(DeviceProfile deviceProfile); - - void process(LwM2MRequestMsg msg, - TransportServiceCallback callback); - void process(SessionInfoProto sessionInfo, SessionEventMsg msg, TransportServiceCallback callback); void process(SessionInfoProto sessionInfo, PostTelemetryMsg msg, TransportServiceCallback callback); diff --git a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigBootstrap.java b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigBootstrap.java deleted file mode 100644 index 2e8a00bc5e..0000000000 --- a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigBootstrap.java +++ /dev/null @@ -1,96 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.common.transport.lwm2m; - -import lombok.Getter; -import lombok.Setter; -import lombok.extern.slf4j.Slf4j; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; -import org.thingsboard.server.gen.transport.TransportProtos; - -import java.security.PublicKey; -import java.security.cert.X509Certificate; -import java.util.Map; - -@Slf4j -@Component -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true') || '${service.type:null}'=='monolith' || '${service.type:null}'=='tb-core'") -public class LwM2MTransportConfigBootstrap { - - - @Getter - @Value("${transport.lwm2m.bootstrap.bind_address:}") - private String bootstrapHost; - - @Getter - @Value("${transport.lwm2m.bootstrap.bind_port:}") - private Integer bootstrapPort; - - @Getter - @Value("${transport.lwm2m.bootstrap.bind_port_cert:}") - private Integer bootstrapPortCert; - - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.start_all:}") - private boolean bootstrapStartAll; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.dtls_mode:}") - private Integer bootStrapDtlsMode; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.bind_address:}") - private String bootstrapSecureHost; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.bind_port:}") - private Integer bootstrapSecurePort; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.bind_port_cert:}") - private Integer bootstrapSecurePortCert; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.public_x:}") - private String bootstrapPublicX; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.public_y:}") - private String bootstrapPublicY; - - @Getter - @Setter - private PublicKey bootstrapPublicKey; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.private_s:}") - private String bootstrapPrivateS; - - @Getter - @Value("${transport.lwm2m.bootstrap.secure.alias:}") - private String bootstrapAlias; - - @Getter - @Setter - private X509Certificate bootstrapCertificate; - - @Getter - @Setter - private Map sessions; -} diff --git a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigServer.java b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigServer.java deleted file mode 100644 index d8f305a049..0000000000 --- a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/lwm2m/LwM2MTransportConfigServer.java +++ /dev/null @@ -1,241 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.common.transport.lwm2m; - -import lombok.Getter; -import lombok.Setter; -import lombok.extern.slf4j.Slf4j; -import org.eclipse.leshan.core.model.ObjectLoader; -import org.eclipse.leshan.core.model.ObjectModel; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; -import org.springframework.stereotype.Component; - -import javax.annotation.PostConstruct; -import java.io.*; -import java.nio.file.Path; -import java.nio.file.Paths; -import java.security.KeyStore; -import java.security.KeyStoreException; -import java.security.NoSuchAlgorithmException; -import java.security.cert.CertificateException; -import java.util.List; - -@Slf4j -@Component -@ConditionalOnExpression("('${service.type:null}'=='tb-transport' && '${transport.lwm2m.enabled:false}'=='true') || '${service.type:null}'=='monolith' || '${service.type:null}'=='tb-core'") -public class LwM2MTransportConfigServer { - - @Getter - @Value("${transport.lwm2m.timeout:}") - private Long timeout; - - @Getter - @Value("${transport.sessions.report_timeout}") - private long sessionReportTimeout; - - @Getter - private String MODEL_PATH_DEFAULT = "models"; - - @Getter - private String KEY_STORE_DEFAULT_RESOURCE_PATH = "credentials"; - - @Getter - private String KEY_STORE_DEFAULT_FILE = "serverKeyStore.jks"; - - @Getter - private String APP_DIR = "common"; - - @Getter - private String TRANSPORT_DIR = "transport"; - - @Getter - private String LWM2M_DIR = "lwm2m"; - - @Getter - private String SRC_DIR = "src"; - - @Getter - private String MAIN_DIR = "main"; - - @Getter - private String RESOURCES_DIR = "resources"; - - @Getter - private String BASE_DIR_PATH = System.getProperty("user.dir"); - - @Getter - @Value("${transport.lwm2m.model_path_file:}") - private String modelPathFile; - - @Getter -// private String PATH_DATA_MICROSERVICE = "/usr/share/tb-lwm2m-transport/data$"; - private String PATH_DATA = "data"; - - @Getter - @Setter - private List modelsValue; - - @Getter - @Value("${transport.lwm2m.support_deprecated_ciphers_enable:}") - private boolean supportDeprecatedCiphersEnable; - - @Getter - @Value("${transport.lwm2m.secure.key_store_type:}") - private String keyStoreType; - - @Getter - @Value("${transport.lwm2m.secure.key_store_path_file:}") - private String keyStorePathFile; - - @Getter - @Setter - private KeyStore keyStoreValue; - - @Getter - @Value("${transport.lwm2m.secure.key_store_password:}") - private String keyStorePasswordServer; - - @Getter - @Value("${transport.lwm2m.secure.root_alias:}") - private String rootAlias; - - @Getter - @Value("${transport.lwm2m.secure.enable_gen_psk_rpk:}") - private Boolean enableGenPskRpk; - - @Getter - @Value("${transport.lwm2m.server.bind_address:}") - private String serverHost; - - @Getter - @Value("${transport.lwm2m.server.bind_port:}") - private Integer serverPort; - - @Getter - @Value("${transport.lwm2m.server.bind_port_cert:}") - private Integer serverPortCert; - - @Getter - @Value("${transport.lwm2m.server.secure.start_all:}") - private boolean serverStartAll; - - @Getter - @Value("${transport.lwm2m.server.secure.dtls_mode:}") - private Integer serverDtlsMode; - - @Getter - @Value("${transport.lwm2m.server.secure.bind_address:}") - private String serverSecureHost; - - @Getter - @Value("${transport.lwm2m.server.secure.bind_port:}") - private Integer serverSecurePort; - - @Getter - @Value("${transport.lwm2m.server.secure.bind_port_cert:}") - private Integer serverSecurePortCert; - - @Getter - @Value("${transport.lwm2m.server.secure.public_x:}") - private String serverPublicX; - - @Getter - @Value("${transport.lwm2m.server.secure.public_y:}") - private String serverPublicY; - - @Getter - @Value("${transport.lwm2m.server.secure.private_s:}") - private String serverPrivateS; - - @Getter - @Value("${transport.lwm2m.server.secure.alias:}") - private String serverAlias; - - @Getter - @Value("${transport.lwm2m.bootstrap.enable:}") - private Boolean bootstrapEnable; - - @Getter - @Value("${transport.lwm2m.secure.redis_url:}") - private String redisUrl; - - @PostConstruct - public void init() { - modelsValue = ObjectLoader.loadDefault(); - File path = getPathModels(); - if (path.isDirectory()) { - try { - modelsValue.addAll(ObjectLoader.loadObjectsFromDir(path)); - log.info(" [{}] Models directory is a directory", path.getAbsoluteFile()); - } catch (Exception e) { - log.error(" [{}] Could not parse the resource definition file", e.toString()); - } - } else { - log.error(" [{}] Read Models", path.getAbsoluteFile()); - } - getInKeyStore(); - } - - private File getPathModels() { - Path pathModels = (modelPathFile != null && !modelPathFile.isEmpty()) ? Paths.get(modelPathFile) : - (new File(Paths.get(getBaseDirPath(), PATH_DATA, MODEL_PATH_DEFAULT).toUri()).isDirectory()) ? - Paths.get(getBaseDirPath(), PATH_DATA, MODEL_PATH_DEFAULT) : - Paths.get(getBaseDirPath(), APP_DIR, TRANSPORT_DIR, LWM2M_DIR, SRC_DIR, MAIN_DIR, RESOURCES_DIR, MODEL_PATH_DEFAULT); - return (pathModels != null) ? new File(pathModels.toUri()) : null; - } - - private KeyStore getInKeyStore() { - try { - if (keyStoreValue != null && keyStoreValue.size() > 0) - return keyStoreValue; - } catch (KeyStoreException e) { - log.error("Uninitialized keystore [{}]", keyStoreValue.toString()); - } - Path keyStorePath = (keyStorePathFile != null && !keyStorePathFile.isEmpty()) ? Paths.get(keyStorePathFile) : - (new File(Paths.get(getBaseDirPath(), PATH_DATA, KEY_STORE_DEFAULT_RESOURCE_PATH, KEY_STORE_DEFAULT_FILE).toUri()).isFile()) ? - Paths.get(getBaseDirPath(), PATH_DATA, KEY_STORE_DEFAULT_RESOURCE_PATH, KEY_STORE_DEFAULT_FILE) : - Paths.get(getBaseDirPath(), APP_DIR, TRANSPORT_DIR, LWM2M_DIR, SRC_DIR, MAIN_DIR, RESOURCES_DIR, KEY_STORE_DEFAULT_RESOURCE_PATH, KEY_STORE_DEFAULT_FILE); - File keyStoreFile = new File(keyStorePath.toUri()); - if (keyStoreFile.isFile()) { - try { - InputStream inKeyStore = new FileInputStream(keyStoreFile); - keyStoreValue = KeyStore.getInstance(keyStoreType); - keyStoreValue.load(inKeyStore, keyStorePasswordServer == null ? null : keyStorePasswordServer.toCharArray()); - } catch (CertificateException | NoSuchAlgorithmException | IOException | KeyStoreException e) { - log.error("[{}] Unable to load KeyStore files server, folder is not a directory", e.getMessage()); - keyStoreValue = null; - } - log.info("[{}] Load KeyStore files server, folder is a directory", keyStoreFile.getAbsoluteFile()); - } else { - log.error("[{}] Unable to load KeyStore files server, is not a file", keyStoreFile.getAbsoluteFile()); - keyStoreValue = null; - } - return keyStoreValue; - } - - private String getBaseDirPath() { - Path FULL_FILE_PATH; - if (BASE_DIR_PATH.endsWith("bin")) { - FULL_FILE_PATH = Paths.get(BASE_DIR_PATH.replaceAll("bin$", "")); - } else if (BASE_DIR_PATH.endsWith("conf")) { - FULL_FILE_PATH = Paths.get(BASE_DIR_PATH.replaceAll("conf$", "")); - } else { - FULL_FILE_PATH = Paths.get(BASE_DIR_PATH); - } - return FULL_FILE_PATH.toUri().getPath(); - } -} diff --git a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportDeviceProfileCache.java b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportDeviceProfileCache.java index edf0ad2339..b12aab1a8c 100644 --- a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportDeviceProfileCache.java +++ b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportDeviceProfileCache.java @@ -17,40 +17,26 @@ package org.thingsboard.server.common.transport.service; import com.google.protobuf.ByteString; import lombok.extern.slf4j.Slf4j; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.context.annotation.Lazy; +import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; import org.springframework.stereotype.Component; import org.thingsboard.server.common.data.DeviceProfile; -import org.thingsboard.server.common.data.EntityType; import org.thingsboard.server.common.data.id.DeviceProfileId; import org.thingsboard.server.common.transport.TransportDeviceProfileCache; -import org.thingsboard.server.common.transport.TransportService; import org.thingsboard.server.common.transport.util.DataDecodingEncodingService; -import org.thingsboard.server.gen.transport.TransportProtos; import org.thingsboard.server.queue.util.TbTransportComponent; import java.util.Optional; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.locks.Lock; -import java.util.concurrent.locks.ReentrantLock; @Slf4j @Component @TbTransportComponent public class DefaultTransportDeviceProfileCache implements TransportDeviceProfileCache { - private final Lock deviceProfileFetchLock = new ReentrantLock(); private final ConcurrentMap deviceProfiles = new ConcurrentHashMap<>(); - private final DataDecodingEncodingService dataDecodingEncodingService; - - private TransportService transportService; - @Lazy - @Autowired - public void setTransportService(TransportService transportService) { - this.transportService = transportService; - } + private final DataDecodingEncodingService dataDecodingEncodingService; public DefaultTransportDeviceProfileCache(DataDecodingEncodingService dataDecodingEncodingService) { this.dataDecodingEncodingService = dataDecodingEncodingService; @@ -71,7 +57,7 @@ public class DefaultTransportDeviceProfileCache implements TransportDeviceProfil @Override public DeviceProfile get(DeviceProfileId id) { - return this.getDeviceProfile(id); + return deviceProfiles.get(id); } @Override @@ -94,31 +80,4 @@ public class DefaultTransportDeviceProfileCache implements TransportDeviceProfil public void evict(DeviceProfileId id) { deviceProfiles.remove(id); } - - - private DeviceProfile getDeviceProfile(DeviceProfileId id) { - DeviceProfile profile = deviceProfiles.get(id); - if (profile == null) { - deviceProfileFetchLock.lock(); - try { - TransportProtos.GetEntityProfileRequestMsg msg = TransportProtos.GetEntityProfileRequestMsg.newBuilder() - .setEntityType(EntityType.DEVICE_PROFILE.name()) - .setEntityIdMSB(id.getId().getMostSignificantBits()) - .setEntityIdLSB(id.getId().getLeastSignificantBits()) - .build(); - TransportProtos.GetEntityProfileResponseMsg entityProfileMsg = transportService.getEntityProfile(msg); - Optional profileOpt = dataDecodingEncodingService.decode(entityProfileMsg.getData().toByteArray()); - if (profileOpt.isPresent()) { - profile = profileOpt.get(); - this.put(profile); - } else { - log.warn("[{}] Can't device profile: {}", id, entityProfileMsg.getData()); - throw new RuntimeException("Can't device profile!"); - } - } finally { - deviceProfileFetchLock.unlock(); - } - } - return profile; - } } diff --git a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportService.java b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportService.java index 246ad7c7c0..3e619f8d6a 100644 --- a/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportService.java +++ b/common/transport/transport-api/src/main/java/org/thingsboard/server/common/transport/service/DefaultTransportService.java @@ -193,7 +193,6 @@ public class DefaultTransportService implements TransportService { } records.forEach(record -> { try { - log.info("[{}] SessionIdMSB, [{}] SessionIdLSB, records", record.getValue().getSessionIdMSB(), record.getValue().getSessionIdLSB()); processToTransportMsg(record.getValue()); } catch (Throwable e) { log.warn("Failed to process the notification.", e); @@ -268,13 +267,6 @@ public class DefaultTransportService implements TransportService { } @Override - public void process(TransportProtos.ValidateDeviceLwM2MCredentialsRequestMsg msg, TransportServiceCallback callback) { - log.trace("Processing msg: {}", msg); - TbProtoQueueMsg protoMsg = new TbProtoQueueMsg<>(UUID.randomUUID(), TransportApiRequestMsg.newBuilder().setValidateDeviceLwM2MCredentialsRequestMsg(msg).build()); - AsyncCallbackTemplate.withCallback(transportApiRequestTemplate.send(protoMsg), - response -> callback.onSuccess(response.getValue().getValidateCredResponseMsg()), callback::onError, transportCallbackExecutor); - } - public void process(DeviceTransportType transportType, TransportProtos.ValidateDeviceX509CertRequestMsg msg, TransportServiceCallback callback) { log.trace("Processing msg: {}", msg); TbProtoQueueMsg protoMsg = new TbProtoQueueMsg<>(UUID.randomUUID(), TransportApiRequestMsg.newBuilder().setValidateX509CertRequestMsg(msg).build()); @@ -326,15 +318,6 @@ public class DefaultTransportService implements TransportService { AsyncCallbackTemplate.withCallback(response, callback::onSuccess, callback::onError, transportCallbackExecutor); } - @Override - public void process(TransportProtos.LwM2MRequestMsg msg, TransportServiceCallback callback) { - log.trace("Processing msg: {}", msg); - TbProtoQueueMsg protoMsg = new TbProtoQueueMsg<>(UUID.randomUUID(), - TransportApiRequestMsg.newBuilder().setLwM2MRequestMsg(msg).build()); - AsyncCallbackTemplate.withCallback(transportApiRequestTemplate.send(protoMsg), - response -> callback.onSuccess(response.getValue().getLwM2MResponseMsg()), callback::onError, transportCallbackExecutor); - } - private TransportDeviceInfo getTransportDeviceInfo(TransportProtos.DeviceInfoProto di) { TransportDeviceInfo tdi = new TransportDeviceInfo(); tdi.setTenantId(new TenantId(new UUID(di.getTenantIdMSB(), di.getTenantIdLSB()))); @@ -356,7 +339,6 @@ public class DefaultTransportService implements TransportService { AsyncCallbackTemplate.withCallback(response, callback::onSuccess, callback::onError, transportCallbackExecutor); } - @Override public void process(TransportProtos.SessionInfoProto sessionInfo, TransportProtos.SubscriptionInfoProto msg, TransportServiceCallback callback) { if (log.isTraceEnabled()) { @@ -623,9 +605,6 @@ public class DefaultTransportService implements TransportService { if (toSessionMsg.hasSessionCloseNotification()) { listener.onRemoteSessionCloseCommand(toSessionMsg.getSessionCloseNotification()); } - if (toSessionMsg.hasToTransportUpdateCredentialsNotification()) { - listener.onToTransportUpdateCredentials(toSessionMsg.getToTransportUpdateCredentialsNotification()); - } if (toSessionMsg.hasToDeviceRequest()) { listener.onToDeviceRpcRequest(toSessionMsg.getToDeviceRequest()); } @@ -689,7 +668,7 @@ public class DefaultTransportService implements TransportService { } } - public void onProfileUpdate(DeviceProfile deviceProfile) { + private void onProfileUpdate(DeviceProfile deviceProfile) { long deviceProfileIdMSB = deviceProfile.getId().getId().getMostSignificantBits(); long deviceProfileIdLSB = deviceProfile.getId().getId().getLeastSignificantBits(); sessions.forEach((id, md) -> { diff --git a/docker/.env b/docker/.env index f7b30aafe0..b632300d5f 100644 --- a/docker/.env +++ b/docker/.env @@ -8,7 +8,6 @@ WEB_UI_DOCKER_NAME=tb-web-ui MQTT_TRANSPORT_DOCKER_NAME=tb-mqtt-transport HTTP_TRANSPORT_DOCKER_NAME=tb-http-transport COAP_TRANSPORT_DOCKER_NAME=tb-coap-transport -LWM2M_TRANSPORT_DOCKER_NAME=tb-lwm2m-transport TB_VERSION=latest diff --git a/docker/docker-compose.aws-sqs.yml b/docker/docker-compose.aws-sqs.yml index 756ae11249..e58917043b 100644 --- a/docker/docker-compose.aws-sqs.yml +++ b/docker/docker-compose.aws-sqs.yml @@ -68,9 +68,4 @@ services: env_file: - queue-aws-sqs.env depends_on: - - zookeeper - tb-lwm2m-transport: - env_file: - - queue-aws-sqs.env - depends_on: - - zookeeper + - zookeeper \ No newline at end of file diff --git a/docker/docker-compose.confluent.yml b/docker/docker-compose.confluent.yml index e16059ea9a..1bbc3f96d6 100644 --- a/docker/docker-compose.confluent.yml +++ b/docker/docker-compose.confluent.yml @@ -55,6 +55,3 @@ services: tb-coap-transport: env_file: - queue-confluent.env - tb-lwm2m-transport: - env_file: - - queue-confluent.env diff --git a/docker/docker-compose.kafka.yml b/docker/docker-compose.kafka.yml index ba844bac2e..4df63eb8b8 100644 --- a/docker/docker-compose.kafka.yml +++ b/docker/docker-compose.kafka.yml @@ -80,8 +80,3 @@ services: - queue-kafka.env depends_on: - kafka - tb-lwm2m-transport: - env_file: - - queue-kafka.env - depends_on: - - kafka diff --git a/docker/docker-compose.postgres.volumes.yml b/docker/docker-compose.postgres.volumes.yml index 45819c4a66..caaacf96e8 100644 --- a/docker/docker-compose.postgres.volumes.yml +++ b/docker/docker-compose.postgres.volumes.yml @@ -35,9 +35,6 @@ services: tb-coap-transport: volumes: - tb-coap-transport-log-volume:/var/log/tb-coap-transport - tb-lwm2m-transport: - volumes: - - tb-lwm2m-transport-log-volume:/var/log/tb-lwm2m-transport tb-http-transport1: volumes: - tb-http-transport-log-volume:/var/log/tb-http-transport @@ -61,9 +58,6 @@ volumes: tb-coap-transport-log-volume: external: true name: ${TB_COAP_TRANSPORT_LOG_VOLUME} - tb-lwm2m-transport-log-volume: - external: true - name: ${TB_LWM2M_TRANSPORT_LOG_VOLUME} tb-http-transport-log-volume: external: true name: ${TB_HTTP_TRANSPORT_LOG_VOLUME} diff --git a/docker/docker-compose.pubsub.yml b/docker/docker-compose.pubsub.yml index 13f9078b99..93b4047a5d 100644 --- a/docker/docker-compose.pubsub.yml +++ b/docker/docker-compose.pubsub.yml @@ -69,8 +69,3 @@ services: - queue-pubsub.env depends_on: - zookeeper - tb-lwm2m-transport: - env_file: - - queue-pubsub.env - depends_on: - - zookeeper diff --git a/docker/docker-compose.rabbitmq.yml b/docker/docker-compose.rabbitmq.yml index 105833caa3..06662b39b6 100644 --- a/docker/docker-compose.rabbitmq.yml +++ b/docker/docker-compose.rabbitmq.yml @@ -68,9 +68,4 @@ services: env_file: - queue-rabbitmq.env depends_on: - - zookeeper - tb-lwm2m-transport: - env_file: - - queue-rabbitmq.env - depends_on: - - zookeeper + - zookeeper \ No newline at end of file diff --git a/docker/docker-compose.service-bus.yml b/docker/docker-compose.service-bus.yml index f24c0ee55b..01dd863792 100644 --- a/docker/docker-compose.service-bus.yml +++ b/docker/docker-compose.service-bus.yml @@ -67,8 +67,5 @@ services: tb-coap-transport: env_file: - queue-service-bus.env - tb-lwm2m-transport: - env_file: - - queue-service-bus.env depends_on: - - zookeeper + - zookeeper \ No newline at end of file diff --git a/docker/docker-compose.yml b/docker/docker-compose.yml index 36a658b5da..fbb8ee262d 100644 --- a/docker/docker-compose.yml +++ b/docker/docker-compose.yml @@ -199,20 +199,6 @@ services: - ./tb-transports/coap/log:/var/log/tb-coap-transport depends_on: - zookeeper - tb-lwm2m-transport: - restart: always - image: "${DOCKER_REPO}/${LWM2M_TRANSPORT_DOCKER_NAME}:${TB_VERSION}" - ports: - - "5685:5685/udp" - environment: - TB_SERVICE_ID: tb-lwm2m-transport - env_file: - - tb-lwm2m-transport.env - volumes: - - ./tb-transports/lwm2m/conf:/config - - ./tb-transports/lwm2m/log:/var/log/tb-lwm2m-transport - depends_on: - - zookeeper tb-web-ui1: restart: always image: "${DOCKER_REPO}/${WEB_UI_DOCKER_NAME}:${TB_VERSION}" diff --git a/docker/docker-create-log-folders.sh b/docker/docker-create-log-folders.sh index bee0b7809e..1ac4539b30 100755 --- a/docker/docker-create-log-folders.sh +++ b/docker/docker-create-log-folders.sh @@ -19,8 +19,6 @@ mkdir -p tb-node/log/ && sudo chown -R 799:799 tb-node/log/ mkdir -p tb-transports/coap/log && sudo chown -R 799:799 tb-transports/coap/log -mkdir -p tb-transports/lwm2m/log && sudo chown -R 799:799 tb-transports/lwm2m/log - mkdir -p tb-transports/http/log && sudo chown -R 799:799 tb-transports/http/log -mkdir -p tb-transports/mqtt/log && sudo chown -R 799:799 tb-transports/mqtt/log +mkdir -p tb-transports/mqtt/log && sudo chown -R 799:799 tb-transports/mqtt/log \ No newline at end of file diff --git a/docker/tb-lwm2m-transport.env b/docker/tb-lwm2m-transport.env deleted file mode 100644 index 6e6cad922b..0000000000 --- a/docker/tb-lwm2m-transport.env +++ /dev/null @@ -1,6 +0,0 @@ -ZOOKEEPER_ENABLED=true -ZOOKEEPER_URL=zookeeper:2181 - -LWM2M_BIND_ADDRESS=0.0.0.0 -LWM2M_BIND_PORT=5685 -LWM2M_TIMEOUT=10000 diff --git a/docker/tb-transports/lwm2m/conf/logback.xml b/docker/tb-transports/lwm2m/conf/logback.xml deleted file mode 100644 index 199e138fc1..0000000000 --- a/docker/tb-transports/lwm2m/conf/logback.xml +++ /dev/null @@ -1,50 +0,0 @@ - - - - - - - /var/log/tb-lwm2m-transport/${TB_SERVICE_ID}/tb-lwm2m-transport.log - - /var/log/tb-lwm2m-transport/${TB_SERVICE_ID}/tb-lwm2m-transport.%d{yyyy-MM-dd}.%i.log - 100MB - 30 - 3GB - - - %d{ISO8601} [%thread] %-5level %logger{36} - %msg%n - - - - - - %d{ISO8601} [%thread] %-5level %logger{36} - %msg%n - - - - - - - - - - - diff --git a/docker/tb-transports/lwm2m/conf/tb-lwm2m-transport.conf b/docker/tb-transports/lwm2m/conf/tb-lwm2m-transport.conf deleted file mode 100644 index 1ea46cd8bf..0000000000 --- a/docker/tb-transports/lwm2m/conf/tb-lwm2m-transport.conf +++ /dev/null @@ -1,23 +0,0 @@ -# -# Copyright © 2016-2020 The Thingsboard Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -export JAVA_OPTS="$JAVA_OPTS -Xloggc:/var/log/tb-lwm2m-transport/${TB_SERVICE_ID}/gc.log -XX:+IgnoreUnrecognizedVMOptions -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/var/log/tb-lwm2m-transport/${TB_SERVICE_ID}/heapdump.bin -XX:+PrintGCDetails -XX:+PrintGCDateStamps" -export JAVA_OPTS="$JAVA_OPTS -XX:+PrintHeapAtGC -XX:+PrintTenuringDistribution -XX:+PrintGCApplicationStoppedTime -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=10" -export JAVA_OPTS="$JAVA_OPTS -XX:GCLogFileSize=10M -XX:-UseBiasedLocking -XX:+UseTLAB -XX:+ResizeTLAB -XX:+PerfDisableSharedMem -XX:+UseCondCardMark" -export JAVA_OPTS="$JAVA_OPTS -XX:CMSWaitDuration=10000 -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:+CMSParallelInitialMarkEnabled" -export JAVA_OPTS="$JAVA_OPTS -XX:+CMSEdenChunksRecordAlways -XX:CMSInitiatingOccupancyFraction=75 -XX:+UseCMSInitiatingOccupancyOnly -XX:+ExitOnOutOfMemoryError" -export LOG_FILENAME=tb-lwm2m-transport.out -export LOADER_PATH=/usr/share/tb-lwm2m-transport/conf diff --git a/k8s/common/thingsboard.yml b/k8s/common/thingsboard.yml index de8bc71c91..af4ff0d678 100644 --- a/k8s/common/thingsboard.yml +++ b/k8s/common/thingsboard.yml @@ -265,72 +265,6 @@ spec: --- apiVersion: apps/v1 kind: Deployment -metadata: - name: tb-lwm2m-transport - namespace: thingsboard -spec: - replicas: 2 - selector: - matchLabels: - app: tb-lwm2m-transport - template: - metadata: - labels: - app: tb-lwm2m-transport - spec: - volumes: - - name: tb-lwm2m-transport-config - configMap: - name: tb-lwm2m-transport-config - items: - - key: conf - path: tb-lwm2m-transport.conf - - key: logback - path: logback.xml - containers: - - name: server - imagePullPolicy: Always - image: thingsboard/tb-lwm2m-transport:latest - ports: - - containerPort: 5685 - name: lwm2m - protocol: UDP - env: - - name: TB_SERVICE_ID - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: TB_QUEUE_TYPE - value: "kafka" - - name: LWM2M_BIND_ADDRESS - value: "0.0.0.0" - - name: LWM2M_BIND_PORT - value: "5685" - - name: LWM2M_TIMEOUT - value: "10000" - - name: TB_KAFKA_SERVERS - value: "tb-kafka:9092" - volumeMounts: - - mountPath: /config - name: tb-lwm2m-transport-config - restartPolicy: Always ---- -apiVersion: v1 -kind: Service -metadata: - name: tb-lwm2m-transport - namespace: thingsboard -spec: - type: LoadBalancer - selector: - app: tb-lwm2m-transport - ports: - - port: 5685 - name: lwm2m - protocol: UDP ---- -apiVersion: apps/v1 -kind: Deployment metadata: name: tb-web-ui namespace: thingsboard diff --git a/msa/black-box-tests/src/test/java/org/thingsboard/server/msa/ThingsBoardDbInstaller.java b/msa/black-box-tests/src/test/java/org/thingsboard/server/msa/ThingsBoardDbInstaller.java index 981b778016..d661bb7476 100644 --- a/msa/black-box-tests/src/test/java/org/thingsboard/server/msa/ThingsBoardDbInstaller.java +++ b/msa/black-box-tests/src/test/java/org/thingsboard/server/msa/ThingsBoardDbInstaller.java @@ -29,7 +29,6 @@ public class ThingsBoardDbInstaller extends ExternalResource { private final static String POSTGRES_DATA_VOLUME = "tb-postgres-test-data-volume"; private final static String TB_LOG_VOLUME = "tb-log-test-volume"; private final static String TB_COAP_TRANSPORT_LOG_VOLUME = "tb-coap-transport-log-test-volume"; - private final static String TB_LWM2M_TRANSPORT_LOG_VOLUME = "tb-lwm2m-transport-log-test-volume"; private final static String TB_HTTP_TRANSPORT_LOG_VOLUME = "tb-http-transport-log-test-volume"; private final static String TB_MQTT_TRANSPORT_LOG_VOLUME = "tb-mqtt-transport-log-test-volume"; @@ -38,7 +37,6 @@ public class ThingsBoardDbInstaller extends ExternalResource { private final String postgresDataVolume; private final String tbLogVolume; private final String tbCoapTransportLogVolume; - private final String tbLwm2mTransportLogVolume; private final String tbHttpTransportLogVolume; private final String tbMqttTransportLogVolume; private final Map env; @@ -54,7 +52,6 @@ public class ThingsBoardDbInstaller extends ExternalResource { postgresDataVolume = project + "_" + POSTGRES_DATA_VOLUME; tbLogVolume = project + "_" + TB_LOG_VOLUME; tbCoapTransportLogVolume = project + "_" + TB_COAP_TRANSPORT_LOG_VOLUME; - tbLwm2mTransportLogVolume = project + "_" + TB_LWM2M_TRANSPORT_LOG_VOLUME; tbHttpTransportLogVolume = project + "_" + TB_HTTP_TRANSPORT_LOG_VOLUME; tbMqttTransportLogVolume = project + "_" + TB_MQTT_TRANSPORT_LOG_VOLUME; @@ -64,7 +61,6 @@ public class ThingsBoardDbInstaller extends ExternalResource { env.put("POSTGRES_DATA_VOLUME", postgresDataVolume); env.put("TB_LOG_VOLUME", tbLogVolume); env.put("TB_COAP_TRANSPORT_LOG_VOLUME", tbCoapTransportLogVolume); - env.put("TB_LWM2M_TRANSPORT_LOG_VOLUME", tbLwm2mTransportLogVolume); env.put("TB_HTTP_TRANSPORT_LOG_VOLUME", tbHttpTransportLogVolume); env.put("TB_MQTT_TRANSPORT_LOG_VOLUME", tbMqttTransportLogVolume); dockerCompose.withEnv(env); @@ -87,9 +83,6 @@ public class ThingsBoardDbInstaller extends ExternalResource { dockerCompose.withCommand("volume create " + tbCoapTransportLogVolume); dockerCompose.invokeDocker(); - dockerCompose.withCommand("volume create " + tbLwm2mTransportLogVolume); - dockerCompose.invokeDocker(); - dockerCompose.withCommand("volume create " + tbHttpTransportLogVolume); dockerCompose.invokeDocker(); @@ -114,12 +107,11 @@ public class ThingsBoardDbInstaller extends ExternalResource { protected void after() { copyLogs(tbLogVolume, "./target/tb-logs/"); copyLogs(tbCoapTransportLogVolume, "./target/tb-coap-transport-logs/"); - copyLogs(tbLwm2mTransportLogVolume, "./target/tb-lwm2m-transport-logs/"); copyLogs(tbHttpTransportLogVolume, "./target/tb-http-transport-logs/"); copyLogs(tbMqttTransportLogVolume, "./target/tb-mqtt-transport-logs/"); dockerCompose.withCommand("volume rm -f " + postgresDataVolume + " " + tbLogVolume + - " " + tbCoapTransportLogVolume + " " + tbLwm2mTransportLogVolume + " " + tbHttpTransportLogVolume + " " + tbMqttTransportLogVolume); + " " + tbCoapTransportLogVolume + " " + tbHttpTransportLogVolume + " " + tbMqttTransportLogVolume); dockerCompose.invokeDocker(); } diff --git a/msa/tb/README.md b/msa/tb/README.md index 6987c42bfa..488ead2d85 100644 --- a/msa/tb/README.md +++ b/msa/tb/README.md @@ -21,7 +21,7 @@ In this example `thingsboard/tb` image will be used. You can choose any other im Execute the following command to run this docker directly: ` -$ docker run -it -p 9090:9090 -p 1883:1883 -p 5683:5683/udp -p 5685:5685/udp -v ~/.mytb-data:/data --name mytb thingsboard/tb +$ docker run -it -p 9090:9090 -p 1883:1883 -p 5683:5683/udp -v ~/.mytb-data:/data --name mytb thingsboard/tb ` Where: @@ -31,7 +31,6 @@ Where: - `-p 9090:9090` - connect local port 9090 to exposed internal HTTP port 9090 - `-p 1883:1883` - connect local port 1883 to exposed internal MQTT port 1883 - `-p 5683:5683` - connect local port 5683 to exposed internal COAP port 5683 -- `-p 5685:5685` - connect local port 5685 to exposed internal COAP port 5685 (lwm2m) - `-v ~/.mytb-data:/data` - mounts the host's dir `~/.mytb-data` to ThingsBoard DataBase data directory - `--name mytb` - friendly local name of this machine - `thingsboard/tb` - docker image, can be also `thingsboard/tb-postgres` or `thingsboard/tb-cassandra` @@ -46,7 +45,6 @@ Where: > $ VBoxManage controlvm "default" natpf1 "tcp-port9090,tcp,,9090,,9090" > $ VBoxManage controlvm "default" natpf1 "tcp-port1883,tcp,,1883,,1883" > $ VBoxManage controlvm "default" natpf1 "tcp-port5683,tcp,,5683,,5683" -> $ VBoxManage controlvm "default" natpf1 "tcp-port5683,tcp,,5685,,5685" > ``` After executing `docker run` command you can open `http://{your-host-ip}:9090` in you browser (for ex. `http://localhost:9090`). You should see ThingsBoard login page. diff --git a/msa/tb/docker-cassandra/Dockerfile b/msa/tb/docker-cassandra/Dockerfile index 1f01d20ddc..ebb52b0186 100644 --- a/msa/tb/docker-cassandra/Dockerfile +++ b/msa/tb/docker-cassandra/Dockerfile @@ -93,7 +93,6 @@ USER ${pkg.user} EXPOSE 9090 EXPOSE 1883 EXPOSE 5683/udp -EXPOSE 5685/udp VOLUME ["/data"] diff --git a/msa/tb/docker-postgres/Dockerfile b/msa/tb/docker-postgres/Dockerfile index edde576167..0c4ef5ed68 100644 --- a/msa/tb/docker-postgres/Dockerfile +++ b/msa/tb/docker-postgres/Dockerfile @@ -74,7 +74,6 @@ USER ${pkg.user} EXPOSE 9090 EXPOSE 1883 EXPOSE 5683/udp -EXPOSE 5685/udp VOLUME ["/data"] diff --git a/msa/tb/docker-tb/Dockerfile b/msa/tb/docker-tb/Dockerfile index da38870530..6e7d2a294a 100644 --- a/msa/tb/docker-tb/Dockerfile +++ b/msa/tb/docker-tb/Dockerfile @@ -54,7 +54,6 @@ USER ${pkg.user} EXPOSE 9090 EXPOSE 1883 EXPOSE 5683/udp -EXPOSE 5685/udp VOLUME ["/data"] diff --git a/msa/transport/lwm2m/docker/Dockerfile b/msa/transport/lwm2m/docker/Dockerfile deleted file mode 100644 index cb79fb3fda..0000000000 --- a/msa/transport/lwm2m/docker/Dockerfile +++ /dev/null @@ -1,33 +0,0 @@ -# -# Copyright © 2016-2020 The Thingsboard Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -FROM thingsboard/openjdk8 - -COPY start-tb-lwm2m-transport.sh ${pkg.name}.deb /tmp/ - -RUN chmod a+x /tmp/*.sh \ - && mv /tmp/start-tb-lwm2m-transport.sh /usr/bin - -RUN yes | dpkg -i /tmp/${pkg.name}.deb -RUN rm /tmp/${pkg.name}.deb - -RUN systemctl --no-reload disable --now ${pkg.name}.service > /dev/null 2>&1 || : - -RUN chmod 555 ${pkg.installFolder}/bin/${pkg.name}.jar - -USER ${pkg.user} - -CMD ["start-tb-lwm2m-transport.sh"] diff --git a/msa/transport/lwm2m/docker/start-tb-lwm2m-transport.sh b/msa/transport/lwm2m/docker/start-tb-lwm2m-transport.sh deleted file mode 100755 index 7fd12d330e..0000000000 --- a/msa/transport/lwm2m/docker/start-tb-lwm2m-transport.sh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/bash -# -# Copyright © 2016-2020 The Thingsboard Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -CONF_FOLDER="/config" -jarfile=${pkg.installFolder}/bin/${pkg.name}.jar -configfile=${pkg.name}.conf - -source "${CONF_FOLDER}/${configfile}" - -export LOADER_PATH=/config,${LOADER_PATH} - -echo "Starting '${project.name}' ..." - -cd ${pkg.installFolder}/bin - -exec java -cp ${jarfile} $JAVA_OPTS -Dloader.main=org.thingsboard.server.lwm2m.ThingsboardLwm2mTransportApplication \ - -Dspring.jpa.hibernate.ddl-auto=none \ - -Dlogging.config=/config/logback.xml \ - org.springframework.boot.loader.PropertiesLauncher diff --git a/msa/transport/lwm2m/pom.xml b/msa/transport/lwm2m/pom.xml deleted file mode 100644 index 039e50564a..0000000000 --- a/msa/transport/lwm2m/pom.xml +++ /dev/null @@ -1,190 +0,0 @@ - - - 4.0.0 - - org.thingsboard.msa - 3.2.0-SNAPSHOT - transport - - org.thingsboard.msa.transport - lwm2m - pom - - ThingsBoard LWM2M Transport Microservice - https://thingsboard.io - ThingsBoard LWM2M Transport Microservice - - - UTF-8 - ${basedir}/../../.. - tb-lwm2m-transport - tb-lwm2m-transport - /var/log/${pkg.name} - /usr/share/${pkg.name} - - - - - org.thingsboard.transport - lwm2m - ${project.version} - deb - deb - provided - - - - - - - org.apache.maven.plugins - maven-dependency-plugin - - - copy-tb-lwm2m-transport-deb - package - - copy - - - - - org.thingsboard.transport - lwm2m - deb - deb - ${pkg.name}.deb - ${project.build.directory} - - - - - - - - org.apache.maven.plugins - maven-resources-plugin - - - copy-docker-config - process-resources - - copy-resources - - - ${project.build.directory} - - - docker - true - - - - - - - - com.spotify - dockerfile-maven-plugin - - - build-docker-image - pre-integration-test - - build - - - ${dockerfile.skip} - ${docker.repo}/${docker.name} - true - false - ${project.build.directory} - - - - tag-docker-image - pre-integration-test - - tag - - - ${dockerfile.skip} - ${docker.repo}/${docker.name} - ${project.version} - - - - - - - - - push-docker-image - - - push-docker-image - - - - - - com.spotify - dockerfile-maven-plugin - - - push-latest-docker-image - pre-integration-test - - push - - - latest - ${docker.repo}/${docker.name} - - - - push-version-docker-image - pre-integration-test - - push - - - ${project.version} - ${docker.repo}/${docker.name} - - - - - - - - - - - jenkins - Jenkins Repository - https://repo.jenkins-ci.org/releases - - false - - - - - diff --git a/msa/transport/pom.xml b/msa/transport/pom.xml index dff87d168e..5a8b79d9d9 100644 --- a/msa/transport/pom.xml +++ b/msa/transport/pom.xml @@ -38,7 +38,6 @@ mqtt http coap - lwm2m diff --git a/pom.xml b/pom.xml index 74c6037ead..dc7fadf4a9 100755 --- a/pom.xml +++ b/pom.xml @@ -62,9 +62,7 @@ 2.11.3 2.11.3 2.2.6 - 2.2.3 - 1.0.1 - 1.0.0 + 1.0.2 2.6.2 2.3.30 1.6.2 @@ -256,8 +254,7 @@ - ${main.dir}/packaging/${pkg.type}/filters/windows.properties - + ${main.dir}/packaging/${pkg.type}/filters/windows.properties @@ -318,8 +315,7 @@ - ${main.dir}/packaging/${pkg.type}/filters/windows.properties - + ${main.dir}/packaging/${pkg.type}/filters/windows.properties @@ -341,8 +337,7 @@ - ${main.dir}/packaging/${pkg.type}/filters/windows.properties - + ${main.dir}/packaging/${pkg.type}/filters/windows.properties @@ -366,39 +361,9 @@ false - - ../common/transport/lwm2m/src/main/resources - - **/*.xml - **/*.jks - - false - - - - - - copy-lwm2m-resources - ${pkg.process-resources.phase} - - copy-resources - - - ../transport/lwm2m/src/main/data - - - ../common/transport/lwm2m/src/main/resources - - **/*.xml - **/*.jks - - false - - - copy-docker-config ${pkg.process-resources.phase} @@ -763,10 +728,6 @@ **/*.proto.js docker/haproxy/** docker/tb-node/** - src/main/resources/models/*.xml - src/main/resources/credentials/*.jks - src/main/resources/credentials/shell/*.jks - src/main/resources/credentials/shell/*.jks.old ui/** src/browserslist **/*.raw @@ -876,11 +837,6 @@ coap ${project.version} - - org.thingsboard.common.transport - lwm2m - ${project.version} - org.thingsboard dao @@ -1145,21 +1101,6 @@ - - org.eclipse.leshan - leshan-server-cf - ${leshan-server.version} - - - org.eclipse.leshan - leshan-client-cf - ${leshan-client.version} - - - org.eclipse.leshan - leshan-server-redis - ${leshan-server.version} - org.eclipse.californium californium-core diff --git a/rule-engine/rule-engine-api/src/main/java/org/thingsboard/rule/engine/api/msg/DeviceCredentialsUpdateNotificationMsg.java b/rule-engine/rule-engine-api/src/main/java/org/thingsboard/rule/engine/api/msg/DeviceCredentialsUpdateNotificationMsg.java index f34459070e..356fd5db0f 100644 --- a/rule-engine/rule-engine-api/src/main/java/org/thingsboard/rule/engine/api/msg/DeviceCredentialsUpdateNotificationMsg.java +++ b/rule-engine/rule-engine-api/src/main/java/org/thingsboard/rule/engine/api/msg/DeviceCredentialsUpdateNotificationMsg.java @@ -21,8 +21,6 @@ import lombok.ToString; import org.thingsboard.server.common.data.id.DeviceId; import org.thingsboard.server.common.data.id.TenantId; import org.thingsboard.server.common.data.kv.AttributeKey; -import org.thingsboard.server.common.data.security.DeviceCredentials; -import org.thingsboard.server.common.data.security.DeviceCredentialsType; import org.thingsboard.server.common.msg.MsgType; import java.util.Set; @@ -36,12 +34,6 @@ public class DeviceCredentialsUpdateNotificationMsg implements ToDeviceActorNoti private final TenantId tenantId; private final DeviceId deviceId; - /** - * LwM2M - * @return - */ - private final DeviceCredentials deviceCredentials; - @Override public MsgType getMsgType() { return MsgType.DEVICE_CREDENTIALS_UPDATE_TO_DEVICE_ACTOR_MSG; diff --git a/transport/lwm2m/pom.xml b/transport/lwm2m/pom.xml deleted file mode 100644 index 23e037451a..0000000000 --- a/transport/lwm2m/pom.xml +++ /dev/null @@ -1,163 +0,0 @@ - - - 4.0.0 - - org.thingsboard - 3.2.0-SNAPSHOT - transport - - org.thingsboard.transport - lwm2m - jar - - Thingsboard LwM2m Transport Service - https://thingsboard.io - - - UTF-8 - ${basedir}/../.. - java - false - process-resources - package - tb-lwm2m-transport - false - ${project.build.directory}/windows - ThingsBoard LwM2m Transport Service - org.thingsboard.server.lwm2m.ThingsboardLwm2mTransportApplication - - - - - org.eclipse.leshan - leshan-server-cf - - - - org.eclipse.leshan - leshan-client-cf - - - - org.eclipse.leshan - leshan-server-redis - - - - org.springframework.boot - spring-boot-starter-test - test - - - junit - junit - test - - - org.mockito - mockito-all - test - - - org.eclipse.californium - californium-core - ${californium.version} - test-jar - test - - - org.eclipse.californium - element-connector - ${californium.version} - test-jar - test - - - - org.thingsboard.common.transport - lwm2m - - - org.thingsboard.common - queue - - - org.springframework.boot - spring-boot-starter-web - - - com.sun.winsw - winsw - bin - exe - provided - - - - - ${pkg.name}-${project.version} - - - ${project.basedir}/src/main/resources - - - - - org.apache.maven.plugins - maven-resources-plugin - - - org.apache.maven.plugins - maven-dependency-plugin - - - org.apache.maven.plugins - maven-jar-plugin - - - org.springframework.boot - spring-boot-maven-plugin - - - org.thingsboard - gradle-maven-plugin - - - org.apache.maven.plugins - maven-assembly-plugin - - - org.apache.maven.plugins - maven-install-plugin - - - - - - jenkins - Jenkins Repository - https://repo.jenkins-ci.org/releases - - false - - - - - diff --git a/transport/lwm2m/src/main/conf/logback.xml b/transport/lwm2m/src/main/conf/logback.xml deleted file mode 100644 index 2f0980ffc9..0000000000 --- a/transport/lwm2m/src/main/conf/logback.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - ${pkg.logFolder}/${pkg.name}.log - - ${pkg.logFolder}/${pkg.name}.%d{yyyy-MM-dd}.%i.log - 100MB - 30 - 3GB - - - %d{ISO8601} [%thread] %-5level %logger{36} - %msg%n - - - - - - - - - - - - diff --git a/transport/lwm2m/src/main/conf/tb-lwm2m-transport.conf b/transport/lwm2m/src/main/conf/tb-lwm2m-transport.conf deleted file mode 100644 index 3e239ef49b..0000000000 --- a/transport/lwm2m/src/main/conf/tb-lwm2m-transport.conf +++ /dev/null @@ -1,23 +0,0 @@ -# -# Copyright © 2016-2020 The Thingsboard Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -export JAVA_OPTS="$JAVA_OPTS -Xloggc:@pkg.logFolder@/gc.log -XX:+IgnoreUnrecognizedVMOptions -XX:+HeapDumpOnOutOfMemoryError -XX:+PrintGCDetails -XX:+PrintGCDateStamps" -export JAVA_OPTS="$JAVA_OPTS -XX:+PrintHeapAtGC -XX:+PrintTenuringDistribution -XX:+PrintGCApplicationStoppedTime -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=10" -export JAVA_OPTS="$JAVA_OPTS -XX:GCLogFileSize=10M -XX:-UseBiasedLocking -XX:+UseTLAB -XX:+ResizeTLAB -XX:+PerfDisableSharedMem -XX:+UseCondCardMark" -export JAVA_OPTS="$JAVA_OPTS -XX:CMSWaitDuration=10000 -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:+CMSParallelInitialMarkEnabled" -export JAVA_OPTS="$JAVA_OPTS -XX:+CMSEdenChunksRecordAlways -XX:CMSInitiatingOccupancyFraction=75 -XX:+UseCMSInitiatingOccupancyOnly" -export LOG_FILENAME=${pkg.name}.out -export LOADER_PATH=${pkg.installFolder}/conf diff --git a/transport/lwm2m/src/main/data/credentials/serverKeyStore.jks b/transport/lwm2m/src/main/data/credentials/serverKeyStore.jks deleted file mode 100644 index b5b6c9fa3c43118262f4c89b1ba319ef09b694d0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5716 zcma)qB?KfE>5`UM79>`>LrS_k1Z1TVP&x!r8kUe1VM&qhE)@w8Sh~AA zmi&2t^Sw25XYQRdbI#23ob%56ndklIKtidsv9WLo?xeTkAdo7uheNQdNgC*M#YWZ9C z8mtluT+B}uLJVIvNe`D=hTCtGC0g)8E|o0i_@b z<2`@}0RCrr0c-)*5SD+MU_nY;a=qs-?3o20i;F--p%6iF5g|cH$l(8gG9>n)%|!@z z`e~6E5#G>|r)1s2=wB!}k(R?oh60L<&#i@}v%BCdnBkr_vz`O3NxUnc)1(^JLQO`X zwV^mGbW}o64_&>?7Jy1|w}NaNo$EGd>HhAmm#N6Iv;_$&{cE?Bf|QKp0Gq#1JpbT$ z0IUHo|Mkj$0umJ!{@=3kibVTk`D@QL$9rwJ;V+EnGxGud0;;rg1_zNtQ=BRb2G*rk z1{WwmgJh<>=_BRh#8DPGxo=GRkn6h)S%ZV2IHFd4%w5-#$#p#yLTagW95m4%RqftYWhsK@*a6EN-rNBoq z+xux$aP8hQmpM^CsXSG5A!Q=@BOmD);TF?)bozM*K#acDrgh?^zPgoP6n-D@$nxW2P%Sa-k*uH}WFVH19iZtl0c zruOT#PpS#YiRmfbE6EO2WO!-9-Dn|>dN8?}^jKRKNU8zp05L%~o-&8Ib*McQ3BluF zNS`Xmx9fXAjca|+KA>!p;SK!rhu~b(a5}qnDj3**$$L%k<9X6nb_0xl%!F%5F*)% z<_%aH^l>CZbg$8fSNaY@62pK+K^dZ4)Wh}K@vU9T_-9Y)t3vFO`g#DU@-o7C7SFUn zcBV?R*Uj#}X0UWH7<0ZFCP8d6bA$IG%C=>5b_=m_^wX7267A#Nxci(>(hDVyJO0I* z7apu;$`x^!M`<-A+TnlVJ17L!9%Mu{sdB0SO)*^I&NMN6?z!U(Vza56>@uS-cP?9K z&0X!}gx7W?yAP^I(oI-Ew0CHJBQDSx962H{i&O1);>NWue0sx5Ds|ZG&l

t^Q*A zz2VM8H6^(VvE-u{#!Femel3CiPESCye(B!J&u9D^V`M zz$xC-NvsP}_BiwB(fc_NofT2Z4!P=CK_}{F-tF`>5R< z0@q0@4pHjD`*pRfU*h%?$!tnIh3B0J3qmQ`Dn&BL53X^0d@608MOLsDcM9d=aMI3? z&LfTUeC`$p(Zdv{5-u=YoU84x?)H6KWZVZG3UNV7B4pvsX9;3!>cU+`ik<~@5&gxw zP)H5EPJ?M zV5ndrZ&-|4@MGH=z1LgMU^-DgyUb>^MJFdH(OUDQ;Rp76!uOwMgPd`2Ij|SL4D{QX zNv<4r``x)@#4$Y4HSV_%$UCraFe1cRX!-T7+PbO%mD?ul9zd&eL)y3MYlZqolkSvA zVs(+}tI&#rm|v+Ky59JOxIL-U889}w@iZCp{W$@PSbZPV)y7DRV5qPab37rH>0fVR z>73o~$Vq)WFTQIU4Gz>IAiDW5j{h{BS7h3dSb+`nwu~%!os=)#jz;|9RY6v&Ov-!% zowQ)>2kbaR_&srS4&yINtZ7?%8jLw%K2vkmrcM5ChRpS{9LPhUUYsi+&sklq44Ztx zfU@kpDA$ElBu5H+Q8Bq`c(HDGSuMymJC3Bs2 z;OcTnnpOl*EoEQn!_S_Z!+@W|4sR}HDiH&(a3wP<&^~#yf+Y%&Ph0uH`j=bb!;!`B zu|UE#6H4#46F9fn3w)0g5FD>_WY%7bzI;n|_KUqEbxSYt&B13!QVL4!Rz+4c#kKln zrw&FqI6^#IN?kGf69&zHfkR+bO40DUpwDnw?F?Jl0=is00b+!^Q5zt+V42>mQ!cC? zMxhilcUgUlD;O-&h`883!Vr}J!IB;Wmd9y~d{(aqe* zCHp7^wEqkx3Qi`gwKsJsZQw`jPUwc?D*$C@DzSX-GlN7vkq+2mH+f23!2hrxn874? zv_2%k`|Fy!@ze*oZsun0oOpvMwCsGSPYI@1H=~z++p`+&)+Z=u49Z&V{?G}P*^yvh zfzihAOgY`kd0n{FFe{_CNOtH4NRG#|`K9=Sck{QyFSC@#!)n59hEm=y1#no-DAiR* zNcdH7nz}aNQzaA@IIh<{*A2*TbsryTC^TgoE)yJ7W$UUxDD{5CTOGQ~& zDLV(hxqS4(2nwSVMyef{4P>HUrWXu}fJlV>f;6mnVvz0?Je!G1_3(kNS z!!F9Nw#7@bc%&o0)qW5iywwP97rM@Cdgwu&JQ5ZttGVomP9TTv{&eF|9zv+=750Q+ zaQMcI3Cj$uyTUTJRw=yo@D8pDCpvo_N7vU0BJv1tibIEL!Xya7xT4y$YkaRh?eE@V zD=P2L%TwvqV*w11I%r~xfxvBo(n>8(#-xsIN!zX7{v0YJ3*{q&b-@Ajmt28&E4SB5 zC<|Dw2(6)}Smlj~u6$fy>;)@+WHD42K*s|SdQhda8Kica=@=^cZP37MLk$b_7_lKy zul6_}h(;l#UB!+FHhmV<#`exzS3^4N7_4t%l~?KM^*_8Uu1b1f3A18kblJt~bX0bn zl*|jd?m&Qe9+LXAc`kN#i3%{hRPThRWA0PDF}b~sAj535@g=6}_Gyk|z*B`PcXbRl zUm2A-fd=APyhAabdJV{q!O5E5#&H2q?aFvAKG#xAz5&PESE;lR3KNeoqG?P!)I7sC z{MeVDg#5CpGd*`;XIF!=zIaw)7$2XHOwP2aDyQ^gZuR@{7Npr=KV6;QDW?FjLnY_T zo5A6G8}kQ)Yb4j(rRB&n9_~|g_Dr+H>aeguZYU;(S6b=6JV_>)(6I0v1IHw zEf!ZOhm(~dI4o5w)JchDhGNo7IsXPPeg3LiCki1-Qhl)qMRQ#fcfO+38)tOk%8@lVP z#e=F)w3hNyvLaQj-I2dYX^$F{H{el=f~(SDy>c`akd)F`EiDX;slE`&ga_6wZ`O}; z`3P=I4C6~s@d7!-rH)kYUug$*%z-%>Hti*ijmBOY+Ss_3n2$gnv3p59$$+!rF9{7L z!0vQV71n|=5n=-<*NkkRx?jw!%|}KBkSU;Wt!2KJguTF=^|^=-T>zY$0Gx$Rjbp8U7(5g`R| z2lO0p>(ii*Mp5(y19wH!V0W1Fa&wi7Pola3$D<8O%Z{Mkc zsG#b2MeQ~i~8Cw1o4-og?YmTn?G$GzK*XrFzBRxh+d4=Xh}^Dk%GX%2M{jaD*g z9$Ul2u-m{L|LIo`K04$(oW3-cg9+)&XhamLHJr$E6yM~{z80M%rvz_ZZpBpl_>@=i zpo#4P9E;b9>D$%gy&B-xIKgYbi|apvWo8R(+wod=7gI9xc=> zOV4lE$|1n=%h|1c`dR7R5*nH-lDv! z%wu*K-U(bw4;U9q839}S4{lD(H!Ty);YQ#cC}L317bwMVQYktcD_q28q>y=u@5FCw zwfdC@Pkh%X%D;$^MlQKyOkq7qJzu9a;p6denhpE9ypwP^9~XFj_I}go5VwwP<&VAi z6VvqhC()mCel0ice({ob{W&Mx(z(v6Yuj(qYr=Jf>^b4(*|!`XGuXt5ta+=CTo=ko zN20d89d%B-n3OWC;YZ)Wv@zO`O)c)YjXTXSn>$U%T*{2CRj}tj!Z%ONCnANoryL{K zu!wwf+S<-{e*x?Yn$n8IORBZmGN@nNSR5kdJXxGYnj?z&SU+!zSF5e@Z?GE=3u5qh z(yQip6>xYtm`XFqQRbg=V=QY56+B}`E#u~yW6N#oXHpz##5TijonNIxW(#3j+EI)q z)M;$KGmXG*y8Bz@jyg`&@JiaIrh=$VLHZHdL@&CRxOyal4poNX`8h<1ILw&U#Y+~M zjbvrrHT{a$4)qJ4fvgx(Ieo`=0Yw{eCu_WMs}#U|SN6cq`jvzv-I2y|%vO_y?YeRS zXU!_oKf7)s4mRZ=D#0BS^xZ7yt%Oy;{WTY*y&)N`wvj&iSttKsx!>h@Z$4y3gb@|a z>BgTazbH_w%PGmF@tC_>4#v)cer&%K%VWWKNgX^5D;T8DXXfF_7Z<2TvGGsm~NuR zvqMUBqBr<=apnX6CWlEIoBl`{-G+xw;U+hrXUyG9`=POP$CIL^6v<}cI2q*9;`H|i zo!!sQ`zKz$_vheHlBMd*wCa}QdlB~_a~+Y`$aJa4S2F_Ph>ZgX0bjiX?uT zX&d7LyBF``a8Oe}?tf|bWg->|Bgj?lccoI@sTagXQy*CcSe5VYNo&xUe+#4RHl(uE zulHEdz}NfkcU&_3tj$;K0hgWj4PBLY-xq~OKhez2|4$C{SY1uUklvotUGZ?CGbDHDF;?N$gDt)i}$)dV=yaYEGI;coQc5P`K z`UPq^SJwI3ez~1(1y%Pbd#2>pD(fTBeCN;3fLQ)(N}K7vQvQ@z##LXlo+djeI!EiOu#@X2 z?(n#SKT8Rr3#}iSK&6^=o5Ecjl5bqHQ4mK?w0GBdcw7a$V8kDQ| qkcRm%4dLuH%rb{d=@zQVZ?hk0O%Ryaxn;x~P%wJagN=g~iTppw$f0Ne diff --git a/transport/lwm2m/src/main/data/models/10241.xml b/transport/lwm2m/src/main/data/models/10241.xml deleted file mode 100644 index 228c8098e2..0000000000 --- a/transport/lwm2m/src/main/data/models/10241.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - HostDeviceInfo - - 10241 - urn:oma:lwm2m:x:10241 - - - Multiple - Optional - - Host Device Manufacturer - R - Multiple - Mandatory - String - - - - - Host Device Model Number - R - Multiple - Mandatory - String - - - - - Host Device Unique ID - R - Multiple - Mandatory - String - - - - - Host Device Software Version - R - Multiple - Mandatory - String - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10242.xml b/transport/lwm2m/src/main/data/models/10242.xml deleted file mode 100644 index d9c8871f48..0000000000 --- a/transport/lwm2m/src/main/data/models/10242.xml +++ /dev/null @@ -1,647 +0,0 @@ - - - - - 3-Phase Power Meter - - - - 10242 - urn:oma:lwm2m:x:10242 - 1.0 - 1.0 - Multiple - Optional - - - Manufacturer - R - Single - Optional - String - - - - - - - - Model Number - R - Single - Optional - String - - - - - - - - Serial Number - R - Single - Optional - String - - - - - - - - Description - R - Single - Optional - String - - - - - - - - Tension R - R - Single - Mandatory - Float - - V - - - - - - Current R - R - Single - Mandatory - Float - - A - - - - - - Active Power R - R - Single - Optional - Float - - kW - - - - - - Reactive Power R - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power R - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power R - R - Single - Optional - Float - - kvar - - - - - - Apparent Power R - R - Single - Optional - Float - - kVA - - - - - - Power Factor R - R - Single - Optional - Float - -1..1 - - - - - - - THD-V R - R - Single - Optional - Float - - /100 - - - - - - THD-A R - R - Single - Optional - Float - - /100 - - - - - - Tension S - R - Single - Mandatory - Float - - V - - - - - - Current S - R - Single - Mandatory - Float - - A - - - - - - Active Power S - R - Single - Optional - Float - - kW - - - - - - Reactive Power S - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power S - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power S - R - Single - Optional - Float - - kvar - - - - - - Apparent Power S - R - Single - Optional - Float - - kVA - - - - - - Power Factor S - R - Single - Optional - Float - -1..1 - - - - - - - THD-V S - R - Single - Optional - Float - - /100 - - - - - - THD-A S - R - Single - Optional - Float - - /100 - - - - - - Tension T - R - Single - Mandatory - Float - - V - - - - - - Current T - R - Single - Mandatory - Float - - A - - - - - - Active Power T - R - Single - Optional - Float - - kW - - - - - - Reactive Power T - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power T - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power T - R - Single - Optional - Float - - kvar - - - - - - Apparent Power T - R - Single - Optional - Float - - kVA - - - - - - Power Factor T - R - Single - Optional - Float - -1..1 - - - - - - - THD-V T - R - Single - Optional - Float - - /100 - - - - - - THD-A T - R - Single - Optional - Float - - /100 - - - - - - 3-Phase Active Power - R - Single - Optional - Float - - kW - - - - - - 3-Phase Reactive Power - R - Single - Optional - Float - - kvar - - - - - - 3-Phase Inductive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - 3-Phase Capacitive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - 3-Phase Apparent Power - R - Single - Optional - Float - - kVA - - - - - - 3-Phase Power Factor - R - Single - Optional - Float - -1..1 - - - - - - - 3-Phase phi cosine - R - Single - Optional - Float - -1..1 - - - - - - - Active Energy - R - Single - Optional - Float - - kWh - - - - - - Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Inductive Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Capacitive Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Apparent Energy - R - Single - Optional - Float - - kVAh - - - - - - Tension R-S - R - Single - Optional - Float - - V - - - - - - Tension S-T - R - Single - Optional - Float - - V - - - - - - Tension T-R - R - Single - Optional - Float - - V - - - - - - Frequency - R - Single - Optional - Float - - Hz - - - - - - Neutral Current - R - Single - Optional - Float - - A - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10243.xml b/transport/lwm2m/src/main/data/models/10243.xml deleted file mode 100644 index 325c8cee0e..0000000000 --- a/transport/lwm2m/src/main/data/models/10243.xml +++ /dev/null @@ -1,251 +0,0 @@ - - - - - Single-Phase Power Meter - - - - 10243 - urn:oma:lwm2m:x:10243 - 1.0 - 1.0 - Multiple - Optional - - - Manufacturer - R - Single - Optional - String - - - - - - - - Model Number - R - Single - Optional - String - - - - - - - - Serial Number - R - Single - Optional - String - - - - - - - - Description - R - Single - Optional - String - - - - - - - - Tension - R - Single - Mandatory - String - - V - - - - - - Current - R - Single - Mandatory - Float - - A - - - - - - Active Power - R - Single - Optional - Float - - kW - - - - - - Reactive Power - R - Single - Optional - Float - - kvar - - - - - - Inductive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - Capacitive Reactive Power - R - Single - Optional - Float - - kvar - - - - - - Apparent Power - R - Single - Optional - Float - - kVA - - - - - - Power Factor - R - Single - Optional - Float - -1..1 - - - - - - - THD-V - R - Single - Optional - Float - - /100 - - - - - - THD-A - R - Single - Optional - Float - - /100 - - - - - - Active Energy - R - Single - Optional - Float - - kWh - - - - - - Reactive Energy - R - Single - Optional - Float - - kvarh - - - - - - Apparent Energy - R - Single - Optional - Float - - kVAh - - - - - - Frequency - R - Single - Optional - Float - - Hz - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10244.xml b/transport/lwm2m/src/main/data/models/10244.xml deleted file mode 100644 index 320e74c5e4..0000000000 --- a/transport/lwm2m/src/main/data/models/10244.xml +++ /dev/null @@ -1,318 +0,0 @@ - - - - VehicleControlUnit - - 10244 - urn:oma:lwm2m:x:10244 - Single - Optional - - Vehicle UI State - R - Single - Mandatory - Integer - 0..15 - - - - Vehicle Speed - R - Single - Mandatory - Integer - - km/h - - - Vehicle Shift Status - R - Single - Mandatory - Integer - 0..3 - - - - Vehicle AP Position - R - Single - Mandatory - Integer - 0..100 - /100 - - - Vehicle Power - R - Single - Optional - Float - - kW - - - Vehicle Drive Energy - R - Single - Optional - Float - - Wh - - - Vehicle Energy Consumption Efficiency - R - Single - Optional - Float - - Wh/km - - - Vehicle Estimated Mileage - R - Single - Optional - Integer - - km - - - Vehicle Charge Cable Status - R - Single - Mandatory - Boolean - - - - - Vehicle Charge Status - R - Single - Mandatory - Integer - 0..15 - - - - Vehicle Charge Voltage - R - Single - Mandatory - Float - - V - - - Vehicle Charge Current - R - Single - Mandatory - Float - - A - - - Vehicle Charge Remaining Time - R - Single - Mandatory - Integer - - min - - - Battery Pack Voltage - R - Single - Mandatory - Float - - V - - - Battery Pack Current - R - Single - Mandatory - Float - - A - - - Battery Pack Remaining Capacity - R - Single - Mandatory - Integer - - Ah - - - Battery Pack SOC - R - Single - Mandatory - Integer - 0..100 - /100 - - - Battery Pack SOH - R - Single - Mandatory - Integer - 0..100 - /100 - - - Battery Cell MinVolt - R - Single - Mandatory - Integer - - mV - - - Battery Cell MaxVolt - R - Single - Mandatory - Integer - - mV - - - Battery Module MinTemp - R - Single - Mandatory - Integer - - Cel - - - Battery Module MaxTemp - R - Single - Mandatory - Integer - - Cel - - - Battery Connection Status - R - Single - Mandatory - Boolean - - - - - - MCU Voltage - R - Single - Mandatory - Integer - - V - - - MCU Temperature - R - Single - Mandatory - Integer - - Cel - - - Motor Speed - R - Single - Mandatory - Integer - - 1/min - - - Motor Temperature - R - Single - Mandatory - Integer - - Cel - - - Motor OT Warning - R - Single - Optional - Boolean - - - - - MCU OT Warning - R - Single - Optional - Boolean - - - - - Battery Pack OT Warning - R - Single - Optional - Boolean - - - - - MCU fault - R - Single - Optional - Boolean - - - - - Motor Error - R - Single - Optional - Boolean - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10245.xml b/transport/lwm2m/src/main/data/models/10245.xml deleted file mode 100644 index 3bb5219949..0000000000 --- a/transport/lwm2m/src/main/data/models/10245.xml +++ /dev/null @@ -1,203 +0,0 @@ - - - - - Relay Management - This LWM2M Object provides a range of eNB related measurements and parameters of which several are changeable. Furthermore, it includes Resources to enable/disable the eNB. - 10245 - urn:oma:lwm2m:x:10245 - - - Single - Optional - - - eNB Availability - R - Single - Mandatory - Boolean - AVAILABLE; UNAVAILABLE - - This field indicates to the CCC whether or not the eNB of the CrowdBox is available for activation: AVAILABLE = TRUE; UNAVAILABLE = FALSE This is set by the CrowdBox itself using an algorithm specific to the use case and based on parameters known to the CrowdBox which may not necessarily be signalled to the network. In the absence of a more specific algorithm, this parameter should be set to AVAILABLE, unless a fault is detected which would prevent activation of the eNB, in which case it should be set to UNAVAILABLE. - - - GPS Status - R - Single - Mandatory - Boolean - UNSYNCHRONISED; SYNCHRONISED - - States whether the CrowdBox GPS receiver is synchronised to GPS time or not: UNSYCHRONISED = FALSE; SYNCHRONISED = TRUE If more than one GPS receiver is used by the CrowdBox, then SYNCHRONISED should be reported only if all receivers are synchronised. - - - Orientation - R - Single - Optional - Integer - -180..180 - deg - Orientation of CrowdBox with respect to magnetic north. The reference orientation of the CrowdBox shall be the pointing direction of the eNB antenna(s) or, in the case of an omni-directional CrowdBox antenna, as defined in the accompanying product documentation. - - - eNB EARFCN - RW - Single - Mandatory - Integer - 0..65535 - - EARFCN currently used by the eNB. Highest valid value in 3GPP is currently 46589. If the requested EARFCN is not supported by the eNB, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - eNB Bandwidth - RW - Single - Mandatory - Integer - 5, 10, 15, 20 - - Bandwidth of the currently used eNB carrier. If the requested bandwidth is not supported by the eNB, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Primary EARFCN - RW - Single - Mandatory - Integer - 0..65535 - - EARFCN of primary cell used for the backhaul. If the requested EARFCN is not supported by the CrowdBox UE, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Secondary EARFCN - RW - Multiple - Mandatory - Integer - 0..65535 - - EARFCN of any secondary cells used for the backhaul, in the event that carrier aggregation is being used. If the requested EARFCN is not supported by the CrowdBox UE, the response should be "Bad Request". The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Cumulative Measurement Window - RW - Single - Mandatory - Integer - 0..65535 - s - The current measurement interval over which cumulative statistics are collected for the following resources: Cumulative Number of Unique Users, Cumulative Downlink Throughput per Connected User, Cumulative Uplink Throughput per Connected User. Note that this measurement period is a sliding window rather than a granularity period. Measurements should never be reset, but rather old measurements should be removed from the cumulative total as they fall outside of the window. A value of 0 shall be interpreted as meaning only the current value should be reported. A value of 65535 shall be interpreted as an infinite window size (i.e. old measurements are never discarded). - - - eNB ECI - R - Single - Mandatory - Integer - 0..2^28-1 - - A 28 bit E-UTRAN Cell Identifier (ECI) - - - eNB Status - RW - Single - Mandatory - Boolean - - - This resource indicates the current status of the eNB and can be used by the CCC to change the state from enabled to disabled. TRUE = eNB enabled FALSE = eNB disabled - - - Enable eNB - E - Single - Mandatory - - - - Enables the eNB. In addition the CrowdBox shall also update its configuration to reflect the current state of other relevant parameters. This might require a reboot. - - - eNB Maximum Power - RW - Single - Mandatory - Integer - 0..63 - dBm - Maximum power for the eNB measured as the sum of input powers to all antenna connectors. The maximum power per antenna port is equal to the maximum eNB power divided by the number of antenna ports. If the requested power is above or below the maximum or minimum power levels of the eNB, then the power level should be set to the maximum or minimum respectively. The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Primary q-OffsetFreq - RW - Single - Mandatory - Integer - -24..24 - dB - q-OffsetFreq parameter for the backhaul primary EARFCN in SIB5 of the CrowdBox eNB BCCH. See TS 36.331 for details. Range: dB-24; dB-22 .. dB24 The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Backhaul Secondary q-OffsetFreq - RW - Multiple - Mandatory - Integer - -24..24 - dB - q-OffsetFreq parameter for the backhaul secondary EARFCN in SIB5 of the CrowdBox eNB BCCH. See TS 36.331 for details Range: dB-24; dB-22 .. dB24 The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Neighbour CrowdBox EARFCN - RW - Multiple - Mandatory - Integer - 0..66635 - - EARFCN of a neighbour CrowdBox. Each instance of this resource relates to the same instance of resource ID 15. - - - Neighbour CrowdBox q-OffsetFreq - RW - Multiple - Mandatory - Integer - -24..24 - dB - q-OffsetFreq parameter of the Neighbour CrowdBox EARFCN in SIB5 of the Neighbour CrowdBox eNB BCCH. See TS 36.331 for details Range: dB-24; dB-22 .. dB24 Each instance of this resource relates to the same instance of resource ID 14. The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - Serving Macro eNB cellIndividualOffset - RW - Single - Mandatory - Integer - -24..24 - dB - Specifies the value of the cellIndividualOffset parameter applicable to the CrowdBox macro serving cell that is to be signalled to connected UEs in their measurement configuration information . See TS 36.331 for details. The CrowdBox shall only apply a change of this resource upon execution of the “Enable eNB” command. - - - - - diff --git a/transport/lwm2m/src/main/data/models/10246.xml b/transport/lwm2m/src/main/data/models/10246.xml deleted file mode 100644 index 6e2965817c..0000000000 --- a/transport/lwm2m/src/main/data/models/10246.xml +++ /dev/null @@ -1,93 +0,0 @@ - - - - - CrowdBox Measurements - This LWM2M Object provides CrowdBox-related measurements such as serving cell parameters, backhaul timing advance, and neighbour cell reports. - 10246 - urn:oma:lwm2m:x:10246 - - - Single - Optional - - - Serving Cell ID - R - Single - Mandatory - Integer - 0..2^32-1 - - Serving cell ID as specified by the cellIdentity field broadcast in SIB1 of the serving cell (see TS 36.331). - - - Serving Cell RSRP - R - Single - Mandatory - Integer - 0..97 - - Serving cell RSRP, as defined in TS 36.133, Section 9.1.4. Range: RSRP_00; RSRP_01 .. RSRP_97 - - - Serving Cell RSRQ - R - Single - Mandatory - Integer - -30..46 - - Serving cell RSRQ, as defined in TS 36.133, Section 9.1.7. Range: RSRQ_-30; RSRQ_-29 .. RSRQ_46 - - - Serving Cell SINR - R - Single - Mandatory - Integer - -10..30 - dB - SINR of serving cell as estimated by the CrowdBox. Note that this is a proprietary measurement dependent on the UE chipset manufacturer. The UE chipset used should be stated in the accompanying product documentation. - - - Cumulative Backhaul Timing Advance - R - Single - Optional - Integer - 0..65535 - - The cumulative timing advance signalled by the current serving cell to the CrowdBox. This is the sum of the initial timing advance signalled in the MAC payload of the Random Access Response (11 bits, 0 .. 1282) and subsequent adjustments signalled in the MAC PDU of DL-SCH transmissions (6 bits, -31 .. 32). See TS 36.321 for details. - - - Neighbour Cell Report - R - Multiple - Mandatory - Objlnk - - - A link to the "Neighbour Cell Report" object for each neighbour cell of the CrowdBox. - - - - - diff --git a/transport/lwm2m/src/main/data/models/10247.xml b/transport/lwm2m/src/main/data/models/10247.xml deleted file mode 100644 index 81dd8486eb..0000000000 --- a/transport/lwm2m/src/main/data/models/10247.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - - - Neighbour Cell Report - This LWM2M Object provides the neighbour cell report. The CrowdBox Measurements Object and the Connected UE Report Object have both Objlnk Resources pointing to this Object. - 10247 - urn:oma:lwm2m:x:10247 - - - Multiple - Optional - - - Neighbour PCI - R - Single - Mandatory - Integer - 0..503 - - Physical Cell ID of neighbouring LTE cell, as defined in TS 36.211 - - - Neighbour Cell ID - R - Single - Optional - Integer - 0..2^32-1 - - Neighbour cell ID as specified by the cellIdentity field broadcast in SIB1 of the neighbour cell (see TS 36.331). - - - Neighbour Cell Rank - R - Single - Mandatory - Integer - 0..255 - - Current neighbour cell rank. Neighbour cells should be ordered (ranked) by the CrowdBox according to neighbour cell RSRP, with a higher RSRP corresponding to a lower index. Hence the neighbouring cell with the highest RSRP should be neighbour cell 0, the second neighbour cell 1, and so on. - - - Neighbour Cell RSRP - R - Single - Mandatory - Integer - 0..97 - - Neighbour cell RSRP, as defined in TS 36.133, Section 9.1.4. Range: RSRP_00; RSRP_01 .. RSRP_97 - - - Neighbour Cell RSRQ - R - Single - Mandatory - Integer - -30..46 - - Neighbour cell RSRQ, as defined in TS 36.133, Section 9.1.7. Range: RSRQ_-30; RSRQ_-29 .. RSRQ_46 - - - - - diff --git a/transport/lwm2m/src/main/data/models/10248.xml b/transport/lwm2m/src/main/data/models/10248.xml deleted file mode 100644 index aaef046e5d..0000000000 --- a/transport/lwm2m/src/main/data/models/10248.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - Connected UE Measurements - This LWM2M Object provides a range of measurements of connected UEs and provides an Object link to the Connected UE report. - 10248 - urn:oma:lwm2m:x:10248 - - - Single - Optional - - - Number of Connected Users - R - Single - Mandatory - Integer - 0..255 - - The number of different UEs currently connected to the eNB (i.e. in RRC_CONNECTED state). - - - Cumulative Number of Unique Users - R - Single - Mandatory - Integer - 0..65535 - - The number of different UEs that have connected to the eNB over the immediately preceding period specified by the "Cumulative Measurement Window" field. - - - Connected UE Report - R - Multiple - Mandatory - Objlnk - - - Provides an Object link to the Connected UE Report which provides a range of information related to the connected UEs. - - - - - diff --git a/transport/lwm2m/src/main/data/models/10249.xml b/transport/lwm2m/src/main/data/models/10249.xml deleted file mode 100644 index d89b8df658..0000000000 --- a/transport/lwm2m/src/main/data/models/10249.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - - - Connected UE Report - This LWM2M Object provides a range of information related to the connected UEs. - 10249 - urn:oma:lwm2m:x:10249 - - - Multiple - Optional - - - Connected User MMEC - R - Single - Mandatory - Integer - 0..255 - - MMEC signalled by the UE to the eNB in the RRCConnectionRequest message (see TS 36.331). - - - Connected User M-TMSI - R - Single - Mandatory - Integer - 0..2^32-1 - - M-TMSI signalled by the UE to the eNB in the RRCConnectionRequest message (see TS 36.331). - - - Serving Cell (CrowdBox) eNB RSRP - R - Single - Mandatory - Integer - 0..97 - - The RSRP of the CrowdBox eNB, as defined in TS 36.133, Section 9.1.4. Range: RSRP_00; RSRP_01 .. RSRP_97 - - - Serving Cell (CrowdBox) eNB RSRQ - R - Single - Mandatory - Integer - -30..46 - - The RSRQ of the CrowdBox eNB, as defined in TS 36.133, Section 9.1.7. Range: RSRQ_-30; RSRQ_-29 .. RSRQ_46 - - - Cumulative Timing Advance per Connected User - R - Single - Optional - Integer - 0..65535 - - The cumulative timing advance signalled by the eNB to each currently connected UE. This is the sum of the initial timing advance signalled in the MAC payload of the Random Access Response (11 bits, 0 .. 1282) and subsequent adjustments signalled in the MAC PDU of DL-SCH transmissions (6 bits, -31 .. 32). See TS 36.321 for details. - - - Last downlink CQI report per Connected User - R - Single - Mandatory - Integer - 0..255 - - The last downlink wideband CQI reported by a connected user the eNB. The CQI format is defined in Table 7.2.3-1 of TS 36.213. - - - Cumulative Downlink Throughput per Connected User - R - Single - Mandatory - Integer - 0..2^32-1 - B - The total number of MAC bytes sent to the connected user over the immediately preceding period specified by the "Cumulative Measurement Window" field. - - - Cumulative Uplink Throughput per Connected User - R - Single - Mandatory - Integer - 0..2^32-1 - B - The total number of MAC bytes received from the connected user over the immediately preceding period specified by the "Cumulative Measurement Window" field. - - - Neighbour Cell Report - R - Multiple - Mandatory - Objlnk - - - A link to the "Neighbour Cell Report" object for each neighbour cell reported to the CrowdBox by the connected UE - - - - - diff --git a/transport/lwm2m/src/main/data/models/10250.xml b/transport/lwm2m/src/main/data/models/10250.xml deleted file mode 100644 index 871ede5741..0000000000 --- a/transport/lwm2m/src/main/data/models/10250.xml +++ /dev/null @@ -1,87 +0,0 @@ - - - - - - App Data Container - - 10250 - urn:oma:lwm2m:x:10250 - 1.0 - 1.0 - Single - Optional - - - UL data - R - Single - Mandatory - Opaque - - - - - - - - DL data - W - Single - Mandatory - Opaque - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10251.xml b/transport/lwm2m/src/main/data/models/10251.xml deleted file mode 100644 index 6b32032097..0000000000 --- a/transport/lwm2m/src/main/data/models/10251.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - - - AT Command - - 10251 - urn:oma:lwm2m:x:10251 - 1.0 - 1.0 - Multiple - Optional - - - Command - RW - Single - Mandatory - String - - - - - - Response - R - Multiple - Mandatory - String - - - - - - Status - R - Multiple - Mandatory - String - - - - - - Timeout - RW - Single - Optional - Integer - - - - - - Run - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10252.xml b/transport/lwm2m/src/main/data/models/10252.xml deleted file mode 100644 index f6ec9bf3bd..0000000000 --- a/transport/lwm2m/src/main/data/models/10252.xml +++ /dev/null @@ -1,168 +0,0 @@ - - - - Manifest - - 10252 - urn:oma:lwm2m:x:10252 - 1.0 - 1.0 - Single - Optional - - - Manifest - W - Single - Mandatory - Opaque - - - - - - - - State - R - Single - Mandatory - Integer - 0..8 - - - - - - Manifest Result - R - Single - Mandatory - Integer - 0..19 - - - - - - Payload Result - R - Single - Mandatory - Opaque - - - - - - - - Asset Hash - R - Single - Mandatory - Opaque - - - - - - - - Manifest version - R - Single - Mandatory - Integer - - - - - - - - Asset Installation Progress - R - Single - Mandatory - Integer - - - - - - - - Campaign Id - RW - Single - Mandatory - String - - - - - - - - Manual Trigger - E - Single - Mandatory - - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10253.xml b/transport/lwm2m/src/main/data/models/10253.xml deleted file mode 100644 index 5d06a21ae4..0000000000 --- a/transport/lwm2m/src/main/data/models/10253.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - Confidential Data - - 10253 - urn:oma:lwm2m:x:10253 - 1.0 - 1.0 - Single - Optional - - - Public Key - RW - Single - Mandatory - Opaque - - - - - - - - Application Data - R - Single - Mandatory - Opaque - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10254.xml b/transport/lwm2m/src/main/data/models/10254.xml deleted file mode 100644 index 805d77df58..0000000000 --- a/transport/lwm2m/src/main/data/models/10254.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - - - Current Loop Input - - 10254 - urn:oma:lwm2m:x:10254:1.0 - 1.0 - 1.0 - Multiple - Optional - - - Current Loop Input Current Value - R - Single - Mandatory - Float - 0; 3.8-20.5 - mA - - - - Min Measured Value - R - Single - Optional - Float - - - - - - Max Measured Value - R - Single - Optional - Float - - - - - - Min Range Value - R - Single - Optional - Float - - - - - - Max Range Value - R - Single - Optional - Float - - - - - - Reset Min and Max Measured Values - E - Single - Optional - - - - - - - Sensor Units - R - Single - Optional - String - - - - - - Application Type - RW - Single - Optional - String - - - - - - Current Calibration - RW - Single - Optional - Float - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10255.xml b/transport/lwm2m/src/main/data/models/10255.xml deleted file mode 100644 index bb1b791046..0000000000 --- a/transport/lwm2m/src/main/data/models/10255.xml +++ /dev/null @@ -1,104 +0,0 @@ - - - - Device Metadata - - 10255 - urn:oma:lwm2m:x:10255 - 1.0 - 1.0 - Single - Optional - - - Protocol supported - R - Single - Mandatory - Integer - - - - - - - - Bootloader hash - R - Single - Mandatory - Opaque - - - - - - - - OEM bootloader hash - R - Single - Mandatory - Opaque - - - - - - - - Vendor - R - Single - Mandatory - String - - - - - - - - Class - R - Single - Mandatory - String - - - - - - - - Device - R - Single - Mandatory - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10256.xml b/transport/lwm2m/src/main/data/models/10256.xml deleted file mode 100644 index cf3141133a..0000000000 --- a/transport/lwm2m/src/main/data/models/10256.xml +++ /dev/null @@ -1,134 +0,0 @@ - - - - - ECID-Signal Measurement Information - - 10256 - urn:oma:lwm2m:x:10256 - 1.0 - 1.0 - Multiple - Optional - - - physCellId - R - Single - Mandatory - Integer - - - - - - - - ECGI - R - Single - Optional - Integer - - - - - - - - arfcnEUTRA - R - Single - Mandatory - Integer - - - - - - - - rsrp-Result - R - Single - Mandatory - Integer - - - - - - - - rsrq-Result - R - Single - Optional - Integer - - - - - - - - ue-RxTxTimeDiff - R - Single - Optional - Integer - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10257.xml b/transport/lwm2m/src/main/data/models/10257.xml deleted file mode 100644 index adbbb51222..0000000000 --- a/transport/lwm2m/src/main/data/models/10257.xml +++ /dev/null @@ -1,292 +0,0 @@ - - - - - Heat / Cooling meter - - 10257 - urn:oma:lwm2m:x:10257 - 1.0 - 1.0 - Multiple - Optional - - - Manufacturer - R - Single - Optional - String - - - - - - Model Number - R - Single - Optional - String - - - - - - Serial Number - R - Single - Optional - String - - - - - - Description - R - Single - Optional - String - - - - - - Error code - R - Multiple - Optional - Integer - - - - - - - Instantaneous active power - R - Single - Optional - Float - - W - - - - Max Measured active power - R - Multiple - Mandatory - Float - - W - - - - Cumulative active power - R - Single - Optional - Float - - Wh - - - - Flow temperature - R - Single - Optional - Float - - Cel - - - - Max Measured flow temperature - R - Single - Optional - Float - - Cel - - - - Return temperature - R - Single - Optional - Float - - Cel - - - - Max Measured return temperature - R - Single - Optional - Float - - Cel - - - - Temperature difference - R - Single - Optional - Float - - K - - - - Flow rate - R - Single - Optional - Float - - m3/s - - - - Max Measured flow - R - Single - Optional - Float - - m3/s - - - - Flow volume - R - Single - Optional - Float - - m3 - - - - Return volume - R - Single - Optional - Float - - m3 - - - - Current Time - RW - Single - Optional - Time - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10258.xml b/transport/lwm2m/src/main/data/models/10258.xml deleted file mode 100644 index 3989a7dcb9..0000000000 --- a/transport/lwm2m/src/main/data/models/10258.xml +++ /dev/null @@ -1,93 +0,0 @@ - - - - - Current Loop Output - - 10258 - urn:oma:lwm2m:x:10258 - 1.0 - 1.0 - Multiple - Optional - - - Current Loop Output Current Value - RW - Single - Mandatory - Float - 3.8-20.5 - mA - - - - Min Range Value - R - Single - Optional - Float - - - - - - Max Range Value - R - Single - Optional - Float - - - - - - Sensor Units - R - Single - Optional - String - - - - - - Application Type - RW - Single - Optional - String - - - - - - Current Calibration - RW - Single - Optional - Float - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10259.xml b/transport/lwm2m/src/main/data/models/10259.xml deleted file mode 100644 index 48472c0b51..0000000000 --- a/transport/lwm2m/src/main/data/models/10259.xml +++ /dev/null @@ -1,100 +0,0 @@ - - - - - System Log - - 10259 - urn:oma:lwm2m:x:10259 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - Read All - R - Single - Mandatory - String - - - - - - - - Read - R - Single - Optional - String - - - - - - - - Enabled - RW - Single - Optional - Boolean - - - - - - - - Capture Level - RW - Single - Optional - Integer - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10260-2_0.xml b/transport/lwm2m/src/main/data/models/10260-2_0.xml deleted file mode 100644 index 371248ddb8..0000000000 --- a/transport/lwm2m/src/main/data/models/10260-2_0.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - RDB - - 10260 - urn:oma:lwm2m:x:10260:2.0 - 1.0 - 2.0 - Multiple - Optional - - - Key - RW - Single - Mandatory - String - - - - - - - - Value - RW - Single - Optional - String - - - - - - - - Exists - RW - Single - Optional - Boolean - - - - - - - - Persistent - RW - Single - Optional - Boolean - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10262.xml b/transport/lwm2m/src/main/data/models/10262.xml deleted file mode 100644 index a4ed354dfe..0000000000 --- a/transport/lwm2m/src/main/data/models/10262.xml +++ /dev/null @@ -1,72 +0,0 @@ - - - - - Interval Data Delivery - - 10262 - urn:oma:lwm2m:x:10262 - Multiple - Optional - - - Name - RW - Single - Mandatory - String - - - - - - Interval Data Links - RW - Multiple - Mandatory - Objlnk - - - - - - Latest Payload - R - Multiple - Mandatory - Opaque - - - - - - Schedule - RW - Single - Optional - Objlnk - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10263.xml b/transport/lwm2m/src/main/data/models/10263.xml deleted file mode 100644 index 72a41a01e0..0000000000 --- a/transport/lwm2m/src/main/data/models/10263.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - - Event Data Delivery - - 10263 - urn:oma:lwm2m:x:10263 - Multiple - Optional - - - Name - RW - Single - Mandatory - String - - - - - - Event Data Links - RW - Multiple - Mandatory - Objlnk - - - - - - Latest Eventlog - R - Multiple - Mandatory - Opaque - - - - - - Schedule - RW - Single - Mandatory - Objlnk - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10264.xml b/transport/lwm2m/src/main/data/models/10264.xml deleted file mode 100644 index 76b6daa42d..0000000000 --- a/transport/lwm2m/src/main/data/models/10264.xml +++ /dev/null @@ -1,102 +0,0 @@ - - - - - Delivery Schedule - - 10264 - urn:oma:lwm2m:x:10264 - Multiple - Optional - - - Schedule Start Time - RW - Single - Mandatory - Integer - - - - - - Schedule UTC Offset - RW - Single - Mandatory - String - - - - - - Delivery Frequency - RW - Single - Mandatory - Integer - - - - - - Randomised Delivery Window - RW - Single - Optional - Integer - - - - - - Number of Retries - RW - Single - Optional - Integer - - - - - - Retry Period - RW - Single - Optional - Integer - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10265.xml b/transport/lwm2m/src/main/data/models/10265.xml deleted file mode 100644 index 43d852e301..0000000000 --- a/transport/lwm2m/src/main/data/models/10265.xml +++ /dev/null @@ -1,121 +0,0 @@ - - - - - Leakage Detection Configuration - - 10265 - urn:oma:lwm2m:x:10265 - Single - Optional - - - Sample Times - RW - Multiple - Mandatory - Integer - - - - - - Sample UTC Offset - RW - Single - Optional - String - - - - - - Detection Mode - RW - Single - Mandatory - Integer - 0..3 - - - - - Top Frequency Count - RW - Single - Optional - Integer - - - - - - Frequency Thresholds - RW - Multiple - Optional - Integer - 0..999 - - - - - Frequency Values - R - Multiple - Optional - Integer - - - - - - Firmware Version - R - Single - Mandatory - String - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10266.xml b/transport/lwm2m/src/main/data/models/10266.xml deleted file mode 100644 index 916586f04d..0000000000 --- a/transport/lwm2m/src/main/data/models/10266.xml +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Water Flow Readings - - 10266 - urn:oma:lwm2m:x:10266 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10267.xml b/transport/lwm2m/src/main/data/models/10267.xml deleted file mode 100644 index db7989ba57..0000000000 --- a/transport/lwm2m/src/main/data/models/10267.xml +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Daily Maximum Flow Rate Readings - - 10267 - urn:oma:lwm2m:x:10267 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10268.xml b/transport/lwm2m/src/main/data/models/10268.xml deleted file mode 100644 index 7042a7d511..0000000000 --- a/transport/lwm2m/src/main/data/models/10268.xml +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Temperature Readings - - 10268 - urn:oma:lwm2m:x:10268 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10269.xml b/transport/lwm2m/src/main/data/models/10269.xml deleted file mode 100644 index ad8037184f..0000000000 --- a/transport/lwm2m/src/main/data/models/10269.xml +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Pressure Readings - - 10269 - urn:oma:lwm2m:x:10269 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10270.xml b/transport/lwm2m/src/main/data/models/10270.xml deleted file mode 100644 index 00c3a889a2..0000000000 --- a/transport/lwm2m/src/main/data/models/10270.xml +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Battery Level Readings - - 10270 - urn:oma:lwm2m:x:10270 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10271.xml b/transport/lwm2m/src/main/data/models/10271.xml deleted file mode 100644 index 105a39b312..0000000000 --- a/transport/lwm2m/src/main/data/models/10271.xml +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Communications Activity Time Readings - - 10271 - urn:oma:lwm2m:x:10271 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10272.xml b/transport/lwm2m/src/main/data/models/10272.xml deleted file mode 100644 index c93162a834..0000000000 --- a/transport/lwm2m/src/main/data/models/10272.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Water Meter Customer Leakage Alarm - - 10272 - urn:oma:lwm2m:x:10272 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10273.xml b/transport/lwm2m/src/main/data/models/10273.xml deleted file mode 100644 index b39695f109..0000000000 --- a/transport/lwm2m/src/main/data/models/10273.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Water Meter Reverse Flow Alarm - - 10273 - urn:oma:lwm2m:x:10273 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10274.xml b/transport/lwm2m/src/main/data/models/10274.xml deleted file mode 100644 index 57d095d79c..0000000000 --- a/transport/lwm2m/src/main/data/models/10274.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Water Meter Empty Pipe Alarm - - 10274 - urn:oma:lwm2m:x:10274 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10275.xml b/transport/lwm2m/src/main/data/models/10275.xml deleted file mode 100644 index 7f88569cd4..0000000000 --- a/transport/lwm2m/src/main/data/models/10275.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Water Meter Tamper Alarm - - 10275 - urn:oma:lwm2m:x:10275 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10276.xml b/transport/lwm2m/src/main/data/models/10276.xml deleted file mode 100644 index 0a642a9774..0000000000 --- a/transport/lwm2m/src/main/data/models/10276.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Water Meter High Pressure Alarm - - 10276 - urn:oma:lwm2m:x:10276 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10277.xml b/transport/lwm2m/src/main/data/models/10277.xml deleted file mode 100644 index d6dcdf92bc..0000000000 --- a/transport/lwm2m/src/main/data/models/10277.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Water Meter Low Pressure Alarm - - 10277 - urn:oma:lwm2m:x:10277 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10278.xml b/transport/lwm2m/src/main/data/models/10278.xml deleted file mode 100644 index c2334e734f..0000000000 --- a/transport/lwm2m/src/main/data/models/10278.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - High Temperature Alarm - - 10278 - urn:oma:lwm2m:x:10278 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10279.xml b/transport/lwm2m/src/main/data/models/10279.xml deleted file mode 100644 index 5875cabfa3..0000000000 --- a/transport/lwm2m/src/main/data/models/10279.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Low Temperature Alarm - - 10279 - urn:oma:lwm2m:x:10279 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10280.xml b/transport/lwm2m/src/main/data/models/10280.xml deleted file mode 100644 index 05d2fe9fd0..0000000000 --- a/transport/lwm2m/src/main/data/models/10280.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Water Network Leak Alarm - - 10280 - urn:oma:lwm2m:x:10280 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10281.xml b/transport/lwm2m/src/main/data/models/10281.xml deleted file mode 100644 index 5af65e535b..0000000000 --- a/transport/lwm2m/src/main/data/models/10281.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Low Battery Alarm - - 10281 - urn:oma:lwm2m:x:10281 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10282.xml b/transport/lwm2m/src/main/data/models/10282.xml deleted file mode 100644 index 3358e710c7..0000000000 --- a/transport/lwm2m/src/main/data/models/10282.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Daughter Board Failure Alarm - - 10282 - urn:oma:lwm2m:x:10282 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10283.xml b/transport/lwm2m/src/main/data/models/10283.xml deleted file mode 100644 index b70c37371e..0000000000 --- a/transport/lwm2m/src/main/data/models/10283.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Device Reboot Event - - 10283 - urn:oma:lwm2m:x:10283 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10284.xml b/transport/lwm2m/src/main/data/models/10284.xml deleted file mode 100644 index 08b9a84d72..0000000000 --- a/transport/lwm2m/src/main/data/models/10284.xml +++ /dev/null @@ -1,215 +0,0 @@ - - - - - Time Synchronisation Event - - 10284 - urn:oma:lwm2m:x:10284 - Multiple - Optional - - - Event Type - RW - Single - Mandatory - Integer - - - - - - Alarm Realtime - RW - Single - Mandatory - Boolean - - - - - - Alarm State - R - Single - Optional - Boolean - - - - - - Alarm Set Threshold - RW - Single - Optional - Float - - - - - - Alarm Set Operator - RW - Single - Optional - Integer - - - - - - Alarm Clear Threshold - RW - Single - Optional - Float - - - - - - Alarm Clear Operator - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Count - RW - Single - Optional - Integer - - - - - - Alarm Maximum Event Period - RW - Single - Optional - Integer - 1..864000 - s - - - - Latest Delivered Event Time - RW - Single - Optional - Time - - - - - - Latest Recorded Event Time - R - Single - Mandatory - Time - - - - - - Alarm Clear - E - Single - Optional - - - - - - - Alarm Auto Clear - RW - Single - Optional - Boolean - - - - - - Event Code - R - Single - Mandatory - Integer - 100..255 - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10286.xml b/transport/lwm2m/src/main/data/models/10286.xml deleted file mode 100644 index 2ac0cf71fb..0000000000 --- a/transport/lwm2m/src/main/data/models/10286.xml +++ /dev/null @@ -1,65 +0,0 @@ - - - - - App Fota Container - - 10286 - urn:oma:lwm2m:x:10286 - 1.0 - 1.0 - Single - Optional - - - UL data - R - Single - Mandatory - Opaque - - - - - - - - DL data - W - Single - Mandatory - Opaque - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10290.xml b/transport/lwm2m/src/main/data/models/10290.xml deleted file mode 100644 index a4f6262d9c..0000000000 --- a/transport/lwm2m/src/main/data/models/10290.xml +++ /dev/null @@ -1,183 +0,0 @@ - - - - - Voltage Logging - - 10290 - urn:oma:lwm2m:x:10290 - 1.0 - 1.0 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10291.xml b/transport/lwm2m/src/main/data/models/10291.xml deleted file mode 100644 index bd6de7cd34..0000000000 --- a/transport/lwm2m/src/main/data/models/10291.xml +++ /dev/null @@ -1,193 +0,0 @@ - - - - - Voltage Transient - - 10291 - urn:oma:lwm2m:x:10291 - 1.0 - 1.0 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Mandatory - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Mandatory - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - Sample Frequency - RW - Single - Mandatory - Float - 0.0..86400.0 - s - How often the inputs are read/sampled.This value can be changed by doing a write command - - - - - diff --git a/transport/lwm2m/src/main/data/models/10292.xml b/transport/lwm2m/src/main/data/models/10292.xml deleted file mode 100644 index 0637afed2a..0000000000 --- a/transport/lwm2m/src/main/data/models/10292.xml +++ /dev/null @@ -1,193 +0,0 @@ - - - - - Pressure Transient - - 10292 - urn:oma:lwm2m:x:10292 - 1.0 - 1.0 - Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Mandatory - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Mandatory - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - Sample Frequency - RW - Single - Mandatory - Float - 0.0..86400.0 - s - How often the inputs are read/sampled.This value can be changed by doing a write command - - - - - diff --git a/transport/lwm2m/src/main/data/models/10299.xml b/transport/lwm2m/src/main/data/models/10299.xml deleted file mode 100644 index c97b9b3ba4..0000000000 --- a/transport/lwm2m/src/main/data/models/10299.xml +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - - - HostDevice - This LWM2M Object provides a range of host device related information which can be queried by the LWM2M Server. The host device is any integrated device with an embedded cellular radio module. - 10299 - urn:oma:lwm2m:x:10299 - 1.0 - 1.0 - Single - Optional - - - Manufacturer - R - Single - Mandatory - String - - - Host device manufacturers name (OEM). - - - Model - R - Single - Mandatory - String - - Identifier of the model name or number determined by device manufacturer. - UniqueID - R - Single - Mandatory - String - - - Unique ID assigned by an manufacturer or other body. Used to uniquely identify a host device. Examples include serial # or UUID. - - - FirmwareVersion - R - Single - Mandatory - String - - - Current Firmware version of the host device. (manufacturer specified string). - - SoftwareVersion - R - Single - Optional - String - - - Current software version of the host device. (manufacturer specified string). - - HardwareVersion - R - Single - Optional - String - - - Current hardware version of the host device. (manufacturer specified string). - - - DateStamp - R - Single - Optional - String - - - UTC value of the time and date of the last Firmware or Software update. Format:MM:DD:YYYY HH:MM:SS - - - - - diff --git a/transport/lwm2m/src/main/data/models/10300.xml b/transport/lwm2m/src/main/data/models/10300.xml deleted file mode 100644 index 4b710f38f5..0000000000 --- a/transport/lwm2m/src/main/data/models/10300.xml +++ /dev/null @@ -1,142 +0,0 @@ - - - - - LWM2M Meta Object - - - - 10300 - urn:oma:lwm2m:x:10300 - 1.0 - 1.0 - Multiple - Optional - - - ObjectID - R - Single - Mandatory - Integer - - - - - - - - ObjectURN - R - Single - Mandatory - String - - - - - - - - ObjectInstanceHandle - R - Single - Optional - Objlnk - - - - - - - - URI - R - Multiple - Mandatory - String - - - - - - - - SHAType - R - Single - Optional - Integer - 0..8 - - - - - - - ChecksumValue - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10308-2_0.xml b/transport/lwm2m/src/main/data/models/10308-2_0.xml deleted file mode 100644 index d119c7d239..0000000000 --- a/transport/lwm2m/src/main/data/models/10308-2_0.xml +++ /dev/null @@ -1,130 +0,0 @@ - - - - - AT&T Connectivity Extension - - 10308 - urn:oma:lwm2m:x:10308:2.0 - 1.0 - 2.0 - Multiple - Optional - - - ICCID - R - Single - Mandatory - String - - - - - - - IMSI - R - Single - Mandatory - String - - - - - - - MSISDN - RW - Single - Mandatory - String - - - - - - - APN Retries - RW - Single - Mandatory - Integer - - - - - - - APN Retry Period - RW - Single - Mandatory - Integer - - - s - - - - APN Retry Back-Off Period - RW - Single - Mandatory - Integer - - - s - - - - SINR - R - Single - Mandatory - Integer - <7 to >12.5 - - - - - SRXLEV - R - Single - Mandatory - Integer - - - - - - - CE_LEVEL - R - Single - Mandatory - Integer - 0,1,2 - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10309.xml b/transport/lwm2m/src/main/data/models/10309.xml deleted file mode 100644 index ba60d0906f..0000000000 --- a/transport/lwm2m/src/main/data/models/10309.xml +++ /dev/null @@ -1,114 +0,0 @@ - - - - - Shareparkinglot - - 10309 - urn:oma:lwm2m:x:10309 - 1.0 - 1.0 - Multiple - Optional - - - LockID - R - Single - Mandatory - Integer - - - - - - LockType - R - Single - Optional - String - - - - - - LightSwitchState - R - Multiple - Optional - Boolean - - - - - - RSSI - R - Multiple - Mandatory - Integer - -30..-120 - dBm - - - - BatteryCapacity - R - Multiple - Optional - Float - 0..100 - %EL - - - - DataUpTime - R - Multiple - Mandatory - Time - - - - - - Latitude - R - Multiple - Optional - String - - - - - - Longitude - R - Multiple - Optional - String - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10311.xml b/transport/lwm2m/src/main/data/models/10311.xml deleted file mode 100644 index 81b3bb69b7..0000000000 --- a/transport/lwm2m/src/main/data/models/10311.xml +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Solar Radiation - - This object is used to report solar irradiance (SI), i.e. power per unit area received from the Sun in the form of electromagnetic radiation, on a planar surface measured by a pyranometer or similar instrument. A pyranometer measures solar irradiance from the hemisphere above within a wavelength range 0.3 μm to 3 μm. For example, the application of solar radiation measurement can be meteorological networks and solar energy applications. - - 10311 - urn:oma:lwm2m:x:10311 - 1.0 - 1.0 - Multiple - Optional - - - Min Measured Value - R - Single - Optional - Float - - - - The minimum value measured by the sensor since it is ON or Reset, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Max Measured Value - R - Single - Optional - Float - - - - The maximum value measured by the sensor since it is ON or Reset, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Min Range Value - R - Single - Optional - Float - - - - The minimum value that can be measured by the sensor, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Max Range Value - R - Single - Optional - Float - - - - The maximum value that can be measured by the sensor, expressed in the unit defined by the "Sensor Units" resource if present. - - - - Reset Min and Max Measured Values - E - Single - Optional - - - - - Reset the Min and Max Measured Values to current value. - - - - Timestamp - R - Single - Optional - Time - - - The timestamp of when the measurement was performed. - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor expressed in the unit defined by the "Sensor Units" resource if present. - - - Sensor Units - R - Single - Optional - String - - - - Measurement Units Definition. - - - - Application Type - RW - Single - Optional - String - - - - The application type of the sensor or actuator as a string, for instance "Air Pressure". - - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - - - diff --git a/transport/lwm2m/src/main/data/models/10313.xml b/transport/lwm2m/src/main/data/models/10313.xml deleted file mode 100644 index e13fefcb23..0000000000 --- a/transport/lwm2m/src/main/data/models/10313.xml +++ /dev/null @@ -1,238 +0,0 @@ - - - - - Gas Readings - - 10313 - urn:oma:lwm2m:x:103131.0 - 1.0Multiple - Optional - - - Interval Period - R - Single - Mandatory - Integer - 1..864000 - s - - - - Interval Start Offset - R - Single - Optional - Integer - 0..86399 - s - - - - Interval UTC Offset - R - Single - Optional - String - - - - - - Interval Collection Start Time - R - Single - Mandatory - Time - - - - - - Oldest Recorded Interval - R - Single - Mandatory - Time - - - - - - Last Delivered Interval - RW - Single - Optional - Time - - - - - - Latest Recorded Interval - R - Single - Mandatory - Time - - - - - - Interval Delivery Midnight Aligned - RW - Single - Mandatory - Boolean - - - - - - Interval Historical Read - E - Single - Optional - - - - - - - Interval Historical Read Payload - R - Single - Optional - Opaque - - - - - - Interval Change Configuration - E - Single - Optional - - - - - - - Start - E - Single - Optional - - - - - - - Stop - E - Single - Optional - - - - - - - Status - R - Single - Optional - Integer - - - - - - Latest Payload - R - Single - Mandatory - Opaque - - - - - - Sensor Warm-up Time - RW - Single - Optional - Integer - 0..86400 - s - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10314.xml b/transport/lwm2m/src/main/data/models/10314.xml deleted file mode 100644 index 0229469801..0000000000 --- a/transport/lwm2m/src/main/data/models/10314.xml +++ /dev/null @@ -1,113 +0,0 @@ - - - - - Particulates - - 10314 - urn:oma:lwm2m:x:10314 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - - - - Min Measured Value - R - Single - Optional - Float - - - - - - Max Measured Value - R - Single - Optional - Float - - - - - - Max Range Value - R - Single - Optional - Float - - - - - - Sensor Units - R - Single - Optional - String - - - - - - Application Type - RW - Single - Optional - String - - - The Application type of the device, for example “Particulate Sensor”. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - - - - Measured Particle Size - R - Single - Mandatory - Float - - m - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10315.xml b/transport/lwm2m/src/main/data/models/10315.xml deleted file mode 100644 index 9886eb7bd0..0000000000 --- a/transport/lwm2m/src/main/data/models/10315.xml +++ /dev/null @@ -1,115 +0,0 @@ - - - - - Robot - - 10315 - urn:oma:lwm2m:x:10315 - 1.0 - 1.0 - Single - Mandatory - - - Robot ID - R - Single - Mandatory - String - 0..255 - - - - - Robot Type - R - Single - Mandatory - String - 0..63 - - - - - Robot Serial Number - R - Single - Mandatory - String - 0..63 - - - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - % - - - - Charging - R - Single - Mandatory - Boolean - - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - Positioning - R - Single - Optional - Boolean - - - - - - Location - R - Single - Optional - Objlnk - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10316.xml b/transport/lwm2m/src/main/data/models/10316.xml deleted file mode 100644 index 3fbb549858..0000000000 --- a/transport/lwm2m/src/main/data/models/10316.xml +++ /dev/null @@ -1,219 +0,0 @@ - - - - - RCU - - 10316 - urn:oma:lwm2m:x:10316 - 1.0 - 1.0 - Single - Mandatory - - - RCU ID - R - Single - Mandatory - String - 0..127 - - - - - RCU Serial Number - R - Single - Mandatory - String - 0..63 - - - - - RCU Software Version - R - Single - Mandatory - String - 0..63 - - - - - RCU OS Version - R - Single - Mandatory - String - 0..127 - - - - - RCU CPU Info - R - Single - Mandatory - String - 64 - - - - - RCU RAM Info - R - Single - Mandatory - String - 64 - - - - - RCU ROM Size - R - Single - Mandatory - Integer - - GB - - - - RCU ROM Available Size - R - Single - Mandatory - Integer - - GB - - - - SD Storage - R - Single - Mandatory - Integer - - GB - - - - SD Available Storage - R - Single - Mandatory - Integer - - GB - - - - RCU GPS Location - R - Single - Optional - Objlnk - - - - - - Wi-Fi MAC - R - Single - Optional - String - 12 - - - - - Bluetooth MAC - R - Single - Optional - String - 12 - - - - - Camera Info - R - Single - Optional - String - 64 - - - - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - /100 - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - - Downloaded APP Packages - R - Multiple - Mandatory - String - - - - - - - RCU APPs - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10318.xml b/transport/lwm2m/src/main/data/models/10318.xml deleted file mode 100644 index 3db4c92fd8..0000000000 --- a/transport/lwm2m/src/main/data/models/10318.xml +++ /dev/null @@ -1,175 +0,0 @@ - - - - - RCU PM - - 10318 - urn:oma:lwm2m:x:10318 - 1.0 - 1.0 - Single - Mandatory - - - CPU Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Max CPU Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Memory Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Storage Usage - R - Single - Mandatory - Integer - 0..100 - /100 - - - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Network Bandwidth - R - Single - Mandatory - Float - - Mbit/s - - - - Mobile Signal - R - Single - Mandatory - Integer - - - - - - GPS Signal - R - Single - Optional - Integer - - - - - - Wi-Fi Signal - R - Single - Mandatory - Integer - - - - - - UpLink Rate - R - Single - Mandatory - Float - - Mbit/s - - - - DownLink Rate - R - Single - Mandatory - Float - - Mbit/s - - - - Packet Loss Rate - R - Single - Mandatory - Integer - 0..100 - /100 - - - - Network Latency - R - Single - Mandatory - Integer - - ms - - - - - Battery Temperature - R - Single - Mandatory - Float - - Cel - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10319.xml b/transport/lwm2m/src/main/data/models/10319.xml deleted file mode 100644 index c3c25871f4..0000000000 --- a/transport/lwm2m/src/main/data/models/10319.xml +++ /dev/null @@ -1,116 +0,0 @@ - - - - - RCU Control - - 10319 - urn:oma:lwm2m:x:10319 - 1.0 - 1.0 - Single - Mandatory - - - RCU Diagnostics Mode - R - Single - Optional - Boolean - - - - - - RCU Log Recording - R - Single - Optional - Boolean - - - - - - - RCU Shutdown - E - Single - Mandatory - - - - - - - RCU Restart - E - Single - Mandatory - - - - - - - RCU Deactivate - E - Single - Mandatory - - - - - - - RCU Reset - E - Single - Mandatory - - - - - - - RCU Diagnostics Mode Control - E - Single - Mandatory - - - - - - - RCU Log Recording Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10320.xml b/transport/lwm2m/src/main/data/models/10320.xml deleted file mode 100644 index 47a4c2e147..0000000000 --- a/transport/lwm2m/src/main/data/models/10320.xml +++ /dev/null @@ -1,127 +0,0 @@ - - - - - CCU - - 10320 - urn:oma:lwm2m:x:10320 - 1.0 - 1.0 - Multiple - Optional - - - CCU ID - R - Single - Mandatory - String - - - - - - CCU FM Version - R - Single - Mandatory - String - - - - - - CCU SW Version - R - Single - Mandatory - String - - - - - - CCU Memory Size - R - Single - Mandatory - Integer - - GB - - - - CCU Storage - R - Single - Mandatory - Integer - - GB - - - - CCU Available Storage - R - Single - Mandatory - Integer - - GB - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - - Downloaded APP Packages - R - Multiple - Optional - String - - - - - - CCU APPs - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10322.xml b/transport/lwm2m/src/main/data/models/10322.xml deleted file mode 100644 index 5375bdd97d..0000000000 --- a/transport/lwm2m/src/main/data/models/10322.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - CCU PM - - 10322 - urn:oma:lwm2m:x:10322 - 1.0 - 1.0 - Multiple - Optional - - - CPU Usage - R - Single - Optional - Integer - 0..100 - % - - - - Max CPU Usage - R - Single - Optional - Integer - 0..100 - % - - - - Memory Usage - R - Single - Optional - Integer - 0..100 - % - - - - Storage Usage - R - Single - Optional - Integer - 0..100 - % - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10323.xml b/transport/lwm2m/src/main/data/models/10323.xml deleted file mode 100644 index 4d9ff0a253..0000000000 --- a/transport/lwm2m/src/main/data/models/10323.xml +++ /dev/null @@ -1,76 +0,0 @@ - - - - - CCU Control - - 10323 - urn:oma:lwm2m:x:10323 - 1.0 - 1.0 - Multiple - Optional - - - - CCU Restart - E - Single - Mandatory - - - - - - - CCU Reset - E - Single - Mandatory - - - - - - - CCU Self-checking - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10324.xml b/transport/lwm2m/src/main/data/models/10324.xml deleted file mode 100644 index 8535a3f5b1..0000000000 --- a/transport/lwm2m/src/main/data/models/10324.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - ECU - - 10324 - urn:oma:lwm2m:x:10324 - 1.0 - 1.0 - Multiple - Optional - - - ECU ID - R - Single - Mandatory - String - - - - - - ECU FM Version - R - Single - Mandatory - String - - - - - - On time - RW - Single - Mandatory - Integer - - s - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10326.xml b/transport/lwm2m/src/main/data/models/10326.xml deleted file mode 100644 index 788c33416a..0000000000 --- a/transport/lwm2m/src/main/data/models/10326.xml +++ /dev/null @@ -1,708 +0,0 @@ - - - - - Robot PM - - 10326 - urn:oma:lwm2m:x:10326 - 1.0 - 1.0 - Single - Mandatory - - - Battery Level - R - Single - Mandatory - Integer - 0..100 - /100 - - - - - Battery Temperature - R - Single - Mandatory - Integer - - Cel - - - - Temperature - R - Single - Optional - Float - - Cel - - - - Humidity - R - Single - Optional - Integer - 0..100 - /100 - - - - PM2.5 - R - Single - Optional - Integer - - ug/m3 - - - - Smog - R - Single - Optional - Float - - ug/m3 - - - - CO - R - Single - Optional - Float - - ppm - - - - CO2 - R - Single - Optional - Float - - ppm - - - - PM10 - R - Single - Optional - Integer - - ug/m3 - - - - Speed - R - Single - Optional - Float - - m/h - - - - Water Used - R - Single - Optional - Integer - 0..100 - /100 - - - - Dust Box Used - R - Single - Optional - Integer - 0..100 - /100 - - - - Obstacle Distance - R - Single - Optional - Integer - - cm - - - - - Robot Temperate - R - Single - Optional - Float - - Cel - - - - Confidence Index - R - Single - Optional - Integer - 0..100 - /100 - - - - - Data Traffic Used - R - Single - Mandatory - Float - - Mbit/s - - - - Images Handled - R - Single - Optional - Integer - - - - - - HARI S-Voice Requests - R - Single - Optional - Integer - - - - - - HARI S-Vision Requests - R - Single - Optional - Integer - - - - - - HARI S-Motion Requests - R - Single - Optional - Integer - - - - - - HARI S-Map Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Voice Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Vision Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Motion Requests - R - Single - Optional - Integer - - - - - - Successful HARI S-Map Requests - R - Single - Optional - Integer - - - - - - Questions Answered - R - Single - Optional - Integer - - - - - - Unknown Questions - R - Single - Optional - Integer - - - - - - Mileage - R - Single - Optional - Integer - - m - - - - Cleaned Times - R - Single - Optional - Integer - - - - - - Cleaned Area - R - Single - Optional - Float - - m2 - - - - Cleaned Time - R - Single - Optional - Integer - - s - - - - ASR Recognized - R - Single - Optional - Integer - - B - - - - Incorrect ASR Recognitions - R - Single - Optional - Integer - - B - - - - Tried TTS Texts - R - Single - Optional - Integer - - B - - - - Successful TTS Texts - R - Single - Optional - Integer - - B - - - - ASR Recognized (CH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (CH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (CH) - R - Single - Optional - Integer - - B - - - - ASR Recognized (EN) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (EN) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (EN) - R - Single - Optional - Integer - - B - - - - ASR Recognized (ES) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (ES) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (ES) - R - Single - Optional - Integer - - B - - - - ASR Recognized (JA) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (JA) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (JA) - R - Single - Optional - Integer - - B - - - - ASR Recognized (SCCH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (SCCH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (SCCH) - R - Single - Optional - Integer - - B - - - - ASR Recognized (GDCH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (GDCH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (GDCH) - R - Single - Optional - Integer - - B - - - - ASR Recognized (TCH) - R - Single - Optional - Integer - - B - - - - Tried TTS Texts (TCH) - R - Single - Optional - Integer - - B - - - - Successful TTS Texts (TCH) - R - Single - Optional - Integer - - B - - - - - Objects Recognition Tries - R - Single - Optional - Integer - - - - - - Successful Object Recognition - R - Single - Optional - Integer - - - - - - Face Recognition Tries - R - Single - Optional - Integer - - - - - - Successful Face Recognitions - R - Single - Optional - Integer - - - - - - Vehicle Plate Recognition Tries - R - Single - Optional - Integer - - - - - - Successful Vehicle Plate Recognitions - R - Single - Optional - Integer - - - - - - Tasks Assigned - R - Single - Mandatory - Integer - - - - - - Successful Tasks Executed - R - Single - Mandatory - Integer - - - - - - Images Uploaded - R - Single - Optional - Integer - - - - - - Videos Uploaded - R - Single - Optional - Integer - - - - - - Images Matted - R - Single - Optional - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10327.xml b/transport/lwm2m/src/main/data/models/10327.xml deleted file mode 100644 index 3e30093d21..0000000000 --- a/transport/lwm2m/src/main/data/models/10327.xml +++ /dev/null @@ -1,54 +0,0 @@ - - - - - Compressor - - 10327 - urn:oma:lwm2m:x:10327 - 1.0 - 1.0 - Multiple - Optional - - - Compressor Name - R - Single - Mandatory - String - - - - - - - Compressor Status - R - Single - Mandatory - Boolean - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10328.xml b/transport/lwm2m/src/main/data/models/10328.xml deleted file mode 100644 index f0e69ccb44..0000000000 --- a/transport/lwm2m/src/main/data/models/10328.xml +++ /dev/null @@ -1,66 +0,0 @@ - - - - - SCA PM - - 10328 - urn:oma:lwm2m:x:10328 - 1.0 - 1.0 - Multiple - Optional - - - SCA Name - R - Single - Mandatory - String - - - - - - - - - SCA Current - R - Single - Mandatory - Float - - A - - - - SCA Temperate - R - Single - Mandatory - Float - - Cel - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10329.xml b/transport/lwm2m/src/main/data/models/10329.xml deleted file mode 100644 index f4e3247416..0000000000 --- a/transport/lwm2m/src/main/data/models/10329.xml +++ /dev/null @@ -1,419 +0,0 @@ - - - - - Robot Control - - 10329 - urn:oma:lwm2m:x:10329 - 1.0 - 1.0 - Single - Mandatory - - - Collision Detection - R - Single - Optional - Boolean - - - - - - Drop Detection - R - Single - Optional - Boolean - - - - - - Automatic Navigation - R - Single - Optional - Boolean - - - - - - Robot Shutdown - E - Single - Mandatory - - - - - - - Robot Reboot - E - Single - Mandatory - - - - - - - Robot Reset - E - Single - Mandatory - - - - - - - Robot Wakeup - E - Single - Mandatory - - - - - - - Robot Sleep - E - Single - Mandatory - - - - - - - Robot Self-checking - E - Single - Mandatory - - - - - - - Emergency Braking - E - Single - Mandatory - - - - - - - Emergency Braking Release - E - Single - Mandatory - - - - - - - Action Execution - E - Single - Optional - - - - - - - Action List Upload - E - Single - Optional - - - - - - - Action List Download - E - Single - Optional - - - - - - - Group Dancing Program Control - E - Single - Optional - - - - - - - Navigation Map Upload - E - Single - Optional - - - - - - - Group Dancing Program Control - E - Single - Optional - - - - - - - Navigation Map Download - E - Single - Optional - - - - - - - Route list Execution - E - Single - Optional - - - - - - - Route list Upload - E - Single - Optional - - - - - - - Route list Download - E - Single - Optional - - - - - - - Automatic Navigation Control - E - Single - Optional - - - - - - - Manual Navigation - E - Single - Optional - - - - - - - Moving to Charging Station - E - Single - Optional - - - - - - - Moving to Specified location - E - Single - Optional - - - - - - - Low Frequency Patrol Broadcasting - E - Single - Optional - - - - - - - Task Start - E - Single - Optional - - - - - - - Task Stop - E - Single - Optional - - - - - - - Task Suspend - E - Single - Optional - - - - - - - Task Resume - E - Single - Optional - - - - - - - Video Upload - E - Single - Optional - - - - - - - Picture Upload - E - Single - Optional - - - - - - - Default Language Switching - E - Single - Optional - - - - - - - Intonation Change - E - Single - Optional - - - - - - - Intonation Change - E - Single - Optional - - - - - - - Speaking with Action - E - Single - Optional - - - - - - - Collision Detection Control - E - Single - Mandatory - - - - - - - Drop Detection Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10330.xml b/transport/lwm2m/src/main/data/models/10330.xml deleted file mode 100644 index 8b37ec3966..0000000000 --- a/transport/lwm2m/src/main/data/models/10330.xml +++ /dev/null @@ -1,106 +0,0 @@ - - - - - Network Info - - 10330 - urn:oma:lwm2m:x:10330 - 1.0 - 1.0 - Single - Mandatory - - - IMEI - R - Single - Mandatory - String - 15 - - - - - IMSI - R - Single - Mandatory - String - 15 - - - - - Radio Connectivity - R - Single - Mandatory - Objlnk - - - - - - - - GPS Signal Status - R - Single - Optional - Integer - 1..4 - - - - - VBN Connection Status - R - Single - Mandatory - Integer - 0..1 - - - - - HARI Connection Status - R - Single - Mandatory - Integer - 0..1 - - - - - CCU Connection Status - R - Multiple - Optional - Integer - 0..1 - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10331.xml b/transport/lwm2m/src/main/data/models/10331.xml deleted file mode 100644 index 305f213cb0..0000000000 --- a/transport/lwm2m/src/main/data/models/10331.xml +++ /dev/null @@ -1,207 +0,0 @@ - - - - - Robot Service Info - - 10331 - urn:oma:lwm2m:x:10331 - 1.0 - 1.0 - Single - Mandatory - - - Current status - R - Single - Mandatory - String - 0..127 - - - - - Services Providing - R - Single - Optional - String - 0..127 - - - - - Advertising Contents - R - Single - Mandatory - String - - - - - - Current Language - R - Single - Optional - String - 0..127 - - - - - Volume - R - Single - Optional - String - 0..100 - /100 - - - - Moving Status - R - Single - Optional - Integer - 0..2 - - - - - Moving Speed - R - Single - Optional - Float - - m/h - - - - Location - R - Single - Optional - Objlnk - - - - - - - - Map List - R - Single - Optional - String - - - - - - Planned Route list - R - Single - Optional - String - - - - - - Current Route - R - Single - Optional - String - - - - - - Route to-do List - R - Single - Optional - String - - - - - - Synchronous Whistle - R - Single - Mandatory - Boolean - - - - - - Current Actions - R - Single - Optional - String - - - - - - ASR Type - R - Single - Optional - Integer - 0..2 - - - - - - TTS Vendor - R - Single - Optional - String - - - - - - TTS Speaker - R - Single - Optional - String - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10332.xml b/transport/lwm2m/src/main/data/models/10332.xml deleted file mode 100644 index 7581fa59a7..0000000000 --- a/transport/lwm2m/src/main/data/models/10332.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - Robot Selfcheck Info - - 10332 - urn:oma:lwm2m:x:10332 - 1.0 - 1.0 - Multiple - Optional - - - Entity - R - Single - Mandatory - String - 4..63 - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10333.xml b/transport/lwm2m/src/main/data/models/10333.xml deleted file mode 100644 index e6d3dda2a6..0000000000 --- a/transport/lwm2m/src/main/data/models/10333.xml +++ /dev/null @@ -1,74 +0,0 @@ - - - - - PM Threshold - - 10333 - urn:oma:lwm2m:x:10333 - 1.0 - 1.0 - Single - Optional - - - Entity - RW - Multiple - Mandatory - String - 4..63 - - - - - Performance Type - RW - Multiple - Mandatory - String - - - - - - High Threshold - RW - Multiple - Mandatory - Float - - - - - - Low Threshold - RW - Multiple - Mandatory - Float - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10334.xml b/transport/lwm2m/src/main/data/models/10334.xml deleted file mode 100644 index 55b7863f66..0000000000 --- a/transport/lwm2m/src/main/data/models/10334.xml +++ /dev/null @@ -1,115 +0,0 @@ - - - - - Robot Alarm - - 10334 - urn:oma:lwm2m:x:10334 - 1.0 - 1.0 - Multiple - Optional - - - Entity - R - Single - Mandatory - String - 4..63 - - - - - Probable Cause - R - Single - Mandatory - Integer - 0..65535 - - - - - Specific Problem - R - Single - Mandatory - String - - - - - - Alarm Type - R - Single - Mandatory - Integer - 2..6 - - - - - Severity - R - Single - Mandatory - Integer - 1..5 - - - - - Report Time - R - Single - Mandatory - Time - - - - - - Sequence No - R - Single - Mandatory - Integer - 0..2^63-1 - - - - - Additional Info - R - Single - Optional - String - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10335.xml b/transport/lwm2m/src/main/data/models/10335.xml deleted file mode 100644 index 3917feb001..0000000000 --- a/transport/lwm2m/src/main/data/models/10335.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - - - Event - - 10335 - urn:oma:lwm2m:x:10335 - 1.0 - 1.0 - Multiple - Optional - - - Entity - R - Single - Mandatory - String - 4..63 - - - - - Event Type - R - Single - Mandatory - Integer - 0..65535 - - - - - Time - R - Single - Mandatory - Time - - - - - - Sequence No - R - Single - Mandatory - Integer - 0..2^63-1 - - - - - Additional Info - R - Single - Optional - String - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10336.xml b/transport/lwm2m/src/main/data/models/10336.xml deleted file mode 100644 index 57211a3819..0000000000 --- a/transport/lwm2m/src/main/data/models/10336.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - MIC - - 10336 - urn:oma:lwm2m:x:10336 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10337.xml b/transport/lwm2m/src/main/data/models/10337.xml deleted file mode 100644 index abbaf23cdf..0000000000 --- a/transport/lwm2m/src/main/data/models/10337.xml +++ /dev/null @@ -1,104 +0,0 @@ - - - - - SCA - - 10337 - urn:oma:lwm2m:x:10337 - 1.0 - 1.0 - Multiple - Optional - - - SCA Name - R - Single - Mandatory - String - - - - - - - - - - SCA Motion Status - R - Single - Optional - Integer - 0..2 - - - - - - SCA Motion Control - E - Single - Optional - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10338.xml b/transport/lwm2m/src/main/data/models/10338.xml deleted file mode 100644 index c4793d625b..0000000000 --- a/transport/lwm2m/src/main/data/models/10338.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - - - Speaker - - 10338 - urn:oma:lwm2m:x:10338 - 1.0 - 1.0 - Single - Optional - - - Speaker status - R - Single - Mandatory - Boolean - - - - - - Voice Warning - R - Single - Mandatory - Boolean - - - - - - - Voice Control - E - Single - Mandatory - - - - - - - Voice Warning Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10339.xml b/transport/lwm2m/src/main/data/models/10339.xml deleted file mode 100644 index 7f3ae3d63b..0000000000 --- a/transport/lwm2m/src/main/data/models/10339.xml +++ /dev/null @@ -1,100 +0,0 @@ - - - - - Tripod Head - - 10339 - urn:oma:lwm2m:x:10339 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - Tripod Direction Control - E - Single - Optional - - - - - - - Tripod Automatic Control - E - Single - Optional - - - - - - - Tripod Reset - E - Single - Optional - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10340.xml b/transport/lwm2m/src/main/data/models/10340.xml deleted file mode 100644 index d602833ddc..0000000000 --- a/transport/lwm2m/src/main/data/models/10340.xml +++ /dev/null @@ -1,204 +0,0 @@ - - - - - Camera - - 10340 - urn:oma:lwm2m:x:10340 - 1.0 - 1.0 - Multiple - Optional - - - Camera Name - R - Single - Mandatory - String - - - - - - - - Camera Status - R - Single - Mandatory - Boolean - - - - - - Connection Status - R - Single - Mandatory - Boolean - - - - - - Working Status - R - Single - Mandatory - Integer - 0..15 - - - - - Local Recording - R - Single - Mandatory - Boolean - - - - - - Image Matting - R - Single - Mandatory - Boolean - - - - - - Camera Snapshot - R - Single - Mandatory - Boolean - - - - - - Camera Recording - R - Single - Mandatory - Boolean - - - - - - - Camera Control - E - Single - Mandatory - - - - - - - Local Recording Control - E - Single - Mandatory - - - - - - - Image Matting Control - E - Single - Mandatory - - - - - - - Camera Snapshot Control - E - Single - Mandatory - - - - - - - Camera Recording Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10341.xml b/transport/lwm2m/src/main/data/models/10341.xml deleted file mode 100644 index 48b9c8a9e5..0000000000 --- a/transport/lwm2m/src/main/data/models/10341.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - GPS - - 10341 - urn:oma:lwm2m:x:10341 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10342.xml b/transport/lwm2m/src/main/data/models/10342.xml deleted file mode 100644 index 3e1e950c9e..0000000000 --- a/transport/lwm2m/src/main/data/models/10342.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - IMU - - 10342 - urn:oma:lwm2m:x:10342 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10343.xml b/transport/lwm2m/src/main/data/models/10343.xml deleted file mode 100644 index 273a7a38c3..0000000000 --- a/transport/lwm2m/src/main/data/models/10343.xml +++ /dev/null @@ -1,82 +0,0 @@ - - - - - LiDAR - - 10343 - urn:oma:lwm2m:x:10343 - 1.0 - 1.0 - Multiple - Optional - - - LiDAR Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10344.xml b/transport/lwm2m/src/main/data/models/10344.xml deleted file mode 100644 index 915372ad6a..0000000000 --- a/transport/lwm2m/src/main/data/models/10344.xml +++ /dev/null @@ -1,82 +0,0 @@ - - - - - Arm - - 10344 - urn:oma:lwm2m:x:10344 - 1.0 - 1.0 - Multiple - Optional - - - Arm Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10345.xml b/transport/lwm2m/src/main/data/models/10345.xml deleted file mode 100644 index bd133a441f..0000000000 --- a/transport/lwm2m/src/main/data/models/10345.xml +++ /dev/null @@ -1,82 +0,0 @@ - - - - - Leg - - 10345 - urn:oma:lwm2m:x:10345 - 1.0 - 1.0 - Multiple - Optional - - - Leg Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10346.xml b/transport/lwm2m/src/main/data/models/10346.xml deleted file mode 100644 index 7e861471ac..0000000000 --- a/transport/lwm2m/src/main/data/models/10346.xml +++ /dev/null @@ -1,82 +0,0 @@ - - - - - Servomotor - - 10346 - urn:oma:lwm2m:x:10346 - 1.0 - 1.0 - Multiple - Optional - - - Servomotor Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10347.xml b/transport/lwm2m/src/main/data/models/10347.xml deleted file mode 100644 index 9c0bdf1aa0..0000000000 --- a/transport/lwm2m/src/main/data/models/10347.xml +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Screen - - 10347 - urn:oma:lwm2m:x:10347 - 1.0 - 1.0 - Single - Optional - - - Screen Status - R - Single - Mandatory - Boolean - - - - - - Startup Page - R - Single - Optional - String - - - The Startup Page of the screen. - - - Current Displaying Page or Current Screen Play List - R - Single - Optional - String - - - Current Displaying Page or Current Screen Play List. - - - - Screen Control - E - Single - Mandatory - - - - - - - Startup Page Set - E - Single - Mandatory - - - - - - - Screen Page Set - E - Single - Mandatory - - - - - - - Screen Play List Set - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10348.xml b/transport/lwm2m/src/main/data/models/10348.xml deleted file mode 100644 index e06d17da3b..0000000000 --- a/transport/lwm2m/src/main/data/models/10348.xml +++ /dev/null @@ -1,82 +0,0 @@ - - - - - Wheel - - 10348 - urn:oma:lwm2m:x:10348 - 1.0 - 1.0 - Multiple - Optional - - - Wheel Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10349.xml b/transport/lwm2m/src/main/data/models/10349.xml deleted file mode 100644 index dae4a6a9cb..0000000000 --- a/transport/lwm2m/src/main/data/models/10349.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - Chassis - - 10349 - urn:oma:lwm2m:x:10349 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10350.xml b/transport/lwm2m/src/main/data/models/10350.xml deleted file mode 100644 index 6b822be2d6..0000000000 --- a/transport/lwm2m/src/main/data/models/10350.xml +++ /dev/null @@ -1,102 +0,0 @@ - - - - - Light - - 10350 - urn:oma:lwm2m:x:10350 - 1.0 - 1.0 - Multiple - Optional - - - Light Name - R - Single - Mandatory - String - - - - - - - - Light Status - R - Single - Mandatory - Boolean - - - - - - - Light Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10351.xml b/transport/lwm2m/src/main/data/models/10351.xml deleted file mode 100644 index 379fa6c581..0000000000 --- a/transport/lwm2m/src/main/data/models/10351.xml +++ /dev/null @@ -1,65 +0,0 @@ - - - - - Door - - 10351 - urn:oma:lwm2m:x:10351 - 1.0 - 1.0 - Multiple - Optional - - - Door Name - R - Single - Mandatory - String - - - - - - - Door Status - R - Single - Mandatory - Boolean - - - - - - - Door Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10352.xml b/transport/lwm2m/src/main/data/models/10352.xml deleted file mode 100644 index ddd9907b3f..0000000000 --- a/transport/lwm2m/src/main/data/models/10352.xml +++ /dev/null @@ -1,100 +0,0 @@ - - - - - Thermal Imager - - 10352 - urn:oma:lwm2m:x:10352 - 1.0 - 1.0 - Single - Optional - - - - Highest Temperature - R - Single - Mandatory - Float - -100.0..100.0 - Cel - The Highest Temperature of the thermal imager. - - - Lowest Temperature - R - Single - Mandatory - Float - -100.0..100.0 - Cel - The Lowest Temperature of the thermal imager. - - - Average Temperature - R - Single - Mandatory - Float - -100.0..100.0 - Cel - The Average Temperature of the thermal imager. - - - - - diff --git a/transport/lwm2m/src/main/data/models/10353.xml b/transport/lwm2m/src/main/data/models/10353.xml deleted file mode 100644 index dcb0fa534b..0000000000 --- a/transport/lwm2m/src/main/data/models/10353.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - Warning Light - - 10353 - urn:oma:lwm2m:x:10353 - 1.0 - 1.0 - Single - Optional - - - Light Status - R - Single - Mandatory - Boolean - - - - - - Light Warning - R - Single - Mandatory - Boolean - - - - - - Light Control - E - Single - Mandatory - - - - - - - Light Warning Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10354.xml b/transport/lwm2m/src/main/data/models/10354.xml deleted file mode 100644 index f1faa3b18b..0000000000 --- a/transport/lwm2m/src/main/data/models/10354.xml +++ /dev/null @@ -1,203 +0,0 @@ - - - - - APP - - 10354 - urn:oma:lwm2m:x:10354 - 1.0 - 1.0 - Multiple - Mandatory - - - APP Name - RW - Single - Mandatory - String - - - The name of the APP, human readable string. - - - APP Version - RW - Single - Mandatory - String - - - The version of the APP, human readable string. - - - APP Build No - RW - Single - Optional - String - - - The Build No of the APP, human readable string. - - - APP Patch No - RW - Single - Optional - String - - - The Patch No of the APP, human readable string. - - - Package URI - W - Single - Optional - String - 0-255 bytes - - - - - Vendor Name - RW - Single - Optional - String - - - The vendor of the package. - - - Installation Target - RW - Single - Mandatory - Objlnk - - - - - - APP Status - R - Single - Mandatory - Integer - 0..5 - - The Status of the APP, 0:Downloading, 1:Downloaded, 2:Installed, 3:Verified, 4:Activated, 5:Stopped. - - - APP Restart - E - Single - Mandatory - - - - - - - APP Start - E - Single - Mandatory - - - - - - - APP Stop - E - Single - Mandatory - - - - - - - APP Download - E - Single - Mandatory - - - - - - - APP Install - E - Single - Mandatory - - - - - - - APP Uninstall - E - Single - Mandatory - - - - - - - APP Activate - E - Single - Mandatory - - - - - - - APP Deactivate - E - Single - Mandatory - - - - - - - APP Verify - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10355.xml b/transport/lwm2m/src/main/data/models/10355.xml deleted file mode 100644 index e485bd488a..0000000000 --- a/transport/lwm2m/src/main/data/models/10355.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - General Info - - 10355 - urn:oma:lwm2m:x:10355 - 1.0 - 1.0 - Single - Optional - - - Robot General Info - R - Single - Mandatory - Objlnk - - - - - - - - RCU General Info - R - Single - Mandatory - Objlnk - - - - - - - - CCU General Info - R - Multiple - Optional - Objlnk - - - - - - - - ECU General Info - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10356.xml b/transport/lwm2m/src/main/data/models/10356.xml deleted file mode 100644 index 2de0ff6741..0000000000 --- a/transport/lwm2m/src/main/data/models/10356.xml +++ /dev/null @@ -1,189 +0,0 @@ - - - - - Service Info - - 10356 - urn:oma:lwm2m:x:10356 - 1.0 - 1.0 - Single - Optional - - - Robot Service Info - R - Single - Mandatory - Objlnk - - - - - - - - SCA Info - R - Multiple - Optional - Objlnk - - - - - - - - Speaker Info - R - Single - Optional - Objlnk - - - - - - - - Camera Info - R - Multiple - Optional - Objlnk - - - - - - - - Screen Info - R - Single - Optional - Objlnk - - - - - - - - Light Info - R - Multiple - Optional - Objlnk - - - - - - - - Warning Light Info - R - Single - Optional - Objlnk - - - - - - - - Door Info - R - Multiple - Optional - Objlnk - - - - - - - - Thermal Imager Info - R - Single - Optional - Objlnk - - - - - - - - Compressor Info - R - Multiple - Optional - Objlnk - - - - - - - - Lock Info - R - Multiple - Optional - Objlnk - - - - - - - - Collision Sensor Info - R - Multiple - Optional - Objlnk - - - - - - - - Drop Sensor Info - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10357.xml b/transport/lwm2m/src/main/data/models/10357.xml deleted file mode 100644 index dec2d805ce..0000000000 --- a/transport/lwm2m/src/main/data/models/10357.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - PM - - 10357 - urn:oma:lwm2m:x:10357 - 1.0 - 1.0 - Single - Optional - - - Robot PM - R - Single - Mandatory - Objlnk - - - - - - - - RCU PM - R - Single - Mandatory - Objlnk - - - - - - - - CCU PM - R - Multiple - Optional - Objlnk - - - - - - - - SCA PM - R - Multiple - Optional - Objlnk - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10358.xml b/transport/lwm2m/src/main/data/models/10358.xml deleted file mode 100644 index 4be63ea09b..0000000000 --- a/transport/lwm2m/src/main/data/models/10358.xml +++ /dev/null @@ -1,56 +0,0 @@ - - - - - Fan PM - - 10358 - urn:oma:lwm2m:x:10358 - 1.0 - 1.0 - Multiple - Optional - - - Fan Name - R - Single - Mandatory - String - - - - - - - - - Fan Speed - R - Single - Optional - Integer - - 1/min - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10359.xml b/transport/lwm2m/src/main/data/models/10359.xml deleted file mode 100644 index 7f11ffa2e9..0000000000 --- a/transport/lwm2m/src/main/data/models/10359.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - Lock - - 10359 - urn:oma:lwm2m:x:10359 - 1.0 - 1.0 - Multiple - Optional - - - Lock Name - R - Single - Mandatory - String - - - - - - Lock Status - R - Single - Optional - Boolean - - - - - - - Lock Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10360.xml b/transport/lwm2m/src/main/data/models/10360.xml deleted file mode 100644 index 6908c5c80d..0000000000 --- a/transport/lwm2m/src/main/data/models/10360.xml +++ /dev/null @@ -1,56 +0,0 @@ - - - - - Ultrasonic Sensor - - 10360 - urn:oma:lwm2m:x:10360 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10361.xml b/transport/lwm2m/src/main/data/models/10361.xml deleted file mode 100644 index 1821406a8b..0000000000 --- a/transport/lwm2m/src/main/data/models/10361.xml +++ /dev/null @@ -1,78 +0,0 @@ - - - - - Collision Sensor - - 10361 - urn:oma:lwm2m:x:10361 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - - Collision Detection - R - Single - Optional - Boolean - - - - - - - Collision Detection Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10362.xml b/transport/lwm2m/src/main/data/models/10362.xml deleted file mode 100644 index 2def77cd12..0000000000 --- a/transport/lwm2m/src/main/data/models/10362.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - - Drop Sensor - - 10362 - urn:oma:lwm2m:x:10362 - 1.0 - 1.0 - Multiple - Optional - - - Name - R - Single - Mandatory - String - - - - - - - - Status - R - Single - Mandatory - Integer - - - - - - Drop Detection - R - Single - Optional - Boolean - - - - - - - Drop Detection Control - E - Single - Mandatory - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10363.xml b/transport/lwm2m/src/main/data/models/10363.xml deleted file mode 100644 index b34b54ccfe..0000000000 --- a/transport/lwm2m/src/main/data/models/10363.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - Temperature Sensor - - 10363 - urn:oma:lwm2m:x:10363 - 1.0 - 1.0 - Single - Optional - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10364.xml b/transport/lwm2m/src/main/data/models/10364.xml deleted file mode 100644 index 09b64e24ad..0000000000 --- a/transport/lwm2m/src/main/data/models/10364.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - Humidity Sensor - - 10364 - urn:oma:lwm2m:x:10364 - 1.0 - 1.0 - Single - Optional - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10365.xml b/transport/lwm2m/src/main/data/models/10365.xml deleted file mode 100644 index 6f5e3bb37b..0000000000 --- a/transport/lwm2m/src/main/data/models/10365.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - Gas-Dust Sensor - - 10365 - urn:oma:lwm2m:x:10365 - 1.0 - 1.0 - Single - Optional - - - Status - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10366.xml b/transport/lwm2m/src/main/data/models/10366.xml deleted file mode 100644 index be603eeaee..0000000000 --- a/transport/lwm2m/src/main/data/models/10366.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - Fan - - 10366 - urn:oma:lwm2m:x:10366 - 1.0 - 1.0 - Multiple - Optional - - - Fan Name - R - Single - Mandatory - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10368.xml b/transport/lwm2m/src/main/data/models/10368.xml deleted file mode 100644 index 694219f23d..0000000000 --- a/transport/lwm2m/src/main/data/models/10368.xml +++ /dev/null @@ -1,82 +0,0 @@ - - - - - SpringMotor - - 10368 - urn:oma:lwm2m:x:10368 - 1.0 - 1.0 - Multiple - Optional - - - SpringMotor Name - R - Single - Mandatory - String - - - - - - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/10369.xml b/transport/lwm2m/src/main/data/models/10369.xml deleted file mode 100644 index 7f86a4a33a..0000000000 --- a/transport/lwm2m/src/main/data/models/10369.xml +++ /dev/null @@ -1,70 +0,0 @@ - - - - - MCU - - 10369 - urn:oma:lwm2m:x:10369 - 1.0 - 1.0 - Single - Optional - - - Host Device Unique ID - R - Single - Optional - String - - - - - - - - Host Device Manufacturer - R - Single - Optional - String - - - - - - - - Host Device Model Number - R - Single - Optional - String - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2048.xml b/transport/lwm2m/src/main/data/models/2048.xml deleted file mode 100644 index 5dc5c7ebaf..0000000000 --- a/transport/lwm2m/src/main/data/models/2048.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - - CmdhPolicy - - 2048 - urn:oma:lwm2m:ext:20481.0 - 1.0Multiple - Optional - - Name - RW - Single - Mandatory - String - - - - - DefaultRule - RW - Single - Mandatory - Objlnk - - - - - LimiRules - RW - Multiple - Mandatory - Objlnk - - - - - NetworkAccessECRules - RW - Multiple - Mandatory - Objlnk - - - - - BufferRules - RW - Multiple - Mandatory - Objlnk - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2049.xml b/transport/lwm2m/src/main/data/models/2049.xml deleted file mode 100644 index 600e437189..0000000000 --- a/transport/lwm2m/src/main/data/models/2049.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - - - ActiveCmdhPolicy - - 2049 - urn:oma:lwm2m:ext:20491.0 - 1.0Single - Optional - - ActiveLink - RW - Single - Mandatory - Objlnk - - - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2050.xml b/transport/lwm2m/src/main/data/models/2050.xml deleted file mode 100644 index caef96ef00..0000000000 --- a/transport/lwm2m/src/main/data/models/2050.xml +++ /dev/null @@ -1,49 +0,0 @@ - - - - - CmdhDefaults - - 2050 - urn:oma:lwm2m:ext:20501.0 - 1.0Multiple - Optional - - DefaultEcRules - RW - Multiple - Mandatory - Objlnk - - - - - - DefaultEcParamRules - RW - Multiple - Mandatory - Objlnk - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2051.xml b/transport/lwm2m/src/main/data/models/2051.xml deleted file mode 100644 index 828cfb809b..0000000000 --- a/transport/lwm2m/src/main/data/models/2051.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - CmdhDefEcValues - - 2051 - urn:oma:lwm2m:ext:20511.0 - 1.0Multiple - Optional - - Order - RW - Single - Mandatory - Integer - - - - - DefEcValue - RW - Single - Mandatory - String - - - - - RequestOrigin - RW - Multiple - Mandatory - String - - - - - RequestContext - RW - Single - Optional - String - - - - - RequestContextNotification - RW - Single - Optional - Boolean - - - - - RequestCharacteristics - RW - Single - Optional - String - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2052.xml b/transport/lwm2m/src/main/data/models/2052.xml deleted file mode 100644 index eccdac1d77..0000000000 --- a/transport/lwm2m/src/main/data/models/2052.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - CmdhEcDefParamValues - - 2052 - urn:oma:lwm2m:ext:20521.0 - 1.0Multiple - Optional - - ApplicableEventCategory - RW - Multiple - Mandatory - Integer - - - - - DefaultRequestExpTime - RW - Single - Mandatory - Integer - - ms - - - - - - - - - DefaultResultExpTime - RW - Single - Mandatory - Integer - - ms - - - - DefaultOpExecTime - RW - Single - Mandatory - Integer - - ms - - - DefaultRespPersistence - RW - Single - Mandatory - Integer - - ms - - - DefaultDelAggregation - RW - Single - Mandatory - Integer - - ms - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2053.xml b/transport/lwm2m/src/main/data/models/2053.xml deleted file mode 100644 index 6e822a4f82..0000000000 --- a/transport/lwm2m/src/main/data/models/2053.xml +++ /dev/null @@ -1,150 +0,0 @@ - - - - - CmdhLimits - - 2053 - urn:oma:lwm2m:ext:20531.0 - 1.0Multiple - Optional - - Order - RW - Single - Mandatory - Integer - - - - - RequestOrigin - RW - Multiple - Mandatory - String - - - - - - - - - - - RequestContext - RW - Single - Optional - String - - - - - - RequestContextNotificatio - RW - Single - Optional - Boolean - - - - - RequestCharacteristics - RW - Single - Optional - String - - - - - LimitsEventCategory - RW - Multiple - Mandatory - Integer - - - - - LimitsRequestExpTime - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsResultExpTime - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsOptExpTime - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsRespPersistence - RW - Multiple - Mandatory - Integer - 2 Instances - ms - - - LimitsDelAggregation - RW - Multiple - Mandatory - String - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2054.xml b/transport/lwm2m/src/main/data/models/2054.xml deleted file mode 100644 index c99c16991c..0000000000 --- a/transport/lwm2m/src/main/data/models/2054.xml +++ /dev/null @@ -1,54 +0,0 @@ - - - - - CmdhNetworkAccessRules - - 2054 - urn:oma:lwm2m:ext:20541.0 - 1.0Multiple - Optional - - ApplicableEventCategories - RW - Multiple - Mandatory - Integer - - - - - NetworkAccessRule - RW - Multiple - Optional - Objlnk - - - - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2055.xml b/transport/lwm2m/src/main/data/models/2055.xml deleted file mode 100644 index f847b64c29..0000000000 --- a/transport/lwm2m/src/main/data/models/2055.xml +++ /dev/null @@ -1,85 +0,0 @@ - - - - - CmdhNwAccessRule - - 2055 - urn:oma:lwm2m:ext:20551.0 - 1.0Multiple - Optional - - TargetNetwork - RW - Multiple - Mandatory - String - - - - - SpreadingWaitTime - RW - Single - Mandatory - Integer - - ms - - - MinReqVolume - RW - Single - Mandatory - Integer - - B - - - BackOffParameters - RW - Single - Mandatory - Objlnk - - - - - OtherConditions - RW - Single - Mandatory - String - - - - - AllowedSchedule - RW - Multiple - Mandatory - String - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2056.xml b/transport/lwm2m/src/main/data/models/2056.xml deleted file mode 100644 index 5f643093f5..0000000000 --- a/transport/lwm2m/src/main/data/models/2056.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - - - CmdhBuffer - - 2056 - urn:oma:lwm2m:ext:20561.0 - 1.0Multiple - Optional - - ApplicableEventCategory - RW - Multiple - Mandatory - Integer - - - - - MaxBufferSize - RW - Single - Mandatory - Integer - - B - - - StoragePriority - RW - Single - Mandatory - Integer - 1..10 - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/2057.xml b/transport/lwm2m/src/main/data/models/2057.xml deleted file mode 100644 index 5ac9c96519..0000000000 --- a/transport/lwm2m/src/main/data/models/2057.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - - CmdhBackOffParametersSet - - 2057 - urn:oma:lwm2m:ext:2057 - 1.0 - 1.0 - Multiple - Optional - - NetworkAction - RW - Single - Optional - Integer - 1..5 - - - - InitialBackoffTime - RW - Single - Mandatory - Integer - - ms - - - AdditionalBackoffTime - RW - Single - Mandatory - Integer - - ms - - - MaximumBackoffTime - RW - Single - Mandatory - Integer - - ms - - - OptionalRandomBackoffTime - RW - Multiple - Optional - Integer - - ms - - - - - diff --git a/transport/lwm2m/src/main/data/models/31024.xml b/transport/lwm2m/src/main/data/models/31024.xml deleted file mode 100644 index 00d27c32f8..0000000000 --- a/transport/lwm2m/src/main/data/models/31024.xml +++ /dev/null @@ -1,68 +0,0 @@ - - - - - Test - A Wakaama object for testing purpose. - - 31024 - urn:oma:lwm2m:x:31024 - Multiple - Optional - - - test - RW - Single - Mandatory - Integer - 0-255 - - - - exec - E - Single - Mandatory - - - - dec - RW - Single - Mandatory - Float - - - - - - sig - RW - Single - Optional - Integer - - - 16-bit signed integer - - - - - diff --git a/transport/lwm2m/src/main/data/models/3200.xml b/transport/lwm2m/src/main/data/models/3200.xml deleted file mode 100644 index 9e1a994efc..0000000000 --- a/transport/lwm2m/src/main/data/models/3200.xml +++ /dev/null @@ -1,114 +0,0 @@ - - - - - - Digital Input - Generic digital input for non-specific sensors - 3200 - urn:oma:lwm2m:ext:3200 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The cumulative value of active state detected. - - - Digital Input Polarity - RW - Single - Optional - Boolean - - - The polarity of the digital input as a Boolean (False = Normal, True = Reversed). - - - Digital Input Debounce - RW - Single - Optional - Integer - - ms - The debounce period in ms. - - - Digital Input Edge Selection - RW - Single - Optional - Integer - 1..3 - - The edge selection as an integer (1 = Falling edge, 2 = Rising edge, 3 = Both Rising and Falling edge). - - - Digital Input Counter Reset - E - Single - Optional - - - - Reset the Counter value. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor (for instance PIR type) - - - - - diff --git a/transport/lwm2m/src/main/data/models/3201.xml b/transport/lwm2m/src/main/data/models/3201.xml deleted file mode 100644 index 32484c8be1..0000000000 --- a/transport/lwm2m/src/main/data/models/3201.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - Digital Output - Generic digital output for non-specific actuators - 3201 - urn:oma:lwm2m:ext:3201 - 1.0 - 1.0 - Multiple - Optional - - - Digital Output State - RW - Single - Mandatory - Boolean - - - The current state of a digital output. - - - Digital Output Polarity - RW - Single - Optional - Boolean - - - The polarity of the digital output as a Boolean (False = Normal, True = Reversed). - - - Application Type - RW - Single - Optional - String - - - The application type of the output as a string, for instance, "LED" - - - - - diff --git a/transport/lwm2m/src/main/data/models/3202.xml b/transport/lwm2m/src/main/data/models/3202.xml deleted file mode 100644 index 391abb5a0f..0000000000 --- a/transport/lwm2m/src/main/data/models/3202.xml +++ /dev/null @@ -1,113 +0,0 @@ - - - - - Analog Input - Generic analog input for non-specific sensors - 3202 - urn:oma:lwm2m:ext:3202 - 1.0 - 1.0 - Multiple - Optional - - - Analog Input Current Value - R - Single - Mandatory - Float - - - The current value of the analog input. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor, for instance PIR type - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/transport/lwm2m/src/main/data/models/3203.xml b/transport/lwm2m/src/main/data/models/3203.xml deleted file mode 100644 index 4dd1ae8c40..0000000000 --- a/transport/lwm2m/src/main/data/models/3203.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - Analog Output - This IPSO object is a generic object that can be used with any kind of analog output interface. - 3203 - urn:oma:lwm2m:ext:3203 - 1.0 - 1.0 - Multiple - Optional - - - Analog Output Current Value - RW - Single - Mandatory - Float - 0..1 - - The current state of the analogue output. - - - Application Type - RW - Single - Optional - String - - - If present, the application type of the actuator as a string, for instance, "Valve" - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be set for the output - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be set for the output - - - - - diff --git a/transport/lwm2m/src/main/data/models/3300.xml b/transport/lwm2m/src/main/data/models/3300.xml deleted file mode 100644 index 20ab00a0d3..0000000000 --- a/transport/lwm2m/src/main/data/models/3300.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - - - Generic Sensor - This IPSO object allows the description of a generic sensor. It is based on the description of a value and a unit according to the SenML specification. Thus, any type of value defined within this specification can be reported using this object. This object may be used as a generic object if a dedicated one does not exist. - 3300 - urn:oma:lwm2m:ext:3300 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Application Type - RW - Single - Optional - String - - - If present, the application type of the sensor as a string, for instance, "CO2" - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor (for instance PIR type) - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/transport/lwm2m/src/main/data/models/3301.xml b/transport/lwm2m/src/main/data/models/3301.xml deleted file mode 100644 index 923c7dc176..0000000000 --- a/transport/lwm2m/src/main/data/models/3301.xml +++ /dev/null @@ -1,103 +0,0 @@ - - - - - Illuminance - Illuminance sensor, example units = lx - 3301 - urn:oma:lwm2m:ext:3301 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - The current value of the luminosity sensor. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3302.xml b/transport/lwm2m/src/main/data/models/3302.xml deleted file mode 100644 index ba49a72f5a..0000000000 --- a/transport/lwm2m/src/main/data/models/3302.xml +++ /dev/null @@ -1,93 +0,0 @@ - - - - - Presence - Presence sensor with digital sensing, optional delay parameters - 3302 - urn:oma:lwm2m:ext:3302 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of the presence sensor - - - Digital Input Counter - R - Single - Optional - Integer - - - The cumulative value of active state detected. - - - Digital Input Counter Reset - E - Single - Optional - - - - Reset the Counter value - - - Sensor Type - R - Single - Optional - String - - - The type of the sensor (for instance PIR type) - - - Busy to Clear delay - RW - Single - Optional - Integer - - ms - Delay from the detection state to the clear state in ms - - - Clear to Busy delay - RW - Single - Optional - Integer - - ms - Delay from the clear state to the busy state in ms - - - - - diff --git a/transport/lwm2m/src/main/data/models/3303.xml b/transport/lwm2m/src/main/data/models/3303.xml deleted file mode 100644 index b73e967135..0000000000 --- a/transport/lwm2m/src/main/data/models/3303.xml +++ /dev/null @@ -1,103 +0,0 @@ - - - - - Temperature - This IPSO object should be used with a temperature sensor to report a temperature measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range that can be measured by the temperature sensor. An example measurement unit is degrees Celsius. - 3303 - urn:oma:lwm2m:ext:3303 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/transport/lwm2m/src/main/data/models/3304.xml b/transport/lwm2m/src/main/data/models/3304.xml deleted file mode 100644 index 47b4361c96..0000000000 --- a/transport/lwm2m/src/main/data/models/3304.xml +++ /dev/null @@ -1,103 +0,0 @@ - - - - - Humidity - This IPSO object should be used with a humidity sensor to report a humidity measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range that can be measured by the humidity sensor. An example measurement unit is relative humidity as a percentage. - 3304 - urn:oma:lwm2m:ext:3304 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/transport/lwm2m/src/main/data/models/3305.xml b/transport/lwm2m/src/main/data/models/3305.xml deleted file mode 100644 index 314c6b6a8e..0000000000 --- a/transport/lwm2m/src/main/data/models/3305.xml +++ /dev/null @@ -1,213 +0,0 @@ - - - - - Power Measurement - This IPSO object should be used over a power measurement sensor to report a remote power measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range for both active and reactive power. It also provides resources for cumulative energy, calibration, and the power factor. - 3305 - urn:oma:lwm2m:ext:3305 - 1.0 - 1.0 - Multiple - Optional - - - Instantaneous active power - R - Single - Mandatory - Float - - W - The current active power - - - Min Measured active power - R - Single - Optional - Float - - W - The minimum active power measured by the sensor since it is ON - - - Max Measured active power - R - Single - Optional - Float - - W - The maximum active power measured by the sensor since it is ON - - - Min Range active power - R - Single - Optional - Float - - W - The minimum active power that can be measured by the sensor - - - Max Range active power - R - Single - Optional - Float - - W - The maximum active power that can be measured by the sensor - - - Cumulative active power - R - Single - Optional - Float - - Wh - The cumulative active power since the last cumulative energy reset or device start - - - Active Power Calibration - W - Single - Optional - Float - - W - Request an active power calibration by writing the value of a calibrated load. - - - Instantaneous reactive power - R - Single - Optional - Float - - var - The current reactive power - - - Min Measured reactive power - R - Single - Optional - Float - - var - The minimum reactive power measured by the sensor since it is ON - - - Max Measured reactive power - R - Single - Optional - Float - - var - The maximum reactive power measured by the sensor since it is ON - - - Min Range reactive power - R - Single - Optional - Float - - var - The minimum active power that can be measured by the sensor - - - Max Range reactive power - R - Single - Optional - Float - - var - The maximum reactive power that can be measured by the sensor - - - Cumulative reactive power - R - Single - Optional - Float - - varh - The cumulative reactive power since the last cumulative energy reset or device start - - - Reactive Power Calibration - W - Single - Optional - Float - - var - Request a reactive power calibration by writing the value of a calibrated load. - - - Power factor - R - Single - Optional - Float - - - If applicable, the power factor of the current consumption. - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Reset Cumulative energy - E - Single - Optional - - - - Reset both cumulative active/reactive power - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/transport/lwm2m/src/main/data/models/3306.xml b/transport/lwm2m/src/main/data/models/3306.xml deleted file mode 100644 index a1534488c5..0000000000 --- a/transport/lwm2m/src/main/data/models/3306.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - - - Actuation - This IPSO object is dedicated to remote actuation such as ON/OFF action or dimming. A multi-state output can also be described as a string. This is useful to send pilot wire orders for instance. It also provides a resource to reflect the time that the device has been switched on. - 3306 - urn:oma:lwm2m:ext:3306 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Dimmer - RW - Single - Optional - Integer - 0..100 - /100 - This resource represents a light dimmer setting, which has an Integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the device has been on. Writing a value of 0 resets the counter. - - - Muti-state Output - RW - Single - Optional - String - - - A string describing a state for multiple level output such as Pilot Wire - - - Application Type - RW - Single - Optional - String - - - The Application type of the device, for example "Motion Closure". - - - - - diff --git a/transport/lwm2m/src/main/data/models/3308.xml b/transport/lwm2m/src/main/data/models/3308.xml deleted file mode 100644 index 021f172572..0000000000 --- a/transport/lwm2m/src/main/data/models/3308.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - Set Point - This IPSO object should be used to set a desired value to a controller, such as a thermostat. A special resource is added to set the colour of an object. - 3308 - urn:oma:lwm2m:ext:3308 - 1.0 - 1.0 - Multiple - Optional - - - Set Point Value - RW - Single - Mandatory - Float - - - The setpoint value. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Colour - RW - Single - Optional - String - - - A string representing a value in some color space - - - Application Type - RW - Single - Optional - String - - - The Application type of the device, for example "Motion Closure". - - - - - diff --git a/transport/lwm2m/src/main/data/models/3310.xml b/transport/lwm2m/src/main/data/models/3310.xml deleted file mode 100644 index 74408d45aa..0000000000 --- a/transport/lwm2m/src/main/data/models/3310.xml +++ /dev/null @@ -1,93 +0,0 @@ - - - - - Load Control - This Object is used for demand-response load control and other load control in automation application (not limited to power). - 3310 - urn:oma:lwm2m:ext:3310 - 1.0 - 1.0 - Multiple - Optional - - - Event Identifier - RW - Single - Mandatory - String - - - The event identifier as a string. - - - Start Time - RW - Single - Mandatory - Time - - - Time when the event started. - - - Duration In Min - RW - Single - Mandatory - Integer - - min - The duration of the event in minutes. - - - Criticality Level - RW - Single - Optional - Integer - 0..3 - - The criticality of the event. The device receiving the event will react in an appropriate fashion for the device. - - - Avg Load AdjPct - RW - Single - Optional - Integer - 0..100 - /100 - Defines the maximum energy usage of the receiving device, as a percentage of the device's normal maximum energy usage. - - - Duty Cycle - RW - Single - Optional - Integer - 0..100 - /100 - Defines the duty cycle for the load control event, i.e, what percentage of time the receiving device is allowed to be on. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3311.xml b/transport/lwm2m/src/main/data/models/3311.xml deleted file mode 100644 index e27543c055..0000000000 --- a/transport/lwm2m/src/main/data/models/3311.xml +++ /dev/null @@ -1,113 +0,0 @@ - - - - - Light Control - This Object is used to control a light source, such as a LED or other light. It allows a light to be turned on or off and its dimmer setting to be control as a % between 0 and 100. An optional colour setting enables a string to be used to indicate the desired colour. - 3311 - urn:oma:lwm2m:ext:3311 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Dimmer - RW - Single - Optional - Integer - 0..100 - /100 - This resource represents a light dimmer setting, which has an Integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the light has been on. Writing a value of 0 resets the counter. - - - Cumulative active power - R - Single - Optional - Float - - Wh - The total power in Wh that the light has used. - - - Power factor - R - Single - Optional - Float - - - The power factor of the light. - - - Colour - RW - Single - Optional - String - - - A string representing a value in some color space - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - - - diff --git a/transport/lwm2m/src/main/data/models/3312.xml b/transport/lwm2m/src/main/data/models/3312.xml deleted file mode 100644 index 395db11213..0000000000 --- a/transport/lwm2m/src/main/data/models/3312.xml +++ /dev/null @@ -1,93 +0,0 @@ - - - - - Power Control - This Object is used to control a power source, such as a Smart Plug. It allows a power relay to be turned on or off and its dimmer setting to be control as a % between 0 and 100. - 3312 - urn:oma:lwm2m:ext:3312 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Dimmer - RW - Single - Optional - Integer - 0..100 - /100 - This resource represents a power dimmer setting, which has an Integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the power relay has been on. Writing a value of 0 resets the counter. - - - Cumulative active power - R - Single - Optional - Float - - Wh - The total power in Wh that has been used by the load. - - - Power factor - R - Single - Optional - Float - - - The power factor of the load. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string, for instance, "Air Pressure" - - - - - diff --git a/transport/lwm2m/src/main/data/models/3313.xml b/transport/lwm2m/src/main/data/models/3313.xml deleted file mode 100644 index 6617d8eaa0..0000000000 --- a/transport/lwm2m/src/main/data/models/3313.xml +++ /dev/null @@ -1,93 +0,0 @@ - - - - - Accelerometer - This IPSO object can be used to represent a 1-3 axis accelerometer. - 3313 - urn:oma:lwm2m:ext:3313 - 1.0 - 1.0 - Multiple - Optional - - - X Value - R - Single - Mandatory - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - - - diff --git a/transport/lwm2m/src/main/data/models/3314.xml b/transport/lwm2m/src/main/data/models/3314.xml deleted file mode 100644 index 6c1379171c..0000000000 --- a/transport/lwm2m/src/main/data/models/3314.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - - - Magnetometer - This IPSO object can be used to represent a 1-3 axis magnetometer with optional compass direction. - 3314 - urn:oma:lwm2m:ext:3314 - 1.0 - 1.0 - Multiple - Optional - - - X Value - R - Single - Mandatory - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Compass Direction - R - Single - Optional - Float - 0..360 - deg - The measured compass direction. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3315.xml b/transport/lwm2m/src/main/data/models/3315.xml deleted file mode 100644 index 61db630342..0000000000 --- a/transport/lwm2m/src/main/data/models/3315.xml +++ /dev/null @@ -1,103 +0,0 @@ - - - - - Barometer - This IPSO object should be used with an air pressure sensor to report a barometer measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range that can be measured by the barometer sensor. An example measurement unit is pascals. - 3315 - urn:oma:lwm2m:ext:3315 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - - - diff --git a/transport/lwm2m/src/main/data/models/3316.xml b/transport/lwm2m/src/main/data/models/3316.xml deleted file mode 100644 index b7cd6fba52..0000000000 --- a/transport/lwm2m/src/main/data/models/3316.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Voltage - This IPSO object should be used with voltmeter sensor to report measured voltage between two points. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is volts. - - 3316 - urn:oma:lwm2m:ext:3316 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3317.xml b/transport/lwm2m/src/main/data/models/3317.xml deleted file mode 100644 index da57a69036..0000000000 --- a/transport/lwm2m/src/main/data/models/3317.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Current - This IPSO object should be used with an ammeter to report measured electric current in amperes. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is ampere. - - 3317 - urn:oma:lwm2m:ext:3317 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3318.xml b/transport/lwm2m/src/main/data/models/3318.xml deleted file mode 100644 index add0f7bd59..0000000000 --- a/transport/lwm2m/src/main/data/models/3318.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Frequency - This IPSO object should be used to report frequency measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is hertz. - - 3318 - urn:oma:lwm2m:ext:3318 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3319.xml b/transport/lwm2m/src/main/data/models/3319.xml deleted file mode 100644 index dc23451a0c..0000000000 --- a/transport/lwm2m/src/main/data/models/3319.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Depth - This IPSO object should be used to report depth measurements. It can, for example, be used to describe a generic rain gauge that measures the accumulated rainfall in millimetres (mm). - - 3319 - urn:oma:lwm2m:ext:3319 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3320.xml b/transport/lwm2m/src/main/data/models/3320.xml deleted file mode 100644 index 17497bd3b0..0000000000 --- a/transport/lwm2m/src/main/data/models/3320.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Percentage - This IPSO object should can be used to report measurements relative to a 0-100% scale. For example it could be used to measure the level of a liquid in a vessel or container in units of %. - - 3320 - urn:oma:lwm2m:ext:3320 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3321.xml b/transport/lwm2m/src/main/data/models/3321.xml deleted file mode 100644 index e53e749494..0000000000 --- a/transport/lwm2m/src/main/data/models/3321.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Altitude - This IPSO object should be used with an altitude sensor to report altitude above sea level in meters. Note that Altitude can be calculated from the measured pressure given the local sea level pressure. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is meters. - - 3321 - urn:oma:lwm2m:ext:3321 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3322.xml b/transport/lwm2m/src/main/data/models/3322.xml deleted file mode 100644 index cc87893761..0000000000 --- a/transport/lwm2m/src/main/data/models/3322.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Load - This IPSO object should be used with a load sensor (as in a scale) to report the applied weight or force. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is kilograms. - - 3322 - urn:oma:lwm2m:ext:3322 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3323.xml b/transport/lwm2m/src/main/data/models/3323.xml deleted file mode 100644 index ffe2991229..0000000000 --- a/transport/lwm2m/src/main/data/models/3323.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Pressure - This IPSO object should be used to report pressure measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is pascals. - - 3323 - urn:oma:lwm2m:ext:3323 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3324.xml b/transport/lwm2m/src/main/data/models/3324.xml deleted file mode 100644 index f90fc40fa7..0000000000 --- a/transport/lwm2m/src/main/data/models/3324.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Loudness - This IPSO object should be used to report loudness or noise level measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is decibels. - - 3324 - urn:oma:lwm2m:ext:3324 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3325.xml b/transport/lwm2m/src/main/data/models/3325.xml deleted file mode 100644 index 68ffe881b9..0000000000 --- a/transport/lwm2m/src/main/data/models/3325.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Concentration - This IPSO object should be used to the particle concentration measurement of a medium. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is parts per million. - - 3325 - urn:oma:lwm2m:ext:3325 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3326.xml b/transport/lwm2m/src/main/data/models/3326.xml deleted file mode 100644 index 66112b1792..0000000000 --- a/transport/lwm2m/src/main/data/models/3326.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Acidity - This IPSO object should be used to report an acidity measurement of a liquid. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is pH. - - 3326 - urn:oma:lwm2m:ext:3326 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3327.xml b/transport/lwm2m/src/main/data/models/3327.xml deleted file mode 100644 index e5087ecbb3..0000000000 --- a/transport/lwm2m/src/main/data/models/3327.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Conductivity - This IPSO object should be used to report a measurement of the electric conductivity of a medium or sample. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is Siemens. - - 3327 - urn:oma:lwm2m:ext:3327 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3328.xml b/transport/lwm2m/src/main/data/models/3328.xml deleted file mode 100644 index 0eeb123c35..0000000000 --- a/transport/lwm2m/src/main/data/models/3328.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Power - This IPSO object should be used to report power measurements. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is Watts. This object may be used for either real power or apparent power measurements. - - 3328 - urn:oma:lwm2m:ext:3328 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3329.xml b/transport/lwm2m/src/main/data/models/3329.xml deleted file mode 100644 index ccfc356119..0000000000 --- a/transport/lwm2m/src/main/data/models/3329.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Power Factor - This IPSO object should be used to report a measurement or calculation of the power factor of a reactive electrical load. Power Factor is normally the ratio of non-reactive power to total power. This object also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. - - 3329 - urn:oma:lwm2m:ext:3329 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3330.xml b/transport/lwm2m/src/main/data/models/3330.xml deleted file mode 100644 index a9ca035a01..0000000000 --- a/transport/lwm2m/src/main/data/models/3330.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Distance - This IPSO object should be used to report a distance measurement. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is Meters. - - 3330 - urn:oma:lwm2m:ext:3330 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3331.xml b/transport/lwm2m/src/main/data/models/3331.xml deleted file mode 100644 index 2da640e45f..0000000000 --- a/transport/lwm2m/src/main/data/models/3331.xml +++ /dev/null @@ -1,74 +0,0 @@ - - - - - Energy - This IPSO object should be used to report energy consumption (Cumulative Power) of an electrical load. An example measurement unit is Watt Hours. - - 3331 - urn:oma:lwm2m:ext:3331 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Reset Cumulative energy - E - Single - Optional - - - - Reset both cumulative active/reactive power. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3332.xml b/transport/lwm2m/src/main/data/models/3332.xml deleted file mode 100644 index 26755629a7..0000000000 --- a/transport/lwm2m/src/main/data/models/3332.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - Direction - This IPSO object is used to report the direction indicated by a compass, wind vane, or other directional indicator. The units of measure is plane angle degrees. - - 3332 - urn:oma:lwm2m:ext:3332 - 1.0 - 1.0 - Multiple - Optional - - - Compass Direction - R - Single - Mandatory - Float - 0..360 - deg - The measured compass direction. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset. - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3333.xml b/transport/lwm2m/src/main/data/models/3333.xml deleted file mode 100644 index 62a574f68e..0000000000 --- a/transport/lwm2m/src/main/data/models/3333.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - Time - This IPSO object is used to report the current time in seconds since January 1, 1970 UTC. There is also a fractional time counter that has a range of less than one second. - - 3333 - urn:oma:lwm2m:ext:3333 - 1.0 - 1.0 - Multiple - Optional - - - Current Time - RW - Single - Mandatory - Time - - - Unix Time. A signed integer representing the number of seconds since Jan 1st, 1970 in the UTC time zone. - - - Fractional Time - RW - Single - Optional - Float - 0..1 - s - Fractional part of the time when sub-second precision is used (e.g., 0.23 for 230 ms). - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3334.xml b/transport/lwm2m/src/main/data/models/3334.xml deleted file mode 100644 index e72ec20cc3..0000000000 --- a/transport/lwm2m/src/main/data/models/3334.xml +++ /dev/null @@ -1,174 +0,0 @@ - - - - - Gyrometer - This IPSO Object is used to report the current reading of a gyrometer sensor in 3 axes. It provides tracking of the minimum and maximum angular rate in all 3 axes. An example unit of measure is radians per second. - - 3334 - urn:oma:lwm2m:ext:3334 - 1.0 - 1.0 - Multiple - Optional - - - X Value - R - Single - Mandatory - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min X Value - R - Single - Optional - Float - - - The minimum measured value along the X axis - - - Max X Value - R - Single - Optional - Float - - - The maximum measured value along the X axis - - - Min Y Value - R - Single - Optional - Float - - - The minimum measured value along the Y axis - - - Max Y Value - R - Single - Optional - Float - - - The maximum measured value along the Y axis - - - Min Z Value - R - Single - Optional - Float - - - The minimum measured value along the Z axis - - - Max Z Value - R - Single - Optional - Float - - - The maximum measured value along the Z axis - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value. - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3335.xml b/transport/lwm2m/src/main/data/models/3335.xml deleted file mode 100644 index 789c5d33a3..0000000000 --- a/transport/lwm2m/src/main/data/models/3335.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - Colour - This IPSO object should be used to report the measured value of a colour sensor in some colour space described by the units resource. - - 3335 - urn:oma:lwm2m:ext:3335 - 1.0 - 1.0 - Multiple - Optional - - - Colour - RW - Single - Mandatory - String - - - A string representing a value in some colour space. - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3336.xml b/transport/lwm2m/src/main/data/models/3336.xml deleted file mode 100644 index 5172c63156..0000000000 --- a/transport/lwm2m/src/main/data/models/3336.xml +++ /dev/null @@ -1,104 +0,0 @@ - - - - - Location - This IPSO object represents GPS coordinates. This object is compatible with the LWM2M management object for location, but uses reusable resources. - - 3336 - urn:oma:lwm2m:ext:3336 - 1.0 - 1.0 - Multiple - Optional - - - Latitude - R - Single - Mandatory - String - - - The decimal notation of latitude, e.g. -43.5723 (World Geodetic System 1984). - - - Longitude - R - Single - Mandatory - String - - - The decimal notation of longitude, e.g. 153.21760 (World Geodetic System 1984). - - - Uncertainty - R - Single - Optional - String - - - The accuracy of the position in meters. - - - Compass Direction - R - Single - Optional - Float - 0..360 - deg - The measured compass direction. - - - Velocity - R - Single - Optional - Opaque - - - The velocity of the device as defined in 3GPP 23.032 GAD specification. This set of values may not be available if the device is static. - - - Timestamp - R - Single - Optional - Time - - - The timestamp of when the measurement was performed. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3337.xml b/transport/lwm2m/src/main/data/models/3337.xml deleted file mode 100644 index 50abbe1621..0000000000 --- a/transport/lwm2m/src/main/data/models/3337.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Positioner - This IPSO object should be used with a generic position actuator with range from 0 to 100%. This object optionally allows setting the transition time for an operation that changes the position of the actuator, and for reading the remaining time of the currently active transition. - - 3337 - urn:oma:lwm2m:ext:3337 - 1.0 - 1.0 - Multiple - Optional - - - Current Position - RW - Single - Mandatory - Float - 0..100 - /100 - Current position or desired position of a positioner actuator. - - - Transition Time - RW - Single - Optional - Float - - s - The time expected to move the actuator to the new position. - - - Remaining Time - R - Single - Optional - Float - - s - The time remaining in an operation. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value set on the actuator since power ON or reset. - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value set on the actuator since power ON or reset. - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value. - - - Min Limit - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor. - - - Max Limit - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3338.xml b/transport/lwm2m/src/main/data/models/3338.xml deleted file mode 100644 index cfa1062a81..0000000000 --- a/transport/lwm2m/src/main/data/models/3338.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - Buzzer - This IPSO object should be used to actuate an audible alarm such as a buzzer, beeper, or vibration alarm. There is a dimmer control for setting the relative loudness of the alarm, and an optional duration control to limit the length of time the alarm sounds when turned on. Each time "true" is written to the On/Off resource, the alarm will sound again for the configured duration. If no duration is programmed or the setting is "false", writing a "true" to the On/Off resource will result in the alarm sounding continuously until a "false" is written to the On/Off resource. - - 3338 - urn:oma:lwm2m:ext:3338 - 1.0 - 1.0 - Multiple - Optional - - - On/Off - RW - Single - Mandatory - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Level - RW - Single - Optional - Float - 0..100 - /100 - Audio volume control, float value between 0 and 100 as a percentage. - - - Delay Duration - RW - Single - Optional - Float - - s - The duration of the time delay. - - - Minimum Off-time - RW - Single - Mandatory - Float - - s - The off time when On/Off control remains on. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3339.xml b/transport/lwm2m/src/main/data/models/3339.xml deleted file mode 100644 index 461b14c160..0000000000 --- a/transport/lwm2m/src/main/data/models/3339.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - - - Audio Clip - This IPSO object should be used for a speaker that plays a pre-recorded audio clip or an audio output that is sent elsewhere. For example, an elevator which announces the floor of the building. A resource is provided to store the clip, a dimmer resource controls the relative sound level of the playback, and a duration resource limits the maximum playback time. After the duration time is reached, any remaining samples in the clip are ignored, and the clip player will be ready to play another clip. - 3339 - urn:oma:lwm2m:ext:3339 - 1.0 - 1.0 - Multiple - Optional - - - Clip - RW - Single - Mandatory - Opaque - - - Audio clip that is playable (e.g., a short audio recording indicating the floor in an elevator). - - - Trigger - E - Single - Optional - - - - Trigger initiating actuation. - - - Level - RW - Single - Optional - Float - 0..100 - /100 - Audio volume control, float value between 0 and 100 as a percentage. - - - Duration - RW - Single - Optional - Float - - s - The duration of the sound once trigger. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3340.xml b/transport/lwm2m/src/main/data/models/3340.xml deleted file mode 100644 index 035b7e5bac..0000000000 --- a/transport/lwm2m/src/main/data/models/3340.xml +++ /dev/null @@ -1,144 +0,0 @@ - - - - - Timer - This IPSO object is used to time events and actions, using patterns common to industrial timers. A write to the trigger resource or On/Off input state change starts the timing operation, and the timer remaining time shows zero when the operation is complete. The patterns supported are One-Shot (mode 1), On-Time or Interval (mode 2), Time delay on pick-up or TDPU (mode 3), and Time Delay on Drop-Out or TDDO (mode 4). Mode 0 disables the timer, so the output follows the input with no delay. A counter is provided to count occurrences of the timer output changing from 0 to 1. Writing a value of zero resets the counter. The Digital Input State resource reports the state of the timer output. - - 3340 - urn:oma:lwm2m:ext:3340 - 1.0 - 1.0 - Multiple - Optional - - - Delay Duration - RW - Single - Mandatory - Float - - s - The duration of the time delay. - - - Remaining Time - R - Single - Optional - Float - - s - The time remaining in an operation. - - - Minimum Off-time - RW - Single - Optional - Float - - s - The duration of the rearm delay (i.e. the delay from the end of one cycle until the beginning of the next, the inhibit time). - - - Trigger - E - Single - Optional - - - - Trigger initiating actuation. - - - On/Off - RW - Single - Optional - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input. - - - Cumulative Time - RW - Single - Optional - Float - - s - The total time in seconds that the timer input is true. Writing a 0 resets the time. - - - Digital State - R - Single - Optional - Boolean - - - The current state of the timer output. - - - Counter - RW - Single - Optional - Integer - - - Counts the number of times the timer output transitions from 0 to 1. - - - Timer Mode - RW - Single - Optional - Integer - 0..4 - - Type of timer pattern used by the patterns. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3341.xml b/transport/lwm2m/src/main/data/models/3341.xml deleted file mode 100644 index ba22001e9a..0000000000 --- a/transport/lwm2m/src/main/data/models/3341.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Addressable Text Display - This IPSO object is used to send text to a text-only or text mode graphics display. Writing a string of text to the text resource causes it to be displayed at the selected X and Y locations on the display. If X or Y are set to a value greater than the size of the display, the position "wraps around" to the modulus of the setting and the display size. Likewise, if the text string overflows the display size, the text "wraps around" and displays on the next line down or, if the last line has been written, wraps around to the top of the display. Brightness and Contrast controls are provided to allow control of various display types including STN and DSTN type LCD character displays. Writing an empty payload to the Clear Display resource causes the display to be erased. - - 3341 - urn:oma:lwm2m:ext:3341 - 1.0 - 1.0 - Multiple - Optional - - - Text - RW - Single - Mandatory - String - - - A string of text. - - - X Coordinate - RW - Single - Optional - Integer - - - X Coordinate. - - - Y Coordinate - RW - Single - Optional - Integer - - - Y Coordinate. - - - Max X Coordinate - R - Single - Optional - Integer - - - The highest X coordinate the display supports before wrapping to the next line. - - - Max Y Coordinate - R - Single - Optional - Integer - - - The highest Y coordinate the display supports before wrapping to the next line. - - - Clear Display - E - Single - Optional - - - - Command to clear the display. - - - Level - RW - Single - Optional - Float - 0..100 - /100 - Brightness control, integer value between 0 and 100 as a percentage. - - - Contrast - RW - Single - Optional - Float - 0..100 - /100 - Proportional control, integer value between 0 and 100 as a percentage. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3342.xml b/transport/lwm2m/src/main/data/models/3342.xml deleted file mode 100644 index 30797468d5..0000000000 --- a/transport/lwm2m/src/main/data/models/3342.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - - - On/Off switch - This IPSO object should be used with an On/Off switch to report the state of the switch. - 3342 - urn:oma:lwm2m:ext:3342 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from 0 to 1. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds since the On command was sent. Writing a value of 0 resets the counter. - - - Off Time - RW - Single - Optional - Integer - - s - The time in seconds since the Off command was sent. Writing a value of 0 resets the counter. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3343.xml b/transport/lwm2m/src/main/data/models/3343.xml deleted file mode 100644 index 2a1ead53cb..0000000000 --- a/transport/lwm2m/src/main/data/models/3343.xml +++ /dev/null @@ -1,74 +0,0 @@ - - - - - Dimmer - This IPSO object should be used with a dimmer or level control to report the state of the control. - - 3343 - urn:oma:lwm2m:ext:3343 - 1.0 - 1.0 - Multiple - Optional - - - Level - RW - Single - Mandatory - Float - 0..100 - /100 - Proportional control, integer value between 0 and 100 as a percentage. - - - On time - RW - Single - Optional - Integer - - s - The time in seconds that the dimmer has been on (Dimmer value has to be > 0). Writing a value of 0 resets the counter. - - - Off Time - RW - Single - Optional - Integer - - s - The time in seconds that the dimmer has been off (dimmer value less or equal to 0) Writing a value of 0 resets the counter. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3344.xml b/transport/lwm2m/src/main/data/models/3344.xml deleted file mode 100644 index d6f3335a6e..0000000000 --- a/transport/lwm2m/src/main/data/models/3344.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - - - Up/Down Control - This IPSO object is used to report the state of an up/down control element like a pair of push buttons or a rotary encoder. Counters for increase and decrease operations are provided for counting pulses from a quadrature encoder. - - 3344 - urn:oma:lwm2m:ext:3344 - 1.0 - 1.0 - Multiple - Optional - - - Increase Input State - R - Single - Mandatory - Boolean - - - Indicates an increase control action. - - - Decrease Input State - R - Single - Mandatory - Boolean - - - Indicates a decrease control action. - - - Up Counter - RW - Single - Optional - Integer - - - Counts the number of times the increase control has been operated. Writing a 0 resets the counter. - - - Down Counter - RW - Single - Optional - Integer - - - Counts the times the decrease control has been operated. Writing a 0 resets the counter. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3345.xml b/transport/lwm2m/src/main/data/models/3345.xml deleted file mode 100644 index acf780488f..0000000000 --- a/transport/lwm2m/src/main/data/models/3345.xml +++ /dev/null @@ -1,94 +0,0 @@ - - - - - Multiple Axis Joystick - This IPSO object can be used to report the position of a shuttle or joystick control. A digital input is provided to report the state of an associated push button. - - 3345 - urn:oma:lwm2m:ext:3345 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Optional - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from 0 to 1. - - - X Value - R - Single - Optional - Float - - - The measured value along the X axis. - - - Y Value - R - Single - Optional - Float - - - The measured value along the Y axis. - - - Z Value - R - Single - Optional - Float - - - The measured value along the Z axis. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3346.xml b/transport/lwm2m/src/main/data/models/3346.xml deleted file mode 100644 index edca22adf4..0000000000 --- a/transport/lwm2m/src/main/data/models/3346.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - Rate - This object type should be used to report a rate measurement, for example the speed of a vehicle, or the rotational speed of a drive shaft. It also provides resources for minimum and maximum measured values, as well as the minimum and maximum range that can be measured by the sensor. An example measurement unit is meters per second (m/s). - - 3346 - urn:oma:lwm2m:ext:3346 - 1.0 - 1.0 - Multiple - Optional - - - Sensor Value - R - Single - Mandatory - Float - - - Last or Current Measured Value from the Sensor - - - Sensor Units - R - Single - Optional - String - - - Measurement Units Definition. - - - Min Measured Value - R - Single - Optional - Float - - - The minimum value measured by the sensor since power ON or reset - - - Max Measured Value - R - Single - Optional - Float - - - The maximum value measured by the sensor since power ON or reset - - - Min Range Value - R - Single - Optional - Float - - - The minimum value that can be measured by the sensor - - - Max Range Value - R - Single - Optional - Float - - - The maximum value that can be measured by the sensor - - - Reset Min and Max Measured Values - E - Single - Optional - - - - Reset the Min and Max Measured Values to Current Value - - - Current Calibration - RW - Single - Optional - Float - - - Read or Write the current calibration coefficient - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case - - - - - diff --git a/transport/lwm2m/src/main/data/models/3347.xml b/transport/lwm2m/src/main/data/models/3347.xml deleted file mode 100644 index 38355dcd82..0000000000 --- a/transport/lwm2m/src/main/data/models/3347.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - Push button - This IPSO object is used to report the state of a momentary action push button control and to count the number of times the control has been operated since the last observation. - - 3347 - urn:oma:lwm2m:ext:3347 - 1.0 - 1.0 - Multiple - Optional - - - Digital Input State - R - Single - Mandatory - Boolean - - - The current state of a digital input. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from 0 to 1. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3348.xml b/transport/lwm2m/src/main/data/models/3348.xml deleted file mode 100644 index bed7ac56d8..0000000000 --- a/transport/lwm2m/src/main/data/models/3348.xml +++ /dev/null @@ -1,54 +0,0 @@ - - - - - Multi-state Selector - This IPSO object is used to represent the state of a Multi-state selector switch with a number of fixed positions. - - 3348 - urn:oma:lwm2m:ext:3348 - 1.0 - 1.0 - Multiple - Optional - - - Multi-state Input - R - Single - Mandatory - Integer - - - The current state of a Multi-state input or selector. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3349.xml b/transport/lwm2m/src/main/data/models/3349.xml deleted file mode 100644 index 8f96334ef2..0000000000 --- a/transport/lwm2m/src/main/data/models/3349.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - Bitmap - Summarize several digital inputs to one value by mapping each bit to a digital input. - 3349 - urn:oma:lwm2m:ext:3349 - 1.0 - 1.0 - Multiple - Optional - - - Bitmap Input - R - Single - Mandatory - Integer - - - Integer in which each of the bits are associated with specific digital input value. Represented as a binary signed integer in network byte order, and in two's complement representation. Using values in range 0-127 is recommended to avoid ambiguities with byte order and negative values. - - - Bitmap Input Reset - E - Single - Optional - - - - Reset the Bitmap Input value. - - - Element Description - RW - Multiple - Optional - String - - - The description of each bit as a string. First instance describes the least significant bit, second instance the second least significant bit. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3350.xml b/transport/lwm2m/src/main/data/models/3350.xml deleted file mode 100644 index 8f026d846a..0000000000 --- a/transport/lwm2m/src/main/data/models/3350.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - Stopwatch - An ascending timer that counts how long time has passed since the timer was started after reset. - 3350 - urn:oma:lwm2m:ext:3350 - 1.0 - 1.0 - Multiple - Optional - - - Cumulative Time - RW - Single - Mandatory - Float - - s - The total time in seconds that the stopwatch has been on. Writing a 0 resets the time. - - - On/Off - RW - Single - Optional - Boolean - - - On/off control. Boolean value where True is On and False is Off. - - - Digital Input Counter - R - Single - Optional - Integer - - - The number of times the input transitions from off to on. - - - Application Type - RW - Single - Optional - String - - - The application type of the sensor or actuator as a string depending on the use case. - - - - - diff --git a/transport/lwm2m/src/main/data/models/3351.xml b/transport/lwm2m/src/main/data/models/3351.xml deleted file mode 100644 index c39b18c9fb..0000000000 --- a/transport/lwm2m/src/main/data/models/3351.xml +++ /dev/null @@ -1,148 +0,0 @@ - - - - powerupLog - - 3351 - urn:oma:lwm2m:ext:3351 - 1.0 - 1.0 - Single - Optional - - deviceName - R - Single - Mandatory - String - - - - - toolVersion - R - Single - Mandatory - String - - - - - IMEI - R - Single - Mandatory - String - - - - - IMSI - R - Single - Mandatory - String - - - - - MSISDN - R - Single - Mandatory - String - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3352.xml b/transport/lwm2m/src/main/data/models/3352.xml deleted file mode 100644 index 1d00dcd95c..0000000000 --- a/transport/lwm2m/src/main/data/models/3352.xml +++ /dev/null @@ -1,141 +0,0 @@ - - - - plmnSearchEvent - - 3352 - urn:oma:lwm2m:ext:3352 - 1.0 - 1.0 - Multiple - Optional - - timeScanStart - R - Single - Mandatory - Integer - - - - - plmnID - R - Single - Mandatory - Integer - - - - - BandIndicator - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3353.xml b/transport/lwm2m/src/main/data/models/3353.xml deleted file mode 100644 index f57fa2de1d..0000000000 --- a/transport/lwm2m/src/main/data/models/3353.xml +++ /dev/null @@ -1,140 +0,0 @@ - - - - scellID - - 3353 - urn:oma:lwm2m:ext:3353 - 1.0 - 1.0 - Single - Optional - - plmnID - R - Single - Mandatory - Integer - - - - - BandIndicator - R - Single - Mandatory - Integer - - - - - TrackingAreaCode - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3354.xml b/transport/lwm2m/src/main/data/models/3354.xml deleted file mode 100644 index 2f70b5668d..0000000000 --- a/transport/lwm2m/src/main/data/models/3354.xml +++ /dev/null @@ -1,151 +0,0 @@ - - - - cellReselectionEvent - - 3354 - urn:oma:lwm2m:ext:3354 - 1.0 - 1.0 - Single - Optional - - timeReselectionStart - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - failureType - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3355.xml b/transport/lwm2m/src/main/data/models/3355.xml deleted file mode 100644 index 6387566c67..0000000000 --- a/transport/lwm2m/src/main/data/models/3355.xml +++ /dev/null @@ -1,173 +0,0 @@ - - - - handoverEvent - - 3355 - urn:oma:lwm2m:ext:3355 - 1.0 - 1.0 - Single - Optional - - timeHandoverStart - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - handoverResult - R - Single - Mandatory - Integer - - - - - - TargetEarfcn - R - Single - Mandatory - Integer - - - - - TargetPhysicalCellID - R - Single - Mandatory - Integer - - - - - targetCellRsrp - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3356.xml b/transport/lwm2m/src/main/data/models/3356.xml deleted file mode 100644 index 2c585903bb..0000000000 --- a/transport/lwm2m/src/main/data/models/3356.xml +++ /dev/null @@ -1,137 +0,0 @@ - - - - radioLinkFailureEvent - - 3356 - urn:oma:lwm2m:ext:3356 - 1.0 - 1.0 - Single - Optional - - timeRLF - R - Single - Mandatory - Integer - - - - - rlfCause - R - Single - Mandatory - Integer - - - - - - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3357.xml b/transport/lwm2m/src/main/data/models/3357.xml deleted file mode 100644 index 9d03cbdc7c..0000000000 --- a/transport/lwm2m/src/main/data/models/3357.xml +++ /dev/null @@ -1,148 +0,0 @@ - - - - rrcStateChangeEvent - - 3357 - urn:oma:lwm2m:ext:3357 - 1.0 - 1.0 - Single - Optional - - rrcState - R - Single - Mandatory - Integer - - - - - rrcStateChangeCause - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3358.xml b/transport/lwm2m/src/main/data/models/3358.xml deleted file mode 100644 index 45775cd0fa..0000000000 --- a/transport/lwm2m/src/main/data/models/3358.xml +++ /dev/null @@ -1,123 +0,0 @@ - - - - rrcTimerExpiryEvent - - 3358 - urn:oma:lwm2m:ext:3358 - 1.0 - 1.0 - Single - Optional - - RrcTimerExpiryEvent - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3359.xml b/transport/lwm2m/src/main/data/models/3359.xml deleted file mode 100644 index d623ecedda..0000000000 --- a/transport/lwm2m/src/main/data/models/3359.xml +++ /dev/null @@ -1,122 +0,0 @@ - - - - cellBlacklistEvent - - 3359 - urn:oma:lwm2m:ext:3359 - 1.0 - 1.0 - Single - Optional - - dlEarfcn - R - Single - Mandatory - Integer - - - - - CellID - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3360.xml b/transport/lwm2m/src/main/data/models/3360.xml deleted file mode 100644 index 9995ab133e..0000000000 --- a/transport/lwm2m/src/main/data/models/3360.xml +++ /dev/null @@ -1,145 +0,0 @@ - - - - esmContextInfo - - 3360 - urn:oma:lwm2m:ext:3360 - 1.0 - 1.0 - Single - Optional - - contextType - R - Single - Mandatory - Integer - - - - - bearerState - R - Single - Mandatory - Integer - - - - - radioBearerId - R - Single - Mandatory - Integer - - - - - qci - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3361.xml b/transport/lwm2m/src/main/data/models/3361.xml deleted file mode 100644 index 6660583208..0000000000 --- a/transport/lwm2m/src/main/data/models/3361.xml +++ /dev/null @@ -1,147 +0,0 @@ - - - - emmStateValue - - 3361 - urn:oma:lwm2m:ext:3361 - 1.0 - 1.0 - Single - Optional - - EmmState - R - Single - Mandatory - Integer - - - - - emmSubstate - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3362.xml b/transport/lwm2m/src/main/data/models/3362.xml deleted file mode 100644 index a9b3de3e5a..0000000000 --- a/transport/lwm2m/src/main/data/models/3362.xml +++ /dev/null @@ -1,114 +0,0 @@ - - - - nasEmmTimerExpiryEvent - - 3362 - urn:oma:lwm2m:ext:3362 - 1.0 - 1.0 - Single - Optional - - NasEmmTimerExpiryEvent - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3363.xml b/transport/lwm2m/src/main/data/models/3363.xml deleted file mode 100644 index b040474dc2..0000000000 --- a/transport/lwm2m/src/main/data/models/3363.xml +++ /dev/null @@ -1,117 +0,0 @@ - - - - nasEsmExpiryEvent - - 3363 - urn:oma:lwm2m:ext:3363 - 1.0 - 1.0 - Single - Optional - - NasEsmExpiryEvent - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3364.xml b/transport/lwm2m/src/main/data/models/3364.xml deleted file mode 100644 index 18bdd00f5a..0000000000 --- a/transport/lwm2m/src/main/data/models/3364.xml +++ /dev/null @@ -1,114 +0,0 @@ - - - - emmFailureCauseEvent - - 3364 - urn:oma:lwm2m:ext:3364 - 1.0 - 1.0 - Single - Optional - - EMMCause - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3365.xml b/transport/lwm2m/src/main/data/models/3365.xml deleted file mode 100644 index 385d952809..0000000000 --- a/transport/lwm2m/src/main/data/models/3365.xml +++ /dev/null @@ -1,140 +0,0 @@ - - - - rachLatency_delay - - 3365 - urn:oma:lwm2m:ext:3365 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - rachLatencyVal - R - Single - Mandatory - Integer - - - - - delay - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3366.xml b/transport/lwm2m/src/main/data/models/3366.xml deleted file mode 100644 index 150c5b84b6..0000000000 --- a/transport/lwm2m/src/main/data/models/3366.xml +++ /dev/null @@ -1,193 +0,0 @@ - - - - macRachAttemptEvent - - 3366 - urn:oma:lwm2m:ext:3366 - 1.0 - 1.0 - Single - Optional - - rachAttemptCounter - R - Single - Mandatory - Integer - - - - - MacRachAttemptEventType - R - Single - Mandatory - Integer - - - - - contentionBased - R - Single - Mandatory - Boolean - - - - - rachMessage - R - Single - Mandatory - Integer - - - - - preambleIndex - R - Single - Mandatory - Integer - - - - - preamblePowerOffset - R - Single - Mandatory - Integer - - - - - backoffTime - R - Single - Mandatory - Integer - - - - - msg2Result - R - Single - Mandatory - Boolean - - - - - timingAdjustmentValue - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3367.xml b/transport/lwm2m/src/main/data/models/3367.xml deleted file mode 100644 index fc0ac146e0..0000000000 --- a/transport/lwm2m/src/main/data/models/3367.xml +++ /dev/null @@ -1,155 +0,0 @@ - - - - macRachAttemptReasonEvent - - 3367 - urn:oma:lwm2m:ext:3367 - 1.0 - 1.0 - Single - Optional - - MacRachAttemptReasonType - R - Single - Mandatory - Integer - - - - - ueID - R - Single - Mandatory - Integer - - - - - contentionBased - R - Single - Mandatory - Boolean - - - - - preamble - R - Single - Mandatory - Integer - - - - - preambleGroupChosen - R - Single - Mandatory - Boolean - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3368.xml b/transport/lwm2m/src/main/data/models/3368.xml deleted file mode 100644 index 2f877024d6..0000000000 --- a/transport/lwm2m/src/main/data/models/3368.xml +++ /dev/null @@ -1,117 +0,0 @@ - - - - macTimerStatusEvent - - 3368 - urn:oma:lwm2m:ext:3368 - 1.0 - 1.0 - Single - Optional - - macTimerName - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3369.xml b/transport/lwm2m/src/main/data/models/3369.xml deleted file mode 100644 index 72debece44..0000000000 --- a/transport/lwm2m/src/main/data/models/3369.xml +++ /dev/null @@ -1,122 +0,0 @@ - - - - macTimingAdvanceEvent - - 3369 - urn:oma:lwm2m:ext:3369 - 1.0 - 1.0 - Single - Optional - - timerValue - R - Single - Mandatory - Integer - - - - - timingAdvance - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3370.xml b/transport/lwm2m/src/main/data/models/3370.xml deleted file mode 100644 index 93df78c63f..0000000000 --- a/transport/lwm2m/src/main/data/models/3370.xml +++ /dev/null @@ -1,158 +0,0 @@ - - - - ServingCellMeasurement - - 3370 - urn:oma:lwm2m:ext:3370 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - pci - R - Single - Mandatory - Integer - - - - - rsrp - R - Single - Mandatory - Integer - - - - - rsrq - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3371.xml b/transport/lwm2m/src/main/data/models/3371.xml deleted file mode 100644 index e61288f414..0000000000 --- a/transport/lwm2m/src/main/data/models/3371.xml +++ /dev/null @@ -1,158 +0,0 @@ - - - - NeighborCellMeasurements - - 3371 - urn:oma:lwm2m:ext:3371 - 1.0 - 1.0 - Multiple - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - pci - R - Single - Mandatory - Integer - - - - - rsrp - R - Single - Mandatory - Integer - - - - - rsrq - R - Single - Mandatory - Integer - - - - - dlEarfcn - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3372.xml b/transport/lwm2m/src/main/data/models/3372.xml deleted file mode 100644 index 959cccf917..0000000000 --- a/transport/lwm2m/src/main/data/models/3372.xml +++ /dev/null @@ -1,132 +0,0 @@ - - - - TimingAdvance - - 3372 - urn:oma:lwm2m:ext:3372 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - timingAdvance - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3373.xml b/transport/lwm2m/src/main/data/models/3373.xml deleted file mode 100644 index b932370393..0000000000 --- a/transport/lwm2m/src/main/data/models/3373.xml +++ /dev/null @@ -1,132 +0,0 @@ - - - - txPowerHeadroomEvent - - 3373 - urn:oma:lwm2m:ext:3373 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - headroom-value - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3374.xml b/transport/lwm2m/src/main/data/models/3374.xml deleted file mode 100644 index ca04397c8d..0000000000 --- a/transport/lwm2m/src/main/data/models/3374.xml +++ /dev/null @@ -1,149 +0,0 @@ - - - - radioLinkMonitoring - - 3374 - urn:oma:lwm2m:ext:3374 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - outOfSyncCount - R - Single - Mandatory - Integer - - - - - inSyncCount - R - Single - Mandatory - Integer - - - - - t310Timer - R - Single - Mandatory - Boolean - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3375.xml b/transport/lwm2m/src/main/data/models/3375.xml deleted file mode 100644 index 9d0e12eb3c..0000000000 --- a/transport/lwm2m/src/main/data/models/3375.xml +++ /dev/null @@ -1,167 +0,0 @@ - - - - PagingDRX - - 3375 - urn:oma:lwm2m:ext:3375 - 1.0 - 1.0 - Single - Optional - - dlEarfcn - R - Single - Mandatory - Integer - - - - - pci - R - Single - Mandatory - Integer - - - - - pagingCycle - R - Single - Mandatory - Integer - - - - - DrxNb - R - Single - Mandatory - Integer - - - - - ueID - R - Single - Mandatory - Integer - - - - - drxSysFrameNumOffset - R - Single - Mandatory - Integer - - - - - drxSubFrameNumOffset - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3376.xml b/transport/lwm2m/src/main/data/models/3376.xml deleted file mode 100644 index 91172c66e6..0000000000 --- a/transport/lwm2m/src/main/data/models/3376.xml +++ /dev/null @@ -1,114 +0,0 @@ - - - - txPowerBackOffEvent - - 3376 - urn:oma:lwm2m:ext:3376 - 1.0 - 1.0 - Single - Optional - - TxPowerBackoff - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3377.xml b/transport/lwm2m/src/main/data/models/3377.xml deleted file mode 100644 index 28204ff2ce..0000000000 --- a/transport/lwm2m/src/main/data/models/3377.xml +++ /dev/null @@ -1,185 +0,0 @@ - - - - Message3Report - - 3377 - urn:oma:lwm2m:ext:3377 - 1.0 - 1.0 - Single - Optional - - tpc - R - Single - Mandatory - Integer - - - - - resourceIndicatorValue - R - Single - Mandatory - Integer - - - - - cqi - R - Single - Mandatory - Integer - - - - - uplinkDelay - R - Single - Mandatory - Boolean - - - - - hoppingEnabled - R - Single - Mandatory - Boolean - - - - - numRb - R - Single - Mandatory - Integer - - - - - transportBlockSizeIndex - R - Single - Mandatory - Integer - - - - - ModulationType - R - Single - Mandatory - Integer - - - - - redundancyVersionIndex - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3378.xml b/transport/lwm2m/src/main/data/models/3378.xml deleted file mode 100644 index a9c1ebc45d..0000000000 --- a/transport/lwm2m/src/main/data/models/3378.xml +++ /dev/null @@ -1,132 +0,0 @@ - - - - PbchDecodingResults - - 3378 - urn:oma:lwm2m:ext:3378 - 1.0 - 1.0 - Single - Optional - - servingCellID - R - Single - Mandatory - Integer - - - - - crcResult - R - Single - Mandatory - Boolean - - - - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3379.xml b/transport/lwm2m/src/main/data/models/3379.xml deleted file mode 100644 index 2a684f2ddd..0000000000 --- a/transport/lwm2m/src/main/data/models/3379.xml +++ /dev/null @@ -1,140 +0,0 @@ - - - - pucchPowerControl - - 3379 - urn:oma:lwm2m:ext:3379 - 1.0 - 1.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - pucchTxPowerValue - - Single - Mandatory - Integer - - - - - dlPathLoss - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3380-2_0.xml b/transport/lwm2m/src/main/data/models/3380-2_0.xml deleted file mode 100644 index 21f9eb9f50..0000000000 --- a/transport/lwm2m/src/main/data/models/3380-2_0.xml +++ /dev/null @@ -1,221 +0,0 @@ - - - - PrachReport - - 3380 - urn:oma:lwm2m:ext:3380:2.0 - 1.0 - 2.0 - Single - Optional - - sysFrameNumber - R - Single - Mandatory - Integer - - - - - subFrameNumber - R - Single - Mandatory - Integer - - - - - rachTxPower - R - Single - Mandatory - Integer - - - - - zadOffSeqNum - R - Single - Mandatory - Integer - - - - - prachConfig - R - Single - Mandatory - Integer - - - - - preambleFormat - R - Single - Mandatory - Integer - - - - - maxTransmissionMsg3 - R - Single - Mandatory - Integer - - - - - raResponseWindowSize - R - Single - Mandatory - Integer - - - - - RachRequestResult - R - Single - Mandatory - Boolean - - - - - ce_mode - R - Single - Mandatory - Integer - - - - - ce_level - R - Single - Mandatory - Integer - - - - - num_prach_repetition - R - Single - Mandatory - Integer - - - - - prach_repetition_seq - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3381.xml b/transport/lwm2m/src/main/data/models/3381.xml deleted file mode 100644 index 9df2e862b9..0000000000 --- a/transport/lwm2m/src/main/data/models/3381.xml +++ /dev/null @@ -1,127 +0,0 @@ - - - - VolteCallEvent - - 3381 - urn:oma:lwm2m:ext:3381 - 1.0 - 1.0 - Single - Optional - - callStatus - R - Single - Mandatory - Integer - - - - - callType - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3382.xml b/transport/lwm2m/src/main/data/models/3382.xml deleted file mode 100644 index 774a3ad20c..0000000000 --- a/transport/lwm2m/src/main/data/models/3382.xml +++ /dev/null @@ -1,125 +0,0 @@ - - - - SipRegistrationEvent - - 3382 - urn:oma:lwm2m:ext:3382 - 1.0 - 1.0 - Single - Optional - - registrationType - R - Single - Mandatory - Integer - - - - - registrationResult - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3383.xml b/transport/lwm2m/src/main/data/models/3383.xml deleted file mode 100644 index 2bd5ed9c24..0000000000 --- a/transport/lwm2m/src/main/data/models/3383.xml +++ /dev/null @@ -1,116 +0,0 @@ - - - - sipPublishEvent - - 3383 - urn:oma:lwm2m:ext:3383 - 1.0 - 1.0 - Single - Optional - - publishResult - R - Single - Mandatory - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3384.xml b/transport/lwm2m/src/main/data/models/3384.xml deleted file mode 100644 index 53cdb71c85..0000000000 --- a/transport/lwm2m/src/main/data/models/3384.xml +++ /dev/null @@ -1,129 +0,0 @@ - - - - sipSubscriptionEvent - - 3384 - urn:oma:lwm2m:ext:3384 - 1.0 - 1.0 - Single - Optional - - eventType - R - Single - Mandatory - Integer - - - - - subscriptionResult - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3385.xml b/transport/lwm2m/src/main/data/models/3385.xml deleted file mode 100644 index bf73c6ec9c..0000000000 --- a/transport/lwm2m/src/main/data/models/3385.xml +++ /dev/null @@ -1,127 +0,0 @@ - - - - volteCallStateChangeEvent - - 3385 - urn:oma:lwm2m:ext:3385 - 1.0 - 1.0 - Single - Optional - - callStatus - R - Single - Mandatory - Integer - - - - - VolteCallStateChangeCause - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/3386.xml b/transport/lwm2m/src/main/data/models/3386.xml deleted file mode 100644 index 64b7ab7ece..0000000000 --- a/transport/lwm2m/src/main/data/models/3386.xml +++ /dev/null @@ -1,122 +0,0 @@ - - - - VoLTErtpPacketLoss - 1]]> - 3386 - urn:oma:lwm2m:ext:3386 - 1.0 - 1.0 - Single - Optional - - ssrc - R - Single - Mandatory - Integer - - - - - packetsLost - R - Single - Mandatory - Integer - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LWM2M_APN_Connection_Profile-v1_0_1.xml b/transport/lwm2m/src/main/data/models/LWM2M_APN_Connection_Profile-v1_0_1.xml deleted file mode 100644 index c1bade6f62..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_APN_Connection_Profile-v1_0_1.xml +++ /dev/null @@ -1,287 +0,0 @@ - - - - - LWM2M APN Connection Profile - - 11 - - urn:oma:lwm2m:oma:11 - 1.0 - 1.0 - Multiple - Optional - - Profile name - RW - Single - Mandatory - String - - - - - APN - RW - Single - Optional - String - - - - - Auto select APN by device - RW - Single - Optional - Boolean - - - - - Enable status - RW - Single - Optional - Boolean - - - - - Authentication Type - RW - Single - Mandatory - Integer - - - - - User Name - RW - Single - Optional - String - - - - - Secret - RW - Single - Optional - String - - - - - Reconnect Schedule - RW - Single - Optional - String - - - - - Validity (MCC, MNC) - RW - Multiple - Optional - String - - - - - Connection establishment time (1) - R - Multiple - Optional - Time - - - - - Connection establishment result (1) - R - Multiple - Optional - Integer - - - - - - Connection establishment reject cause (1) - R - Multiple - Optional - Integer - 0..111 - - - - Connection end time (1) - R - Multiple - Optional - Time - - - - - TotalBytesSent - R - Single - Optional - Integer - - - - - TotalBytesReceived - R - Single - Optional - Integer - - - - - IP address (2) - RW - Multiple - Optional - String - - - - - Prefix length(2) - RW - Multiple - Optional - String - - - - - Subnet mask (2) - RW - Multiple - Optional - String - - - - - Gateway (2) - RW - Multiple - Optional - String - - - - - Primary DNS address (2) - RW - Multiple - Optional - String - - - - - Secondary DNS address (2) - RW - Multiple - Optional - String - - - - - QCI (3) - R - Single - Optional - Integer - 1..9 - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - TotalPacketsSent - R - Single - Optional - Integer - - - - - PDN Type - RW - Single - Optional - Integer - - - - - - APN Rate Control - R - Single - Optional - Integer - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LWM2M_Bearer_Selection-v1_0_1.xml b/transport/lwm2m/src/main/data/models/LWM2M_Bearer_Selection-v1_0_1.xml deleted file mode 100644 index 0e52c8b58e..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_Bearer_Selection-v1_0_1.xml +++ /dev/null @@ -1,174 +0,0 @@ - - - - - LWM2M Bearer Selection - - 13 - urn:oma:lwm2m:oma:13 - 1.0 - 1.0 - Single - Optional - - Preferred Communications Bearer - RW - Multiple - Optional - Integer - 8 bit - - - - Acceptable RSSI (GSM) - RW - Single - Optional - Integer - - - - - Acceptable RSCP (UMTS) - RW - Single - Optional - Integer - - - - - Acceptable RSRP (LTE) - RW - Single - Optional - Integer - - - - - Acceptable RSSI (1xEV-DO) - RW - Single - Optional - Integer - - - - - Cell lock list - RW - Single - Optional - String - - - - - Operator list - RW - Single - Optional - String - - - - - Operator list mode - RW - Single - Optional - Boolean - - - - - List of available PLMNs - R - Single - Optional - String - - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - Acceptable RSRP (NB-IoT) - RW - Single - Optional - Integer - - - - - Higher Priority PLMN Search Timer - RW - Single - Optional - Integer - - - - - Attach without PDN connection - RW - Single - Optional - Boolean - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LWM2M_Cellular_Connectivity-v1_0_1.xml b/transport/lwm2m/src/main/data/models/LWM2M_Cellular_Connectivity-v1_0_1.xml deleted file mode 100644 index b02490cc6d..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_Cellular_Connectivity-v1_0_1.xml +++ /dev/null @@ -1,146 +0,0 @@ - - - - - LWM2M Cellular Connectivity - - 10 - urn:oma:lwm2m:oma:10 - 1.0 - 1.0 - Single - Optional - - SMSC address - RW - Single - Optional - String - - - - - Disable radio period - RW - Single - Optional - Integer - 0..65535 - - 0 the device SHALL disconnect. When the period has elapsed the device MAY reconnect.]]> - - Module activation code - RW - Single - Optional - String - - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - PSM Timer (1) - RW - Single - Optional - Integer - - s - - - Active Timer (1) - RW - Single - Optional - Integer - - s - - - Serving PLMN Rate control - R - Single - Optional - Integer - - - - - eDRX parameters for Iu mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - eDRX parameters for WB-S1 mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - eDRX parameters for NB-S1 mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - eDRX parameters for A/Gb mode (1) - RW - Single - Optional - Opaque - 8 bit - - - - Activated Profile Names - R - Multiple - Mandatory - Objlnk - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml b/transport/lwm2m/src/main/data/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml deleted file mode 100644 index 48e942983d..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_Connectivity_Monitoring-v1_0_2.xml +++ /dev/null @@ -1,167 +0,0 @@ - - - - - Connectivity Monitoring - - This LwM2M Object enables monitoring of parameters related to network connectivity. In this general connectivity Object, the Resources are limited to the most general cases common to most network bearers. It is recommended to read the description, which refers to relevant standard development organizations (e.g. 3GPP, IEEE). The goal of the Connectivity Monitoring Object is to carry information reflecting the more up to date values of the current connection for monitoring purposes. Resources such as Link Quality, Radio Signal Strength, Cell ID are retrieved during connected mode at least for cellular networks. - - 4 - urn:oma:lwm2m:oma:4 - 1.0 - 1.0 - Single - Optional - - - Network Bearer - R - Single - Mandatory - Integer - 0-50 - - - Indicates the network bearer used for the current LwM2M communication session from the network bearer list below. The number range is split into three categories: 0 - 20 are Cellular Bearers 21 - 40 are Wireless Bearers 41 - 50 are Wireline Bearers More specifically: 0: GSM cellular network 1: TD-SCDMA cellular network 2: WCDMA cellular network 3: CDMA2000 cellular network 4: WiMAX cellular network 5: LTE-TDD cellular network 6: LTE-FDD cellular network 7: NB-IoT 8 - 20: Reserved for other types of cellular network 21: WLAN network 22: Bluetooth network 23: IEEE 802.15.4 network 24 - 40: Reserved for other types of local wireless network 41: Ethernet 42: DSL 43: PLC 44 - 50: reserved for other types of wireline networks. - - - - Available Network Bearer - R - Multiple - Mandatory - Integer - 0-50 - - - Indicates a list of current available network bearer. Each Resource Instance has a value from the network bearer list. - - - - Radio Signal Strength - R - Single - Mandatory - Integer - - dBm - - Indicates the average value of the received signal strength indication used in the current network bearer (as indicated by Resource 0 of this Object). For the following network bearers the signal strength parameters indicated below are represented by this resource: GSM: RSSI UMTS: RSCP LTE: RSRP NB-IoT: NRSRP For more details on Network Measurement Report, refer to the appropriate Cellular or Wireless Network standards, (e.g. for LTE Cellular Network refer to 3GPP TS 36.133 specification). - - - - Link Quality - R - Single - Optional - Integer - - - - This contains received link quality e.g. LQI for IEEE 802.15.4 (range 0...255), RxQual Downlink for GSM (range 0...7, refer to [3GPP 44.018] for more details on Network Measurement Report encoding), RSRQ for LTE, (refer to [3GPP 36.214]), NRSRQ for NB-IoT (refer to [3GPP 36.214]). - - - - IP Addresses - R - Multiple - Mandatory - String - - - - The IP addresses assigned to the connectivity interface. (e.g. IPv4, IPv6, etc.) - - - - Router IP Addresses - R - Multiple - Optional - String - - - - The IP address of the next-hop IP router, on each of the interfaces specified in resource 4 (IP Addresses). Note: This IP Address doesn’t indicate the Server IP address. - - - - Link Utilization - R - Single - Optional - Integer - 0-100 - % - - The percentage indicating the average utilization of the link to the next-hop IP router. - - - - APN - R - Multiple - Optional - String - - - - Access Point Name in case Network Bearer Resource is a Cellular Network. - - - - Cell ID - R - Single - Optional - Integer - - - - Serving Cell ID in case Network Bearer Resource is a Cellular Network. As specified in TS [3GPP 23.003] and in [3GPP. 24.008]. Range (0...65535) in GSM/EDGE UTRAN Cell ID has a length of 28 bits. Cell Identity in WCDMA/TD-SCDMA. Range: (0...268435455). LTE Cell ID has a length of 28 bits. Parameter definitions in [3GPP 25.331]. - - - - SMNC - R - Single - Optional - Integer - 0-999 - % - - Serving Mobile Network Code. This is applicable when the Network Bearer Resource value is referring to a cellular network. As specified in TS [3GPP 23.003]. - - - - SMCC - R - Single - Optional - Integer - 0-999 - - - Serving Mobile Country Code. This is applicable when the Network Bearer Resource value is referring to a cellular network. As specified in TS [3GPP 23.003]. - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LWM2M_DevCapMgmt-v1_0.xml b/transport/lwm2m/src/main/data/models/LWM2M_DevCapMgmt-v1_0.xml deleted file mode 100644 index f45689a64f..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_DevCapMgmt-v1_0.xml +++ /dev/null @@ -1,130 +0,0 @@ - - - - - DevCapMgmt - - 15 - urn:oma:lwm2m:oma:15 - Multiple - Optional - - Property - R - Single - Mandatory - String - - - - - Group - R - Single - Mandatory - Integer - 0-15 - - - - Description - R - Single - Optional - String - - - - - Attached - R - Single - Optional - Boolean - - - - - Enabled - R - Single - Mandatory - Boolean - - - - - opEnable - E - Single - Mandatory - - - - - - opDisable - E - Multiple - Mandatory - - - - - - NotifyEn - RW - Single - Optional - Boolean - - - - - - - \ No newline at end of file diff --git a/transport/lwm2m/src/main/data/models/LWM2M_LOCKWIPE-v1_0_1.xml b/transport/lwm2m/src/main/data/models/LWM2M_LOCKWIPE-v1_0_1.xml deleted file mode 100644 index 913d294acf..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_LOCKWIPE-v1_0_1.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - Lock and Wipe - - 8 - urn:oma:lwm2m:oma:8 - Single - Optional - - State - RW - Single - Mandatory - Integer - 0-2 - - - - Lock target - W - Multiple - Mandatory - String - - - - - Wipe item - R - Multiple - Optional - String - - - - - Wipe - E - Single - Mandatory - - - - - - - Wipe target - W - Multiple - Mandatory - String - - - - Lock or Wipe Operation Result - R - Single - Mandatory - Integer - 0-8 - - - - - - \ No newline at end of file diff --git a/transport/lwm2m/src/main/data/models/LWM2M_Portfolio-v1_0.xml b/transport/lwm2m/src/main/data/models/LWM2M_Portfolio-v1_0.xml deleted file mode 100644 index 993a3fa126..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_Portfolio-v1_0.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - Portfolio - - 16 - urn:oma:lwm2m:oma:161.0 - 1.0Multiple - Optional - - Identity - RW - Multiple - Mandatory - String - - - - - GetAuthData - E - Single - Optional - - - - - - AuthData - R - Multiple - Optional - Opaque - - - - - AuthStatus - R - Single - Optional - Integer - [0-2] - - - - - - \ No newline at end of file diff --git a/transport/lwm2m/src/main/data/models/LWM2M_Software_Component-v1_0.xml b/transport/lwm2m/src/main/data/models/LWM2M_Software_Component-v1_0.xml deleted file mode 100644 index 9d2f886ed5..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_Software_Component-v1_0.xml +++ /dev/null @@ -1,95 +0,0 @@ - - - - - LWM2M Software Component - - 14 - urn:oma:lwm2m:oma:14 - Multiple - Optional - - - Component Identity - R - Single - Optional - String - 0-255 bytes - - - - - Component Pack - R - Single - Optional - Opaque - - - - - - Component Version - R - Single - Optional - String - 0-255 bytes - - - - - Activate - E - Single - Optional - - - - - - - Deactivate - E - Single - Optional - - - - - - Activation State - R - Single - Optional - Boolean - - - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LWM2M_Software_Management-v1_0.xml b/transport/lwm2m/src/main/data/models/LWM2M_Software_Management-v1_0.xml deleted file mode 100644 index 7be031c6d5..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_Software_Management-v1_0.xml +++ /dev/null @@ -1,235 +0,0 @@ - - - - - LWM2M Software Management - - 9 - urn:oma:lwm2m:oma:9 - Multiple - Optional - - - PkgName - R - Single - Mandatory - String - 0-255 bytes - - - - - PkgVersion - R - Single - Mandatory - String - 0-255 bytes - - - - - Package - W - Single - Optional - Opaque - - - - - - Package URI - W - Single - Optional - String - 0-255 bytes - - - - - Install - E - Single - Mandatory - - - - - - Checkpoint - R - Single - Optional - Objlnk - - - - - Uninstall - E - Single - Mandatory - - - - - - Update State - R - Single - Mandatory - Integer - 0-4 - - - - Update Supported Objects - RW - Single - Optional - Boolean - - - - - Update Result - R - Single - Mandatory - Integer - 0-200 - - - - Activate - E - Single - Mandatory - - - - - - Deactivate - E - Single - Mandatory - - - - - - Activation State - R - Single - Mandatory - Boolean - - - - - Package Settings - RW - Single - Optional - Objlnk - - - - - User Name - W - Single - Optional - String - 0-255 bytes - - - - Password - W - Single - Optional - String - 0-255 bytes - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LWM2M_WLAN_connectivity4-v1_0.xml b/transport/lwm2m/src/main/data/models/LWM2M_WLAN_connectivity4-v1_0.xml deleted file mode 100644 index c18a673a10..0000000000 --- a/transport/lwm2m/src/main/data/models/LWM2M_WLAN_connectivity4-v1_0.xml +++ /dev/null @@ -1,528 +0,0 @@ - - - - - WLAN connectivity - - 12 - urn:oma:lwm2m:oma:12 - - - Multiple - Optional - - Interface name - RW - Single - Mandatory - String - - - - - Enable - RW - Single - Mandatory - Boolean - - - - - Radio Enabled - RW - Single - Optional - Integer - - - - - Status - R - Single - Mandatory - Integer - - - - - BSSID - R - Single - Mandatory - String - 12 bytes - - - - SSID - RW - Single - Mandatory - String - 1-32 Bytes - - - - Broadcast SSID - RW - Single - Optional - Boolean - - - - - Beacon Enabled - RW - Single - Optional - Boolean - - - - - Mode - RW - Single - Mandatory - Integer - - - - - Channel - RW - Single - Mandatory - Integer - 0-255 - - - - Auto Channel - RW - Single - Optional - Boolean - - - - - Supported Channels - RW - Multiple - Optional - Integer - - - - - Channels In Use - RW - Multiple - Optional - Integer - - - - - Regulatory Domain - RW - Single - Optional - String - 3 Bytes - - - - Standard - RW - Single - Mandatory - Integer - - - - - Authentication Mode - RW - Single - Mandatory - Integer - - - - - Encryption Mode - RW - Single - Optional - Integer - - - - - WPA Pre Shared Key - W - Single - Optional - String - 64 Bytes - - - - WPA Key Phrase - W - Single - Optional - String - 1-64 Bytes - - - - WEP Encryption Type - RW - Single - Optional - Integer - - - - - WEP Key Index - RW - Single - Optional - Integer - [1:4] - - - - WEP Key Phrase - W - Single - Optional - String - 1-64 Bytes - - - - WEP Key 1 - W - Single - Optional - String - 0 or 26 Bytes - - - - WEP Key 2 - W - Single - Optional - String - 0 or 26 Bytes - - - - WEP Key 3 - W - Single - Optional - String - 10 or 26 Bytes - - - - WEP Key 4 - W - Single - Optional - String - 10 or 26 Bytes - - - - RADIUS Server - RW - Single - Optional - String - 1-256 Bytes - - - - RADIUS Server Port - RW - Single - Optional - Integer - - - - - RADIUS Secret - W - Single - Optional - String - 1-256 Bytes - - - - WMM Supported - R - Single - Optional - Boolean - - - - - WMM Enabled - RW - Single - Optional - Boolean - - - - - MAC Control Enabled - RW - Single - Optional - Boolean - - - - - MAC Address List - RW - Multiple - Optional - String - 12 Bytes - - - - Total Bytes Sent - R - Single - Optional - Integer - - - - - Total Bytes Received - R - Single - Optional - Integer - - - - - Total Packets Sent - R - Single - Optional - Integer - - - - - Total Packets Received - R - Single - Optional - Integer - - - - - Transmit Errors - R - Single - Optional - Integer - - - - - Receive Errors - R - Single - Optional - Integer - - - - - Unicast Packets Sent - R - Single - Optional - Integer - - - - - Unicast Packets Received - R - Single - Optional - Integer - - - - - Multicast Packets Received - R - Single - Optional - Integer - - - - - Multicast Packets Received - R - Single - Optional - Integer - - - - - Broadcast Packets Sent - R - Single - Optional - Integer - - - - - 44 Broadcast Packets Received - R - Single - Optional - Integer - - - - - Discard Packets Sent - R - Single - Optional - Integer - - - - - Discard Packets Received - R - Single - Optional - Integer - - - - - Unknown Packets Received - R - Single - Optional - Integer - - - - - Vendor specific extensions - R - Single - Optional - Objlnk - - - - - - - \ No newline at end of file diff --git a/transport/lwm2m/src/main/data/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml b/transport/lwm2m/src/main/data/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml deleted file mode 100644 index 374dac72bc..0000000000 --- a/transport/lwm2m/src/main/data/models/LwM2M_BinaryAppDataContainer-v1_0_1.xml +++ /dev/null @@ -1,164 +0,0 @@ - - - - - - BinaryAppDataContainer - - 19 - urn:oma:lwm2m:oma:19 - 1.0 - 1.0 - Multiple - Optional - - Data - RW - - - - Multiple - Mandatory - Opaque - - - - - Data Priority - RW - Single - Optional - Integer - 1 bytes - - - - Data Creation Time - RW - Single - Optional - Time - - - - - Data Description - RW - Single - Optional - String - 32 bytes - - - - Data Format - RW - Single - Optional - String - 32 bytes - - - - App ID - RW - Single - Optional - Integer - 2 bytes - - - - - - diff --git a/transport/lwm2m/src/main/data/models/LwM2M_EventLog-V1_0.xml b/transport/lwm2m/src/main/data/models/LwM2M_EventLog-V1_0.xml deleted file mode 100644 index d7054de9ff..0000000000 --- a/transport/lwm2m/src/main/data/models/LwM2M_EventLog-V1_0.xml +++ /dev/null @@ -1,101 +0,0 @@ - - - - - - Event Log - - 20 - urn:oma:lwm2m:oma:20 - 1.0 - 1.0 - Single - Optional - - LogClass - RW - Single - Optional - Integer - 255 - - - - LogStart - E - Single - Optional - - - - - - LogStop - E - Single - Optional - - - - - - LogStatus - R - Single - Optional - Integer - 8-Bits - - - - LogData - R - Single - Mandatory - Opaque - - - - - LogDataFormat - RW - Single - Optional - Integer - 255 - - - - - - \ No newline at end of file diff --git a/transport/lwm2m/src/main/java/org/thingsboard/server/lwm2m/ThingsboardLwm2mTransportApplication.java b/transport/lwm2m/src/main/java/org/thingsboard/server/lwm2m/ThingsboardLwm2mTransportApplication.java deleted file mode 100644 index 1b3423055e..0000000000 --- a/transport/lwm2m/src/main/java/org/thingsboard/server/lwm2m/ThingsboardLwm2mTransportApplication.java +++ /dev/null @@ -1,48 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.thingsboard.server.lwm2m; - -import org.springframework.boot.SpringApplication; -import org.springframework.boot.SpringBootConfiguration; -import org.springframework.context.annotation.ComponentScan; -import org.springframework.scheduling.annotation.EnableAsync; -import org.springframework.scheduling.annotation.EnableScheduling; - -import java.util.Arrays; - -@SpringBootConfiguration -@EnableAsync -@EnableScheduling -@ComponentScan({"org.thingsboard.server.lwm2m", "org.thingsboard.server.common", "org.thingsboard.server.transport.lwm2m", "org.thingsboard.server.queue"}) -public class ThingsboardLwm2mTransportApplication { - - private static final String SPRING_CONFIG_NAME_KEY = "--spring.config.name"; - private static final String DEFAULT_SPRING_CONFIG_PARAM = SPRING_CONFIG_NAME_KEY + "=" + "tb-lwm2m-transport"; - - public static void main(String[] args) { - SpringApplication.run(ThingsboardLwm2mTransportApplication.class, updateArguments(args)); - } - - private static String[] updateArguments(String[] args) { - if (Arrays.stream(args).noneMatch(arg -> arg.startsWith(SPRING_CONFIG_NAME_KEY))) { - String[] modifiedArgs = new String[args.length + 1]; - System.arraycopy(args, 0, modifiedArgs, 0, args.length); - modifiedArgs[args.length] = DEFAULT_SPRING_CONFIG_PARAM; - return modifiedArgs; - } - return args; - } -} diff --git a/transport/lwm2m/src/main/resources/tb-lwm2m-transport.yml b/transport/lwm2m/src/main/resources/tb-lwm2m-transport.yml deleted file mode 100644 index d6fe7b5b1f..0000000000 --- a/transport/lwm2m/src/main/resources/tb-lwm2m-transport.yml +++ /dev/null @@ -1,301 +0,0 @@ -# -# Copyright © 2016-2020 The Thingsboard Authors -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# If you enabled process metrics you should also enable 'web-environment'. -spring.main.web-environment: "${WEB_APPLICATION_ENABLE:false}" -# If you enabled process metrics you should set 'web-application-type' to 'servlet' value. -spring.main.web-application-type: "${WEB_APPLICATION_TYPE:none}" - -server: - # Server bind address (has no effect if web-environment is disabled). - address: "${HTTP_BIND_ADDRESS:0.0.0.0}" - # Server bind port (has no effect if web-environment is disabled). - port: "${HTTP_BIND_PORT:8083}" - -# Zookeeper connection parameters. Used for service discovery. -zk: - # Enable/disable zookeeper discovery service. - enabled: "${ZOOKEEPER_ENABLED:false}" - # Zookeeper connect string - url: "${ZOOKEEPER_URL:localhost:2181}" - # Zookeeper retry interval in milliseconds - retry_interval_ms: "${ZOOKEEPER_RETRY_INTERVAL_MS:3000}" - # Zookeeper connection timeout in milliseconds - connection_timeout_ms: "${ZOOKEEPER_CONNECTION_TIMEOUT_MS:3000}" - # Zookeeper session timeout in milliseconds - session_timeout_ms: "${ZOOKEEPER_SESSION_TIMEOUT_MS:3000}" - # Name of the directory in zookeeper 'filesystem' - zk_dir: "${ZOOKEEPER_NODES_DIR:/thingsboard}" - -# LWM2M server parameters -transport: - lwm2m: - # Enable/disable lvm2m transport protocol. - enabled: "${LWM2M_ENABLED:true}" - # We choose a default timeout a bit higher to the MAX_TRANSMIT_WAIT(62-93s) which is the time from starting to - # send a Confirmable message to the time when an acknowledgement is no longer expected. - # DEFAULT_TIMEOUT = 2 * 60 * 1000l; 2 min in ms - timeout: "${LWM2M_TIMEOUT:120000}" - # model_path_file: "${LWM2M_MODEL_PATH_FILE:./common/transport/lwm2m/src/main/resources/models/}" - model_path_file: "${LWM2M_MODEL_PATH_FILE:}" - support_deprecated_ciphers_enable: "${LWM2M_SUPPORT_DEPRECATED_CIPHERS_ENABLED:true}" - secure: - # Only Certificate_x509: - # To get helps about files format and how to generate it, see: https://github.com/eclipse/leshan/wiki/Credential-files-format - # Create new X509 Certificates: common/transport/lwm2m/src/main/resources/credentials/shell/lwM2M_credentials.sh - key_store_type: "${LWM2M_KEYSTORE_TYPE:JKS}" - # key_store_type: "${LWM2M_KEYSTORE_TYPE:PKCS12}" - # key_store_path_file: "${KEY_STORE_PATH_FILE:/usr/share/thingsboard/conf/credentials/serverKeyStore.jks}" - key_store_path_file: "${KEY_STORE_PATH_FILE:}" - key_store_password: "${LWM2M_KEYSTORE_PASSWORD_SERVER:server_ks_password}" - root_alias: "${LWM2M_SERVER_ROOT_CA:rootca}" - enable_gen_psk_rpk: "${ENABLE_GEN_PSK_RPK:true}" - server: - bind_address: "${LWM2M_BIND_ADDRESS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT:5685}" - bind_port_cert: "${LWM2M_BIND_PORT_CERT:5687}" - secure: - start_all: "${START_SERVER_ALL:true}" - #leshan.core (V1_1) - #DTLS security modes: - #0: Pre-Shared Key mode - #1: Raw Public Key mode - #2: Certificate mode X509 - #3: NoSec mode * - #OMA-TS-LightweightM2M_Core-V1_1_1-20190617-A (add) - #4: Certificate mode X509 with EST - # If only startAll == false - dtls_mode: "${LWM2M_SECURITY_MODE:1}" - bind_address: "${LWM2M_BIND_ADDRESS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT_SEC:5686}" - bind_port_cert: "${LWM2M_BIND_PORT_SEC_CERT:5688}" - # Only RPK: Public & Private Key - # create_rpk: "${CREATE_RPK:}" - public_x: "${LWM2M_SERVER_PUBLIC_X:405354ea8893471d9296afbc8b020a5c6201b0bb25812a53b849d4480fa5f069}" - public_y: "${LWM2M_SERVER_PUBLIC_Y:30c9237e946a3a1692c1cafaa01a238a077f632c99371348337512363f28212b}" - private_s: "${LWM2M_SERVER_PRIVATE_S:274671fe40ce937b8a6352cf0a418e8a39e4bf0bb9bf74c910db953c20c73802}" - # Only Certificate_x509: - alias: "${LWM2M_KEYSTORE_ALIAS_SERVER:server}" - bootstrap: - enable: "${BOOTSTRAP:true}" - bind_address: "${LWM2M_BIND_ADDRESS_BS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT_BS:5689}" - bind_port_cert: "${LWM2M_BIND_PORT_SER_BS:5691}" - secure: - start_all: "${START_BOOTSTRAP_ALL:true}" - # If only startAll == false - dtls_mode: "${LWM2M_SECURITY_MODE_BS:1}" - bind_address: "${LWM2M_BIND_ADDRESS_BS:0.0.0.0}" - bind_port: "${LWM2M_BIND_PORT_SEC_BS:5690}" - bind_port_cert: "${LWM2M_BIND_PORT_SEC_CERT_BS:5692}" - # Only RPK: Public & Private Key - public_x: "${LWM2M_SERVER_PUBLIC_X_BS:993ef2b698c6a9c0c1d8be78b13a9383c0854c7c7c7a504d289b403794648183}" - public_y: "${LWM2M_SERVER_PUBLIC_Y_BS:267412d5fc4e5ceb2257cb7fd7f76ebdac2fa9aa100afb162e990074cc0bfaa2}" - private_s: "${LWM2M_SERVER_PRIVATE_S_BS:9dbdbb073fc63570693a9aaf1013414e261c571f27e27fc6a8c1c2ad9347875a}" - # Only Certificate_x509: - alias: "${LWM2M_KEYSTORE_ALIAS_BOOTSTRAP:bootstrap}" - # Redis - redis_url: "${LWM2M_REDIS_URL:''}" - sessions: - inactivity_timeout: "${TB_TRANSPORT_SESSIONS_INACTIVITY_TIMEOUT:300000}" - report_timeout: "${TB_TRANSPORT_SESSIONS_REPORT_TIMEOUT:30000}" - json: - # Cast String data types to Numeric if possible when processing Telemetry/Attributes JSON - type_cast_enabled: "${JSON_TYPE_CAST_ENABLED:true}" - # Maximum allowed string value length when processing Telemetry/Attributes JSON (0 value disables string value length check) - max_string_value_length: "${JSON_MAX_STRING_VALUE_LENGTH:0}" - -queue: - type: "${TB_QUEUE_TYPE:kafka}" # kafka (Apache Kafka) or aws-sqs (AWS SQS) or pubsub (PubSub) or service-bus (Azure Service Bus) or rabbitmq (RabbitMQ) - kafka: - bootstrap.servers: "${TB_KAFKA_SERVERS:localhost:9092}" - acks: "${TB_KAFKA_ACKS:all}" - retries: "${TB_KAFKA_RETRIES:1}" - batch.size: "${TB_KAFKA_BATCH_SIZE:16384}" - linger.ms: "${TB_KAFKA_LINGER_MS:1}" - buffer.memory: "${TB_BUFFER_MEMORY:33554432}" - replication_factor: "${TB_QUEUE_KAFKA_REPLICATION_FACTOR:1}" - use_confluent_cloud: "${TB_QUEUE_KAFKA_USE_CONFLUENT_CLOUD:false}" - confluent: - ssl.algorithm: "${TB_QUEUE_KAFKA_CONFLUENT_SSL_ALGORITHM:https}" - sasl.mechanism: "${TB_QUEUE_KAFKA_CONFLUENT_SASL_MECHANISM:PLAIN}" - sasl.config: "${TB_QUEUE_KAFKA_CONFLUENT_SASL_JAAS_CONFIG:org.apache.kafka.common.security.plain.PlainLoginModule required username=\"CLUSTER_API_KEY\" password=\"CLUSTER_API_SECRET\";}" - security.protocol: "${TB_QUEUE_KAFKA_CONFLUENT_SECURITY_PROTOCOL:SASL_SSL}" - other: - topic-properties: - rule-engine: "${TB_QUEUE_KAFKA_RE_TOPIC_PROPERTIES:retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1}" - core: "${TB_QUEUE_KAFKA_CORE_TOPIC_PROPERTIES:retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1}" - transport-api: "${TB_QUEUE_KAFKA_TA_TOPIC_PROPERTIES:retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1}" - notifications: "${TB_QUEUE_KAFKA_NOTIFICATIONS_TOPIC_PROPERTIES:retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1}" - js-executor: "${TB_QUEUE_KAFKA_JE_TOPIC_PROPERTIES:retention.ms:604800000;segment.bytes:26214400;retention.bytes:104857600;partitions:100}" - aws_sqs: - use_default_credential_provider_chain: "${TB_QUEUE_AWS_SQS_USE_DEFAULT_CREDENTIAL_PROVIDER_CHAIN:false}" - access_key_id: "${TB_QUEUE_AWS_SQS_ACCESS_KEY_ID:YOUR_KEY}" - secret_access_key: "${TB_QUEUE_AWS_SQS_SECRET_ACCESS_KEY:YOUR_SECRET}" - region: "${TB_QUEUE_AWS_SQS_REGION:YOUR_REGION}" - threads_per_topic: "${TB_QUEUE_AWS_SQS_THREADS_PER_TOPIC:1}" - queue-properties: - rule-engine: "${TB_QUEUE_AWS_SQS_RE_QUEUE_PROPERTIES:VisibilityTimeout:30;MaximumMessageSize:262144;MessageRetentionPeriod:604800}" - core: "${TB_QUEUE_AWS_SQS_CORE_QUEUE_PROPERTIES:VisibilityTimeout:30;MaximumMessageSize:262144;MessageRetentionPeriod:604800}" - transport-api: "${TB_QUEUE_AWS_SQS_TA_QUEUE_PROPERTIES:VisibilityTimeout:30;MaximumMessageSize:262144;MessageRetentionPeriod:604800}" - notifications: "${TB_QUEUE_AWS_SQS_NOTIFICATIONS_QUEUE_PROPERTIES:VisibilityTimeout:30;MaximumMessageSize:262144;MessageRetentionPeriod:604800}" - js-executor: "${TB_QUEUE_AWS_SQS_JE_QUEUE_PROPERTIES:VisibilityTimeout:30;MaximumMessageSize:262144;MessageRetentionPeriod:604800}" - # VisibilityTimeout in seconds;MaximumMessageSize in bytes;MessageRetentionPeriod in seconds - pubsub: - project_id: "${TB_QUEUE_PUBSUB_PROJECT_ID:YOUR_PROJECT_ID}" - service_account: "${TB_QUEUE_PUBSUB_SERVICE_ACCOUNT:YOUR_SERVICE_ACCOUNT}" - max_msg_size: "${TB_QUEUE_PUBSUB_MAX_MSG_SIZE:1048576}" #in bytes - max_messages: "${TB_QUEUE_PUBSUB_MAX_MESSAGES:1000}" - queue-properties: - rule-engine: "${TB_QUEUE_PUBSUB_RE_QUEUE_PROPERTIES:ackDeadlineInSec:30;messageRetentionInSec:604800}" - core: "${TB_QUEUE_PUBSUB_CORE_QUEUE_PROPERTIES:ackDeadlineInSec:30;messageRetentionInSec:604800}" - transport-api: "${TB_QUEUE_PUBSUB_TA_QUEUE_PROPERTIES:ackDeadlineInSec:30;messageRetentionInSec:604800}" - notifications: "${TB_QUEUE_PUBSUB_NOTIFICATIONS_QUEUE_PROPERTIES:ackDeadlineInSec:30;messageRetentionInSec:604800}" - js-executor: "${TB_QUEUE_PUBSUB_JE_QUEUE_PROPERTIES:ackDeadlineInSec:30;messageRetentionInSec:604800}" - service_bus: - namespace_name: "${TB_QUEUE_SERVICE_BUS_NAMESPACE_NAME:YOUR_NAMESPACE_NAME}" - sas_key_name: "${TB_QUEUE_SERVICE_BUS_SAS_KEY_NAME:YOUR_SAS_KEY_NAME}" - sas_key: "${TB_QUEUE_SERVICE_BUS_SAS_KEY:YOUR_SAS_KEY}" - max_messages: "${TB_QUEUE_SERVICE_BUS_MAX_MESSAGES:1000}" - queue-properties: - rule-engine: "${TB_QUEUE_SERVICE_BUS_RE_QUEUE_PROPERTIES:lockDurationInSec:30;maxSizeInMb:1024;messageTimeToLiveInSec:604800}" - core: "${TB_QUEUE_SERVICE_BUS_CORE_QUEUE_PROPERTIES:lockDurationInSec:30;maxSizeInMb:1024;messageTimeToLiveInSec:604800}" - transport-api: "${TB_QUEUE_SERVICE_BUS_TA_QUEUE_PROPERTIES:lockDurationInSec:30;maxSizeInMb:1024;messageTimeToLiveInSec:604800}" - notifications: "${TB_QUEUE_SERVICE_BUS_NOTIFICATIONS_QUEUE_PROPERTIES:lockDurationInSec:30;maxSizeInMb:1024;messageTimeToLiveInSec:604800}" - js-executor: "${TB_QUEUE_SERVICE_BUS_JE_QUEUE_PROPERTIES:lockDurationInSec:30;maxSizeInMb:1024;messageTimeToLiveInSec:604800}" - rabbitmq: - exchange_name: "${TB_QUEUE_RABBIT_MQ_EXCHANGE_NAME:}" - host: "${TB_QUEUE_RABBIT_MQ_HOST:localhost}" - port: "${TB_QUEUE_RABBIT_MQ_PORT:5672}" - virtual_host: "${TB_QUEUE_RABBIT_MQ_VIRTUAL_HOST:/}" - username: "${TB_QUEUE_RABBIT_MQ_USERNAME:YOUR_USERNAME}" - password: "${TB_QUEUE_RABBIT_MQ_PASSWORD:YOUR_PASSWORD}" - automatic_recovery_enabled: "${TB_QUEUE_RABBIT_MQ_AUTOMATIC_RECOVERY_ENABLED:false}" - connection_timeout: "${TB_QUEUE_RABBIT_MQ_CONNECTION_TIMEOUT:60000}" - handshake_timeout: "${TB_QUEUE_RABBIT_MQ_HANDSHAKE_TIMEOUT:10000}" - queue-properties: - rule-engine: "${TB_QUEUE_RABBIT_MQ_RE_QUEUE_PROPERTIES:x-max-length-bytes:1048576000;x-message-ttl:604800000}" - core: "${TB_QUEUE_RABBIT_MQ_CORE_QUEUE_PROPERTIES:x-max-length-bytes:1048576000;x-message-ttl:604800000}" - transport-api: "${TB_QUEUE_RABBIT_MQ_TA_QUEUE_PROPERTIES:x-max-length-bytes:1048576000;x-message-ttl:604800000}" - notifications: "${TB_QUEUE_RABBIT_MQ_NOTIFICATIONS_QUEUE_PROPERTIES:x-max-length-bytes:1048576000;x-message-ttl:604800000}" - js-executor: "${TB_QUEUE_RABBIT_MQ_JE_QUEUE_PROPERTIES:x-max-length-bytes:1048576000;x-message-ttl:604800000}" - partitions: - hash_function_name: "${TB_QUEUE_PARTITIONS_HASH_FUNCTION_NAME:murmur3_128}" - virtual_nodes_size: "${TB_QUEUE_PARTITIONS_VIRTUAL_NODES_SIZE:16}" - transport_api: - requests_topic: "${TB_QUEUE_TRANSPORT_API_REQUEST_TOPIC:tb_transport.api.requests}" - responses_topic: "${TB_QUEUE_TRANSPORT_API_RESPONSE_TOPIC:tb_transport.api.responses}" - max_pending_requests: "${TB_QUEUE_TRANSPORT_MAX_PENDING_REQUESTS:10000}" - max_requests_timeout: "${TB_QUEUE_TRANSPORT_MAX_REQUEST_TIMEOUT:10000}" - max_callback_threads: "${TB_QUEUE_TRANSPORT_MAX_CALLBACK_THREADS:100}" - request_poll_interval: "${TB_QUEUE_TRANSPORT_REQUEST_POLL_INTERVAL_MS:25}" - response_poll_interval: "${TB_QUEUE_TRANSPORT_RESPONSE_POLL_INTERVAL_MS:25}" - core: - topic: "${TB_QUEUE_CORE_TOPIC:tb_core}" - poll-interval: "${TB_QUEUE_CORE_POLL_INTERVAL_MS:25}" - partitions: "${TB_QUEUE_CORE_PARTITIONS:10}" - pack-processing-timeout: "${TB_QUEUE_CORE_PACK_PROCESSING_TIMEOUT_MS:60000}" - stats: - enabled: "${TB_QUEUE_CORE_STATS_ENABLED:false}" - print-interval-ms: "${TB_QUEUE_CORE_STATS_PRINT_INTERVAL_MS:10000}" - js: - # JS Eval request topic - request_topic: "${REMOTE_JS_EVAL_REQUEST_TOPIC:js_eval.requests}" - # JS Eval responses topic prefix that is combined with node id - response_topic_prefix: "${REMOTE_JS_EVAL_RESPONSE_TOPIC:js_eval.responses}" - # JS Eval max pending requests - max_pending_requests: "${REMOTE_JS_MAX_PENDING_REQUESTS:10000}" - # JS Eval max request timeout - max_requests_timeout: "${REMOTE_JS_MAX_REQUEST_TIMEOUT:10000}" - # JS response poll interval - response_poll_interval: "${REMOTE_JS_RESPONSE_POLL_INTERVAL_MS:25}" - # JS response auto commit interval - response_auto_commit_interval: "${REMOTE_JS_RESPONSE_AUTO_COMMIT_INTERVAL_MS:100}" - rule-engine: - topic: "${TB_QUEUE_RULE_ENGINE_TOPIC:tb_rule_engine}" - poll-interval: "${TB_QUEUE_RULE_ENGINE_POLL_INTERVAL_MS:25}" - pack-processing-timeout: "${TB_QUEUE_RULE_ENGINE_PACK_PROCESSING_TIMEOUT_MS:60000}" - stats: - enabled: "${TB_QUEUE_RULE_ENGINE_STATS_ENABLED:true}" - print-interval-ms: "${TB_QUEUE_RULE_ENGINE_STATS_PRINT_INTERVAL_MS:60000}" - queues: - - name: "${TB_QUEUE_RE_MAIN_QUEUE_NAME:Main}" - topic: "${TB_QUEUE_RE_MAIN_TOPIC:tb_rule_engine.main}" - poll-interval: "${TB_QUEUE_RE_MAIN_POLL_INTERVAL_MS:25}" - partitions: "${TB_QUEUE_RE_MAIN_PARTITIONS:10}" - pack-processing-timeout: "${TB_QUEUE_RE_MAIN_PACK_PROCESSING_TIMEOUT_MS:60000}" - submit-strategy: - type: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL - # For BATCH only - batch-size: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_BATCH_SIZE:1000}" # Maximum number of messages in batch - processing-strategy: - type: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_TYPE:SKIP_ALL_FAILURES}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT - # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT - retries: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited - failure-percentage: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages; - pause-between-retries: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_RETRY_PAUSE:3}"# Time in seconds to wait in consumer thread before retries; - - name: "${TB_QUEUE_RE_HP_QUEUE_NAME:HighPriority}" - topic: "${TB_QUEUE_RE_HP_TOPIC:tb_rule_engine.hp}" - poll-interval: "${TB_QUEUE_RE_HP_POLL_INTERVAL_MS:25}" - partitions: "${TB_QUEUE_RE_HP_PARTITIONS:10}" - pack-processing-timeout: "${TB_QUEUE_RE_HP_PACK_PROCESSING_TIMEOUT_MS:60000}" - submit-strategy: - type: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL - # For BATCH only - batch-size: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch - processing-strategy: - type: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT - # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT - retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRIES:0}" # Number of retries, 0 is unlimited - failure-percentage: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages; - pause-between-retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries; - - name: "${TB_QUEUE_RE_SQ_QUEUE_NAME:SequentialByOriginator}" - topic: "${TB_QUEUE_RE_SQ_TOPIC:tb_rule_engine.sq}" - poll-interval: "${TB_QUEUE_RE_SQ_POLL_INTERVAL_MS:25}" - partitions: "${TB_QUEUE_RE_SQ_PARTITIONS:10}" - pack-processing-timeout: "${TB_QUEUE_RE_SQ_PACK_PROCESSING_TIMEOUT_MS:60000}" - submit-strategy: - type: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_TYPE:SEQUENTIAL_BY_ORIGINATOR}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL - # For BATCH only - batch-size: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch - processing-strategy: - type: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT - # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT - retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited - failure-percentage: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages; - pause-between-retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries; - transport: - # For high priority notifications that require minimum latency and processing time - notifications_topic: "${TB_QUEUE_TRANSPORT_NOTIFICATIONS_TOPIC:tb_transport.notifications}" - poll_interval: "${TB_QUEUE_TRANSPORT_NOTIFICATIONS_POLL_INTERVAL_MS:25}" - -service: - type: "${TB_SERVICE_TYPE:tb-transport}" - # Unique id for this service (autogenerated if empty) - id: "${TB_SERVICE_ID:}" - tenant_id: "${TB_SERVICE_TENANT_ID:}" # empty or specific tenant id. - - -metrics: - # Enable/disable actuator metrics. - enabled: "${METRICS_ENABLED:false}" - -management: - endpoints: - web: - exposure: - # Expose metrics endpoint (use value 'prometheus' to enable prometheus metrics). - include: '${METRICS_ENDPOINTS_EXPOSE:info}' diff --git a/transport/pom.xml b/transport/pom.xml index c289237a03..d477fc7de2 100644 --- a/transport/pom.xml +++ b/transport/pom.xml @@ -37,7 +37,6 @@ http mqtt coap - lwm2m diff --git a/ui-ngx/src/app/core/http/device-profile.service.ts b/ui-ngx/src/app/core/http/device-profile.service.ts index 16f6edb512..c535878fd2 100644 --- a/ui-ngx/src/app/core/http/device-profile.service.ts +++ b/ui-ngx/src/app/core/http/device-profile.service.ts @@ -22,9 +22,6 @@ import { Observable } from 'rxjs'; import { PageData } from '@shared/models/page/page-data'; import { DeviceProfile, DeviceProfileInfo, DeviceTransportType } from '@shared/models/device.models'; import { isDefinedAndNotNull } from '@core/utils'; -import { - ObjectLwM2M, ServerSecurityConfig -} from "../../modules/home/components/profile/device/lwm2m/profile-config.models"; @Injectable({ providedIn: 'root' @@ -43,18 +40,6 @@ export class DeviceProfileService { return this.http.get(`/api/deviceProfile/${deviceProfileId}`, defaultHttpOptionsFromConfig(config)); } - public getLwm2mObjects(objectIds: number [], config?: RequestConfig): Observable { - return this.http.get(`/api/lwm2m/deviceProfile/${objectIds}`, defaultHttpOptionsFromConfig(config)); - } - - public getLwm2mBootstrapSecurityInfo(securityMode: string, bootstrapServerIs: boolean, config?: RequestConfig): Observable { - return this.http.get(`/api/lwm2m/deviceProfile/bootstrap/${securityMode}/${bootstrapServerIs}`, defaultHttpOptionsFromConfig(config)); - } - - public getLwm2mObjectsPage(pageLink: PageLink, config?: RequestConfig): Observable> { - return this.http.get>(`/api/lwm2m/deviceProfile/objects${pageLink.toQuery()}`, defaultHttpOptionsFromConfig(config)); - } - public saveDeviceProfile(deviceProfile: DeviceProfile, config?: RequestConfig): Observable { return this.http.post('/api/deviceProfile', deviceProfile, defaultHttpOptionsFromConfig(config)); } diff --git a/ui-ngx/src/app/modules/home/components/device/device-credentials.component.html b/ui-ngx/src/app/modules/home/components/device/device-credentials.component.html index 44337d30a5..a8b48e30d1 100644 --- a/ui-ngx/src/app/modules/home/components/device/device-credentials.component.html +++ b/ui-ngx/src/app/modules/home/components/device/device-credentials.component.html @@ -74,29 +74,4 @@ [error]="deviceCredentialsFormGroup.get('credentialsBasic').hasError('atLeastOne') ? ('device.client-id-or-user-name-necessary' | translate) : ''"> -

- - device.lwm2m-key - - - {{ 'device.lwm2m-key-required' | translate }} - - - - device.lwm2m-value - - - {{ 'device.lwm2m-value-required' | translate }} - -
- -
-
-
diff --git a/ui-ngx/src/app/modules/home/components/device/device-credentials.component.ts b/ui-ngx/src/app/modules/home/components/device/device-credentials.component.ts index 4c622747ef..fd6680fe17 100644 --- a/ui-ngx/src/app/modules/home/components/device/device-credentials.component.ts +++ b/ui-ngx/src/app/modules/home/components/device/device-credentials.component.ts @@ -14,7 +14,7 @@ /// limitations under the License. /// -import { Component, forwardRef, Inject, Input, OnDestroy, OnInit } from '@angular/core'; +import { Component, forwardRef, Input, OnDestroy, OnInit } from '@angular/core'; import { ControlValueAccessor, FormBuilder, @@ -34,19 +34,8 @@ import { DeviceCredentialsType } from '@shared/models/device.models'; import { Subscription } from 'rxjs'; -import { distinctUntilChanged } from 'rxjs/operators'; -import { SecurityConfigComponent } from '@home/pages/device/lwm2m/security-config.component'; -import { - DEFAULT_END_POINT, - DeviceCredentialsDialogLwm2mData, - END_POINT, - getDefaultSecurityConfig, - JSON_ALL_CONFIG, - SecurityConfigModels -} from '@home/pages/device/lwm2m/security-config.models'; -import { TranslateService } from '@ngx-translate/core'; -import { MatDialog } from '@angular/material/dialog'; import { isDefinedAndNotNull } from '@core/utils'; +import { distinctUntilChanged } from 'rxjs/operators'; @Component({ selector: 'tb-device-credentials', @@ -87,9 +76,7 @@ export class DeviceCredentialsComponent implements ControlValueAccessor, OnInit, private propagateChange = (v: any) => {}; - constructor(public fb: FormBuilder, - private translate: TranslateService, - private dialog: MatDialog) { + constructor(public fb: FormBuilder) { this.deviceCredentialsFormGroup = this.fb.group({ credentialsType: [DeviceCredentialsType.ACCESS_TOKEN], credentialsId: [null], @@ -210,14 +197,6 @@ export class DeviceCredentialsComponent implements ControlValueAccessor, OnInit, this.deviceCredentialsFormGroup.get('credentialsId').updateValueAndValidity({emitEvent: false}); this.deviceCredentialsFormGroup.get('credentialsValue').setValidators([]); this.deviceCredentialsFormGroup.get('credentialsValue').updateValueAndValidity({emitEvent: false}); - break; - case DeviceCredentialsType.LWM2M_CREDENTIALS: - this.deviceCredentialsFormGroup.get('credentialsValue').setValidators([Validators.required]); - this.deviceCredentialsFormGroup.get('credentialsValue').updateValueAndValidity({emitEvent: false}); - this.deviceCredentialsFormGroup.get('credentialsId').setValidators([]); - this.deviceCredentialsFormGroup.get('credentialsId').updateValueAndValidity({emitEvent: false}); - this.deviceCredentialsFormGroup.get('credentialsBasic').disable({emitEvent: false}); - break; } } @@ -244,28 +223,4 @@ export class DeviceCredentialsComponent implements ControlValueAccessor, OnInit, onlySelf: true }); } - - openSecurityInfoLwM2mDialog($event: Event, value: string, id: string): void { - if ($event) { - $event.stopPropagation(); - $event.preventDefault(); - } - this.dialog.open(SecurityConfigComponent, { - disableClose: true, - panelClass: ['tb-dialog', 'tb-fullscreen-dialog'], - data: { - jsonAllConfig: (value === null || value.length === 0) ? getDefaultSecurityConfig() as SecurityConfigModels : JSON.parse(value) as SecurityConfigModels, - endPoint: (id === null) ? DEFAULT_END_POINT : id, - isNew: (id === null || value === null || value.length === 0) - } - }).afterClosed().subscribe( - (res) => { - if (res) { - this.deviceCredentialsFormGroup.get('credentialsValue').patchValue((Object.keys(res[JSON_ALL_CONFIG]).length === 0 || JSON.stringify(res[JSON_ALL_CONFIG]) === "[{}]") ? null : JSON.stringify(res[JSON_ALL_CONFIG])); - this.deviceCredentialsFormGroup.get('credentialsId').patchValue((Object.keys(res[END_POINT]).length === 0 || JSON.stringify(res[END_POINT]) === "[{}]") ? null : JSON.stringify(res[END_POINT]).split('\"').join('')); - this.deviceCredentialsFormGroup.get('credentialsValue').markAsDirty(); - } - } - ); - } } diff --git a/ui-ngx/src/app/modules/home/components/home-components.module.ts b/ui-ngx/src/app/modules/home/components/home-components.module.ts index 67f86cb812..113f4ae4bb 100644 --- a/ui-ngx/src/app/modules/home/components/home-components.module.ts +++ b/ui-ngx/src/app/modules/home/components/home-components.module.ts @@ -96,6 +96,7 @@ import { DeviceProfileTransportConfigurationComponent } from '@home/components/p import { DeviceProfileDialogComponent } from '@home/components/profile/device-profile-dialog.component'; import { DeviceProfileAutocompleteComponent } from '@home/components/profile/device-profile-autocomplete.component'; import { MqttDeviceProfileTransportConfigurationComponent } from '@home/components/profile/device/mqtt-device-profile-transport-configuration.component'; +import { Lwm2mDeviceProfileTransportConfigurationComponent } from '@home/components/profile/device/lwm2m-device-profile-transport-configuration.component'; import { DeviceProfileAlarmsComponent } from '@home/components/profile/alarm/device-profile-alarms.component'; import { DeviceProfileAlarmComponent } from '@home/components/profile/alarm/device-profile-alarm.component'; import { CreateAlarmRulesComponent } from '@home/components/profile/alarm/create-alarm-rules.component'; @@ -118,7 +119,6 @@ import { SmsProviderConfigurationComponent } from '@home/components/sms/sms-prov import { AwsSnsProviderConfigurationComponent } from '@home/components/sms/aws-sns-provider-configuration.component'; import { TwilioSmsProviderConfigurationComponent } from '@home/components/sms/twilio-sms-provider-configuration.component'; import { CopyDeviceCredentialsComponent } from '@home/components/device/copy-device-credentials.component'; -import { Lwm2mProfileComponentsModule } from '@home/components/profile/device/lwm2m/lwm2m-profile-components.module'; @NgModule({ declarations: @@ -198,6 +198,7 @@ import { Lwm2mProfileComponentsModule } from '@home/components/profile/device/lw DeviceProfileConfigurationComponent, DefaultDeviceProfileTransportConfigurationComponent, MqttDeviceProfileTransportConfigurationComponent, + Lwm2mDeviceProfileTransportConfigurationComponent, DeviceProfileTransportConfigurationComponent, CreateAlarmRulesComponent, AlarmRuleComponent, @@ -224,8 +225,7 @@ import { Lwm2mProfileComponentsModule } from '@home/components/profile/device/lw imports: [ CommonModule, SharedModule, - SharedHomeComponentsModule, - Lwm2mProfileComponentsModule + SharedHomeComponentsModule ], exports: [ EntitiesTableComponent, @@ -287,6 +287,7 @@ import { Lwm2mProfileComponentsModule } from '@home/components/profile/device/lw DeviceProfileConfigurationComponent, DefaultDeviceProfileTransportConfigurationComponent, MqttDeviceProfileTransportConfigurationComponent, + Lwm2mDeviceProfileTransportConfigurationComponent, DeviceProfileTransportConfigurationComponent, CreateAlarmRulesComponent, AlarmRuleComponent, @@ -306,8 +307,6 @@ import { Lwm2mProfileComponentsModule } from '@home/components/profile/device/lw AlarmScheduleDialogComponent, EditAlarmDetailsDialogComponent, DeviceProfileProvisionConfigurationComponent, - AlarmScheduleComponent, - Lwm2mProfileComponentsModule, SmsProviderConfigurationComponent, AwsSnsProviderConfigurationComponent, TwilioSmsProviderConfigurationComponent diff --git a/ui-ngx/src/app/modules/home/components/profile/device-profile-dialog.component.ts b/ui-ngx/src/app/modules/home/components/profile/device-profile-dialog.component.ts index 6dea0eaad8..b3e96c228d 100644 --- a/ui-ngx/src/app/modules/home/components/profile/device-profile-dialog.component.ts +++ b/ui-ngx/src/app/modules/home/components/profile/device-profile-dialog.component.ts @@ -97,4 +97,5 @@ export class DeviceProfileDialogComponent extends ); } } + } diff --git a/ui-ngx/src/app/modules/home/components/profile/device/device-profile-transport-configuration.component.html b/ui-ngx/src/app/modules/home/components/profile/device/device-profile-transport-configuration.component.html index c88f1f8b85..ea6427addd 100644 --- a/ui-ngx/src/app/modules/home/components/profile/device/device-profile-transport-configuration.component.html +++ b/ui-ngx/src/app/modules/home/components/profile/device/device-profile-transport-configuration.component.html @@ -29,11 +29,11 @@ formControlName="configuration"> - - + - - + + diff --git a/transport/lwm2m/src/main/resources/logback.xml b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.html similarity index 52% rename from transport/lwm2m/src/main/resources/logback.xml rename to ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.html index e96ad177ef..03530c2b2e 100644 --- a/transport/lwm2m/src/main/resources/logback.xml +++ b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.html @@ -1,4 +1,3 @@ - - - - - - - %d{ISO8601} [%thread] %-5level %logger{36} - %msg%n - - - - - - - - - - - - \ No newline at end of file +
+ + +
diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.ts new file mode 100644 index 0000000000..7a7a1d285f --- /dev/null +++ b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m-device-profile-transport-configuration.component.ts @@ -0,0 +1,96 @@ +/// +/// Copyright © 2016-2020 The Thingsboard Authors +/// +/// Licensed under the Apache License, Version 2.0 (the "License"); +/// you may not use this file except in compliance with the License. +/// You may obtain a copy of the License at +/// +/// http://www.apache.org/licenses/LICENSE-2.0 +/// +/// Unless required by applicable law or agreed to in writing, software +/// distributed under the License is distributed on an "AS IS" BASIS, +/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +/// See the License for the specific language governing permissions and +/// limitations under the License. +/// + +import { Component, forwardRef, Input, OnInit } from '@angular/core'; +import { ControlValueAccessor, FormBuilder, FormGroup, NG_VALUE_ACCESSOR, Validators } from '@angular/forms'; +import { Store } from '@ngrx/store'; +import { AppState } from '@app/core/core.state'; +import { coerceBooleanProperty } from '@angular/cdk/coercion'; +import { + DeviceProfileTransportConfiguration, + DeviceTransportType, Lwm2mDeviceProfileTransportConfiguration +} from '@shared/models/device.models'; + +@Component({ + selector: 'tb-lwm2m-device-profile-transport-configuration', + templateUrl: './lwm2m-device-profile-transport-configuration.component.html', + styleUrls: [], + providers: [{ + provide: NG_VALUE_ACCESSOR, + useExisting: forwardRef(() => Lwm2mDeviceProfileTransportConfigurationComponent), + multi: true + }] +}) +export class Lwm2mDeviceProfileTransportConfigurationComponent implements ControlValueAccessor, OnInit { + + lwm2mDeviceProfileTransportConfigurationFormGroup: FormGroup; + + private requiredValue: boolean; + get required(): boolean { + return this.requiredValue; + } + @Input() + set required(value: boolean) { + this.requiredValue = coerceBooleanProperty(value); + } + + @Input() + disabled: boolean; + + private propagateChange = (v: any) => { }; + + constructor(private store: Store, + private fb: FormBuilder) { + } + + registerOnChange(fn: any): void { + this.propagateChange = fn; + } + + registerOnTouched(fn: any): void { + } + + ngOnInit() { + this.lwm2mDeviceProfileTransportConfigurationFormGroup = this.fb.group({ + configuration: [null, Validators.required] + }); + this.lwm2mDeviceProfileTransportConfigurationFormGroup.valueChanges.subscribe(() => { + this.updateModel(); + }); + } + + setDisabledState(isDisabled: boolean): void { + this.disabled = isDisabled; + if (this.disabled) { + this.lwm2mDeviceProfileTransportConfigurationFormGroup.disable({emitEvent: false}); + } else { + this.lwm2mDeviceProfileTransportConfigurationFormGroup.enable({emitEvent: false}); + } + } + + writeValue(value: Lwm2mDeviceProfileTransportConfiguration | null): void { + this.lwm2mDeviceProfileTransportConfigurationFormGroup.patchValue({configuration: value}, {emitEvent: false}); + } + + private updateModel() { + let configuration: DeviceProfileTransportConfiguration = null; + if (this.lwm2mDeviceProfileTransportConfigurationFormGroup.valid) { + configuration = this.lwm2mDeviceProfileTransportConfigurationFormGroup.getRawValue().configuration; + // configuration.type = DeviceTransportType.LWM2M; + } + this.propagateChange(configuration); + } +} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.html b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.html deleted file mode 100644 index 0e10a8e843..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.html +++ /dev/null @@ -1,120 +0,0 @@ - -
-
-
-
- - {{ 'device-profile.lwm2m.mode' | translate }} - - - {{ credentialTypeLwM2MNamesMap.get(securityConfigLwM2MType[securityMode]) }} - - - - - {{ 'device-profile.lwm2m.server-host' | translate }} - - - {{ 'device-profile.lwm2m.server-host' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - - - {{ 'device-profile.lwm2m.server-port' | translate }} - - - {{ 'device-profile.lwm2m.server-port' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - - - {{ 'device-profile.lwm2m.short-id' | translate }} - - - {{ 'device-profile.lwm2m.short-id' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - -
-
-
-
- - {{ 'device-profile.lwm2m.client-hold-off-time' | translate }} - - - {{ 'device-profile.lwm2m.client-hold-off-time' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - - - {{ 'device-profile.lwm2m.bootstrap-server-account-timeout' | translate }} - - - {{ 'device-profile.lwm2m.bootstrap-server-account-timeout' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - - - {{ 'device-profile.lwm2m.bootstrap-server' | translate }} - -
-
-
- - {{ 'device-profile.lwm2m.server-public-key' | translate }} - - {{serverPublicKey.value?.length || 0}}/{{lenMaxServerPublicKey}} - - {{ 'device-profile.lwm2m.server-public-key' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - - {{ 'device-profile.lwm2m.client-key' | translate }} - {{ 'device-profile.lwm2m.pattern_hex_dec_182' | translate }} - - - {{ 'device-profile.lwm2m.client-key' | translate }} - {{ 'device-profile.lwm2m.pattern_hex_dec' | translate }} - - -
-
-
-
-
diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.ts deleted file mode 100644 index 9f1fed9bc9..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.ts +++ /dev/null @@ -1,223 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { Component, forwardRef, Inject, Input, OnInit } from "@angular/core"; - -import { - ControlValueAccessor, - FormBuilder, FormGroup, NG_VALUE_ACCESSOR, NgModel, Validators -} from "@angular/forms"; -import { - SECURITY_CONFIG_MODE, - SECURITY_CONFIG_MODE_NAMES, - KEY_PUBLIC_REGEXP_PSK, - ServerSecurityConfig, - LEN_MAX_PUBLIC_KEY_PSK, - LEN_MAX_PUBLIC_KEY_RPK_X509, - KEY_PUBLIC_REGEXP_X509, - DEFAULT_PORT_BOOTSTRAP_NO_SEC, - DEFAULT_PORT_SERVER_NO_SEC, - DEFAULT_CLIENT_HOLD_OFF_TIME, - DEFAULT_ID_SERVER -} from "./profile-config.models"; -import { Store } from "@ngrx/store"; -import { AppState } from "@core/core.state"; -import { coerceBooleanProperty } from "@angular/cdk/coercion"; -import { WINDOW } from "../../../../../../core/services/window.service"; -import { pairwise, startWith } from 'rxjs/operators'; -import { DeviceProfileService } from '@core/http/device-profile.service'; - -@Component({ - selector: 'tb-profile-lwm2m-device-config-server', - templateUrl: './lwm2m-device-config-server.component.html', - styleUrls: [], - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: forwardRef(() => Lwm2mDeviceConfigServerComponent), - multi: true - } - ] -}) - -export class Lwm2mDeviceConfigServerComponent implements OnInit, ControlValueAccessor, Validators { - - valuePrev = null as any; - private requiredValue: boolean; - serverFormGroup: FormGroup; - securityConfigLwM2MType = SECURITY_CONFIG_MODE; - securityConfigLwM2MTypes = Object.keys(SECURITY_CONFIG_MODE); - credentialTypeLwM2MNamesMap = SECURITY_CONFIG_MODE_NAMES; - lenMaxServerPublicKey = LEN_MAX_PUBLIC_KEY_PSK; - currentSecurityMode = null; - - - @Input() - disabled: boolean; - - @Input() - bootstrapServerIs: boolean - - get required(): boolean { - return this.requiredValue; - } - - @Input() - set required(value: boolean) { - this.requiredValue = coerceBooleanProperty(value); - } - - constructor(protected store: Store, - public fb: FormBuilder, - private deviceProfileService: DeviceProfileService, - @Inject(WINDOW) private window: Window) { - this.serverFormGroup = this.getServerGroup(); - this.serverFormGroup.get('securityMode').valueChanges.pipe( - startWith(null), - pairwise() - ).subscribe(([previousValue, currentValue]) => { - if (previousValue === null || previousValue !== currentValue) { - this.getLwm2mBootstrapSecurityInfo(currentValue); - this.updateValidate(currentValue); - this.serverFormGroup.updateValueAndValidity(); - } - - }); - this.serverFormGroup.valueChanges.subscribe(value => { - if (this.disabled !== undefined && !this.disabled) { - this.propagateChangeState(value); - } - }); - } - - ngOnInit(): void { - } - - updateValueFields(serverData: ServerSecurityConfig): void { - serverData['bootstrapServerIs'] = this.bootstrapServerIs; - this.serverFormGroup.patchValue(serverData, {emitEvent: false}); - this.serverFormGroup.get('bootstrapServerIs').disable(); - const securityMode = this.serverFormGroup.get('securityMode').value as SECURITY_CONFIG_MODE; - this.updateValidate(securityMode); - } - - updateValidate(securityMode: SECURITY_CONFIG_MODE): void { - switch (securityMode) { - case SECURITY_CONFIG_MODE.NO_SEC: - this.serverFormGroup.get('serverPublicKey').setValidators([]); - break; - case SECURITY_CONFIG_MODE.PSK: - this.lenMaxServerPublicKey = LEN_MAX_PUBLIC_KEY_PSK; - this.serverFormGroup.get('serverPublicKey').setValidators([]); - break; - case SECURITY_CONFIG_MODE.RPK: - this.lenMaxServerPublicKey = LEN_MAX_PUBLIC_KEY_RPK_X509; - this.serverFormGroup.get('serverPublicKey').setValidators([Validators.required, Validators.pattern(KEY_PUBLIC_REGEXP_PSK)]); - break; - case SECURITY_CONFIG_MODE.X509: - this.lenMaxServerPublicKey = LEN_MAX_PUBLIC_KEY_RPK_X509; - this.serverFormGroup.get('serverPublicKey').setValidators([Validators.required, Validators.pattern(KEY_PUBLIC_REGEXP_X509)]); - break; - } - this.checkValueWithNewValidate(); - } - - checkValueWithNewValidate(): void { - this.serverFormGroup.patchValue({ - host: this.serverFormGroup.get('host').value, - port: this.serverFormGroup.get('port').value, - bootstrapServerIs: this.serverFormGroup.get('bootstrapServerIs').value, - serverPublicKey: this.serverFormGroup.get('serverPublicKey').value, - clientHoldOffTime: this.serverFormGroup.get('clientHoldOffTime').value, - serverId: this.serverFormGroup.get('serverId').value, - bootstrapServerAccountTimeout: this.serverFormGroup.get('bootstrapServerAccountTimeout').value, - }, - {emitEvent: true}); - } - - writeValue(value: any): void { - if (value) { - this.updateValueFields(value); - } - } - - private propagateChange = (v: any) => { - }; - - registerOnChange(fn: any): void { - this.propagateChange = fn; - } - - private propagateChangeState(value: any): void { - if (value !== undefined) { - if (this.valuePrev === null) { - this.valuePrev = "init"; - } else if (this.valuePrev === "init") { - this.valuePrev = value; - } else if (JSON.stringify(value) !== JSON.stringify(this.valuePrev)) { - this.valuePrev = value; - if (this.serverFormGroup.valid) { - this.propagateChange(value); - } else { - this.propagateChange(null); - } - } - } - } - - setDisabledState(isDisabled: boolean): void { - this.disabled = isDisabled; - this.valuePrev = null; - if (isDisabled) { - this.serverFormGroup.disable({emitEvent: false}); - } else { - this.serverFormGroup.enable({emitEvent: false}); - } - } - - registerOnTouched(fn: any): void { - } - - getServerGroup(): FormGroup { - const port = (this.bootstrapServerIs) ? DEFAULT_PORT_BOOTSTRAP_NO_SEC : DEFAULT_PORT_SERVER_NO_SEC; - return this.fb.group({ - host: [this.window.location.hostname, this.required ? [Validators.required] : []], - port: [port, this.required ? [Validators.required] : []], - bootstrapServerIs: [this.bootstrapServerIs, []], - securityMode: [this.fb.control(SECURITY_CONFIG_MODE.NO_SEC), []], - serverPublicKey: ['', this.required ? [Validators.required] : []], - clientHoldOffTime: [DEFAULT_CLIENT_HOLD_OFF_TIME, this.required ? [Validators.required] : []], - serverId: [DEFAULT_ID_SERVER, this.required ? [Validators.required] : []], - bootstrapServerAccountTimeout: ['', this.required ? [Validators.required] : []], - }) - } - - getLwm2mBootstrapSecurityInfo(mode: string) { - this.deviceProfileService.getLwm2mBootstrapSecurityInfo(mode, this.serverFormGroup.get('bootstrapServerIs').value).subscribe( - (serverSecurityConfig) => { - this.serverFormGroup.patchValue({ - host: serverSecurityConfig.host, - port: serverSecurityConfig.port, - serverPublicKey: serverSecurityConfig.serverPublicKey, - clientHoldOffTime: serverSecurityConfig.clientHoldOffTime, - serverId: serverSecurityConfig.serverId, - bootstrapServerAccountTimeout: serverSecurityConfig.bootstrapServerAccountTimeout - }, - {emitEvent: true}); - } - ); - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.html b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.html deleted file mode 100644 index 846f991e3e..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.html +++ /dev/null @@ -1,140 +0,0 @@ - -
-
- - -
- - -
-
- - -
-
- -
- - - - -
{{ 'device-profile.lwm2m.servers' | translate | uppercase }}
-
-
-
-
- - {{ 'device-profile.lwm2m.short-id' | translate }} - - - {{ 'device-profile.lwm2m.short-id' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - - - {{ 'device-profile.lwm2m.lifetime' | translate }} - - - {{ 'device-profile.lwm2m.lifetime' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - -
-
- - {{ 'device-profile.lwm2m.default-min-period' | translate }} - - - {{ 'device-profile.lwm2m.default-min-period' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - - - {{ 'device-profile.lwm2m.binding' | translate }} - - - {{ 'device-profile.lwm2m.binding' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - -
-
- - {{ 'device-profile.lwm2m.notif-if-disabled' | translate }} - -
-
-
-
- - - - -
{{ 'device-profile.lwm2m.bootstrap-server' | translate | uppercase }}
-
-
-
- - -
-
-
- - - - -
{{ 'device-profile.lwm2m.lwm2m-server' | translate | uppercase }}
-
-
-
- - -
-
-
-
-
- -
- - -
-
-
-
-
diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.ts deleted file mode 100644 index d724a25332..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.ts +++ /dev/null @@ -1,541 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { - DeviceProfileTransportConfiguration, - DeviceTransportType -} from '@shared/models/device.models'; -import { - Component, - forwardRef, Inject, - Input, - OnInit -} from '@angular/core'; -import { ControlValueAccessor, FormBuilder, FormGroup, NG_VALUE_ACCESSOR, Validators } from '@angular/forms'; -import { Store } from '@ngrx/store'; -import { AppState } from '@app/core/core.state'; -import { coerceBooleanProperty } from '@angular/cdk/coercion'; -import { - ATTR, - OBSERVE, - OBSERVE_ATTR, - TELEMETRY, - ObjectLwM2M, getDefaultProfileConfig, KEY_NAME, Instance -} from "./profile-config.models"; -import { DeviceProfileService } from "../../../../../../core/http/device-profile.service"; -import { deepClone, isUndefined } from "../../../../../../core/utils"; -import { WINDOW } from "../../../../../../core/services/window.service"; -import { JsonObject } from '@angular/compiler-cli/ngcc/src/packages/entry_point'; -import { isNotNullOrUndefined } from 'codelyzer/util/isNotNullOrUndefined'; - -@Component({ - selector: 'tb-profile-lwm2m-device-transport-configuration', - templateUrl: './lwm2m-device-profile-transport-configuration.component.html', - styleUrls: [], - providers: [{ - provide: NG_VALUE_ACCESSOR, - useExisting: forwardRef(() => Lwm2mDeviceProfileTransportConfigurationComponent), - multi: true - }] -}) -export class Lwm2mDeviceProfileTransportConfigurationComponent implements ControlValueAccessor, OnInit, Validators { - - lwm2mDeviceProfileTransportConfFormGroup: FormGroup; - observeAttr = OBSERVE_ATTR as string; - observe = OBSERVE as string; - attribute = ATTR as string; - telemetry = TELEMETRY as string; - keyName = KEY_NAME as string; - bootstrapServers: string; - bootstrapServer: string; - lwm2mServer: string; - private configurationValue: {}; - private requiredValue: boolean; - private disabled = false as boolean; - sortFunction = this.sortObjectKeyPathJson; - - get required(): boolean { - return this.requiredValue; - } - - @Input() - set required(value: boolean) { - this.requiredValue = coerceBooleanProperty(value); - } - - private propagateChange = (v: any) => { - }; - - constructor(private store: Store, - private fb: FormBuilder, - private deviceProfileService: DeviceProfileService, - @Inject(WINDOW) private window: Window) { - this.lwm2mDeviceProfileTransportConfFormGroup = this.fb.group({ - objectIds: [{}, Validators.required], - observeAttrTelemetry: [{'clientLwM2M': [] as ObjectLwM2M []}, Validators.required], - shortId: [null, Validators.required], - lifetime: [null, Validators.required], - defaultMinPeriod: [null, Validators.required], - notifIfDisabled: [true, []], - binding: ["U", Validators.required], - bootstrapServer: [null, Validators.required], - lwm2mServer: [null, Validators.required], - configurationJson: [null, Validators.required], - }); - this.lwm2mDeviceProfileTransportConfFormGroup.valueChanges.subscribe(value => { - if (!this.disabled) { - this.updateModel(); - } - }); - } - - registerOnChange(fn: any): void { - this.propagateChange = fn; - } - - registerOnTouched(fn: any): void { - } - - ngOnInit() { - } - - setDisabledState(isDisabled: boolean): void { - this.disabled = isDisabled; - if (isDisabled) { - this.lwm2mDeviceProfileTransportConfFormGroup.disable({emitEvent: false}); - } else { - this.lwm2mDeviceProfileTransportConfFormGroup.enable({emitEvent: false}); - } - } - - writeValue(value: any | null): void { - value = (Object.keys(value).length == 0) ? getDefaultProfileConfig() : value; - this.lwm2mDeviceProfileTransportConfFormGroup.patchValue({ - configurationJson: value - }, - {emitEvent: false}); - this.configurationValue = this.lwm2mDeviceProfileTransportConfFormGroup.getRawValue().configurationJson; - this.initWriteValue(); - } - - private initWriteValue(): void { - let modelValue = {"objectIds": null, "objectsList": []}; - modelValue.objectIds = this.getObjectsFromJsonAllConfig(); - if (modelValue.objectIds !== null) { - this.deviceProfileService.getLwm2mObjects(modelValue.objectIds).subscribe( - (objectsList) => { - modelValue.objectsList = objectsList; - this.updateWriteValue(modelValue); - } - ); - } else { - this.updateWriteValue(modelValue); - } - } - - private updateWriteValue(value: any): void { - let objectsList = deepClone(value.objectsList); - this.lwm2mDeviceProfileTransportConfFormGroup.patchValue({ - objectIds: value, - observeAttrTelemetry: {clientLwM2M: this.getObserveAttrTelemetryObjects(objectsList)}, - shortId: this.configurationValue['bootstrap'].servers.shortId, - lifetime: this.configurationValue['bootstrap'].servers.lifetime, - defaultMinPeriod: this.configurationValue['bootstrap'].servers.defaultMinPeriod, - notifIfDisabled: this.configurationValue['bootstrap'].servers.notifIfDisabled, - binding: this.configurationValue['bootstrap'].servers.binding, - bootstrapServer: this.configurationValue['bootstrap'].bootstrapServer, - lwm2mServer: this.configurationValue['bootstrap'].lwm2mServer - }, - {emitEvent: false}); - } - - private updateModel() { - let configuration: DeviceProfileTransportConfiguration = null; - if (this.lwm2mDeviceProfileTransportConfFormGroup.valid) { - this.upDateValueToJson(); - configuration = this.lwm2mDeviceProfileTransportConfFormGroup.getRawValue().configurationJson; - configuration.type = DeviceTransportType.LWM2M; - } - this.propagateChange(configuration); - } - - private updateObserveAttrTelemetryObjectFormGroup(objectsList: ObjectLwM2M[]) { - this.lwm2mDeviceProfileTransportConfFormGroup.patchValue({ - observeAttrTelemetry: {clientLwM2M: this.getObserveAttrTelemetryObjects(objectsList)} - }, - {emitEvent: false}); - this.lwm2mDeviceProfileTransportConfFormGroup.get("observeAttrTelemetry").markAsPristine({ - onlySelf: true - }); - } - - upDateValueToJson(): void { - this.upDateValueToJsonTab_0(); - this.upDateValueToJsonTab_1(); - } - - upDateValueToJsonTab_0(): void { - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get("observeAttrTelemetry").pristine) { - this.upDateObserveAttrTelemetryFromGroupToJson(this.lwm2mDeviceProfileTransportConfFormGroup.get("observeAttrTelemetry").value['clientLwM2M']); - this.lwm2mDeviceProfileTransportConfFormGroup.get("observeAttrTelemetry").markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - } - - upDateValueToJsonTab_1(): void { - this.upDateValueServersToJson(); - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get('bootstrapServer').pristine) { - this.configurationValue['bootstrap'].bootstrapServer = this.lwm2mDeviceProfileTransportConfFormGroup.get('bootstrapServer').value; - this.lwm2mDeviceProfileTransportConfFormGroup.get('bootstrapServer').markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get('lwm2mServer').pristine) { - this.configurationValue['bootstrap'].lwm2mServer = this.lwm2mDeviceProfileTransportConfFormGroup.get('lwm2mServer').value; - this.lwm2mDeviceProfileTransportConfFormGroup.get('lwm2mServer').markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - } - - upDateValueServersToJson(): void { - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get('shortId').pristine) { - this.configurationValue['bootstrap'].servers.shortId = this.lwm2mDeviceProfileTransportConfFormGroup.get('shortId').value; - this.lwm2mDeviceProfileTransportConfFormGroup.get('shortId').markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get('lifetime').pristine) { - this.configurationValue['bootstrap'].servers.lifetime = this.lwm2mDeviceProfileTransportConfFormGroup.get('lifetime').value; - this.lwm2mDeviceProfileTransportConfFormGroup.get('lifetime').markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get('defaultMinPeriod').pristine) { - this.configurationValue['bootstrap'].servers.defaultMinPeriod = this.lwm2mDeviceProfileTransportConfFormGroup.get('defaultMinPeriod').value; - this.lwm2mDeviceProfileTransportConfFormGroup.get('defaultMinPeriod').markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get('notifIfDisabled').pristine) { - this.configurationValue['bootstrap'].servers.notifIfDisabled = this.lwm2mDeviceProfileTransportConfFormGroup.get('notifIfDisabled').value; - this.lwm2mDeviceProfileTransportConfFormGroup.get('notifIfDisabled').markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - if (!this.lwm2mDeviceProfileTransportConfFormGroup.get('binding').pristine) { - this.configurationValue['bootstrap'].servers.binding = this.lwm2mDeviceProfileTransportConfFormGroup.get('binding').value; - this.lwm2mDeviceProfileTransportConfFormGroup.get('binding').markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - } - - getObserveAttrTelemetryObjects(listObject: ObjectLwM2M[]): ObjectLwM2M [] { - let clientObserveAttr = deepClone(listObject) as ObjectLwM2M[]; - if (this.configurationValue[this.observeAttr]) { - let observeArray = this.configurationValue[this.observeAttr][this.observe] as Array; - let attributeArray = this.configurationValue[this.observeAttr][this.attribute] as Array; - let telemetryArray = this.configurationValue[this.observeAttr][this.telemetry] as Array; - let keyNameJson = this.configurationValue[this.observeAttr][this.keyName] as JsonObject; - if (this.includesInstancesNo(attributeArray, telemetryArray, clientObserveAttr)) { - this.addInstances(attributeArray, telemetryArray, clientObserveAttr); - } - if (observeArray) this.updateObserveAttrTelemetryObjects(observeArray, clientObserveAttr, "observe"); - if (attributeArray) this.updateObserveAttrTelemetryObjects(attributeArray, clientObserveAttr, "attribute"); - if (telemetryArray) this.updateObserveAttrTelemetryObjects(telemetryArray, clientObserveAttr, "telemetry"); - if (keyNameJson) this.updateKeyNameObjects(deepClone(keyNameJson), clientObserveAttr); - } - clientObserveAttr.forEach(obj => { - obj.instances.sort((a,b) => a.id - b.id);; - }) - return clientObserveAttr; - } - - includesInstancesNo(attributeArray: Array, telemetryArray: Array, clientObserveAttr: ObjectLwM2M[]): boolean { - let isIdIndex = (element) => !element.includes("/0/"); - return attributeArray.findIndex(isIdIndex) >= 0 || telemetryArray.findIndex(isIdIndex) >= 0 - - } - - addInstances(attributeArray: Array, telemetryArray: Array, clientObserveAttr: ObjectLwM2M[]): void { - let attr = [] as Array; - [...attributeArray].filter(x => (!x.includes("/0/"))).forEach(x => { - attr.push(this.convertPathToInstance(x)); - }); - let telemetry = [] as Array; - [...telemetryArray].filter(x => (!x.includes("/0/"))).forEach(x => { - telemetry.push(this.convertPathToInstance(x)); - }); - let instancesNoZero = new Set(attr.concat(telemetry).sort()); - instancesNoZero.forEach(path => { - let pathParameter = Array.from(path.split('/'), Number); - let objectLwM2M = clientObserveAttr.find(x => (x.id === pathParameter[0])); - if (objectLwM2M) { - let instance = deepClone(objectLwM2M.instances[0]) as Instance; - instance.id = pathParameter[1]; - objectLwM2M.instances.push(instance); - } - }) - } - - convertPathToInstance(path: string): string { - let newX = Array.from(path.substring(1).split('/'), Number); - return [newX[0], newX[1]].join("/"); - } - - updateObserveAttrTelemetryObjects(isParameter: Array, clientObserveAttr: ObjectLwM2M[], nameParameter: string): void { - isParameter.forEach(attr => { - let idKeys = Array.from(attr.substring(1).split('/'), Number); - clientObserveAttr - .forEach(e => { - if (e.id == idKeys[0]) { - let instance = e.instances.find(e => e.id == idKeys[1]); - if (isNotNullOrUndefined(instance)) { - instance.resources.find(e => e.id == idKeys[2])[nameParameter] = true; - } - } - }); - }); - } - - updateKeyNameObjects(nameJson: JsonObject, clientObserveAttr: ObjectLwM2M[]): void { - let keyName = JSON.parse(JSON.stringify(nameJson)); - Object.keys(keyName).forEach(function (key) { - let idKeys = Array.from(key.substring(1).split('/'), Number); - clientObserveAttr - .forEach(e => { - if (e.id == idKeys[0]) { - e.instances.find(e => e.id == idKeys[1]).resources - .find(e => e.id == idKeys[2]).keyName = keyName[key]; - } - }); - }); - } - - upDateObserveAttrTelemetryFromGroupToJson(val: ObjectLwM2M []): void { - let observeArray = [] as Array; - let attributeArray = [] as Array; - let telemetryArray = [] as Array; - let observeJson = JSON.parse(JSON.stringify(val)); - let pathObj; - let pathInst; - let pathRes - observeJson.forEach(obj => { - Object.entries(obj).forEach(([key, value]) => { - if (key === 'id') { - pathObj = value; - } - if (key === 'instances') { - let instancesJson = JSON.parse(JSON.stringify(value)) as []; - if (instancesJson.length > 0) { - instancesJson.forEach(instance => { - Object.entries(instance).forEach(([key, value]) => { - if (key === 'id') { - pathInst = value; - } - if (key === 'resources') { - let resourcesJson = JSON.parse(JSON.stringify(value)) as []; - if (resourcesJson.length > 0) { - resourcesJson.forEach(res => { - Object.entries(res).forEach(([key, value]) => { - if (key === 'id') { - // pathRes = value - pathRes = '/' + pathObj + '/' + pathInst + '/' + value; - } else if (key === 'observe' && value) { - observeArray.push(pathRes) - } else if (key === 'attribute' && value) { - attributeArray.push(pathRes) - } else if (key === 'telemetry' && value) { - telemetryArray.push(pathRes) - } - }); - }); - } - } - }); - }); - } - } - }); - }); - if (isUndefined(this.configurationValue[this.observeAttr])) { - this.configurationValue[this.observeAttr] = { - [this.observe]: observeArray, - [this.attribute]: attributeArray, - [this.telemetry]: telemetryArray - }; - } else { - this.configurationValue[this.observeAttr][this.observe] = observeArray; - this.configurationValue[this.observeAttr][this.attribute] = attributeArray; - this.configurationValue[this.observeAttr][this.telemetry] = telemetryArray; - } - this.updateKeyName(); - } - - sortObjectKeyPathJson(key, value) { - if (key == "keyName") { - return Object.keys(value).sort((a, b) => { - let aLC = Array.from(a.substring(1).split('/'), Number); - let bLC = Array.from(b.substring(1).split('/'), Number); - return aLC[0] == bLC[0] ? aLC[1] - bLC[1] : aLC[0] - bLC[0]; - }).reduce((r, k) => (r[k] = value[k], r), {}); - } else { - return value - } - } - - updateKeyName(): void { - let paths = new Set(); - if (this.configurationValue[this.observeAttr][this.attribute]) { - this.configurationValue[this.observeAttr][this.attribute].forEach(path => { - paths.add(path); - }); - } - if (this.configurationValue[this.observeAttr][this.telemetry]) { - this.configurationValue[this.observeAttr][this.telemetry].forEach(path => { - paths.add(path); - }); - } - let keyNameNew = {}; - paths.forEach(path => { - let pathParameter = this.findIndexsForIds(path); - if (pathParameter.length === 3) { - let value = this.lwm2mDeviceProfileTransportConfFormGroup.get("observeAttrTelemetry").value['clientLwM2M'][pathParameter[0]].instances[pathParameter[1]].resources[pathParameter[2]][this.keyName]; - keyNameNew[path] = value; - } - }); - this.configurationValue[this.observeAttr][this.keyName] = this.sortObjectKeyPathJson("keyName", keyNameNew); - } - - findIndexsForIds(path: string): number[] { - let pathParameter = Array.from(path.substring(1).split('/'), Number); - let pathParameterIndexes = [] as number[]; - let objectsOld = deepClone(this.lwm2mDeviceProfileTransportConfFormGroup.get("observeAttrTelemetry").value.clientLwM2M) as ObjectLwM2M[]; - let isIdIndex = (element) => element.id === pathParameter[0]; - let objIndex = objectsOld.findIndex(isIdIndex); - if (objIndex >= 0) { - pathParameterIndexes.push(objIndex); - isIdIndex = (element) => element.id === pathParameter[1]; - let instIndex = objectsOld[objIndex].instances.findIndex(isIdIndex); - if (instIndex >= 0) { - pathParameterIndexes.push(instIndex); - isIdIndex = (element) => element.id === pathParameter[2]; - let resIndex = objectsOld[objIndex].instances[instIndex].resources.findIndex(isIdIndex); - if (resIndex >= 0) { - pathParameterIndexes.push(resIndex); - } - } - } - return pathParameterIndexes; - } - - getObjectsFromJsonAllConfig(): number [] { - let objectsIds = new Set(); - if (this.configurationValue[this.observeAttr]) { - if (this.configurationValue[this.observeAttr][this.observe]) { - this.configurationValue[this.observeAttr][this.observe].forEach(obj => { - objectsIds.add(Array.from(obj.substring(1).split('/'), Number)[0]); - }); - } - if (this.configurationValue[this.observeAttr][this.attribute]) { - this.configurationValue[this.observeAttr][this.attribute].forEach(obj => { - objectsIds.add(Array.from(obj.substring(1).split('/'), Number)[0]); - }); - } - if (this.configurationValue[this.observeAttr][this.telemetry]) { - this.configurationValue[this.observeAttr][this.telemetry].forEach(obj => { - objectsIds.add(Array.from(obj.substring(1).split('/'), Number)[0]); - }); - } - } - return (objectsIds.size > 0) ? Array.from(objectsIds) : null; - } - - upDateJsonAllConfig(): void { - this.lwm2mDeviceProfileTransportConfFormGroup.patchValue({ - configurationJson: this.configurationValue - }, {emitEvent: false}); - this.lwm2mDeviceProfileTransportConfFormGroup.markAsPristine({ - onlySelf: true - }); - } - - addObjectsList(value: ObjectLwM2M[]): void { - this.updateObserveAttrTelemetryObjectFormGroup(deepClone(value)); - } - - removeObjectsList(value: ObjectLwM2M): void { - let objectsOld = deepClone(this.lwm2mDeviceProfileTransportConfFormGroup.get("observeAttrTelemetry").value.clientLwM2M); - const isIdIndex = (element) => element.id === value.id; - let index = objectsOld.findIndex(isIdIndex); - if (index >= 0) { - objectsOld.splice(index, 1); - } - this.updateObserveAttrTelemetryObjectFormGroup(objectsOld); - this.removeObserveAttrTelemetryFromJson(this.observe, value.id); - this.removeObserveAttrTelemetryFromJson(this.telemetry, value.id); - this.removeObserveAttrTelemetryFromJson(this.attribute, value.id); - this.removeObserveAttrTelemetryFromJson(this.attribute, value.id); - this.removeKeyNameFromJson(value.id); - this.upDateJsonAllConfig(); - } - - removeObserveAttrTelemetryFromJson(observeAttrTel: string, id: number): void { - let isIdIndex = (element) => Array.from(element.substring(1).split('/'), Number)[0] === id; - let index = this.configurationValue[this.observeAttr][observeAttrTel].findIndex(isIdIndex); - while (index >= 0) { - this.configurationValue[this.observeAttr][observeAttrTel].splice(index, 1); - index = this.configurationValue[this.observeAttr][observeAttrTel].findIndex(isIdIndex); - } - } - - removeKeyNameFromJson(id: number): void { - let keyNmaeJson = this.configurationValue[this.observeAttr][this.keyName]; - Object.keys(keyNmaeJson).forEach(function (key) { - let idKey = Array.from(key.substring(1).split('/'), Number)[0]; - if (idKey === id) { - delete keyNmaeJson[key]; - } - }); - } - - isPathInJson(path: string): boolean { - let isPath = this.findPathInJson(path, this.attribute); - if (!isPath) { - isPath = this.findPathInJson(path, this.telemetry); - } - return (isPath) ? true : false; - } - - findPathInJson(path: string, side: string): string { - if (this.configurationValue[this.observeAttr]) { - if (this.configurationValue[this.observeAttr][side]) { - return this.configurationValue[this.observeAttr][side].find( - pathJs => pathJs === path); - } - } - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.html b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.html deleted file mode 100644 index cddc6f1ef5..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.html +++ /dev/null @@ -1,57 +0,0 @@ - - - {{ 'device-profile.lwm2m.instances-list' | translate }} - - - {{instanceIdInputFor}} - close - - - {{ 'device-profile.lwm2m.instances-input' | translate }} - - - {{ translate.get('device-profile.lwm2m.valid-id-instance-no-min', { - instance: instanceIdInput.value.toString(), min: instanceIdValueMin.toString() - }) | async }} - - - {{ translate.get('device-profile.lwm2m.valid-id-instance-no-max', { - instance: instanceIdInput.value.toString(), max: instanceIdValueMax.toString() - }) | async }} - - - {{ translate.get('device-profile.lwm2m.instances-input-holder', { - instance: instanceIdInput.value.toString(), max: instanceIdValueMax.toString() - }) | async }} - - - - - diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.scss b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.scss deleted file mode 100644 index 45e601db09..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.scss +++ /dev/null @@ -1,22 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -:host ::ng-deep { - mat-form-field.lwm2m-instances-list { - & > .mat-form-field-wrapper > .mat-form-field-underline { - display: none; - } - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.ts deleted file mode 100644 index 20a72d8dcd..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances-list.component.ts +++ /dev/null @@ -1,179 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { - Component, - forwardRef, - Input, - OnInit, - ViewChild, - ElementRef, -} from "@angular/core"; -import { - ControlValueAccessor, - FormBuilder, - FormGroup, NG_VALIDATORS, - NG_VALUE_ACCESSOR, Validators -} from "@angular/forms"; -import { coerceBooleanProperty } from "@angular/cdk/coercion"; -import { Store } from "@ngrx/store"; -import { AppState } from "../../../../../../core/core.state"; -import { MatChipList } from '@angular/material/chips'; -import { - INSTANCES_ID_VALUE_MAX, - INSTANCES_ID_VALUE_MIN -} from "./profile-config.models"; -import { TranslateService } from "@ngx-translate/core"; -import { DeviceProfileService } from "../../../../../../core/http/device-profile.service"; - -@Component({ - selector: 'tb-profile-lwm2m-object-add-instances-list', - templateUrl: './lwm2m-object-add-instances-list.component.html', - styleUrls: ['./lwm2m-object-add-instances-list.component.scss'], - providers: [{ - provide: NG_VALUE_ACCESSOR, - useExisting: forwardRef(() => Lwm2mObjectAddInstancesListComponent), - multi: true - }] -}) -export class Lwm2mObjectAddInstancesListComponent implements ControlValueAccessor, OnInit, Validators { - - lwm2mObjectListFormGroup: FormGroup; - private requiredValue: boolean; - private instancesIdsList: Set | null; - filteredObjectsList: Array; - private disabled = false as boolean; - private dirty = false as boolean; - instanceIdValueMin = INSTANCES_ID_VALUE_MIN as number - instanceIdValueMax = INSTANCES_ID_VALUE_MAX as number - - get required(): boolean { - return this.requiredValue; - } - - @Input() - set required(value: boolean) { - const newVal = coerceBooleanProperty(value); - if (this.requiredValue !== newVal) { - this.requiredValue = newVal; - this.updateValidators(); - } - } - - @ViewChild('instanceIdInput') instanceIdInput: ElementRef; - @ViewChild('chipList', {static: true}) chipList: MatChipList; - - private propagateChange = (v: any) => { - }; - - constructor(private store: Store, - public translate: TranslateService, - private deviceProfileService: DeviceProfileService, - private fb: FormBuilder) { - this.lwm2mObjectListFormGroup = this.fb.group({ - instancesIdsList: [null], - instanceIdInput: [null] - }); - } - - updateValidators() { - this.lwm2mObjectListFormGroup.get('instanceIdInput').setValidators([ - Validators.min(this.instanceIdValueMin), - Validators.max(this.instanceIdValueMax)]); - this.lwm2mObjectListFormGroup.get('instanceIdInput').updateValueAndValidity(); - } - - registerOnChange(fn: any): void { - this.propagateChange = fn; - } - - registerOnTouched(fn: any): void { - } - - ngOnInit() { - } - - ngAfterViewInit(): void { - } - - setDisabledState(isDisabled: boolean): void { - this.disabled = isDisabled; - if (isDisabled) { - this.lwm2mObjectListFormGroup.disable({emitEvent: false}); - } else { - this.lwm2mObjectListFormGroup.enable({emitEvent: false}); - } - } - - writeValue(value: Set): void { - this.instancesIdsList = new Set(); - if (value && value.size) { - value.forEach(item => this.instancesIdsList.add(item)); - this.lwm2mObjectListFormGroup.get('instancesIdsList').setValue(this.instancesIdsList); - } - this.updateValidators(); - this.dirty = false; - } - - add(value: number): void { - if (!isNaN(value) && this.lwm2mObjectListFormGroup.get('instanceIdInput').valid) { - this.instancesIdsList.add(value); - this.lwm2mObjectListFormGroup.get('instancesIdsList').setValue(this.instancesIdsList); - this.propagateChange(this.instancesIdsList); - this.dirty = true - } - this.clear(); - } - - remove(object: number) { - this.instancesIdsList.delete(object); - this.lwm2mObjectListFormGroup.get('instancesIdsList').setValue(this.instancesIdsList); - this.propagateChange(this.instancesIdsList); - this.dirty = true - this.clear(); - } - - displayFn(object?: number): number | undefined { - return object ? object : undefined; - } - - clear() { - this.lwm2mObjectListFormGroup.get('instanceIdInput').patchValue(null, {emitEvent: true}); - this.instanceIdInput.nativeElement.value = ""; - setTimeout(() => { - this.instanceIdInput.nativeElement.blur(); - this.instanceIdInput.nativeElement.focus(); - }, 0); - } - - onkeydown(e: KeyboardEvent) { - if (e.keyCode == 189 || e.keyCode == 187 || e.keyCode == 109 || e.keyCode == 107) { - return false; - } else if (e.keyCode == 8) { - if (this.lwm2mObjectListFormGroup.get('instanceIdInput').value == null) { - this.clear(); - } - this.instanceIdInput.nativeElement.focus(); - } - } - - onFocus() { - if (this.dirty) { - this.lwm2mObjectListFormGroup.get('instanceIdInput').updateValueAndValidity({onlySelf: true, emitEvent: true}); - this.dirty = false; - } - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.html b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.html deleted file mode 100644 index b8d10689e1..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.html +++ /dev/null @@ -1,54 +0,0 @@ - -
- - {{data.objectName}}    (object [{{data.objectId}}]) - - - - - -
-
-
-
- - -
-
-
-
- - - -
-
diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.ts deleted file mode 100644 index 62f516b660..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-add-instances.component.ts +++ /dev/null @@ -1,67 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { Component, Inject, OnInit } from '@angular/core'; -import { DialogComponent } from '@shared/components/dialog.component'; -import { ControlValueAccessor, FormBuilder, FormGroup } from '@angular/forms'; -import { Store } from '@ngrx/store'; -import { AppState } from '@core/core.state'; -import { Router } from '@angular/router'; -import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog'; -import { TranslateService } from '@ngx-translate/core'; - -export interface Lwm2mObjectAddInstancesData { - instancesIds: Set; - objectName?: string; - objectId?: number; -} - -@Component({ - selector: 'tb-lwm2m-object-add-instances', - templateUrl: './lwm2m-object-add-instances.component.html', - styleUrls: [] -}) -export class Lwm2mObjectAddInstancesComponent extends DialogComponent implements OnInit { - - jsonFormGroup: FormGroup; - // title: string; - - submitted = false; - - constructor(protected store: Store, - protected router: Router, - @Inject(MAT_DIALOG_DATA) public data: Lwm2mObjectAddInstancesData, - public dialogRef: MatDialogRef, - public fb: FormBuilder) { - super(store, router, dialogRef); - } - - - ngOnInit(): void { - this.jsonFormGroup = this.fb.group({ - instancesIds: this.data.instancesIds - }) - } - - cancel(): void { - this.dialogRef.close(undefined); - } - - add(): void { - this.data.instancesIds = this.jsonFormGroup.get('instancesIds').value - this.dialogRef.close(this.data); - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.html b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.html deleted file mode 100644 index 7ad661752b..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.html +++ /dev/null @@ -1,56 +0,0 @@ - - - - - - {{objectLwm2m.name}} - close - - - - - - - - - - {{ translate.get('device-profile.lwm2m.no-objects-matching', {object: searchText}) | async }} - - - - - {{ 'device-profile.lwm2m.object-list-empty' | translate }} - - - diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.ts deleted file mode 100644 index b0f9ea4ebf..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-object-list.component.ts +++ /dev/null @@ -1,234 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { - Component, - forwardRef, - Input, - OnInit, - ViewChild, - ElementRef, - Output, - EventEmitter -} from "@angular/core"; -import { - ControlValueAccessor, - FormBuilder, - FormGroup, - NG_VALUE_ACCESSOR, Validators -} from "@angular/forms"; -import {coerceBooleanProperty} from "@angular/cdk/coercion"; -import {Store} from "@ngrx/store"; -import {AppState} from "../../../../../../core/core.state"; -import {MatChipList} from '@angular/material/chips'; -import {MatAutocomplete} from "@angular/material/autocomplete"; -import {Observable} from "rxjs"; -import {filter, map, mergeMap, share, tap} from 'rxjs/operators'; -import {ObjectLwM2M} from "./profile-config.models"; -import {TranslateService} from "@ngx-translate/core"; -import {DeviceProfileService} from "../../../../../../core/http/device-profile.service"; -import {PageLink} from "../../../../../../shared/models/page/page-link"; -import {Direction} from "../../../../../../shared/models/page/sort-order"; - -@Component({ - selector: 'tb-profile-lwm2m-object-list', - templateUrl: './lwm2m-object-list.component.html', - styleUrls: [], - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: forwardRef(() => Lwm2mObjectListComponent), - multi: true - }] -}) -export class Lwm2mObjectListComponent implements ControlValueAccessor, OnInit, Validators { - - lwm2mObjectListFormGroup: FormGroup; - private requiredValue: boolean; - modelValue: Array | null; - objectsList: Array = []; - filteredObjectsList: Observable>; - private disabled = false as boolean; - searchText = '' as string; - private dirty = false as boolean; - - get required(): boolean { - return this.requiredValue; - } - - @Input() - set required(value: boolean) { - const newVal = coerceBooleanProperty(value); - if (this.requiredValue !== newVal) { - this.requiredValue = newVal; - this.updateValidators(); - } - } - - @Output() - addList = new EventEmitter(); - - @Output() - removeList = new EventEmitter(); - - @ViewChild('objectInput') objectInput: ElementRef; - @ViewChild('objectAutocomplete') matAutocomplete: MatAutocomplete; - @ViewChild('chipList', {static: true}) chipList: MatChipList; - - private propagateChange = (v: any) => { - }; - - constructor(private store: Store, - public translate: TranslateService, - private deviceProfileService: DeviceProfileService, - private fb: FormBuilder) { - this.lwm2mObjectListFormGroup = this.fb.group({ - objectsList: [this.objectsList], - objectLwm2m: [null, this.required ? [Validators.required] : []] - }); - } - - updateValidators() { - this.lwm2mObjectListFormGroup.get('objectLwm2m').setValidators(this.required ? [Validators.required] : []); - this.lwm2mObjectListFormGroup.get('objectLwm2m').updateValueAndValidity(); - } - - registerOnChange(fn: any): void { - this.propagateChange = fn; - } - - registerOnTouched(fn: any): void { - } - - ngOnInit() { - this.filteredObjectsList = this.lwm2mObjectListFormGroup.get('objectLwm2m').valueChanges - .pipe( - tap((value) => { - if (value && typeof value !== 'string') { - this.add(value); - } else if (value === null) { - this.clear(this.objectInput.nativeElement.value); - } - }), - filter((value) => typeof value === 'string'), - map((value) => value ? (typeof value === 'string' ? value : value.name) : ''), - mergeMap(name => this.fetchListObjects(name)), - share() - ); - } - - ngAfterViewInit(): void { - } - - setDisabledState(isDisabled: boolean): void { - this.disabled = isDisabled; - if (isDisabled) { - this.lwm2mObjectListFormGroup.disable({emitEvent: false}); - } else { - this.lwm2mObjectListFormGroup.enable({emitEvent: false}); - } - } - - writeValue(value: any): void { - this.searchText = ''; - if (value.hasOwnProperty("objectIds") && value["objectIds"] != null && value["objectIds"].length > 0) { - this.modelValue = [...value["objectIds"]]; - this.objectsList = value["objectsList"]; - this.lwm2mObjectListFormGroup.get('objectsList').setValue(this.objectsList); - } else { - this.objectsList = []; - this.lwm2mObjectListFormGroup.get('objectsList').setValue(this.objectsList); - this.modelValue = null; - } - this.dirty = true; - } - - reset() { - this.objectsList = []; - this.lwm2mObjectListFormGroup.get('objectsList').setValue(this.objectsList); - this.modelValue = null; - if (this.objectInput) { - this.objectInput.nativeElement.value = ''; - } - this.lwm2mObjectListFormGroup.get('objectLwm2m').patchValue('', {emitEvent: false}); - this.propagateChange(this.modelValue); - this.dirty = true; - } - - add(object: ObjectLwM2M): void { - if (!this.modelValue || this.modelValue.indexOf(object.id) === -1) { - if (!this.modelValue) { - this.modelValue = []; - } - this.modelValue.push(object.id); - this.objectsList.push(object); - this.lwm2mObjectListFormGroup.get('objectsList').setValue(this.objectsList); - this.addList.next(this.objectsList); - } - this.propagateChange(this.modelValue); - this.clear(); - } - - remove(object: ObjectLwM2M) { - let index = this.objectsList.indexOf(object); - if (index >= 0) { - this.objectsList.splice(index, 1); - this.lwm2mObjectListFormGroup.get('objectsList').setValue(this.objectsList); - index = this.modelValue.indexOf(object.id); - this.modelValue.splice(index, 1); - this.removeList.next(object); - if (!this.modelValue.length) { - this.modelValue = null; - } - this.propagateChange(this.modelValue); - this.clear(); - } - } - - displayObjectLwm2mFn(object?: ObjectLwM2M): string | undefined { - return object ? object.name : undefined; - } - - fetchListObjects(searchText?: string): Observable> { - this.searchText = searchText; - const pageLink = new PageLink(10, 0, searchText, { - property: 'name', - direction: Direction.ASC - }); - return this.deviceProfileService.getLwm2mObjectsPage(pageLink, {ignoreLoading: true}).pipe( - map(pageData => { - let data = pageData.data; - return data; - }) - ); - } - - onFocus() { - if (this.dirty) { - this.lwm2mObjectListFormGroup.get('objectLwm2m').updateValueAndValidity({onlySelf: true, emitEvent: true}); - this.dirty = false; - } - } - - clear(value: string = '') { - this.objectInput.nativeElement.value = value; - this.lwm2mObjectListFormGroup.get('objectLwm2m').patchValue(value, {emitEvent: true}); - setTimeout(() => { - this.objectInput.nativeElement.blur(); - this.objectInput.nativeElement.focus(); - }, 0); - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.html b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.html deleted file mode 100644 index 322fba8086..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.html +++ /dev/null @@ -1,86 +0,0 @@ - -
-
-
-
-
- -
-
- - device-profile.lwm2m.observe-label - -
-
- - device-profile.lwm2m.attribute-label - -
-
- - device-profile.lwm2m.telemetry-label - -
-
- - device-profile.lwm2m.key-name-label - -
-
-
-
- Resource[{{resourceLwM2M.get('id').value}}] - name:{{resourceLwM2M.get('name').value}} -
-
- - -
-
- - -
-
- - -
- - - {{ 'device-profile.lwm2m.key-name_label' | translate }} - - - - {{ 'device-profile.lwm2m.key-name' | translate }} - {{ 'device-profile.lwm2m.required' | translate }} - - -
-
-
-
diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.ts deleted file mode 100644 index f94cd589ae..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry-resource.component.ts +++ /dev/null @@ -1,156 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { Component, EventEmitter, forwardRef, Input, OnInit, Output, ViewChild } from "@angular/core"; -import { - ControlValueAccessor, - FormArray, FormBuilder, - FormGroup, - NG_VALUE_ACCESSOR, Validators -} from "@angular/forms"; -import { - CAMEL_CASE_REGEXP, - ResourceLwM2M -} from '@home/components/profile/device/lwm2m/profile-config.models'; -import { Store } from '@ngrx/store'; -import { AppState } from '@core/core.state'; -import { deepClone, isUndefined } from '@core/utils'; -import { coerceBooleanProperty } from '@angular/cdk/coercion'; - -@Component({ - selector: 'tb-profile-lwm2m-observe-attr-telemetry-resource', - templateUrl: './lwm2m-observe-attr-telemetry-resource.component.html', - styleUrls: [], - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: forwardRef(() => Lwm2mObserveAttrTelemetryResourceComponent), - multi: true - } - ] -}) - -export class Lwm2mObserveAttrTelemetryResourceComponent implements ControlValueAccessor, OnInit, Validators { - - resourceFormGroup : FormGroup; - - disabled = false as boolean; - private requiredValue: boolean; - - get required(): boolean { - return this.requiredValue; - } - - @Input() - set required(value: boolean) { - const newVal = coerceBooleanProperty(value); - if (this.requiredValue !== newVal) { - this.requiredValue = newVal; - } - } - constructor(private store: Store, - private fb: FormBuilder) { - this.resourceFormGroup = this.fb.group({'resources': this.fb.array([])}); - this.resourceFormGroup.valueChanges.subscribe(value => { - if (!this.disabled) { - this.propagateChangeState(value.resources); - } - }); - } - - ngOnInit(): void { - } - - registerOnTouched(fn: any): void { - } - - writeValue(value: ResourceLwM2M[]): void { - this.createResourceLwM2M(value); - } - - get resourceFormArray(): FormArray{ - return this.resourceFormGroup.get('resources') as FormArray; - } - - resourceLwm2mFormArray(instance: FormGroup): FormArray { - return instance.get('resources') as FormArray; - } - - setDisabledState(isDisabled: boolean): void { - this.disabled = isDisabled; - if (isDisabled) { - this.resourceFormGroup.disable(); - } else { - this.resourceFormGroup.enable(); - } - } - - getDisabledState(): boolean { - return this.disabled; - } - - updateValueKeyName (event: any, z: number): void { - this.resourceFormArray.at(z).patchValue( {keyName: this.keysToCamel(deepClone(event.target.value))} ); - } - - keysToCamel(o: any): string { - let val = o.split(" "); - let playStore = []; - val.forEach(function (item, k){ - item = item.replace(CAMEL_CASE_REGEXP, ''); - item = (k===0)? item.charAt(0).toLowerCase() + item.substr(1) : item.charAt(0).toUpperCase() + item.substr(1) - playStore.push(item); - }); - return playStore.join(''); - } - - createResourceLwM2M(resourcesLwM2MJson: ResourceLwM2M []): void { - if(resourcesLwM2MJson.length === this.resourceFormArray.length) { - this.resourceFormArray.patchValue(resourcesLwM2MJson, {emitEvent: false}) - } else { - this.resourceFormArray.clear(); - resourcesLwM2MJson.forEach(resourceLwM2M => { - this.resourceFormArray.push(this.fb.group({ - id: resourceLwM2M.id, - name: resourceLwM2M.name, - observe: resourceLwM2M.observe, - attribute: resourceLwM2M.attribute, - telemetry: resourceLwM2M.telemetry, - keyName: [resourceLwM2M.keyName, Validators.required] - })); - }) - } - } - - private propagateChange = (v: any) => { - }; - - registerOnChange(fn: any): void { - this.propagateChange = fn; - } - - private propagateChangeState(value: any): void { - if (value && this.resourceFormGroup.valid) { - this.propagateChange(value); - } else { - this.propagateChange(null); - } - } - - trackByParams(index: number): number { - return index; - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.css b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.css deleted file mode 100644 index 9d2aa31a2c..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.css +++ /dev/null @@ -1,49 +0,0 @@ -/** - * Copyright © 2016-2020 The Thingsboard Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -.vertical-padding { - padding: 0 0 10px 20px; -} - -.left-padding { - padding-left: 5px; -} - -.tb-panel-title-height { - user-select: none; - min-height: 32px; -} - -.checkbox-padding { - padding-left: 22px; -} - -.label-resource { - /*padding: 4px;*/ - color: #002699; - /*text-transform: uppercase;*/ - background: rgba(220, 220, 220, .35); - border-radius: 20px; - width: inherit; - /*margin: 10px 0;*/ - overflow: hidden; - font-size: 15px; - text-overflow: ellipsis; - white-space: nowrap; - opacity: .8; - text-align:center; -} - diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.html b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.html deleted file mode 100644 index ea3233f769..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.html +++ /dev/null @@ -1,102 +0,0 @@ - - -
- - - - -
{{ objectLwM2M.get('name').value}} (object [{{ objectLwM2M.get('id').value}}])
- -
-
-
- - - - -
-
-
- Instance [{{instances.get('id').value}}] -
-
- - -
-
- - -
-
- - -
-
-
-
-
-
-
- - - - -
-
-
-
-
-
diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.ts deleted file mode 100644 index 8482fde97a..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-observe-attr-telemetry.component.ts +++ /dev/null @@ -1,352 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - - -import { Component, forwardRef, Input, OnInit, Output } from "@angular/core"; -import { - AbstractControl, - ControlValueAccessor, - FormArray, - FormBuilder, - FormGroup, - NG_VALUE_ACCESSOR, - Validators -} from "@angular/forms"; -import { Store } from "@ngrx/store"; -import { AppState } from "@core/core.state"; -import { coerceBooleanProperty } from "@angular/cdk/coercion"; -import { - ATTR, - Instance, - ObjectLwM2M, - OBSERVE, - ResourceLwM2M, - TELEMETRY -} from "./profile-config.models"; -import { isNotNullOrUndefined } from 'codelyzer/util/isNotNullOrUndefined'; -import { deepClone, isUndefined } from '@core/utils'; -import { MatDialog } from '@angular/material/dialog'; -import { TranslateService } from '@ngx-translate/core'; -import { - Lwm2mObjectAddInstancesComponent, - Lwm2mObjectAddInstancesData -} from '@home/components/profile/device/lwm2m/lwm2m-object-add-instances.component'; -import { Control } from 'leaflet'; - -@Component({ - selector: 'tb-profile-lwm2m-observe-attr-telemetry', - templateUrl: './lwm2m-observe-attr-telemetry.component.html', - styleUrls: ['./lwm2m-observe-attr-telemetry.component.css'], - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: forwardRef(() => Lwm2mObserveAttrTelemetryComponent), - multi: true - } - ] -}) - -export class Lwm2mObserveAttrTelemetryComponent implements ControlValueAccessor, OnInit, Validators { - - valuePrev = null as any; - observeAttrTelemetryFormGroup: FormGroup; - observe = OBSERVE as string; - attribute = ATTR as string; - telemetry = TELEMETRY as string; - private requiredValue: boolean; - - get required(): boolean { - return this.requiredValue; - } - - @Input() - disabled: boolean; - - @Input() - set required(value: boolean) { - const newVal = coerceBooleanProperty(value); - if (this.requiredValue !== newVal) { - this.requiredValue = newVal; - this.updateValidators(); - } - } - - constructor(private store: Store, - private fb: FormBuilder, - private dialog: MatDialog, - private translate: TranslateService) { - this.observeAttrTelemetryFormGroup = this.fb.group({ - clientLwM2M: this.fb.array([]) - }); - this.observeAttrTelemetryFormGroup.valueChanges.subscribe(value => { - if (isUndefined(this.disabled) || !this.disabled) { - this.propagateChangeState(value); - } - }); - } - - ngOnInit(): void { - } - - private propagateChange = (v: any) => { - }; - - - registerOnChange(fn: any): void { - this.propagateChange = fn; - } - - private propagateChangeState(value: any): void { - if (value) { - if (this.valuePrev === null) { - this.valuePrev = "init"; - } else if (this.valuePrev === "init") { - this.valuePrev = value; - } else if (JSON.stringify(value) !== JSON.stringify(this.valuePrev)) { - this.valuePrev = value; - if (this.observeAttrTelemetryFormGroup.valid) { - this.propagateChange(value); - } else { - this.propagateChange(null); - } - } - } - } - - registerOnTouched(fn: any): void { - } - - setDisabledState(isDisabled: boolean): void { - this.disabled = isDisabled; - this.valuePrev = null; - if (isDisabled) { - this.observeAttrTelemetryFormGroup.disable(); - } else { - this.observeAttrTelemetryFormGroup.enable(); - } - } - - getDisabledState(): boolean { - return this.disabled; - } - - writeValue(value: any): void { - this.buildClientObjectsLwM2M(value.clientLwM2M); - } - - private buildClientObjectsLwM2M(objectsLwM2M: ObjectLwM2M []): void { - this.observeAttrTelemetryFormGroup.setControl('clientLwM2M', - this.createObjectsLwM2M(objectsLwM2M) - ); - } - - createObjectsLwM2M(objectsLwM2MJson: ObjectLwM2M []): FormArray { - return this.fb.array(objectsLwM2MJson.map((objectLwM2M) => { - return this.fb.group({ - id: objectLwM2M.id, - name: objectLwM2M.name, - multiple: objectLwM2M.multiple, - mandatory: objectLwM2M.mandatory, - instances: this.createInstanceLwM2M(objectLwM2M.instances) - }) - })) - } - - createInstanceLwM2M(instanceLwM2MJson: Instance []): FormArray { - return this.fb.array(instanceLwM2MJson.map((instanceLwM2M, index) => { - return this.fb.group({ - id: instanceLwM2M.id, - [this.observe]: {value: false, disabled: this.disabled}, - [this.attribute]: {value: false, disabled: this.disabled}, - [this.telemetry]: {value: false, disabled: this.disabled}, - resources: {value: instanceLwM2M.resources, disabled: this.disabled} - }) - })) - } - - clientLwM2MFormArray(formGroup: FormGroup): FormArray { - return formGroup.get('clientLwM2M') as FormArray; - } - - instancesLwm2mFormArray(objectLwM2M: AbstractControl): FormArray { - return objectLwM2M.get('instances') as FormArray; - } - - changeInstanceResourcesCheckBox(value: boolean, instance: AbstractControl, type: string): void { - let resources = instance.get('resources').value as ResourceLwM2M [] - resources.forEach(resource => resource[type] = value); - instance.get('resources').patchValue(resources); - this.propagateChange(this.observeAttrTelemetryFormGroup.value); - } - - updateValidators() { - this.observeAttrTelemetryFormGroup.get('clientLwM2M').setValidators(this.required ? [Validators.required] : []); - this.observeAttrTelemetryFormGroup.get('clientLwM2M').updateValueAndValidity(); - } - - trackByParams(index: number): number { - return index; - } - - getIndeterminate(instance: AbstractControl, type: string) { - const resources = instance.get('resources').value as ResourceLwM2M []; - if (isNotNullOrUndefined(resources)) { - const isType = (element) => element[type] === true; - let checkedResource = resources.filter(isType); - if (checkedResource.length === 0) return false; - else if (checkedResource.length === resources.length) { - instance.patchValue({[type]: true}); - return false; - } else return true; - } - return false; - } - - - getChecked(instance: AbstractControl, type: string) { - const resources = instance.get('resources').value as ResourceLwM2M []; - if (isNotNullOrUndefined(resources)) { - return resources.some(resource => resource[type]); - } - return false; - } - - getExpended(objectLwM2M: AbstractControl) { - return this.instancesLwm2mFormArray(objectLwM2M).length === 1; - } - - /** - * Instances: indicates whether this Object supports multiple Object Instances or not. - * 1) Field in object: == Multiple/Single - * 2) Field in object: == Mandatory/Optional - * If this field is “Multiple” then the number of Object Instance can be from 0 to many (Object Instance ID MAX_ID=65535). - * If this field is “Single” then the number of Object Instance can be from 0 to 1. (max count == 1) - * If the Object field “Mandatory” is “Mandatory” and the Object field “Instances” is “Single” then, the number of Object Instance MUST be 1. - * 1. == Multiple (true), == Optional (false) => Object Instance ID MIN_ID=0 MAX_ID=65535 (может ни одного не быть) - * 2. == Multiple (true), == Mandatory (true) => Object Instance ID MIN_ID=0 MAX_ID=65535 (min один обязательный) - * 3. == Single (false), == Optional (false) => Object Instance ID cnt_max = 1 cnt_min = 0 (может ни одного не быть) - * 4. == Single (false), == Mandatory (true) => Object Instance ID cnt_max = cnt_min = 1 (всегда есть один) - * @param $event - * @param objectId - * @param objectName - */ - - addInstances($event: Event, object: ObjectLwM2M): void { - if ($event) { - $event.stopPropagation(); - $event.preventDefault(); - } - let instancesIds = new Set(); - object.instances.forEach(inst => { - instancesIds.add(inst.id); - }); - this.dialog.open(Lwm2mObjectAddInstancesComponent, { - disableClose: true, - panelClass: ['tb-dialog', 'tb-fullscreen-dialog'], - data: { - instancesIds: this.setInstancesIds(object.instances), - objectName: object.name, - objectId: object.id - } - }).afterClosed().subscribe( - (res: Lwm2mObjectAddInstancesData | undefined) => { - if (isNotNullOrUndefined(res)) { - this.updateInstancesIds(res); - } - } - ); - } - - updateInstancesIds(data: Lwm2mObjectAddInstancesData) { - let valueNew = new Set(); - let valueOld = new Set(); - data.instancesIds.forEach(value => { - valueNew.add(value); - }) - let oldInstances = (this.observeAttrTelemetryFormGroup.get('clientLwM2M').value as ObjectLwM2M []).find(e => e.id == data.objectId).instances; - oldInstances.forEach(inst => { - valueOld.add(inst.id); - }); - if (JSON.stringify(Array.from(valueOld)) != JSON.stringify(Array.from(valueNew))) { - let idsDel = this.diffBetweenSet(valueNew, this.deepCloneSet(valueOld)); - let idsAdd = this.diffBetweenSet(valueOld, this.deepCloneSet(valueNew)); - if (idsAdd.size) { - this.addInstancesNew(data.objectId, idsAdd) - } - if (idsDel.size) { - this.delInstances(data.objectId, idsDel); - } - } - } - - delInstances(objectId: number, idsDel: Set): void { - let isIdIndex = (element) => element.id == objectId; - let objectIndex = (this.observeAttrTelemetryFormGroup.get('clientLwM2M').value as ObjectLwM2M []).findIndex(isIdIndex); - idsDel.forEach(x => { - isIdIndex = (element) => element.value.id == x; - let instancesFormArray = ((this.observeAttrTelemetryFormGroup.get('clientLwM2M') as FormArray).controls[objectIndex].get("instances") as FormArray); - let instanceIndex = instancesFormArray.controls.findIndex(isIdIndex); - instancesFormArray.removeAt(instanceIndex); - }) - } - - addInstancesNew(objectId: number, idsAdd: Set): void { - let instancesValue = (this.observeAttrTelemetryFormGroup.get('clientLwM2M').value as ObjectLwM2M []).find(e => e.id == objectId).instances; - let instancesFormArray = ((this.observeAttrTelemetryFormGroup.get('clientLwM2M') as FormArray).controls.find(e => e.value.id == objectId).get("instances") as FormArray) as FormArray; - idsAdd.forEach(x => { - let instanceNew = deepClone(instancesValue[0]) as Instance; - instanceNew.id = x; - instanceNew.resources.forEach(r => { - r.attribute = false; - r.telemetry = false; - r.observe = false; - }); - instancesFormArray.push(this.fb.group({ - id: x, - [this.observe]: {value: false, disabled: this.disabled}, - [this.attribute]: {value: false, disabled: this.disabled}, - [this.telemetry]: {value: false, disabled: this.disabled}, - resources: {value: instanceNew.resources, disabled: this.disabled} - })); - }); - (instancesFormArray.controls as FormGroup[]).sort((a,b) => a.value.id - b.value.id); - } - - deepCloneSet(oldSet: Set): Set { - let newSet = new Set(); - oldSet.forEach(p => { - newSet.add(p); - }) - return newSet; - } - - diffBetweenSet(firstSet: Set, secondSet: Set): Set { - firstSet.forEach(p => { - secondSet.delete(p); - }) - return secondSet - } - - setInstancesIds(instances: Instance []): Set { - let instancesIds = new Set(); - if (instances && instances.length) { - instances.forEach(inst => { - instancesIds.add(inst.id); - }); - } - return instancesIds; - } -} diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-profile-components.module.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-profile-components.module.ts deleted file mode 100644 index 1f829aee19..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-profile-components.module.ts +++ /dev/null @@ -1,55 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { NgModule } from '@angular/core'; -import { Lwm2mDeviceProfileTransportConfigurationComponent } from './lwm2m-device-profile-transport-configuration.component'; -import { Lwm2mObjectListComponent } from './lwm2m-object-list.component'; -import { Lwm2mObserveAttrTelemetryComponent } from './lwm2m-observe-attr-telemetry.component'; -import { Lwm2mObserveAttrTelemetryResourceComponent } from './lwm2m-observe-attr-telemetry-resource.component'; -import { Lwm2mDeviceConfigServerComponent } from './lwm2m-device-config-server.component'; -import { Lwm2mObjectAddInstancesComponent } from './lwm2m-object-add-instances.component'; -import { Lwm2mObjectAddInstancesListComponent } from './lwm2m-object-add-instances-list.component'; -import { CommonModule } from '@angular/common'; -import { SharedModule } from '@app/shared/shared.module'; - -@NgModule({ - declarations: - [ - Lwm2mDeviceProfileTransportConfigurationComponent, - Lwm2mObjectListComponent, - Lwm2mObserveAttrTelemetryComponent, - Lwm2mObserveAttrTelemetryResourceComponent, - Lwm2mDeviceConfigServerComponent, - Lwm2mObjectAddInstancesComponent, - Lwm2mObjectAddInstancesListComponent - ], - imports: [ - CommonModule, - SharedModule - ], - exports: [ - Lwm2mDeviceProfileTransportConfigurationComponent, - Lwm2mObjectListComponent, - Lwm2mObserveAttrTelemetryComponent, - Lwm2mObserveAttrTelemetryResourceComponent, - Lwm2mDeviceConfigServerComponent, - Lwm2mObjectAddInstancesComponent, - Lwm2mObjectAddInstancesListComponent - ], - providers: [ - ] -}) -export class Lwm2mProfileComponentsModule { } diff --git a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/profile-config.models.ts b/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/profile-config.models.ts deleted file mode 100644 index c626138828..0000000000 --- a/ui-ngx/src/app/modules/home/components/profile/device/lwm2m/profile-config.models.ts +++ /dev/null @@ -1,212 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import { AbstractControl, ValidationErrors } from '@angular/forms'; - -export const OBSERVE_ATTR = 'observeAttr'; -export const OBSERVE = 'observe'; -export const ATTR = 'attribute'; -export const TELEMETRY = 'telemetry'; -export const KEY_NAME = 'keyName'; -export const DEFAULT_ID_SERVER = 123; -export const DEFAULT_ID_BOOTSTRAP = 111; -export const DEFAULT_HOST_NAME = "localhost"; -export const DEFAULT_PORT_SERVER_NO_SEC = 5685; -export const DEFAULT_PORT_SERVER_SEC = 5686; -export const DEFAULT_PORT_SERVER_SEC_CERT = 5688; -export const DEFAULT_PORT_BOOTSTRAP_NO_SEC = 5689; -export const DEFAULT_PORT_BOOTSTRAP_SEC = 5690; -export const DEFAULT_PORT_BOOTSTRAP_SEC_CERT = 5692; -export const DEFAULT_CLIENT_HOLD_OFF_TIME = 1; -export const DEFAULT_LIFE_TIME = 300; -export const DEFAULT_DEFAULT_MIN_PERIOD = 1; -export const DEFAULT_NOTIF_IF_DESIBLED = true; -export const DEFAULT_BINDING = "U"; -export const DEFAULT_BOOTSTRAP_SERVER_ACCOUNT_TIME_OUT = 0; -export const LEN_MAX_PUBLIC_KEY_PSK = 182; -export const LEN_MAX_PUBLIC_KEY_RPK_X509 = 3000; -export const KEY_IDENT_REGEXP_PSK = /^[0-9a-fA-F]{64,64}$/; -export const KEY_PRIVATE_REGEXP = /^[0-9a-fA-F]{134,134}$/; -export const KEY_PUBLIC_REGEXP_PSK = /^[0-9a-fA-F]{182,182}$/; -export const KEY_PUBLIC_REGEXP_X509 = /^[0-9a-fA-F]{0,3000}$/; -export const CAMEL_CASE_REGEXP = /[-_&@.,*+!?^${}()|[\]\\]/g; -export const INSTANCES_ID_VALUE_MIN = 0; -export const INSTANCES_ID_VALUE_MAX = 65535; - -//ok -export enum SECURITY_CONFIG_MODE { - PSK = 'PSK', - RPK = 'RPK', - X509 = 'X509', - NO_SEC = 'NO_SEC' -} -//ok -export const SECURITY_CONFIG_MODE_NAMES = new Map( - [ - [SECURITY_CONFIG_MODE.PSK, 'Pre-Shared Key'], - [SECURITY_CONFIG_MODE.RPK, 'Raw Public Key'], - [SECURITY_CONFIG_MODE.X509, 'X.509 Certificate'], - [SECURITY_CONFIG_MODE.NO_SEC, 'No Security'], - ] -); -//ok -export interface BootstrapServersSecurityConfig { - shortId: number, - lifetime: number, - defaultMinPeriod: number, - notifIfDisabled: boolean, - binding: string -} - -//ok -export interface ServerSecurityConfig { - host?: string, - port?: number, - bootstrapServerIs?: boolean, - securityMode: string, - clientPublicKeyOrId?: string, - clientSecretKey?: string, - serverPublicKey?: string; - clientHoldOffTime?: number, - serverId?: number, - bootstrapServerAccountTimeout: number -} - -//ok -interface BootstrapSecurityConfig { - servers: BootstrapServersSecurityConfig, - bootstrapServer: ServerSecurityConfig, - lwm2mServer: ServerSecurityConfig -} - -//ok -export interface ProfileConfigModels { - bootstrap: BootstrapSecurityConfig, - observeAttr: { - observe: string [], - attribute: string [], - telemetry: string [], - keyName: [] - } -} - -//ok -export function getDefaultBootstrapServersSecurityConfig(): BootstrapServersSecurityConfig { - return { - shortId: DEFAULT_ID_SERVER, - lifetime: DEFAULT_LIFE_TIME, - defaultMinPeriod: DEFAULT_DEFAULT_MIN_PERIOD, - notifIfDisabled: DEFAULT_NOTIF_IF_DESIBLED, - binding: DEFAULT_BINDING - } -} - -//ok -export function getDefaultBootstrapServerSecurityConfig(hostname: any): ServerSecurityConfig { - return { - host: hostname, - port: getDefaultPortBootstrap(), - bootstrapServerIs: true, - securityMode: SECURITY_CONFIG_MODE.NO_SEC.toString(), - serverPublicKey: '', - clientHoldOffTime: DEFAULT_CLIENT_HOLD_OFF_TIME, - serverId: DEFAULT_ID_BOOTSTRAP, - bootstrapServerAccountTimeout: DEFAULT_BOOTSTRAP_SERVER_ACCOUNT_TIME_OUT - } -} -//ok -export function getDefaultLwM2MServerSecurityConfig(hostname): ServerSecurityConfig { - const DefaultLwM2MServerSecurityConfig = getDefaultBootstrapServerSecurityConfig(hostname); - DefaultLwM2MServerSecurityConfig.bootstrapServerIs = false; - DefaultLwM2MServerSecurityConfig.port = getDefaultPortServer(); - DefaultLwM2MServerSecurityConfig.serverId = DEFAULT_ID_SERVER; - return DefaultLwM2MServerSecurityConfig; -} -//ok -export function getDefaultPortBootstrap(securityMode?: string): number { - return (!securityMode || securityMode === SECURITY_CONFIG_MODE.NO_SEC.toString()) ? DEFAULT_PORT_BOOTSTRAP_NO_SEC : - (securityMode === SECURITY_CONFIG_MODE.X509.toString()) ? DEFAULT_PORT_BOOTSTRAP_SEC_CERT : DEFAULT_PORT_BOOTSTRAP_SEC; -} -//ok -export function getDefaultPortServer(securityMode?: string): number { - return (!securityMode || securityMode === SECURITY_CONFIG_MODE.NO_SEC.toString()) ? DEFAULT_PORT_SERVER_NO_SEC : - (securityMode === SECURITY_CONFIG_MODE.X509.toString()) ? DEFAULT_PORT_SERVER_SEC_CERT : DEFAULT_PORT_SERVER_SEC; -} - -//ok -function getDefaultProfileBootstrapSecurityConfig(hostname: any): BootstrapSecurityConfig { - return { - servers: getDefaultBootstrapServersSecurityConfig(), - bootstrapServer: getDefaultBootstrapServerSecurityConfig(hostname), - lwm2mServer: getDefaultLwM2MServerSecurityConfig(hostname) - } -} - -//ok -export function getDefaultProfileConfig(hostname?: any): ProfileConfigModels { - return { - bootstrap: getDefaultProfileBootstrapSecurityConfig((hostname)? hostname : DEFAULT_HOST_NAME), - observeAttr: { - observe: [], - attribute: [], - telemetry: [], - keyName: [] - } - }; -} - -//ok -export interface ResourceLwM2M { - id: number, - name: string, - observe: boolean, - attribute: boolean, - telemetry: boolean, - keyName: string -} -//ok -export interface Instance { - id: number, - resources: ResourceLwM2M[] -} - -/** - * multiple == true => Multiple - * multiple == false => Single - * mandatory == true => Mandatory - * mandatory == false => Optional - */ -export interface ObjectLwM2M { - id: number, - name: string, - multiple?: boolean, - mandatory?: boolean, - instances?: Instance [] -} - -export function getChangeInstancesIds (): ChangeInstancesIds { - let changeInstancesIds: ChangeInstancesIds; - changeInstancesIds.add = new Set(); - changeInstancesIds.del = new Set(); - return changeInstancesIds; - -} - -export interface ChangeInstancesIds { - add: Set, - del: Set -} - diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/gateway/gateway-form.component.html b/ui-ngx/src/app/modules/home/components/widget/lib/gateway/gateway-form.component.html index 19f6b87471..8340857d8d 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/gateway/gateway-form.component.html +++ b/ui-ngx/src/app/modules/home/components/widget/lib/gateway/gateway-form.component.html @@ -35,7 +35,7 @@ required > -
profile-tab +
{{'gateway.security-type' | translate }} diff --git a/ui-ngx/src/app/modules/home/pages/device/device.module.ts b/ui-ngx/src/app/modules/home/pages/device/device.module.ts index 54c02f447b..53ee34d570 100644 --- a/ui-ngx/src/app/modules/home/pages/device/device.module.ts +++ b/ui-ngx/src/app/modules/home/pages/device/device.module.ts @@ -24,9 +24,6 @@ import { DeviceCredentialsDialogComponent } from '@modules/home/pages/device/dev import { HomeDialogsModule } from '../../dialogs/home-dialogs.module'; import { HomeComponentsModule } from '@modules/home/components/home-components.module'; import { DeviceTabsComponent } from '@home/pages/device/device-tabs.component'; -import { SecurityConfigComponent } from '@home/pages/device/lwm2m/security-config.component'; -// TODO: @nickAS21 move to device profile -import {SecurityConfigServerComponent} from "@home/pages/device/lwm2m/security-config-server.component"; import { DefaultDeviceConfigurationComponent } from './data/default-device-configuration.component'; import { DeviceConfigurationComponent } from './data/device-configuration.component'; import { DeviceDataComponent } from './data/device-data.component'; @@ -47,9 +44,7 @@ import { Lwm2mDeviceTransportConfigurationComponent } from './data/lwm2m-device- DeviceComponent, DeviceTabsComponent, DeviceTableHeaderComponent, - DeviceCredentialsDialogComponent, - SecurityConfigComponent, - SecurityConfigServerComponent + DeviceCredentialsDialogComponent ], imports: [ CommonModule, diff --git a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.html b/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.html deleted file mode 100644 index a2be8e6334..0000000000 --- a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.html +++ /dev/null @@ -1,80 +0,0 @@ - -
-
-
-
- - device.lwm2m-security-config.mode - - - {{ credentialTypeLwM2MNamesMap.get(securityConfigLwM2MType[securityMode]) }} - - - -
-
-
-
- - {{ 'device.lwm2m-security-config.client-publicKey-or-id' | translate }} - - {{clientPublicKeyOrId.value?.length || 0}}/{{lenMaxClientPublicKeyOrId}} - - {{ 'device.lwm2m-security-config.client-publicKey-or-id' | translate }} - {{ 'device.lwm2m-security-config.required' | translate }} - - - {{ 'device.lwm2m-security-config.client-key' | translate }} - {{ 'device.lwm2m-security-config.pattern_hex_dec_182' | translate }} - - - {{ 'device.lwm2m-security-config.client-key' | translate }} - {{ 'device.lwm2m-security-config.pattern_hex_dec' | translate }} - - - - {{ 'device.lwm2m-security-config.client-secret-key' | translate }} - - {{clientSecretKey.value?.length || 0}}/{{lenMaxClientSecretKey}} - - {{ 'device.lwm2m-security-config.client-secret-key' | translate }} - {{ 'device.lwm2m-security-config.required' | translate }} - - - {{ 'device.lwm2m-security-config.client-key' | translate }} - {{ 'device.lwm2m-security-config.pattern_hex_dec_134' | translate }} - - - {{ 'device.lwm2m-security-config.client-key' | translate }} - {{ 'device-profile.lwm2m.pattern_hex_dec_64' | translate }} - - -
-
-
-
diff --git a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.ts b/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.ts deleted file mode 100644 index d60ff447c6..0000000000 --- a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config-server.component.ts +++ /dev/null @@ -1,128 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -import {Component, forwardRef, Inject, Input, OnInit, ViewChild} from "@angular/core"; - -import { - ControlValueAccessor, - FormBuilder, FormGroup, NG_VALUE_ACCESSOR, Validators -} from "@angular/forms"; -import { - SECURITY_CONFIG_MODE, - SECURITY_CONFIG_MODE_NAMES, - KEY_IDENT_REGEXP_PSK, - ServerSecurityConfig, - DeviceCredentialsDialogLwm2mData, - LEN_MAX_PSK, - LEN_MAX_PRIVATE_KEY, LEN_MAX_PUBLIC_KEY_RPK, KEY_PRIVATE_REGEXP, LEN_MAX_PUBLIC_KEY_X509, KEY_PUBLIC_REGEXP_X509 -} from "@home/pages/device/lwm2m/security-config.models"; -import {Store} from "@ngrx/store"; -import {AppState} from "@core/core.state"; -import {MAT_DIALOG_DATA, MatDialogRef} from "@angular/material/dialog"; -import {PageComponent} from "@shared/components/page.component"; -import {MatPaginator} from "@angular/material/paginator"; -import { TranslateService } from '@ngx-translate/core'; - -@Component({ - selector: 'tb-security-config-server-lwm2m', - templateUrl: './security-config-server.component.html', - styleUrls: [], - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: forwardRef(() => SecurityConfigServerComponent), - multi: true - } - ] -}) - -export class SecurityConfigServerComponent extends PageComponent implements OnInit, ControlValueAccessor { - - securityConfigLwM2MType = SECURITY_CONFIG_MODE; - securityConfigLwM2MTypes = Object.keys(SECURITY_CONFIG_MODE); - credentialTypeLwM2MNamesMap = SECURITY_CONFIG_MODE_NAMES; - lenMaxClientPublicKeyOrId = LEN_MAX_PSK; - lenMaxClientSecretKey = LEN_MAX_PRIVATE_KEY; - - @Input() serverFormGroup: FormGroup; - - @ViewChild(MatPaginator) paginator: MatPaginator; - - constructor(protected store: Store, - @Inject(MAT_DIALOG_DATA) public data: DeviceCredentialsDialogLwm2mData, - public dialogRef: MatDialogRef, - public translate: TranslateService, - public fb: FormBuilder) { - super(store); - } - - ngOnInit(): void { - this.registerDisableOnLoadFormControl(this.serverFormGroup.get('securityMode')); - } - - updateValueFields(serverData: ServerSecurityConfig): void { - this.serverFormGroup.patchValue(serverData, {emitEvent: false}); - const securityMode = this.serverFormGroup.get('securityMode').value as SECURITY_CONFIG_MODE; - this.updateValidate(securityMode); - } - - updateValidate(securityMode: SECURITY_CONFIG_MODE): void { - switch (securityMode) { - case SECURITY_CONFIG_MODE.NO_SEC: - this.serverFormGroup.get('clientPublicKeyOrId').setValidators([]); - this.serverFormGroup.get('clientSecretKey').setValidators([]); - break; - case SECURITY_CONFIG_MODE.PSK: - this.lenMaxClientPublicKeyOrId = LEN_MAX_PUBLIC_KEY_RPK; - this.lenMaxClientSecretKey = LEN_MAX_PSK; - this.serverFormGroup.get('clientPublicKeyOrId').setValidators([Validators.required]); - this.serverFormGroup.get('clientSecretKey').setValidators([Validators.required, Validators.pattern(KEY_IDENT_REGEXP_PSK)]); - break; - case SECURITY_CONFIG_MODE.RPK: - this.lenMaxClientPublicKeyOrId = LEN_MAX_PUBLIC_KEY_X509; - this.lenMaxClientSecretKey = LEN_MAX_PRIVATE_KEY; - this.serverFormGroup.get('clientPublicKeyOrId').setValidators([Validators.required, Validators.pattern(KEY_PUBLIC_REGEXP_X509)]); - this.serverFormGroup.get('clientSecretKey').setValidators([Validators.required, Validators.pattern(KEY_PRIVATE_REGEXP)]); - break; - case SECURITY_CONFIG_MODE.X509: - this.lenMaxClientPublicKeyOrId = LEN_MAX_PUBLIC_KEY_X509; - this.lenMaxClientSecretKey = LEN_MAX_PRIVATE_KEY; - this.serverFormGroup.get('clientPublicKeyOrId').setValidators([Validators.required, Validators.pattern(KEY_PUBLIC_REGEXP_X509)]); - this.serverFormGroup.get('clientSecretKey').setValidators([Validators.required, Validators.pattern(KEY_PRIVATE_REGEXP)]); - break; - } - this.serverFormGroup.updateValueAndValidity(); - } - - securityModeChanged(securityMode: SECURITY_CONFIG_MODE): void { - this.updateValidate(securityMode); - } - - writeValue(value: any): void { - if (value) { - this.updateValueFields(value); - } - } - - registerOnChange(fn: (value: any) => any): void { - } - - registerOnTouched(fn: any): void { - } - - setDisabledState?(isDisabled: boolean): void { - } -} diff --git a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.html b/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.html deleted file mode 100644 index 20b163503c..0000000000 --- a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.html +++ /dev/null @@ -1,160 +0,0 @@ - -
- -

{{ title }}

- - -
-
-
- - device.lwm2m-security-config.endpoint - - - {{ 'device.lwm2m-security-config.endpoint' | translate }} - {{ 'device.lwm2m-security-config.required' | translate }} - - - - -
- - device.lwm2m-security-config.mode - - - {{ credentialTypeLwM2MNamesMap.get(securityConfigLwM2MType[securityConfigClientMode]) }} - - - -
- - {{ 'device.lwm2m-security-config.identity' | translate }} - - - {{ 'device.lwm2m-security-config.identity' | translate }} - {{ 'device.lwm2m-security-config.required' | translate }} - - -
-
- - {{ 'device.lwm2m-security-config.client-key' | translate }} - - {{clientKey.value?.length || 0}}/{{lenMaxKeyClient}} - - {{ 'device.lwm2m-security-config.client-key' | translate }} - {{ 'device.lwm2m-security-config.required' | translate }} - - - {{ 'device.lwm2m-security-config.client-key' | translate }} - {{ 'device-profile.lwm2m-security-config.pattern_hex_dec_64' | translate }} - - - {{ 'device.lwm2m-security-config.client-key' | translate }} - {{ 'device.lwm2m-security-config.pattern_hex_dec_182' | translate }} - - -
-
- - {{ 'device.lwm2m-security-config.client-certificate' | translate }} - -
-
-
- -
- - - - -
{{ 'device.lwm2m-security-config.bootstrap-server' | translate | uppercase }}
-
-
-
- - -
-
-
- - - - -
{{ 'device.lwm2m-security-config.lwm2m-server' | translate | uppercase }}
-
-
-
- - -
-
-
-
-
- -
-
- - -
-
-
-
-
-
-
- - - -
-
diff --git a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.ts b/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.ts deleted file mode 100644 index a43f21431a..0000000000 --- a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.component.ts +++ /dev/null @@ -1,384 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - - -import {Component, Inject, OnInit} from '@angular/core'; -import {DialogComponent} from '@shared/components/dialog.component'; -import {Store} from '@ngrx/store'; -import {AppState} from '@core/core.state'; -import {Router} from '@angular/router'; -import {MAT_DIALOG_DATA, MatDialogRef} from '@angular/material/dialog'; -import {FormBuilder, FormGroup, Validators} from '@angular/forms'; -import {TranslateService} from '@ngx-translate/core'; -import { - SECURITY_CONFIG_MODE_NAMES, - SECURITY_CONFIG_MODE, - SecurityConfigModels, - ClientSecurityConfigPSK, - ClientSecurityConfigRPK, - JSON_ALL_CONFIG, - KEY_IDENT_REGEXP_PSK, - KEY_PUBLIC_REGEXP_PSK, - DeviceCredentialsDialogLwm2mData, - BOOTSTRAP_SERVER, - BOOTSTRAP_SERVERS, - LWM2M_SERVER, - ClientSecurityConfigX509, - ClientSecurityConfigNO_SEC, - getDefaultClientSecurityConfigType, - LEN_MAX_PSK, - LEN_MAX_PUBLIC_KEY_RPK -} from "./security-config.models"; -import {WINDOW} from "@core/services/window.service"; -import {MatTabChangeEvent, MatTabGroup} from "@angular/material/tabs"; -import {MatTab} from "@angular/material/tabs/tab"; - - -@Component({ - selector: 'tb-security-config-lwm2m', - templateUrl: './security-config.component.html', - styleUrls: [] -}) - -export class SecurityConfigComponent extends DialogComponent implements OnInit { - - lwm2mConfigFormGroup: FormGroup; - title: string; - submitted = false; - securityConfigLwM2MType = SECURITY_CONFIG_MODE; - securityConfigLwM2MTypes = Object.keys(SECURITY_CONFIG_MODE); - credentialTypeLwM2MNamesMap = SECURITY_CONFIG_MODE_NAMES; - formControlNameJsonAllConfig = JSON_ALL_CONFIG; - jsonAllConfig: SecurityConfigModels; - bootstrapServers: string; - bootstrapServer: string; - lwm2mServer: string; - jsonObserveData: {}; - lenMaxKeyClient = LEN_MAX_PSK; - tabPrevious: MatTab - tabIndexPrevious = 0 as number; - - constructor(protected store: Store, - protected router: Router, - @Inject(MAT_DIALOG_DATA) public data: DeviceCredentialsDialogLwm2mData, - public dialogRef: MatDialogRef, - public fb: FormBuilder, - private translate: TranslateService, - @Inject(WINDOW) private window: Window) { - super(store, router, dialogRef); - } - - ngOnInit(): void { - this.jsonAllConfig = JSON.parse(JSON.stringify(this.data.jsonAllConfig)) as SecurityConfigModels; - this.initConstants(); - this.lwm2mConfigFormGroup = this.initLwm2mConfigFormGroup(); - this.title = this.translate.instant('device.lwm2m-security-info') + ": " + this.data.endPoint - this.lwm2mConfigFormGroup.get('clientCertificate').disable(); - this.initClientSecurityConfig(this.lwm2mConfigFormGroup.get('jsonAllConfig').value); - this.registerDisableOnLoadFormControl(this.lwm2mConfigFormGroup.get('securityConfigClientMode')); - } - - initConstants(): void { - this.bootstrapServers = BOOTSTRAP_SERVERS; - this.bootstrapServer = BOOTSTRAP_SERVER; - this.lwm2mServer = LWM2M_SERVER; - } - - /** - * initChildesFormGroup - */ - get bootstrapFormGroup(): FormGroup { - return this.lwm2mConfigFormGroup.get('bootstrapFormGroup') as FormGroup; - } - - get lwm2mServerFormGroup(): FormGroup { - return this.lwm2mConfigFormGroup.get('lwm2mServerFormGroup') as FormGroup; - } - - get observeAttrFormGroup(): FormGroup { - return this.lwm2mConfigFormGroup.get('observeFormGroup') as FormGroup; - } - - initClientSecurityConfig(jsonAllConfig: SecurityConfigModels): void { - switch (jsonAllConfig.client.securityConfigClientMode.toString()) { - case SECURITY_CONFIG_MODE.NO_SEC.toString(): - break; - case SECURITY_CONFIG_MODE.PSK.toString(): - const clientSecurityConfigPSK = jsonAllConfig.client as ClientSecurityConfigPSK; - this.lwm2mConfigFormGroup.patchValue({ - identityPSK: clientSecurityConfigPSK.identity, - clientKey: clientSecurityConfigPSK.key, - }, {emitEvent: false}); - break; - case SECURITY_CONFIG_MODE.RPK.toString(): - const clientSecurityConfigRPK = jsonAllConfig.client as ClientSecurityConfigRPK; - this.lwm2mConfigFormGroup.patchValue({ - clientKey: clientSecurityConfigRPK.key, - }, {emitEvent: false}); - break; - case SECURITY_CONFIG_MODE.X509.toString(): - const clientSecurityConfigX509 = jsonAllConfig.client as ClientSecurityConfigX509; - this.lwm2mConfigFormGroup.patchValue({ - clientCertificate: clientSecurityConfigX509.x509 - }, {emitEvent: false}); - break; - } - this.securityConfigClientUpdateValidators(this.lwm2mConfigFormGroup.get('securityConfigClientMode').value); - } - - securityConfigClientModeChanged(mode: SECURITY_CONFIG_MODE): void { - switch (mode) { - case SECURITY_CONFIG_MODE.NO_SEC: - let clientSecurityConfigNO_SEC = getDefaultClientSecurityConfigType(mode) as ClientSecurityConfigNO_SEC; - this.jsonAllConfig.client = clientSecurityConfigNO_SEC; - this.lwm2mConfigFormGroup.patchValue({ - jsonAllConfig: this.jsonAllConfig, - clientCertificate: false - }, {emitEvent: true}); - break; - case SECURITY_CONFIG_MODE.PSK: - let clientSecurityConfigPSK = getDefaultClientSecurityConfigType(mode, this.lwm2mConfigFormGroup.get('endPoint').value) as ClientSecurityConfigPSK; - clientSecurityConfigPSK.identity = this.data.endPoint; - clientSecurityConfigPSK.key = this.lwm2mConfigFormGroup.get('clientKey').value; - this.jsonAllConfig.client = clientSecurityConfigPSK; - this.lwm2mConfigFormGroup.patchValue({ - identityPSK: clientSecurityConfigPSK.identity, - clientCertificate: false - }, {emitEvent: true}); - break; - case SECURITY_CONFIG_MODE.RPK: - let clientSecurityConfigRPK = getDefaultClientSecurityConfigType(mode) as ClientSecurityConfigRPK; - clientSecurityConfigRPK.key = this.lwm2mConfigFormGroup.get('clientKey').value; - this.jsonAllConfig.client = clientSecurityConfigRPK; - this.lwm2mConfigFormGroup.patchValue({ - jsonAllConfig: this.jsonAllConfig, - clientCertificate: false - }, {emitEvent: true}) - break; - case SECURITY_CONFIG_MODE.X509: - let clientSecurityConfigX509 = getDefaultClientSecurityConfigType(mode) as ClientSecurityConfigX509; - this.jsonAllConfig.client = clientSecurityConfigX509; - this.lwm2mConfigFormGroup.patchValue({ - jsonAllConfig: this.jsonAllConfig, - clientCertificate: true - }, {emitEvent: true}) - break; - } - this.securityConfigClientUpdateValidators(mode); - } - - securityConfigClientUpdateValidators(mode: SECURITY_CONFIG_MODE): void { - switch (mode) { - case SECURITY_CONFIG_MODE.NO_SEC: - this.lwm2mConfigFormGroup.get('identityPSK').setValidators([]); - this.lwm2mConfigFormGroup.get('identityPSK').updateValueAndValidity(); - this.lwm2mConfigFormGroup.get('clientKey').setValidators([]); - this.lwm2mConfigFormGroup.get('clientKey').updateValueAndValidity(); - break; - case SECURITY_CONFIG_MODE.PSK: - this.lenMaxKeyClient = LEN_MAX_PSK; - this.lwm2mConfigFormGroup.get('identityPSK').setValidators([]); - this.lwm2mConfigFormGroup.get('identityPSK').updateValueAndValidity(); - this.lwm2mConfigFormGroup.get('clientKey').setValidators([Validators.required, Validators.pattern(KEY_IDENT_REGEXP_PSK)]); - this.lwm2mConfigFormGroup.get('clientKey').updateValueAndValidity(); - break; - case SECURITY_CONFIG_MODE.RPK: - this.lenMaxKeyClient = LEN_MAX_PUBLIC_KEY_RPK; - this.lwm2mConfigFormGroup.get('identityPSK').setValidators([]); - this.lwm2mConfigFormGroup.get('identityPSK').updateValueAndValidity(); - this.lwm2mConfigFormGroup.get('clientKey').setValidators([Validators.required, Validators.pattern(KEY_PUBLIC_REGEXP_PSK)]); - this.lwm2mConfigFormGroup.get('clientKey').updateValueAndValidity(); - break; - case SECURITY_CONFIG_MODE.X509: - this.lenMaxKeyClient = LEN_MAX_PUBLIC_KEY_RPK; - this.lwm2mConfigFormGroup.get('identityPSK').setValidators([]); - this.lwm2mConfigFormGroup.get('identityPSK').updateValueAndValidity(); - this.lwm2mConfigFormGroup.get('clientKey').setValidators([]); - this.lwm2mConfigFormGroup.get('clientKey').updateValueAndValidity(); - break; - } - } - - tabChanged = (tabChangeEvent: MatTabChangeEvent): void => { - if (this.tabIndexPrevious !== tabChangeEvent.index) this.upDateValueToJson(); - this.tabIndexPrevious = tabChangeEvent.index; - } - - upDateValueToJson(): void { - switch (this.tabIndexPrevious) { - case 0: - this.upDateValueToJsonTab_0(); - break; - case 1: - this.upDateValueToJsonTab_1(); - break; - case 2: - this.upDateValueToJsonTab_2(); - break; - } - } - - upDateValueToJsonTab_0(): void { - if (this.lwm2mConfigFormGroup !== null) { - if (!this.lwm2mConfigFormGroup.get('endPoint').pristine && this.lwm2mConfigFormGroup.get('endPoint').valid) { - this.data.endPoint = this.lwm2mConfigFormGroup.get('endPoint').value; - // Client mode == PSK - if (this.lwm2mConfigFormGroup.get('securityConfigClientMode').value === SECURITY_CONFIG_MODE.PSK) { - this.jsonAllConfig.client["endpoint"] = this.data.endPoint; - this.jsonAllConfig.client["endpoint"].markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - } - /** only Client mode == PSK */ - if (!this.lwm2mConfigFormGroup.get('identityPSK').pristine && this.lwm2mConfigFormGroup.get('identityPSK').valid) { - this.lwm2mConfigFormGroup.get('identityPSK').markAsPristine({ - onlySelf: true - }); - this.updateIdentityPSK(); - } - /** only Client mode == PSK (len = 64) || RPK (len = 182) */ - if (!this.lwm2mConfigFormGroup.get('clientKey').pristine && this.lwm2mConfigFormGroup.get('clientKey').valid) { - this.lwm2mConfigFormGroup.get('clientKey').markAsPristine({ - onlySelf: true - }); - this.updateClientKey(); - } - } - } - - upDateValueToJsonTab_1(): void { - if (this.lwm2mConfigFormGroup !== null) { - if (this.bootstrapFormGroup !== null && !this.bootstrapFormGroup.pristine && this.bootstrapFormGroup.valid) { - this.jsonAllConfig.bootstrap.bootstrapServer = this.bootstrapFormGroup.value; - this.bootstrapFormGroup.markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - - if (this.lwm2mServerFormGroup !== null && !this.lwm2mServerFormGroup.pristine && this.lwm2mServerFormGroup.valid) { - this.jsonAllConfig.bootstrap.lwm2mServer = this.lwm2mServerFormGroup.value; - this.lwm2mServerFormGroup.markAsPristine({ - onlySelf: true - }); - this.upDateJsonAllConfig(); - } - } - } - - upDateValueToJsonTab_2(): void { - if (!this.lwm2mConfigFormGroup.get(this.formControlNameJsonAllConfig).pristine && this.lwm2mConfigFormGroup.get(this.formControlNameJsonAllConfig).valid) { - this.jsonAllConfig = this.lwm2mConfigFormGroup.get(this.formControlNameJsonAllConfig).value; - this.lwm2mConfigFormGroup.get(this.formControlNameJsonAllConfig).markAsPristine({ - onlySelf: true - }); - } - } - - updateIdentityPSK(): void { - if (this.lwm2mConfigFormGroup.get('bootstrapServer').value['securityMode'] === SECURITY_CONFIG_MODE.PSK.toString()) { - this.lwm2mConfigFormGroup.get('bootstrapFormGroup').patchValue({ - clientPublicKeyOrId: this.lwm2mConfigFormGroup.get('identityPSK').value - }); - this.jsonAllConfig.client['identity'] = this.lwm2mConfigFormGroup.get('identityPSK').value; - this.upDateJsonAllConfig(); - } - if (this.lwm2mConfigFormGroup.get('lwm2mServer').value['securityMode'] === SECURITY_CONFIG_MODE.PSK.toString()) { - this.lwm2mConfigFormGroup.get('lwm2mServerFormGroup').patchValue({ - clientPublicKeyOrId: this.lwm2mConfigFormGroup.get('identityPSK').value - }); - this.jsonAllConfig.bootstrap.lwm2mServer.clientPublicKeyOrId = this.lwm2mConfigFormGroup.get('identityPSK').value; - this.upDateJsonAllConfig(); - } - } - - updateClientKey(): void { - this.jsonAllConfig.client["key"] = this.lwm2mConfigFormGroup.get('clientKey').value; - if (this.lwm2mConfigFormGroup.get('bootstrapServer').value['securityMode'] === SECURITY_CONFIG_MODE.PSK.toString()) { - this.lwm2mConfigFormGroup.get('bootstrapServer').patchValue({ - clientSecretKey: this.jsonAllConfig.client["key"] - }, {emitEvent: false}); - this.jsonAllConfig.bootstrap.bootstrapServer.clientSecretKey = this.jsonAllConfig.client["key"]; - } - if (this.lwm2mConfigFormGroup.get('lwm2mServer').value['securityMode'] === SECURITY_CONFIG_MODE.PSK.toString()) { - this.lwm2mConfigFormGroup.get('lwm2mServer').patchValue({ - clientSecretKey: this.jsonAllConfig.client["key"] - }, {emitEvent: false}); - this.jsonAllConfig.bootstrap.lwm2mServer.clientSecretKey = this.jsonAllConfig.client["key"]; - } - this.upDateJsonAllConfig(); - } - - upDateJsonAllConfig(): void { - this.data.jsonAllConfig = JSON.parse(JSON.stringify(this.jsonAllConfig)); - this.lwm2mConfigFormGroup.patchValue({ - jsonAllConfig: JSON.parse(JSON.stringify(this.jsonAllConfig)) - }, {emitEvent: false}); - this.lwm2mConfigFormGroup.markAsDirty(); - } - - upDateBootstrapFormGroup(): void { - this.data.jsonAllConfig = JSON.parse(JSON.stringify(this.jsonAllConfig)); - this.lwm2mConfigFormGroup.patchValue({ - jsonAllConfig: JSON.parse(JSON.stringify(this.jsonAllConfig)) - }, {emitEvent: false}); - this.lwm2mConfigFormGroup.markAsDirty(); - } - - initLwm2mConfigFormGroup(): FormGroup { - if (SECURITY_CONFIG_MODE[this.jsonAllConfig.client.securityConfigClientMode.toString()] === SECURITY_CONFIG_MODE.PSK) { - this.data.endPoint = this.jsonAllConfig.client['endpoint']; - } - return this.fb.group({ - securityConfigClientMode: [SECURITY_CONFIG_MODE[this.jsonAllConfig.client.securityConfigClientMode.toString()], []], - identityPSK: ['', []], - clientKey: ['', []], - clientCertificate: [false, []], - bootstrapServer: [this.jsonAllConfig.bootstrap[this.bootstrapServer], []], - lwm2mServer: [this.jsonAllConfig.bootstrap[this.lwm2mServer], []], - bootstrapFormGroup: this.getServerGroup(true), - lwm2mServerFormGroup: this.getServerGroup(false), - endPoint: [this.data.endPoint, []], - jsonAllConfig: [this.jsonAllConfig, []] - }); - } - - getServerGroup(bootstrapServerIs: boolean): FormGroup { - return this.fb.group({ - securityMode: [this.fb.control(SECURITY_CONFIG_MODE.NO_SEC), []], - clientPublicKeyOrId: ['', []], - clientSecretKey: ['', []] - }) - } - - save(): void { - this.upDateValueToJson(); - this.data.endPoint = this.lwm2mConfigFormGroup.get('endPoint').value.split('\"').join(''); - this.data.jsonAllConfig = this.jsonAllConfig; - if (this.lwm2mConfigFormGroup.get('securityConfigClientMode').value === SECURITY_CONFIG_MODE.PSK) { - this.data.endPoint = this.data.jsonAllConfig.client["identity"]; - } - this.dialogRef.close(this.data); - } - - cancel(): void { - this.dialogRef.close(undefined); - } -} - - diff --git a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.models.ts b/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.models.ts deleted file mode 100644 index cd323e2f90..0000000000 --- a/ui-ngx/src/app/modules/home/pages/device/lwm2m/security-config.models.ts +++ /dev/null @@ -1,154 +0,0 @@ -/// -/// Copyright © 2016-2020 The Thingsboard Authors -/// -/// Licensed under the Apache License, Version 2.0 (the "License"); -/// you may not use this file except in compliance with the License. -/// You may obtain a copy of the License at -/// -/// http://www.apache.org/licenses/LICENSE-2.0 -/// -/// Unless required by applicable law or agreed to in writing, software -/// distributed under the License is distributed on an "AS IS" BASIS, -/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -/// See the License for the specific language governing permissions and -/// limitations under the License. -/// - -export const JSON_ALL_CONFIG = 'jsonAllConfig'; -export const END_POINT = 'endPoint'; -export const DEFAULT_END_POINT = 'default_client_lwm2m_end_point_no_sec'; -export const BOOTSTRAP_SERVERS = 'servers'; -export const BOOTSTRAP_SERVER = 'bootstrapServer'; -export const LWM2M_SERVER = 'lwm2mServer'; -export const JSON_OBSERVE = 'jsonObserve'; -export const LEN_MAX_PSK = 64; -export const LEN_MAX_PRIVATE_KEY = 134; -export const LEN_MAX_PUBLIC_KEY_RPK = 182; -export const LEN_MAX_PUBLIC_KEY_X509 = 3000; -export const KEY_IDENT_REGEXP_PSK = /^[0-9a-fA-F]{64,64}$/; -export const KEY_PRIVATE_REGEXP = /^[0-9a-fA-F]{134,134}$/; -export const KEY_PUBLIC_REGEXP_PSK = /^[0-9a-fA-F]{182,182}$/; -export const KEY_PUBLIC_REGEXP_X509 = /^[0-9a-fA-F]{0,3000}$/; - -export interface DeviceCredentialsDialogLwm2mData { - jsonAllConfig?: SecurityConfigModels; - endPoint?: string; - isNew?: boolean; -} - -export enum SECURITY_CONFIG_MODE { - PSK = 'PSK', - RPK = 'RPK', - X509 = 'X509', - NO_SEC = 'NO_SEC' -} - -export const SECURITY_CONFIG_MODE_NAMES = new Map( - [ - [SECURITY_CONFIG_MODE.PSK, 'Pre-Shared Key'], - [SECURITY_CONFIG_MODE.RPK, 'Raw Public Key'], - [SECURITY_CONFIG_MODE.X509, 'X.509 Certificate'], - [SECURITY_CONFIG_MODE.NO_SEC, 'No Security'], - ] -); - -export type ClientSecurityConfigType = - ClientSecurityConfigPSK - | ClientSecurityConfigRPK - | ClientSecurityConfigX509 - | ClientSecurityConfigNO_SEC; - -export interface ClientSecurityConfigPSK { - securityConfigClientMode: string, - endpoint: string, - identity: string, - key: string -} - -export interface ClientSecurityConfigRPK { - securityConfigClientMode: string, - key: string -} - -export interface ClientSecurityConfigX509 { - securityConfigClientMode: string, - x509: boolean -} - -export interface ClientSecurityConfigNO_SEC { - securityConfigClientMode: string -} - -export interface ServerSecurityConfig { - securityMode: string, - clientPublicKeyOrId?: string, - clientSecretKey?: string -} - -interface BootstrapSecurityConfig { - bootstrapServer: ServerSecurityConfig, - lwm2mServer: ServerSecurityConfig -} - -export interface SecurityConfigModels { - client: ClientSecurityConfigType, - bootstrap: BootstrapSecurityConfig -} - -export function getDefaultClientSecurityConfigType(securityConfigMode: SECURITY_CONFIG_MODE, endPoint?: string): ClientSecurityConfigType { - let security: ClientSecurityConfigType; - switch (securityConfigMode) { - case SECURITY_CONFIG_MODE.PSK: - security = { - securityConfigClientMode: '', - endpoint: endPoint, - identity: endPoint, - key: '' - } - break; - case SECURITY_CONFIG_MODE.RPK: - security = { - securityConfigClientMode: '', - key: '' - } - break; - case SECURITY_CONFIG_MODE.X509: - security = { - securityConfigClientMode: '', - x509: true - } - break; - case SECURITY_CONFIG_MODE.NO_SEC: - security = { - securityConfigClientMode: '' - } - break; - } - security.securityConfigClientMode = securityConfigMode.toString(); - return security; -} - -export function getDefaultServerSecurityConfig(): ServerSecurityConfig { - return { - securityMode: SECURITY_CONFIG_MODE.NO_SEC.toString(), - clientPublicKeyOrId: '', - clientSecretKey: '' - } -} - -function getDefaultBootstrapSecurityConfig(): BootstrapSecurityConfig { - return { - bootstrapServer: getDefaultServerSecurityConfig(), - lwm2mServer: getDefaultServerSecurityConfig() - } -} - -export function getDefaultSecurityConfig(): SecurityConfigModels { - const securityConfigModels = { - client: getDefaultClientSecurityConfigType(SECURITY_CONFIG_MODE.NO_SEC), - bootstrap: getDefaultBootstrapSecurityConfig() - }; - return securityConfigModels; -} - - diff --git a/ui-ngx/src/app/shared/components/json-object-edit.component.ts b/ui-ngx/src/app/shared/components/json-object-edit.component.ts index 72c4505c0b..503b12c1a8 100644 --- a/ui-ngx/src/app/shared/components/json-object-edit.component.ts +++ b/ui-ngx/src/app/shared/components/json-object-edit.component.ts @@ -22,7 +22,7 @@ import { ActionNotificationHide, ActionNotificationShow } from '@core/notificati import { Store } from '@ngrx/store'; import { AppState } from '@core/core.state'; import { CancelAnimationFrame, RafService } from '@core/services/raf.service'; -import { guid, isUndefined } from '@core/utils'; +import { guid } from '@core/utils'; import { ResizeObserver } from '@juggle/resize-observer'; @Component({ @@ -59,27 +59,21 @@ export class JsonObjectEditComponent implements OnInit, ControlValueAccessor, Va @Input() fillHeight: boolean; - @Input() editorStyle: { [klass: string]: any }; - - @Input() sort: Function; + @Input() editorStyle: {[klass: string]: any}; private requiredValue: boolean; - get required(): boolean { return this.requiredValue; } - @Input() set required(value: boolean) { this.requiredValue = coerceBooleanProperty(value); } private readonlyValue: boolean; - get readonly(): boolean { return this.readonlyValue; } - @Input() set readonly(value: boolean) { this.readonlyValue = coerceBooleanProperty(value); @@ -224,12 +218,8 @@ export class JsonObjectEditComponent implements OnInit, ControlValueAccessor, Va this.contentValue = ''; this.objectValid = false; try { - if (this.modelValue) { - this.contentValue = JSON.stringify(this.modelValue, isUndefined(this.sort) ? undefined : - (key, value) => { - return this.sort(key, value) - }, 2); + this.contentValue = JSON.stringify(this.modelValue, undefined, 2); this.objectValid = true; } else { this.objectValid = !this.required; diff --git a/ui-ngx/src/app/shared/models/device.models.ts b/ui-ngx/src/app/shared/models/device.models.ts index 0f07cadd36..ffeae2f56d 100644 --- a/ui-ngx/src/app/shared/models/device.models.ts +++ b/ui-ngx/src/app/shared/models/device.models.ts @@ -35,7 +35,7 @@ export enum DeviceProfileType { export enum DeviceTransportType { DEFAULT = 'DEFAULT', MQTT = 'MQTT', - LWM2M = 'LWM2M' + // LWM2M = 'LWM2M' } export enum MqttTransportPayloadType { @@ -76,7 +76,7 @@ export const deviceTransportTypeTranslationMap = new Map( [ [DeviceTransportType.DEFAULT, 'device-profile.transport-type-default-hint'], [DeviceTransportType.MQTT, 'device-profile.transport-type-mqtt-hint'], - [DeviceTransportType.LWM2M, 'device-profile.transport-type-lwm2m-hint'] + // [DeviceTransportType.LWM2M, 'device-profile.transport-type-lwm2m-hint'] ] ); @@ -121,13 +121,13 @@ export const deviceTransportTypeConfigurationInfoMap = new Map( [ [DeviceCredentialsType.ACCESS_TOKEN, 'Access token'], [DeviceCredentialsType.X509_CERTIFICATE, 'MQTT X.509'], - [DeviceCredentialsType.MQTT_BASIC, 'MQTT Basic'], - [DeviceCredentialsType.LWM2M_CREDENTIALS, 'LwM2M Credentials'] + [DeviceCredentialsType.MQTT_BASIC, 'MQTT Basic'] ] ); @@ -454,8 +452,6 @@ export interface DeviceCredentials extends BaseData { credentialsType: DeviceCredentialsType; credentialsId: string; credentialsValue: string; - credentialsLwKey: string; - credentialsLwValue: string; } export interface DeviceCredentialMQTTBasic { diff --git a/ui-ngx/src/assets/locale/locale.constant-en_US.json b/ui-ngx/src/assets/locale/locale.constant-en_US.json index b1dcbf97d5..86ac20bf35 100644 --- a/ui-ngx/src/assets/locale/locale.constant-en_US.json +++ b/ui-ngx/src/assets/locale/locale.constant-en_US.json @@ -872,31 +872,6 @@ "access-token-invalid": "Access token length must be from 1 to 20 characters.", "rsa-key": "RSA public key", "rsa-key-required": "RSA public key is required.", - "lwm2m-key": "LwM2M Security config key", - "lwm2m-key-required": "LwM2M Security config key is required.", - "lwm2m-value": "LwM2M Security config", - "lwm2m-value-required": "LwM2M Security config value is required.", - "lwm2m-endpoint": "Client endpoint/identity", - "lwm2m-security-info": "Security Config Info", - "lwm2m-value-edit": "Edit Security config", - "lwm2m-value-edit-tip": "Edit security config json editor", - "lwm2m-security-config": { - "identity": "Client Identity", - "client-key": "Client Key", - "required": " value is required.", - "endpoint": "Endpoint Client Name", - "mode": "Security config mode", - "client-tab": "Client Security Config", - "client-certificate": "Client certificate", - "bootstrap-tab": "Bootstrap Client", - "bootstrap-server": "Bootstrap Server", - "lwm2m-server": "LwM2M Server", - "client-publicKey-or-id": "Client Public Key or Id", - "client-secret-key": "Client Secret Key", - "config-json-tab": "Json Client Security Config", - "pattern_hex_dec_64": "must be hex decimal format and 64 characters", - "pattern_hex_dec_182": "must be hex decimal format and 182 characters" - }, "client-id": "Client ID", "client-id-pattern": "Contains invalid character.", "user-name": "User Name", @@ -1096,57 +1071,7 @@ "schedule-time": "Time", "schedule-time-from": "From", "schedule-time-to": "To", - "schedule-days-of-week-required": "At least one day of week should be selected.", - "lwm2m": { - "object-list": "Object list", - "object-list-empty": "No objects selected.", - "no-objects-matching": "No objects matching '{{object}}' were found.", - "valid-id-instance-no-min": "Instance number '{{instance}}' no validated. Min value='{{min}}'", - "valid-id-instance-no-max": "Instance number '{{instance}}' no validated. Max value='{{max}}'", - "model-tab": "LWM2M Model", - "add-instances-tip": "Add new instances", - "instances-list": "Instances list", - "instances-input": "Input Instance Id value", - "instances-input-holder": "Input Instance number...", - "resource-label": "Resource", - "observe-label": "Observe", - "attribute-label": "Attribute", - "telemetry-label": "Telemetry", - "key-name-label": "Key Name", - "is-observe-tip": "Is Observe", - "is-attr-tip": "Is Attribute", - "is-telemetry-tip": "Is Telemetry", - "key-name-tip": "Key Name", - "key-name": "Key Name", - "key-name_label": "Key Name in Camel format", - "required": " value is required.", - "mode": "Security config mode", - "pattern_hex_dec_64": "must be hex decimal format and 64 characters", - "pattern_hex_dec_134": "must be hex decimal format and 134 characters", - "pattern_hex_dec_182": "must be hex decimal format and 182 characters", - "pattern_hex_dec": "must be hex decimal format", - "bootstrap-tab": "Bootstrap", - "servers": "Servers", - "short-id": "Short ID", - "short-id-tip": "Short Server ID", - "lifetime": "Lifetime of the registration for this LwM2M client", - "default-min-period": "Minimum Period between two notifications (sec)", - "notif-if-disabled": "Notification Storing When Disabled or Offline", - "binding": "Binding", - "bootstrap-server": "Bootstrap Server", - "lwm2m-server": "LwM2M Server", - "server-host": "Host", - "server-host-tip": "Server Host", - "server-port": "Port", - "server-port-tip": "Server Port", - "server-public-key": "Server Public Key", - "server-public-key-tip": "Server Public Key only for X509, RPK", - "client-hold-off-time": "Hold Off Time", - "client-hold-off-time-tip": "Client Hold Off Time for use with a Bootstrap-Server only", - "bootstrap-server-account-timeout": "Account after the timeout", - "bootstrap-server-account-timeout-tip": "Bootstrap-Server Account after the timeout value given by this resource.", - "config-json-tab": "Json Config Profile Device" - } + "schedule-days-of-week-required": "At least one day of week should be selected." }, "dialog": { "close": "Close dialog"