Skip to content

Add DZK Bacnet Thermostat Accessory#27

Open
elhernes wants to merge 19 commits intoApsysikal:masterfrom
elhernes:master
Open

Add DZK Bacnet Thermostat Accessory#27
elhernes wants to merge 19 commits intoApsysikal:masterfrom
elhernes:master

Conversation

@elhernes
Copy link
Copy Markdown

@elhernes elhernes commented Oct 9, 2022

This adds support for the Daikin DZK-BACNET-3 zone controller - https://backend.daikincomfort.com/docs/default-source/product-documents/residential/brochures/pf-dzkbac.pdf?sfvrsn=80c62826_14

Highlights:

  • dzk-bacnet.ts module for Thermostat Accessories (one per zone). Config is simple - just need the IP address of the DZK unit and the names for each zone.

  • added a couple accessor methods to bacnet/bacnet.ts to simplify the bacnet requests.

  • added more types to the objectStringParser (Multistate objects, etc)

@Apsysikal
Copy link
Copy Markdown
Owner

Hey, thank you a lot for the pull request.
On first sight, I really like your work, I'll try to have a look at it in the next few days. After I'm done I'd love to release a new package version.

I've let the automated tests run and they've come up with some linting errors. Maybe you could look at that until I've got some more time on my hands ;) But don't feel obliged to it.

@Apsysikal Apsysikal added the enhancement New feature or request label Oct 10, 2022
@elhernes
Copy link
Copy Markdown
Author

Hi Benedikt,

Thanks for the quick look. I have not used typescript before, so I was clearly breaking some of the rules regarding object and any. The latest commits show a clean lint.

-Eric

bac_ob = "cold-set-point";
break;
case DzkOperationMode.HEAT:
bac_ob = "heat-set-point";
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The switch statement seems to not be used. When returning, the calculations made in the switch statement aren't used. Is it meant to be this way?

/**
* Characteristic "Target Fan State"
*/
class TargetFanState {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to not be used. Only in commented out code. Is this meant to be removed oder is the commented out code meant to be not commented out?

}
}
},
"dzk-bacnet": {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is used in homebridge ui. With the current configuration the output is always at minimum some JSON-Object. I think the user should be able to remove some item completely or at least an empty object or array.

{
    "name": "BAChome Dynamic Platform",
    "dzk-bacnet": {
        "zones": [
            {
                "zone": 6
            }
        ]
    },
    "platform": "bachome"
}

Screenshot of the homebrige ui config screen

{
"platform": "bachome",
"name": "BAChome Dynamic Platform",
"dzk-bacnet": {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This maybe needs some refactoring after updating the config.schema.json

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

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants