Difference between revisions of "HomeAutomation and Tellstick"

From BubbaWiki
Jump to navigation Jump to search
Line 3: Line 3:
<br>  
<br>  


= Installera Tellstick  =
= Install Tellstick  =


'''Utgångsläge'''<br>  
'''Conditions'''<br>  


*Tellstick ej ansluten<br>  
*Tellstick not connected to B3<br>  
*Inloggad som root B3
*Logged in as root on B3


<br>  
<br>  


1. Hämta paket och installera paket för att kompilera egna program<br>  
1. Install packet for compiling on B3<br>  
<pre>apt-get install cmake</pre><pre>apt-get install build-essential</pre>  
<pre>apt-get install cmake</pre><pre>apt-get install build-essential</pre>  
<br>  
<br>  


2. Installera paket som telldus behöver för kompilering<br>  
2. Install packet needed by Telldus <br>  
<pre>apt-get install libconfuse-dev libqt4-dev help2man
<pre>apt-get install libconfuse-dev libqt4-dev help2man
</pre>  
</pre>  
<br>  
<br>  


3. Hämta hem mjukvaran till Tellstick o packa upp. Använd senaste tellstick core: http://download.telldus.se/TellStick/Software/telldus-core/.<br>  
3. Download the latest software for Tellstick and extract. Use the latest tellstick core found at: http://download.telldus.se/TellStick/Software/telldus-core/.<br>  
<pre>wget http://download.telldus.se/TellStick/Software/telldus-core/telldus-core-2.0.4.tar.gz</pre><pre>tar xvfz telldus-core-2.0.4.tar.gz</pre><pre>cd telldus-core</pre>  
<pre>wget http://download.telldus.se/TellStick/Software/telldus-core/telldus-core-2.0.4.tar.gz</pre><pre>tar xvfz telldus-core-2.0.4.tar.gz</pre><pre>cd telldus-core</pre>  
<br>4. Bygg tdtool och rfcmd, med följande kommando:
<br>4. Build tdtool and rfcmd.
<pre>cmake -DBUILD_LIBTELLDUS-CORE=1 -DBUILD_TDTOOL=1 -DBUILD_RFCMD_WITH_LIBFTDI=0 -DGENERATE_MAN=1</pre><pre>make</pre><pre>make install</pre>  
<pre>cmake -DBUILD_LIBTELLDUS-CORE=1 -DBUILD_TDTOOL=1 -DBUILD_RFCMD_WITH_LIBFTDI=0 -DGENERATE_MAN=1</pre><pre>make</pre><pre>make install</pre>  
<br>5. Edit the file /etc/ld.so.conf.d/local.conf (if not excisting, add the file):  
<br>5. Edit the file /etc/ld.so.conf.d/local.conf (if not excisting, add the file):  
Line 32: Line 32:
<br>  
<br>  


6. Kör sen:  
6. Then run:  
<pre>ldconfig</pre><pre>rm -f /var/state/telldus-core.conf</pre>  
<pre>ldconfig</pre><pre>rm -f /var/state/telldus-core.conf</pre>  
<br>7. Sätt i Tellstick i B3  
<br>7. Insert the Tellstick into B3  


8. För att lägga till mottagarenheter, editera filen /etc/tellstick.conf  
8. To add receiver units, edit the file /etc/tellstick.conf  
<pre>nano /etc/tellstick.conf</pre>  
<pre>nano /etc/tellstick.conf</pre>  
Anpassa configfilen efter dina switchar, i detta fallet: 1st NEXA NEYCR-1000 och 1st NEXA LWMR-210.  
Adjust the config file to your receiver units. In this case: 1pcs NEXA NEYCR-1000 and 1pcs NEXA LWMR-210.  
<pre>deviceNode = "/dev/tellstick"
<pre>deviceNode = "/dev/tellstick"
device {
device {

Revision as of 10:12, 29 August 2011

This guide will help you to install the fantastic software HomeAutomation and the very neat piece of hardware Telldus Tellstick on a B3. The information here is collected from various threads on http://forum.excito.net/.


Install Tellstick

Conditions

  • Tellstick not connected to B3
  • Logged in as root on B3


1. Install packet for compiling on B3

apt-get install cmake
apt-get install build-essential


2. Install packet needed by Telldus

apt-get install libconfuse-dev libqt4-dev help2man


3. Download the latest software for Tellstick and extract. Use the latest tellstick core found at: http://download.telldus.se/TellStick/Software/telldus-core/.

wget http://download.telldus.se/TellStick/Software/telldus-core/telldus-core-2.0.4.tar.gz
tar xvfz telldus-core-2.0.4.tar.gz
cd telldus-core


4. Build tdtool and rfcmd.

cmake -DBUILD_LIBTELLDUS-CORE=1 -DBUILD_TDTOOL=1 -DBUILD_RFCMD_WITH_LIBFTDI=0 -DGENERATE_MAN=1
make
make install


5. Edit the file /etc/ld.so.conf.d/local.conf (if not excisting, add the file):

nano /etc/ld.so.conf.d/local.conf

Add the following line:

/usr/local/lib 


6. Then run:

ldconfig
rm -f /var/state/telldus-core.conf


7. Insert the Tellstick into B3

8. To add receiver units, edit the file /etc/tellstick.conf

nano /etc/tellstick.conf

Adjust the config file to your receiver units. In this case: 1pcs NEXA NEYCR-1000 and 1pcs NEXA LWMR-210.

deviceNode = "/dev/tellstick"
device {
id = 1
name = "Office"
protocol = "arctech"
model = "codeswitch"
parameters {
house = "112233"
unit = "1"
}
}

device {
id = 2
name = "Outside"
protocol = "arctech"
model = "selflearning-dimmer"
parameters {
house = "445566"
unit = "1"
}
} 

Change the parameter "house" to a randomly choosen number. The uniqe numbers will make sure your units do not interfear with other units.

Installera HomeAutomation


1. Installera AT för schemaläggning:

apt-get install at

2. Plocka bort www-data från filerna: /etc/cron.deny, /etc/at.deny, /etc/cron.allow and /etc/at.allow files (if they exist).

nano /etc/at.deny

3. Ladda ner senaste HomeAutomation-mjukvara till din PC. http://karpero.mine.nu/ha/index.php?page=download&hl=sv_SE

4. Packa upp i /home/web/HApå din B3

5. Editera konfigurationsfilen /home/web/HA/config_sample_linux.php. Sätt sökvägen i filen till: /home/web/HA .

6. Döp om konfigurationsfilen config_sample_linux.php till config.php

7. Sätt tidszon för Appache2. Editera filen php.ini.

nano /etc/php5/apache2/php.ini

Ändra date.timezone till följande:

”date.timezone = Europe/Stockholm”


8. Starta om B3 för att php-ändringarna ska ta

9. Installera myPhPAdmin på B3.

apt-get install phpMyAdmin

10. Lägg till en databas för HomeAutomation.

mysqladmin create <välj-databas-namn>

11. Logga in på http://b3/HA/ och följ instruktionerna.

12. För databasen: ange databasnamnet du skapat

12.1. Usr: root

12.2. Psw: ”” (dvs tomt)

Konfigurering av dina enheter i HomeAutomation

1. Logga in via UIt http://b3/HA/

2. Uppdatera enheter från tellstick under menyn ”Enheter”

3. Inlärning av Nexa-enheter från web-UIt :

3.1. Tryck på learn-knappen på NEXA

3.2. Slå på din enhet under menyn Enheter.

3.3. Se till att din enhet blir syncad med Tellsticken.. dvs blinkar.