Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 103323

Universal Media Remote to Control Marantz NR1501 AV Receiver via Broadlink RM Pro Plus

$
0
0

Hi! I somehow managed to create Universal Medial Player to control my Marantz receiver via IR commands. I use Broadlink RM Pro Plus to send them.

First of all, I want to share my experience and what I came up with in 2 days.

# Switches
switch:
  - platform: template
    switches:
      projector:
        unique_id: switch.projector
        friendly_name: Projector
        value_template: "{{ is_state('input_boolean.projector_state', 'on') }}"
        turn_on:
          service: script.projector_turn_on
        turn_off:
          service: script.projector_turn_off

input_text:
  marantz_av_receiver_state:
    name: Marantz AV Receiver - State
    icon: mdi:audio-video

input_number:
  marantz_av_receiver_volume_level:
    name: Marantz AV Receiver - Volume Level
    icon: mdi:volume-high
    min: 0
    max: 0.8
    step: 0.01
    mode: slider
  
input_boolean:
  marantz_av_receiver_mute:
    name: Marantz AV Receiver - Mute
    icon: mdi:volume-mute
  projector_state:
    name: Projector - State
    icon: mdi:projector
    
input_select:
  marantz_av_receiver_source:
    name: Marantz AV Receiver - Source
    options:
      - BD
      - GAME
      - DVD
      - DSS
      - VCR
      - CD
      - TUNE
      - AUX1
      - AUX2
    icon: mdi:video-input-component

media_player:
  name: Marantz AV Receiver
  platform: universal
  # device_class: receiver
  attributes:
    state: input_text.marantz_av_receiver_state
    is_volume_muted: input_boolean.marantz_av_receiver_mute
    volume_level: input_number.marantz_av_receiver_volume_level
    source: input_select.marantz_av_receiver_source
    source_list: input_select.marantz_av_receiver_source|options
  commands:
    turn_on:
      service: script.marantz_av_receiver_turn_on
    turn_off:
      service: script.marantz_av_receiver_turn_off
    volume_up:
      service: script.marantz_av_receiver_set_volume_level
      data:
        volume_level: "{{ states('input_number.marantz_av_receiver_volume_level') | float + 0.01 }}"
    volume_down:
      service: script.marantz_av_receiver_set_volume_level
      data:
        volume_level: "{{ states('input_number.marantz_av_receiver_volume_level') | float - 0.01 }}"
    volume_mute:
      service: script.marantz_av_receiver_mute_toggle
    select_source:
      service: script.marantz_av_receiver_set_source
      data:
        source: "{{ source }}"
    volume_set:
      service: script.marantz_av_receiver_set_volume_level
      data:
        volume_level: "{{ volume_level }}"

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 103323

Trending Articles