Archived
1
0
Fork 0

Software angepasst (und Dateien hinzugefügt)

This commit is contained in:
Findus23 2014-11-23 12:05:51 +01:00
parent aa9adc5fc2
commit d6ac2a1e59
4 changed files with 50 additions and 11 deletions

View file

@ -1,8 +1,7 @@
#!/bin/bash
zufall=0
PFAD="/var/www/" #Pfad zum Web-Verzeichnis
r=0 # Backup-Zahl auf Null setzen
IFS="; " #Spezial-Variable, enthält Trennzeichen zum Trennen von Luftdruck und -temperatur
IFS="; " #Spezial-Variable - enthält Trennzeichen zum Trennen von Luftdruck und -temperatur
re='^[0-9]+$' # Regulärer Ausdruck, ob Variable eine Zahl ist
pushbullet_api_key=$(cat /home/pi/Temperaturmessung/Fremddateien/pushbullet_settings.txt | head -n 1)
pushbullet_device=$(cat /home/pi/Temperaturmessung/Fremddateien/pushbullet_settings.txt | tail -n 1)
@ -27,13 +26,9 @@ then
fi
while true
do
uhrzeit=$(date +%Y/%m/%d\ %H:%M:%S) # z.B.: 2014/10/05 11:00:00 (für csv-Datei)
uhrzeit_display=$(date +%d.%m\ %H:%M:%S) # z.B.: 05.10 11:00:00 (für Display)
uhrzeit_lang=$(date +%d.%m.%y\ %H:%M:%S) # z.B.: 05.10.2014 11:00:00 (für Webinterface)
#zufall=$(($zufall + $((RANDOM % 10)) - 5)) # a um eine zufällige Zahl zwischen -5 und 5 ändern
##a=a+[Zufallszahl von 0-32767] modulo 10 (um eine Zahl von 0-10 zu bekommen) -5 (-> -5 bis 5)
#zufall=$a
rasp=$(/opt/vc/bin/vcgencmd measure_temp | cut -c 6,7,8,9) #Betriebstemberatur messen
temp1=$(echo "scale=3; $(grep 't=' /sys/bus/w1/devices/w1_bus_master1/10-000802b53835/w1_slave | awk -F 't=' '{print $2}') / 1000" | bc -l) #Innentemperatur
while [ "$temp1" == "-1.250" ] || [ "$temp1" == "85.000" ] || [ "$temp1" == "85.000" ]

BIN
main.pdf

Binary file not shown.

View file

@ -1,7 +1,18 @@
% This file was created with JabRef 2.10.
% Encoding: ISO8859_1
% Encoding: UTF8
@Online{verkauf,
Title = {@ruskin147 As of today, it looks like 3.8 million - that's an *awful lot of computers*.},
Author = {@Raspberry\_Pi},
Date = {2014-10-12},
Url = {https://twitter.com/Raspberry_Pi/status/521065388948586497},
Urldate = {2014-11-22},
Owner = {lukas},
Timestamp = {2014.11.22}
}
@Online{bmp058_adafruit,
Title = {Using the BMP085/180 with Raspberry Pi or Beaglebone Black},
Author = {{Adafruit User KEVIN TOWNSEND}},
@ -76,7 +87,7 @@
}
@Online{innenraum,
Title = {LEITFADEN F\"UR DIE INNENRAUMHYGIENE IN SCHULGEB\"AUDEN},
Title = {LEITFADEN FÜR DIE INNENRAUMHYGIENE IN SCHULGEBÄUDEN},
Author = {{Innenraumlufthygiene-Kommission des Umweltbundesamtes}},
Url = {http://www.umweltbundesamt.de/sites/default/files/medien/publikation/long/3689.pdf},
Year = {2008},
@ -96,6 +107,17 @@
Timestamp = {2014.10.17}
}
@Online{display_pollin,
Title = {LCD-Modul TC1602E-01},
Author = {Pollin.de},
Url = {http://www.pollin.de/shop/dt/OTc1OTc4OTk-/Bauelemente_Bauteile/Aktive_Bauelemente/Displays/LCD_Modul_TC1602E_01.html},
Year = {2014},
Urldate = {2014-11-23},
Owner = {lukas},
Timestamp = {2014.11.23}
}
@Online{aboutraspberry,
Title = {The Making of Pi},
Author = {{Raspberry Pi Foundation}},
@ -117,7 +139,7 @@
}
@Online{Velux,
Title = {VELUX Raumluftf\"uhler},
Title = {VELUX Raumluftfühler},
Author = {Velux},
Url = {http://www.velux.de/privatkunden/produkte/integra_system/produkte/produktempfehlung/raumluftfuehler},
Year = {2014},
@ -127,6 +149,17 @@
Timestamp = {2014.11.08}
}
@Online{conrad_datenblatt,
Title = {AV1624 Datasheet},
Author = {ANAG VISION},
Date = {2006-05-22},
Url = {http://conrad.ru/doci/tekstovyy_displey_stn_anag_vision_av1624gfbw_sj__seryy_181664_en.pdf},
Urldate = {2014-11-23},
Owner = {lukas},
Timestamp = {2014.11.23}
}
@Online{wiki:bus,
Title = {Bus--- Wikipedia{,} Die freie Enzyklopädie},
Author = {Wikipedia},
@ -147,7 +180,7 @@
}
@Online{VOC,
Title = {Fl\"uchtige organische Verbindung},
Title = {Flüchtige organische Verbindung},
Author = {{WISSEN Wiki}},
Url = {http://www.wissenwiki.de/index.php?title=Fl%C3%BCchtige_organische_Verbindung&oldid=41478},
Year = {2014},
@ -157,3 +190,14 @@
Timestamp = {2014.11.11}
}
@Online{schnatterente,
Title = {Raspberry Pi: 32 Zeichen Hitachi HD44780 Display},
Author = {www.schnatterente.net},
Date = {2014-10-10},
Url = {http://www.schnatterente.net/technik/raspberry-pi-32-zeichen-hitachi-hd44780-display#},
Urldate = {2014-11-23},
Owner = {lukas},
Timestamp = {2014.11.23}
}

View file

@ -14,5 +14,5 @@ Die Software, die verwendet wird, teilt sich in (?) Teile auf:
Das wichtigste Programm ist das Bash-Script \textit{main.sh}. Mithilfe eines Bash-Scriptes können Programme automatisiert gestartet und ihre Ausgaben ausgewertet werden.
\codeline{main.sh}{bash}{1}
Die Datei beginnt mit einem \textit{Shebang} (auch \textit{Magic Line}) genannt. Diese Zeile sagt dem Betriebssystem, womit die Datei ausgeführt werden soll.
\code{main.sh}{bash}{3}{14}
\code{main.sh}{bash}{2}{13}
Die folgenden Zeilen geben allgemeine Einstellungen an und definieren später gebrauchte Variablen. Man kann den Pfad zum Webserver, auf dem das Webinterface liegt, angeben. In Zeile 7 und 8 werden die Zugangsdaten für Pushbullet aus einer anderen Datei ausgelesen.