Site updated at 2017-03-18 17:12:07 UTC

This commit is contained in:
Travis CI 2017-03-18 17:12:07 +00:00
parent 7573fcba68
commit 67179bf8fe
994 changed files with 1768 additions and 68252 deletions

View file

@ -3,17 +3,14 @@
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!--> <html> <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Broadlink RM Switch - Home Assistant</title>
<meta name="author" content="Home Assistant">
<meta name="description" content="Instructions how to have Broadlink RM switches.">
<meta name="viewport" content="width=device-width">
<link rel="canonical" href="https://home-assistant.io/components/switch.broadlink/">
<meta property="fb:app_id" content="338291289691179">
<meta property="og:title" content="Broadlink RM Switch">
<meta property="og:site_name" content="Home Assistant">
@ -21,39 +18,31 @@
<meta property="og:type" content="article">
<meta property="og:description" content="Instructions how to have Broadlink RM switches.">
<meta property="og:image" content="https://home-assistant.io/images/default-social.png">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:site" content="@home_assistant">
<meta name="twitter:title" content="Broadlink RM Switch">
<meta name="twitter:description" content="Instructions how to have Broadlink RM switches.">
<meta name="twitter:image" content="https://home-assistant.io/images/default-social.png">
<link href="/stylesheets/screen.css" media="screen, projection" rel="stylesheet">
<link href="/atom.xml" rel="alternate" title="Home Assistant" type="application/atom+xml">
<link rel='shortcut icon' href='/images/favicon.ico' />
<link rel='icon' type='image/png' href='/images/favicon-192x192.png' sizes='192x192' />
</head>
<body >
<header>
<div class="grid-wrapper">
<div class="grid">
<div class="grid__item three-tenths lap-two-sixths palm-one-whole ha-title">
<a href="/" class="site-title">
<img width='40' src='/demo/favicon-192x192.png'>
<span>Home Assistant</span>
</a>
</div>
<div class="grid__item seven-tenths lap-four-sixths palm-one-whole">
<nav>
<input type="checkbox" id="toggle">
<label for="toggle" class="toggle" data-open="Main Menu" data-close="Close Menu"></label>
<ul class="menu pull-right">
<li><a href="/getting-started/">Getting started</a></li>
<li><a href="/components/">Components</a></li>
<li><a href="/docs/">Docs</a></li>
@ -64,36 +53,21 @@
</ul>
</nav>
</div>
</div>
</div>
</header>
<div class="grid-wrapper">
<div class="grid grid-center">
<div class="grid__item two-thirds lap-one-whole palm-one-whole">
<article class="page">
<header>
<h1 class="title indent">
Broadlink RM Switch
</h1>
</header>
<hr class="divider">
<p>This <code class="highlighter-rouge">Broadlink</code> switch platform allow to you control Broadlink <a href="http://www.ibroadlink.com/rm/">devices</a>.</p>
<p>To enable it, add the following lines to your <code class="highlighter-rouge">configuration.yaml</code>:</p>
<div class="language-yaml highlighter-rouge"><pre class="highlight"><code><span class="c1"># Example configuration.yaml entry</span>
<span class="s">switch</span><span class="pi">:</span>
<span class="s">platform</span><span class="pi">:</span> <span class="s">broadlink</span>
@ -105,9 +79,7 @@
<span class="s">command_off</span><span class="pi">:</span> <span class="s1">'</span><span class="s">switch_packet</span><span class="nv"> </span><span class="s">off'</span>
</code></pre>
</div>
<p>Configuration variables:</p>
<ul>
<li><strong>host</strong> (<em>Required</em>): The hostname/IP address to connect to.</li>
<li><strong>mac</strong> (<em>Required</em>): Device mac address.</li>
@ -126,15 +98,10 @@
</ul>
</li>
</ul>
<p>Information about how to install on Windows can be found <a href="https://home-assistant.io/components/sensor.broadlink/#microsoft-windows-installation">here</a></p>
<h3><a class="title-link" name="how-to-obtain-irrf-packets" href="#how-to-obtain-irrf-packets"></a> How to obtain IR/RF packets?</h3>
<p>Choose Call Service from the Developer Tools. Choose the service broadlink/learn_command from the list of Available services: and hit CALL SERVICE. Press the button on your remote with in 20 seconds. The packet will be printed in the log and as a persistent notification.</p>
<p>Example config for rm, rm2, rm_mini, rm_pro_phicomm, rm2_home_plus, rm2_home_plus_gdt, rm2_pro_plus, rm2_pro_plus2, rm2_pro_plus_bl and rm_mini_shate devices:</p>
<div class="language-yaml highlighter-rouge"><pre class="highlight"><code><span class="s">switch 2</span><span class="pi">:</span>
<span class="s">platform</span><span class="pi">:</span> <span class="s">broadlink</span>
<span class="s">host</span><span class="pi">:</span> <span class="s">192.168.1.2</span>
@ -182,9 +149,7 @@
</code></pre>
</div>
<p>Example config for sp1, sp2, honeywell_sp2, sp3, spmini2 and spminiplus devices:</p>
<div class="language-yaml highlighter-rouge"><pre class="highlight"><code><span class="s">switch 1</span><span class="pi">:</span>
<span class="s">platform</span><span class="pi">:</span> <span class="s">broadlink</span>
<span class="s">host</span><span class="pi">:</span> <span class="s">IP_ADDRESS</span>
@ -201,11 +166,8 @@
</code></pre>
</div>
<h3><a class="title-link" name="service-send_packet" href="#service-send_packet"></a> Service <code class="highlighter-rouge">send_packet</code></h3>
<p>You can use the service broadlink/send_packet to directly send IR packets without the need to assign a switch entity for each command.</p>
<table>
<thead>
<tr>
@ -222,9 +184,7 @@
</tr>
</tbody>
</table>
<p>Example:</p>
<div class="language-yaml highlighter-rouge"><pre class="highlight"><code><span class="s">script</span><span class="pi">:</span>
<span class="s">tv_select_source</span><span class="pi">:</span>
<span class="s">sequence</span><span class="pi">:</span>
@ -235,41 +195,31 @@
<span class="pi">-</span> <span class="s2">"</span><span class="s">JgBGAJSTFDUUNhM2ExITEhMSExITEhM2EzYTNhQRFBEUERQRFBEUNRQ2ExITNhMSExITNhMSExITEhM2ExITNhQ1FBEUNhMADQUAAA=="</span>
</code></pre>
</div>
<h3><a class="title-link" name="using-e-control-remotes" href="#using-e-control-remotes"></a> Using E-Control Remotes</h3>
<p>If you already have your remotes learned on E-Control app you can use this method to “copy” trem to HA.</p>
<p>First get or learn all the remotes you want to add on HA in E-Control</p>
<ol>
<li>
<p>Download</p>
<p>Get the script from <a href="https://github.com/NightRang3r/Broadlink-e-control-db-dump">here</a>.</p>
</li>
<li>
<p>Dump the data from the app</p>
<p>Open the E-Control app on your mobile device. On the left side menu choose “Share” and then “Share to other phones in WLAN”. It will generate the files you will need for the script.</p>
</li>
<li>
<p>Get data from your Android device</p>
<p>Connect your Android device to your computer and browse the SD card / External Storage folder “/broadlink/newremote/SharedData/”. You need to get the following files and put them in the same folder as this script.:</p>
<p>jsonSubIr
jsonButton
jsonIrCode</p>
</li>
<li>
<p>Install Requirements</p>
<p>Run <code class="highlighter-rouge">pip install simplejson</code>. You must install simplejson in the same python version you will use to run the scripts. You can ensure that the current version is installed by attempting to install again and confirming that you see “Requirement already satisfied”.</p>
</li>
<li>
<p>Get the data from the device</p>
<p>Navigate to the folder you downloaded and run <code class="highlighter-rouge">python getBroadlinkSharedData.py</code>. Follow the steps on screen. NOTE: These scripts were only tested with Python 2.7.</p>
</li>
<li>
@ -291,18 +241,10 @@ Not every code works.</p>
<li>Convert the hex codes to base64
Use <a href="http://tomeko.net/online_tools/hex_to_base64.php?lang=en1">this</a> tool to convert the hex codes to base64 for use with Home Assistant.</li>
</ol>
</article>
</div>
<aside id="sidebar" class="grid__item one-third lap-one-whole palm-one-whole">
<div class="grid">
<section class="aside-module grid__item one-whole lap-one-half">
<div class='edit-github'><a href='https://github.com/home-assistant/home-assistant.github.io/tree/current/source/_components/switch.broadlink.markdown'>Edit this page on GitHub</a></div>
<div class='brand-logo-container section'>
@ -485,13 +427,10 @@ Use <a href="http://tomeko.net/online_tools/hex_to_base64.php?lang=en1">this</a>
</ul>
</div>
</section>
</div>
</aside>
</div>
</div>
<footer>
<div class="grid-wrapper">
<div class="grid">
@ -501,7 +440,6 @@ Use <a href="http://tomeko.net/online_tools/hex_to_base64.php?lang=en1">this</a>
<a rel="me" href='https://facebook.com/homeassistantio'><i class="icon-facebook"></i></a>
<a rel="me" href='https://plus.google.com/110560654828510104551'><i class="icon-google-plus"></i></a>
<a rel="me" href='https://github.com/home-assistant/home-assistant'><i class="icon-github"></i></a>
<div class="credit">
Contact us at <a href='mailto:hello@home-assistant.io'>hello@home-assistant.io</a>.<br>
Website powered by <a href='http://jekyllrb.com/'>Jekyll</a> and the <a href='https://github.com/coogie/oscailte'>Oscalite theme</a>.<br />
@ -513,7 +451,6 @@ Use <a href="http://tomeko.net/online_tools/hex_to_base64.php?lang=en1">this</a>
</div>
</div>
</footer>
<script>
var _gaq=[['_setAccount','UA-57927901-1'],['_trackPageview']];
(function(d,t){var g=d.createElement(t),s=d.getElementsByTagName(t)[0];
@ -521,4 +458,4 @@ Use <a href="http://tomeko.net/online_tools/hex_to_base64.php?lang=en1">this</a>
s.parentNode.insertBefore(g,s)}(document,'script'));
</script>
</body>
</html>
</html>