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

New features for leshan-client-demo ? #1248

Closed
JaroslawLegierski opened this issue Apr 27, 2022 · 11 comments
Closed

New features for leshan-client-demo ? #1248

JaroslawLegierski opened this issue Apr 27, 2022 · 11 comments
Labels
discussion Discussion about anything

Comments

@JaroslawLegierski
Copy link
Contributor

Our colleagues developed interesting tool: https://github.com/JaroslawLegierski/lwm2m-simulator Please let me know if you would be interested some of its features that can be potentially implemented e.g. in leshan-client-demo ?

@sbernard31
Copy link
Contributor

Thx for sharing this. 🙏
I will look at this as soon as I find some time to do that.

Any reason why https://github.com/JaroslawLegierski/lwm2m-simulator is a private repository ?

@sbernard31 sbernard31 added the discussion Discussion about anything label Apr 27, 2022
@JaroslawLegierski
Copy link
Contributor Author

I must clean the project before make it public. But most of all I would like to know your opinion if it makes sense. Some of the project's features are specific, but maybe there is something interesting in this tool from the leshan-client-demo point of view?

@sbernard31
Copy link
Contributor

My opinion :
Don't worry if code is great state when you share it publicly as far as the quality state of the code is clearly explained.

(The only thing you must be sure is that you don't share confidential information)

Oops 😬 I didn't accept your invitation to access to your private repository in time :

This invitation has expired.

@sbernard31
Copy link
Contributor

I looked at this and this looks like a fork of leshan-client-demo.

The main new feature I see is the TestObjectController which allow to configure behavior of the client ? or maybe I missed something else ?

Note that your TestObjectController are using 3442 id which is reserved id for : https://github.com/OpenMobileAlliance/lwm2m-registry/blob/prod/3442.xml

For now I'm not so sure we want to integrate this in Leshan. 🤔

But I think it could make sense to have more open source project or example of code based on Leshan, so if you make it public we can create a dedicated wiki page to list of all this projects/examples.

@JaroslawLegierski
Copy link
Contributor Author

There is another potentially interesting CLI feature in the lwm2m-simulator project - the list nodes command which returns a list of all nodes on leshan-client-demo side: https://github.com/Przem83/leshan/tree/opl/list_nodes What's your opinion about this feature?

@sbernard31
Copy link
Contributor

Oh I missed that one.

This is about listing all available object/object instance/ resource on the client ? without resource/resourceInstance value ? right ?

I don't remember that I needing this kind of feature but maybe this is because I know too much the client-demo behavior. Maybe this can help for new users to discover what is supported by client-demo ?

As the code is pretty small and isolated and if you think this is useful we can add it.

"Deciding to add or not feature in demos" is not so easy decision because the scope of the demo is not clearly defined and adding a lot of feature is tempting but in the end this could make future refactoring more complicated.

@JaroslawLegierski
Copy link
Contributor Author

This is about listing all available object/object instance/ resource on the client ? without resource/resourceInstance value ? right ?

Yes this function is responsible for listing objects/object instances/resources without values e.g.:

/0/0 : LWM2M Security

  • 0 : LWM2M Server URI
  • 1 : Bootstrap-Server
  • 2 : Security Mode
  • 3 : Public Key or Identity
  • 4 : Server Public Key
  • 5 : Secret Key
    ......
    /6/0 : Location
  • 0 : Latitude
  • 1 : Longitude
  • 5 : Timestamp
    /3303/0 : Temperature
  • 5700 : Sensor Value
  • 5701 : Sensor Units
  • 5602 : Max Measured Value
  • 5601 : Min Measured Value
  • 5605 : Reset Min and Max Measured Values

I don't remember that I needing this kind of feature but maybe this is because I know too much the client-demo behavior. Maybe this can help for new users to discover what is supported by client-demo ?

In my opinion, this option can be useful, for example, for new users, but also when, during the tests, when we have many (different) leshan-demo-client instances running

As the code is pretty small and isolated and if you think this is useful we can add it.

Thank you very much - I will prepare the appropriate PR

"Deciding to add or not feature in demos" is not so easy decision because the scope of the demo is not clearly defined and adding a lot of feature is tempting but in the end this could make future refactoring more complicated.

You are absolutely right - that's why we decided to make the lwm2m-simulator project public according to your suggestion (after cleaning and necessary modifications).

@JaroslawLegierski
Copy link
Contributor Author

I created PR #1258

@sbernard31
Copy link
Contributor

Wtih #1258 (and so 30bad68), the list command is not added in master

Should we close this issue ?

@JaroslawLegierski
Copy link
Contributor Author

Wtih #1258 (and so 30bad68), the list command is not added in master

Should we close this issue ?

Yes of course. Thank You very much.

@sbernard31
Copy link
Contributor

Thx to you for your contribution 🙏 !

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

No branches or pull requests

2 participants