Skip to content

remove const for adress, length, converter #144

Description

@s0170071

As I try to access data points dynamicly, e.g. by calling http://192.168.1.151/read?DP=0x2000&Type=TempL, you recently suggested to just instantiate a data point locally.

Turns out, that may not be such a great idea, because if I did, that DP exists within that function only. If the function exits, the DP is gone.
The callback function, however, kicks in later ( or not at all ? ) but the DP is gone. Potentially even crashing the system.

Having a global DP solves that issue, however, it turned out that all the crucial data is const so I only set it up once and then thats it.

My suggestion: remove const for everything that is required to re-use a DP. Name is irrelevant, I guess.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    staleDenotes issues that are probably not applicable anymore

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions