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

Generate OBISHandlers dynamically #28

Open
CRSLEE opened this issue Jul 19, 2023 · 1 comment
Open

Generate OBISHandlers dynamically #28

CRSLEE opened this issue Jul 19, 2023 · 1 comment

Comments

@CRSLEE
Copy link
Contributor

CRSLEE commented Jul 19, 2023

Hi, im trying to Generate the OBIS Handlers dynamically to switch between different smart meter types.
Is there a working solution to achive this?
Ive spend a lot of time figuring out how to get the data dynamic but with no succsess :/

OBISHandler OBISHandlers[] = {
{{ 0x81, 0x81, 0xc7, 0x82, 0x03, 0xff }, &Manufacturer}, /* 129-129:199.130.3255 /
{{ 0x01, 0x00, 0x01, 0x08, 0x01, 0xff }, &PowerT1}, /
1- 0: 1. 8.1
255 (T1) /
{{ 0x01, 0x00, 0x01, 0x08, 0x00, 0xff }, &PowerSum}, /
1- 0: 1. 8.0255 (T1 + T2) /
{{ 0x01, 0x00, 0x0F, 0x07, 0x00, 0xff }, &PowerW}, /
1- 0: 15. 7.0
255 (Watt) */
{{ 0, 0 }}
};

@olliiiver
Copy link
Owner

Hi @CRSLEE . I think the best way to dynamically get the data would be to walk through the SML tree and parse the node with all the OBIS information. See also #14. However, I have not implemented that yet.

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

2 participants