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

mbus-serial-request-data only gets correct data if mbus-serial-request-data-multi-reply is called before #180

Open
meberli opened this issue Aug 25, 2020 · 2 comments

Comments

@meberli
Copy link

meberli commented Aug 25, 2020

when reading a sontex heat outlet with command line tools I found a strange behaviour:

  • mbus-serial-request-data returns 18 records with only entries with unit 'Volume' - makes no sense to me
  • mbus-serial-request-data-multi-reply returns 102 records
  • after the execution of mbus-serial-request-data-multi-reply all subsequent reads with mbus-serial-request-data return correct result: 24 records with all correct informations

And if mbus-serial-request-data-multi-reply is executed again, the whole thing starts from the beginning...

@ttjaden
Copy link

ttjaden commented Mar 5, 2021

For me it's the same with the following hardware:

  • Relay M-Bus Mikro-Master
  • Zensus C5-ISF Meter

If i first do
mbus-serial-request-data-multi-reply -b 2400 /dev/ttyUSB0 2
i get the output, see:
01_mbus-serial-request-data-multi-reply.log

Afterwards I do
mbus-serial-request-data -b 2400 /dev/ttyUSB0 2
and get:
02_mbus-serial-request-data.log

But without doing the first command, or by doing the command twice, at least the following information is missing in when calling mbus-serial-request-data -b 2400 /dev/ttyUSB0 2:

 <DataRecord id="9">
        <Function>Instantaneous value</Function>
        <StorageNumber>0</StorageNumber>
        <Unit>Flow temperature (1e-2 deg C)</Unit>
        <Value>2972</Value>
        <Timestamp>2021-03-05T21:34:14Z</Timestamp>
    </DataRecord>

    <DataRecord id="10">
        <Function>Instantaneous value</Function>
        <StorageNumber>0</StorageNumber>
        <Unit>Return temperature (1e-2 deg C)</Unit>
        <Value>2261</Value>
        <Timestamp>2021-03-05T21:34:14Z</Timestamp>
    </DataRecord>

    <DataRecord id="11">
        <Function>Instantaneous value</Function>
        <StorageNumber>0</StorageNumber>
        <Unit>Temperature Difference (1e-2  deg C)</Unit>
        <Value>711</Value>
        <Timestamp>2021-03-05T21:34:14Z</Timestamp>
    </DataRecord>

    <DataRecord id="12">
        <Function>Instantaneous value</Function>
        <StorageNumber>0</StorageNumber>
        <Unit>Power (100 W)</Unit>
        <Value>0</Value>
        <Timestamp>2021-03-05T21:34:14Z</Timestamp>
    </DataRecord>

    <DataRecord id="13">
        <Function>Instantaneous value</Function>
        <StorageNumber>0</StorageNumber>
        <Unit>Volume flow (m m^3/h)</Unit>
        <Value>0</Value>
        <Timestamp>2021-03-05T21:34:14Z</Timestamp>
    </DataRecord>

    <DataRecord id="14">
        <Function>Instantaneous value</Function>
        <StorageNumber>0</StorageNumber>
        <Unit>Time Point (time &amp; date)</Unit>
        <Value>2021-03-05T22:14:00</Value>
        <Timestamp>2021-03-05T21:34:14Z</Timestamp>
    </DataRecord>

    <DataRecord id="15">
        <Function>Instantaneous value</Function>
        <StorageNumber>0</StorageNumber>
        <Unit>Operating time (hours)</Unit>
        <Value>12975</Value>
        <Timestamp>2021-03-05T21:34:14Z</Timestamp>
    </DataRecord>

@Apollon77
Copy link
Contributor

I can proof the basic solution to send a rest to the respective device address working. I basically only added the lines here and left "Init_slaves" as is.

Apollon77/node-mbus@95d02e1#diff-e8fba70aee8fbbcfc020c8266880774a1f474f09f3f8c5ffb5a1a76254712038R305-R320

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