Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Options not optional? #28

Open
nzfarmer1 opened this issue Aug 19, 2018 · 3 comments
Open

Options not optional? #28

nzfarmer1 opened this issue Aug 19, 2018 · 3 comments

Comments

@nzfarmer1
Copy link

I spent sometime last week on getting a client request working from this library.

It spat the dummy on the return message. On investigation the code used to parse the Options made the assumption that there had to be 1 or more options, but in the spec options can be 0 or more.

coap_options.c: 178 if (srcArr[0] == OPTION_PAYLOAD_MARKER)

(This is a later version to the code I was looking at, but my reading of the spec implies that a payload can follow the tokens - something this doesn't allow for, and is always invoked as part of the message processing?)

I could be wrong here though, it was a quick fix to render the response of a coapthon server that may well be violating the spec.

@thebigtimes
Copy link

Hi nzfarmer1,

Also currently working through a client request example using the library. I am having issues getting a valid response after my localhost coapthon server receives the initial request message.

Do you mind showing your client code? I will give it a try and see if I am seeing the same thing when using no options.

Thanks.

@nzfarmer1
Copy link
Author

nzfarmer1 commented Aug 23, 2018

Sure thing. I made a few changes to both lobaro and coapthon and have now got observer working with lobar acting as a server. Send me your email address.

@niondir
Copy link
Member

niondir commented Sep 4, 2018

Thanks for mentioning the issue. We are open for all pull request addressing the issue.

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

No branches or pull requests

3 participants