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 service calls for LCN component #24105

Merged
merged 1 commit into from May 29, 2019

Conversation

Projects
None yet
3 participants
@alengwenus
Copy link
Contributor

commented May 25, 2019

Description:

Besides the already added LCN platforms, the LCN system offers a number of additional functions which cannot be directly represented by the platforms. In order to use these functionalities as well, this PR adds a bunch of service calls to the LCN component.

The implemented service calls are:

  • var_abs: Assign an absolute value to a hardware variable
  • var_rel: Shift the value of a hardware variable
  • var_reset: Reset the value of a hardware variable
  • led: Set lighting mode of hardware LEDs (on, off, blink, flicker)
  • lock_regulator: Lock a regulator setpoint
  • send_keys: Send hardware keys (which will execute hardware programmed commands)
  • lock_keys: Lock a hardware key (so it cannot be activated)
  • dyn_text: Send dynamic text to a LCN display
  • pck: Send an arbitrary PCK command
  • output_abs: Set absolute brightness of an output port with arbitrary transition time
  • output_rel: Set relative brightness of an output port with arbitrary transition time
  • output_toggle: Toggle an output port with arbitrary transition time
  • relays: Switch/Toggle arbitrary hardware relais

Pull request with documentation for home-assistant.io (if applicable): home-assistant/home-assistant.io#9516

Example entry for configuration.yaml (if applicable):

lcn:
  connections:
    - name: myhome
      host: 192.168.2.41
      port: 4114
      username: !secret lcn_username
      password: !secret lcn_password

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly. Update and include derived files by running python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt by running python3 -m script.gen_requirements_all.
  • Untested files have been added to .coveragerc.

@alengwenus alengwenus force-pushed the alengwenus:dev_lcn_service_calls branch from 0e365ab to 833fac7 May 25, 2019

@pvizeli pvizeli requested a review from balloob May 26, 2019

@balloob

This comment has been minimized.

Copy link
Member

commented May 29, 2019

I get a feeling here that everything has been made accessible as a service because we can. We should only make things accessible as a service if they are going to be used by users in automations.

@alengwenus

This comment has been minimized.

Copy link
Contributor Author

commented May 29, 2019

I get a feeling here that everything has been made accessible as a service because we can. We should only make things accessible as a service if they are going to be used by users in automations.

I just have directed myself to what was also implemented in the OpenHab binding. From the discussions in the forums I get the feeling that people indeed are using these functionalities. It‘s hard to say what people will use. I guess nothing‘s wrong about completeness?

@balloob balloob merged commit 50db622 into home-assistant:dev May 29, 2019

14 checks passed

build Workflow: build
Details
ci/circleci: pre-install-all-requirements Your tests passed on CircleCI!
Details
ci/circleci: pre-test 3.5.5 Your tests passed on CircleCI!
Details
ci/circleci: pre-test 3.6 Your tests passed on CircleCI!
Details
ci/circleci: pre-test 3.7 Your tests passed on CircleCI!
Details
ci/circleci: pylint Your tests passed on CircleCI!
Details
ci/circleci: static-check Your tests passed on CircleCI!
Details
ci/circleci: test 3.5.5 Your tests passed on CircleCI!
Details
ci/circleci: test 3.6 Your tests passed on CircleCI!
Details
ci/circleci: test 3.7 Your tests passed on CircleCI!
Details
cla-bot Everyone involved has signed the CLA
codecov/patch Coverage not affected when comparing c928f82...833fac7
Details
codecov/project 94.13% (target 90%)
Details
home-assistant Build #20190525.32 succeeded
Details

@alengwenus alengwenus deleted the alengwenus:dev_lcn_service_calls branch May 30, 2019

@balloob balloob referenced this pull request Jun 4, 2019

Merged

0.94.0 #24305

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.