Read / Write lwm2m resource instance

Hi all,

I'm implementing a lwm2m client on a NRF9160 and have a problem with read/write resource instances. I use Leshan demo server to test the object and a came across a problem on ‘Remote SIM Provisioning’ object 504. When I read ‘504/0/11’ it reads all instances of this resource, but when I try to read a single instance of this resource, got an error. See images blow

Read resource insntances OK

Read single resource instace NOK.

This is my first problem, because after i need to write.

Can anybody help?

Parents
  • After digging in other blogs i found what should be the answer for 'Read resource instance'

    This is what Leshan asks

    00> >>>> RCV COAP MSG LEN: 26<<<<
    00>
    00> Header<> 48 01 #ID 07 7a #TK 78 62 70 15 7e de ef 47
    00> Payld <> b3 35 30 34 01 30 02 31 31 01 30 62 2d 16
    00> >>>> END MSG <<<<
    00>
    00> RCV PATH: obj_id 504, obj_inst_id 0, res_id 11, res_inst_id 0, level 4
    00>

    This should be what lwm2m client answers


    00> >>>> SND COAP MSG LEN: 39<<<<
    00>
    00> Header<> 68 45 #ID 07 7a #TK 78 62 70 15 7e de ef 47
    00> Payld <> c2 2d 16 ff 48 00 14 38 39 33 35 31 30 36 30 30 30 30 37 37 30 38 36 32 39 39 31
    00> >>>> END MSG <<<<

    With this answer from lwm2m client everything works fine.

Reply
  • After digging in other blogs i found what should be the answer for 'Read resource instance'

    This is what Leshan asks

    00> >>>> RCV COAP MSG LEN: 26<<<<
    00>
    00> Header<> 48 01 #ID 07 7a #TK 78 62 70 15 7e de ef 47
    00> Payld <> b3 35 30 34 01 30 02 31 31 01 30 62 2d 16
    00> >>>> END MSG <<<<
    00>
    00> RCV PATH: obj_id 504, obj_inst_id 0, res_id 11, res_inst_id 0, level 4
    00>

    This should be what lwm2m client answers


    00> >>>> SND COAP MSG LEN: 39<<<<
    00>
    00> Header<> 68 45 #ID 07 7a #TK 78 62 70 15 7e de ef 47
    00> Payld <> c2 2d 16 ff 48 00 14 38 39 33 35 31 30 36 30 30 30 30 37 37 30 38 36 32 39 39 31
    00> >>>> END MSG <<<<

    With this answer from lwm2m client everything works fine.

Children
Related