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

Add minValue, maxValue and MinStep #131

Closed
NikDevx opened this issue Mar 28, 2021 · 5 comments
Closed

Add minValue, maxValue and MinStep #131

NikDevx opened this issue Mar 28, 2021 · 5 comments

Comments

@NikDevx
Copy link

NikDevx commented Mar 28, 2021

Hello @benzman81
You can add minValue, maxValue and MinStep for HttpWebHookThermostatAccessory.js
Need to add this function to line 35

.setProps({
        minValue: 17,
        maxValue: 30,
        minStep: 1
    });
@NikDevx
Copy link
Author

NikDevx commented Mar 28, 2021

@benzman81 I have already tested and it works :)

@benzman81
Copy link
Owner

@NikDevx Whats the setting for, and why these explicit numbers?

@NikDevx
Copy link
Author

NikDevx commented Mar 28, 2021

@NikDevx Whats the setting for, and why these explicit numbers?

@benzman81 this number will just show you an example
This will help you set the minimum and maximum temperature and the switching step for thermostat.

In your plugin, you can add variables and add new parameters to the config.
Like that:

    this.service.getCharacteristic(Characteristic.TargetTemperature).on('get', this.getTargetTemperature.bind(this)).on('set', this.setTargetTemperature.bind(this)).setProps({
        minValue: this.minTemp,
        maxValue: this.maxTemp,
        minStep: this.minStep
    });

@NikDevx
Copy link
Author

NikDevx commented Mar 29, 2021

@benzman81 #133

@benzman81
Copy link
Owner

Fixed in 0.1.15.

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