Skip to content
This repository has been archived by the owner on Oct 11, 2023. It is now read-only.

David eating parameter when using cbor #15

Open
felixletkemann opened this issue Apr 24, 2018 · 0 comments
Open

David eating parameter when using cbor #15

felixletkemann opened this issue Apr 24, 2018 · 0 comments

Comments

@felixletkemann
Copy link

If I transmit the following JSON over CoAP, everything works fine:
[52403729, 13437171, 123456789, -1171, 3794, 4, 21212121, 1000]

If I transmit the same encoded as CBOR, the "params" variable looks like
[0, 13437171, 123456789, -1171, 3794, 4, 21212121, 1000]

The first parameter seems to be lost. Switching back to non-cbor solves the problem - but I want to use cbor. The strange thing is, that all the other parameters are transmitted correctly. The problem only affects the first one. First I thought that the problem might be my cbor encoder. So I had a look into the request object. I found the following lines:

@params={"X?"=>{"52195380, 13498559, 123456789, -1171, 3794, 4, 21212121, 1000"=>nil}}>

So the correct value is transmitted - but lost somewhere. The correct value makes it into the request object but not to the params variable.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant