{"id":154,"date":"2014-06-28T20:01:19","date_gmt":"2014-06-28T17:01:19","guid":{"rendered":"http:\/\/www.bashpi.org\/?page_id=154"},"modified":"2020-12-03T17:33:49","modified_gmt":"2020-12-03T15:33:49","slug":"how-to-get-byvac-bv4627-relay-controller-working-with-bash-automated","status":"publish","type":"page","link":"https:\/\/www.bashpi.org\/?page_id=154","title":{"rendered":"How to get ByVac BV4627 relay controller working with bash (automated)"},"content":{"rendered":"<p><strong>This how-to has multiple pages.&nbsp;This page is about automated configuration. Previous, advanced configuration page is available <a title=\"How to get ByVac BV4627 relay controller working with bash (advanced)\" href=\"http:\/\/www.bashpi.org\/?page_id=111\">here<\/a><\/strong><\/p>\n<p>This page is about configuring BV4627 board automatically e.g. doing all actions what were discussed on <a title=\"How to get ByVac BV4627 relay controller working with bash (advanced)\" href=\"http:\/\/www.bashpi.org\/?page_id=111\">advanced configuration page<\/a> with script. Additionally automated configuration will create some sudo rules.<\/p>\n<p>First thing you need is to download few kilobytes of code:&nbsp; <a href=\"http:\/\/www.bashpi.org\/wp-content\/uploads\/2014\/06\/relay_1.2.tar.gz\">relay.tar.gz<\/a><\/p>\n<p>After that put the file to your Raspberry Pi or PC, unpack and run configuration as shown below.<\/p>\n<pre><code class=\"language-bash\">tar -xzvf relay*.tar.gz\ncd relay\/\nsudo .\/configure.sh configure\n<\/code><\/pre>\n<p>Now its time to plug in the board to USB and wait about 15 sec.<\/p>\n<p>Test board with command below where &lt;serial&gt; is replaced with your board serialnumber. If you want, you can create board aliases in the relay.sh script to ease up usage in the future.<\/p>\n<pre><code class=\"language-bash\">\nsudo -u relay \/home\/relay\/relay.sh &lt;serial&gt; a on 0\n<\/code><\/pre>\n<p>If you dont know your board&#8217;s serial, read <a title=\"How to get ByVac BV4627 relay controller working with bash (advanced)\" href=\"http:\/\/www.bashpi.org\/?page_id=111\">previous page<\/a>.<\/p>\n<p>Scripts in this page were tested on:<\/p>\n<ul>\n<li>Raspberry Pi Model B 512MB RAM. OS: Raspbian Wheezy, released in 2014-01-07. All updates installed on 1. september 2014.<\/li>\n<li>Almost random pc with x86-64 architecture, running Ubuntu 12.04 (precise)<\/li>\n<\/ul>\n<p>Thats it about relays and configuration. Now its time to move mountains with them!<\/p>\n<p>If you found this useful, say thanks, click on some banners or <a href=\"http:\/\/www.bashpi.org\/?page_id=105\">donate<\/a>, I can always use some beer money.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This how-to has multiple pages.&nbsp;This page is about automated configuration. Previous, advanced configuration page is available here This page is about configuring BV4627 board automatically e.g. doing all actions what were discussed on advanced configuration page with script. Additionally automated configuration will create some sudo rules. First thing you need is to download few kilobytes [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":111,"menu_order":0,"comment_status":"closed","ping_status":"open","template":"","meta":{"footnotes":""},"class_list":["post-154","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.bashpi.org\/index.php?rest_route=\/wp\/v2\/pages\/154","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.bashpi.org\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.bashpi.org\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.bashpi.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.bashpi.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=154"}],"version-history":[{"count":11,"href":"https:\/\/www.bashpi.org\/index.php?rest_route=\/wp\/v2\/pages\/154\/revisions"}],"predecessor-version":[{"id":770,"href":"https:\/\/www.bashpi.org\/index.php?rest_route=\/wp\/v2\/pages\/154\/revisions\/770"}],"up":[{"embeddable":true,"href":"https:\/\/www.bashpi.org\/index.php?rest_route=\/wp\/v2\/pages\/111"}],"wp:attachment":[{"href":"https:\/\/www.bashpi.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=154"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}