CANDY-LINE / node-red-contrib-lwm2m

Step-by-step tutorial is available at
http://candy-line.tumblr.com/post/166976363228/oma-lwm2m-node-red-node
Apache License 2.0
7 stars 3 forks source link

client registers only with smart object instance not zero - using bootstrap #12

Closed djDuff closed 5 years ago

djDuff commented 5 years ago

@dbaba san, I have found one more bug when bootstrapping. Bootstrap works, but node-red client registers on lwm2m server only with smart object instances that are not 0. For example, temperature (same for other smart objects): in Node-Red client, i have defined: /3303/0/, /3303/1/, /3303/2/ On LwM2M GW (when client bootstrapped): I see only /3303/1/, /3303/2/5, and /3303/0/ is not listed. image

When I register the same NR client (without bootstrap) on LwM2M GW, I see all smart object instances as expected: /3303/0/, /3303/1/, /3303/2/ image

If I use leshan client, then everything is working as expected with or without bootstrap (all smart object instances are available).

Could you have a look, please?

I am using latest node-red-contrib-lwm2m v2.1.2 and latest Node-Red v0.20.6

Lwm2m client node config: [{"id":"78b8cfb6.e1fcc","type":"lwm2m client out","z":"da23253d.516e98","name":"ezhiand-nodered-bootstrap-device","lwm2mClient":"6fe91e47.cfeb6","x":480,"y":1260,"wires":[]},{"id":"6fe91e47.cfeb6","type":"lwm2m client","z":"","disabled":false,"clientName":"ezhiand-nodered-bootstrap-device","enableDTLS":true,"clientPort":"56821","lifetimeSec":"300","reconnectSec":"300","requestBootstrap":true,"saveProvisionedConfig":false,"useIPv4":true,"serverHost":"mybss","serverPort":"5684","redirectLwm2mClientLog":false,"dumpLwm2mMessages":false,"hideSensitiveInfo":false,"propagateInternalEvents":false,"objects":"{\"3303\":{\"0\":{\"5700\":{\"type\":\"FLOAT\",\"acl\":\"R\",\"value\":\"\"}},\"1\":{\"5700\":{\"type\":\"FLOAT\",\"acl\":\"R\",\"value\":\"\"}},\"2\":{\"5700\":{\"type\":\"FLOAT\",\"acl\":\"R\",\"value\":\"\"}}},\"3304\":{\"0\":{\"5700\":{\"type\":\"FLOAT\",\"acl\":\"R\",\"value\":\"\"}},\"1\":{\"5700\":{\"type\":\"FLOAT\",\"acl\":\"R\",\"value\":\"\"}},\"2\":{\"5700\":{\"type\":\"FLOAT\",\"acl\":\"R\",\"value\":\"\"}}},\"3341\":{\"0\":{\"5527\":{\"type\":\"STRING\",\"acl\":\"RW\",\"value\":\"\"}}},\"3347\":{\"0\":{\"5500\":{\"type\":\"BOOLEAN\",\"acl\":\"RW\",\"value\":\"\"}}}}"}]

dbaba commented 5 years ago

Thank you for the precise report, very helpful. Now fixed the issue. Could you please try v2.1.3?

djDuff commented 5 years ago

@dbaba yes, working fine now. Thank you!