Backup
2
.gitignore
vendored
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
public
|
||||||
|
release.sh
|
6
archetypes/default.md
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
title: "{{ replace .Name "-" " " | title }}"
|
||||||
|
date: {{ .Date }}
|
||||||
|
draft: true
|
||||||
|
---
|
||||||
|
|
49
config.toml
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
baseURL = "https://www.kekskurse.de/"
|
||||||
|
languageCode = "en-us"
|
||||||
|
title = "Kekskurse"
|
||||||
|
theme="archie"
|
||||||
|
|
||||||
|
[params]
|
||||||
|
mode="auto"
|
||||||
|
featherIconsCDN=false
|
||||||
|
subtitle = "Private Webpage"
|
||||||
|
|
||||||
|
[[params.social]]
|
||||||
|
name = "GitHub"
|
||||||
|
icon = "github"
|
||||||
|
url = "https://github.com/kekskurse"
|
||||||
|
|
||||||
|
[[params.social]]
|
||||||
|
name = "Twitter"
|
||||||
|
icon = "twitter"
|
||||||
|
url = "https://twitter.com/kekskurse"
|
||||||
|
|
||||||
|
[[params.social]]
|
||||||
|
name = "Instagram"
|
||||||
|
icon = "instagram"
|
||||||
|
url = "https://instagram.com/kekskurse"
|
||||||
|
|
||||||
|
[[menu.main]]
|
||||||
|
name = "Blog"
|
||||||
|
url = "/tags/blog/"
|
||||||
|
weight = 10
|
||||||
|
|
||||||
|
|
||||||
|
[[menu.main]]
|
||||||
|
name = "Images"
|
||||||
|
url = "/gallery/"
|
||||||
|
weight = 30
|
||||||
|
|
||||||
|
|
||||||
|
[[menu.main]]
|
||||||
|
name = "Contact"
|
||||||
|
url = "/about"
|
||||||
|
weight = 40
|
||||||
|
|
||||||
|
[taxonomies]
|
||||||
|
tag = "tags"
|
||||||
|
category = "categories"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
7
content/about.md
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
---
|
||||||
|
title: "About"
|
||||||
|
date: 2020-10-01T14:49:09+02:00
|
||||||
|
draft: false
|
||||||
|
---
|
||||||
|
|
||||||
|
Mail: hello [at] kekskurse.de
|
7
content/gallery.md
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
---
|
||||||
|
title: "Gallery"
|
||||||
|
date: 2020-10-01T14:49:09+02:00
|
||||||
|
draft: true
|
||||||
|
hideDate: true
|
||||||
|
---
|
||||||
|
{{<gallery-all>}}
|
12
content/posts/2020-06-30-Kasterne-Vogelsang.md
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
---
|
||||||
|
title: "Kaserne Vogelsang"
|
||||||
|
date: 2020-06-30T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
tags: ["Lost Places"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/06/kaserne-vogelsang/DSC03651.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/06/kaserne-vogelsang" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
11
content/posts/2020-07-01-Meseberg.md
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
---
|
||||||
|
title: "Meseberg"
|
||||||
|
date: 2020-07-01T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/07/meseberg/DSC03707.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/07/meseberg" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
11
content/posts/2020-07-01-Natur.md
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
---
|
||||||
|
title: "Natur"
|
||||||
|
date: 2020-07-01T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/07/natur/DSC03483.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/07/natur" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
11
content/posts/2020-07-02-Sterne.md
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
---
|
||||||
|
title: "Sterne"
|
||||||
|
date: 2020-07-02T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/07/sterne/DSC03784.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/07/sterne" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
12
content/posts/2020-07-11-Königin-Elisabeth-Hospital.md
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
---
|
||||||
|
title: "Königin-Elisabeth-Hospital"
|
||||||
|
date: 2020-07-11T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
tags: ["Lost Places"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/07/koenigin-elisabeth-hospital/DSC03990.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/07/koenigin-elisabeth-hospital" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
12
content/posts/2020-08-01-Flugplatz-Rangsdorf.md
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
---
|
||||||
|
title: "Flugplatz Rangsdorf"
|
||||||
|
date: 2020-08-01T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
tags: ["Lost Places"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/08/flugplatz-rangsdorf/DSC04292.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/08/flugplatz-rangsdorf" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
11
content/posts/2020-08-19-Birkenwerder.md
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
---
|
||||||
|
title: "Birkenwerder"
|
||||||
|
date: 2020-08-19T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/08/birkenwerder/DSC04866.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/08/birkenwerder" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
11
content/posts/2020-09-06-Fürstenberg.md
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
---
|
||||||
|
title: "Fürstenberg"
|
||||||
|
date: 2020-09-06T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/09/fuerstenberg/DSC05990.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/09/fuerstenberg" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
12
content/posts/2020-09-06-Haus-der-Offiziere.md
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
---
|
||||||
|
title: "Haus der Offiziere"
|
||||||
|
date: 2020-09-06T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
tags: ["Lost Places"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/09/haus-der-offiziere/DSC05619.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/09/haus-der-offiziere" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
13
content/posts/2020-09-06-Kraftfuttermischwerk.md
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
---
|
||||||
|
title: "Kraftfuttermischwerk"
|
||||||
|
date: 2020-09-06T16:31:55+02:00
|
||||||
|
draft: false
|
||||||
|
categories: ["Images"]
|
||||||
|
description: "Image Gallery"
|
||||||
|
tags: ["Lost Places"]
|
||||||
|
startpage: false
|
||||||
|
lang: img
|
||||||
|
gallery: "/img/2020/09/kraftfuttermischwerk/DSC05547.jpg"
|
||||||
|
---
|
||||||
|
|
||||||
|
{{< gallery dir="img/2020/09/kraftfuttermischwerk" caption-position="none" caption-effect="fade" />}} {{< load-photoswipe >}}
|
81
content/posts/2020-10-01-Edifier-remote.md
Normal file
|
@ -0,0 +1,81 @@
|
||||||
|
---
|
||||||
|
title: "Edifier R1700BT Remote Control"
|
||||||
|
date: 2020-10-01T14:44:25+02:00
|
||||||
|
draft: false
|
||||||
|
description: "Use a Wemos to create an mqtt-based remote control"
|
||||||
|
tags: ["WeMos", "Arduino", "Blog"]
|
||||||
|
categories: ["Electronics"]
|
||||||
|
startpage: true
|
||||||
|
lang: gb
|
||||||
|
---
|
||||||
|
|
||||||
|
After I got the Edifier R1700BT Speaker I notice that i want to control them like all my other stuff with my moile phone and MQTT. So i got some IR reciver and LEDs to simulate the Edifier Remote with a Wemos who is connected to my MQTT Server.
|
||||||
|
|
||||||
|
{{< tweet 1310694353187344385 >}}
|
||||||
|
|
||||||
|
I figure out the IR-Codes used:
|
||||||
|
|
||||||
|
* 149389439 -> power on/off
|
||||||
|
* 149356799 -> mute
|
||||||
|
* 149369039 -> Volume Up
|
||||||
|
* 149393519 -> Volume Down
|
||||||
|
* 149377199 -> Switch input to Bluetooth
|
||||||
|
* 149399639 -> Switch input to Line In
|
||||||
|
|
||||||
|
## Hardware
|
||||||
|
|
||||||
|
I connected the IR-LED to the D4 Pin of a Wemos. I used [this question](https://antwortenhier.me/q/wie-steuere-ich-die-ir-led-mit-esp8266-pint-bei-3-3-v-und-mosfet-um-einen-62376266277) as basic idea.
|
||||||
|
|
||||||
|
{{< figure src="/img/2020/10/ir-remote/plan.png" >}}
|
||||||
|
|
||||||
|
## Software
|
||||||
|
|
||||||
|
With this Numbers, and the [pubsubclient](https://github.com/knolleary/pubsubclient) and [IRremoteESP8266](https://github.com/crankyoldgit/IRremoteESP8266) i just can subscripe to some topics, and every time a message aravid at one of the topics i could send the code to the speaker:
|
||||||
|
|
||||||
|
```
|
||||||
|
if(String(topic)=="musik/power") {
|
||||||
|
irsend.sendNEC(149389439, 32);
|
||||||
|
Serial.println("EDIFIER: Power");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/mute") {
|
||||||
|
irsend.sendNEC(149356799, 32);
|
||||||
|
Serial.println("EDIFIER: Mute");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/down") {
|
||||||
|
irsend.sendNEC(149369039, 32);
|
||||||
|
Serial.println("EDIFIER: Down");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/up") {
|
||||||
|
irsend.sendNEC(149393519, 32);
|
||||||
|
Serial.println("EDIFIER: UP");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/bluetooth") {
|
||||||
|
irsend.sendNEC(149377199, 32);
|
||||||
|
Serial.println("EDIFIER: Bluetooth");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/line") {
|
||||||
|
irsend.sendNEC(149399639, 32);
|
||||||
|
Serial.println("EDIFIER: Line");
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## Final Result
|
||||||
|
|
||||||
|
After solder everything to a perforated board I got the following result.
|
||||||
|
|
||||||
|
{{< figure src="/img/2020/10/ir-remote/result.jpg" >}}
|
||||||
|
|
||||||
|
Maybe I will create another smaller version to hide next to the speaker. For now it works.
|
||||||
|
|
||||||
|
## Complete Code
|
||||||
|
|
||||||
|
|
||||||
|
You can got the complete code here: [Complete Code](/code/ir-wemos-mosfet.txt)
|
||||||
|
|
||||||
|
|
||||||
|
{{< load-photoswipe >}}
|
41
content/posts/2020-10-03-spaziergang-gruenau.md
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
---
|
||||||
|
title: "Spaziergang Grünau"
|
||||||
|
date: 2020-10-03T14:44:25+02:00
|
||||||
|
draft: false
|
||||||
|
description: "Spaziergang in Grünau"
|
||||||
|
tags: ["Lost Places", "Blog"]
|
||||||
|
categories: ["Images"]
|
||||||
|
startpage: false
|
||||||
|
lang: de
|
||||||
|
gallery: "/img/2020/10/gruenau/DSC06623.jpg"
|
||||||
|
---
|
||||||
|
Heute lief ich am [ehemalige Funkhaus Grünau](https://de.wikipedia.org/wiki/Funkhaus_Gr%C3%BCnau) vorbei. Das Gebäude kann aktuell scheinbar nicht mehr betreten werden.
|
||||||
|
|
||||||
|
{{< gallery caption-position="bottom" caption-effect="fade" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06623.jpg" caption="Eingangstür" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06676.jpg" caption="Seitenansicht Rechts" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06677.jpg" caption="Seitenansicht Links" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06673.jpg" caption="Wasser Seite" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06675.jpg" caption="Grafitti" >}}
|
||||||
|
{{< /gallery >}}
|
||||||
|
|
||||||
|
Hinter dem Funkhaus schließt sich ein schöner Fuß/Rad weg an. Auf diesem kann entlang des Wassers spaziert werden mit vielen Sitzplätzen inc Wasserblick. Außerdem ist sehr leicht an vielen Stellen in die Tram die alle 20 Minuten den selben weg entlangfährt einzusteigen und sich wieder zurück fahren zu lassen.
|
||||||
|
|
||||||
|
{{< gallery caption-position="bottom" caption-effect="fade" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06633_01.jpg" caption="Pilz" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06643.jpg" caption="Bauwerk auf Wasser" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06647.jpg" caption="Steg auf Wasser" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06661.jpg" caption="Rote Bojen umrandet von Blättern" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06680_01.jpg" caption="Tram" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06682_01.jpg" caption="Parkendes Motorad" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06694_01.jpg" caption="Ins Wasser reichender Baum" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06711.jpg" caption="Ins Wasser reichender Baum" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06725.jpg" caption="Sitzgelegenheit am Wasser" >}}
|
||||||
|
{{< figure src="/img/2020/10/gruenau/DSC06730.jpg" caption="Bote" >}}
|
||||||
|
{{< /gallery >}}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
{{< load-photoswipe >}}
|
79
content/posts/2020-10-17-Hugo-Shortcodes.md
Normal file
|
@ -0,0 +1,79 @@
|
||||||
|
---
|
||||||
|
title: "Own Hugo Shortcodes"
|
||||||
|
date: 2020-10-17T02:22:53+02:00
|
||||||
|
draft: false
|
||||||
|
description: "How to create your own Shortcodes with Hugo"
|
||||||
|
tags: ["Hugo", "Go", "Blog"]
|
||||||
|
categories: ["Programming"]
|
||||||
|
startpage: true
|
||||||
|
lang: gb
|
||||||
|
---
|
||||||
|
After using [Hugo](https://gohugo.io/) for this Webpage I want to create a [Gallery Page](/gallery/). I already used [hugo-easy-gallery](https://github.com/liwenyip/hugo-easy-gallery) inside Posts so i noticed the "layouts/shortcodes" folder at my projekt. After I created a new Layout for one Page and implement all the used HTML/JS/CSS Stuff i thought it would be a better way to use the "normal" layout and find anouther way to create the Gallery view.
|
||||||
|
|
||||||
|
## Generale Shortcodes
|
||||||
|
|
||||||
|
I created a new html file inside the Folder `layouts/shortcodes`. I called it `test.html` for now. In this file I could insert some basic HTML Code:
|
||||||
|
|
||||||
|
```
|
||||||
|
<b>Foo</b><i>Bar</i> Sample
|
||||||
|
```
|
||||||
|
|
||||||
|
and a new md file for my Gallery with the following content:
|
||||||
|
|
||||||
|
```
|
||||||
|
---
|
||||||
|
title: "Gallery"
|
||||||
|
date: 2020-10-01T14:49:09+02:00
|
||||||
|
draft: true
|
||||||
|
---
|
||||||
|
{{<test>}}
|
||||||
|
```
|
||||||
|
|
||||||
|
which together create the following Result:
|
||||||
|
|
||||||
|
{{< figure src="/img/2020/10/hugo-shortcodes/test-html.png" >}}
|
||||||
|
|
||||||
|
Based on the [offical documentation](https://gohugo.io/templates/shortcode-templates/) hugo try to find the html File in the `/layouts/shortcodes/<SHORTCODE>.html` or the `/themes/<THEME>/layouts/shortcodes/<SHORTCODE>.html` directory.
|
||||||
|
|
||||||
|
## Create a Gallery with a Shortcode
|
||||||
|
|
||||||
|
The Gallery Page is a overview over multible Posts, so i don't want to show a Publish Date. On my theme I need to create a small hack to achieve that, I added a new Varieable to my Posts call `hideDate`. In my template single.html file i just added an if to check if the Parametet is set:
|
||||||
|
|
||||||
|
```
|
||||||
|
{{ if eq .Params.hideDate nil}}
|
||||||
|
<div class="meta">Posted on {{ dateFormat "Jan 2, 2006" .Date }}{{ if .Draft }} <span class="draft-label">DRAFT</span> {{ end }}</div>
|
||||||
|
{{ end }}
|
||||||
|
```
|
||||||
|
|
||||||
|
I also added a `gallery` Field in the Post-Header of all Content Fiels which should be shown in the Gallery. The `gallery` fieeld contains a link to an image. So I can query for that posts in the hugo langauge.
|
||||||
|
|
||||||
|
```
|
||||||
|
{{ $pages := where (where .Site.RegularPages "Type" "in" .Site.Params.mainSections) ".Params.gallery" "!=" nil }}
|
||||||
|
```
|
||||||
|
|
||||||
|
To create the Galery itselfs i used the JQuery (i know its not the best any more but easy to integrate in hugo) [Justified-Gallery](http://miromannino.github.io/Justified-Gallery/). Also there is no reason to show the Gallery two times at one Page, therefore I don't care about loading the js file multible times. If te same shourcade is used more than one time it may make sens to move the loading of external javascript files to another place.
|
||||||
|
|
||||||
|
After all I have the following shortcode-file:
|
||||||
|
|
||||||
|
```
|
||||||
|
<link rel="stylesheet" href="/css/justifiedGallery.min.css" />
|
||||||
|
<script src="/js/jquery-3.5.1.min.js"></script>
|
||||||
|
<script src="/js/jquery.justifiedGallery.min.js"></script>
|
||||||
|
{{ $pages := where (where .Site.RegularPages "Type" "in" .Site.Params.mainSections) ".Params.gallery" "!=" nil }}
|
||||||
|
<div id="all" >
|
||||||
|
{{ range $pages }}
|
||||||
|
<a style="border-bottom: 5px solid transparent" href="{{ .RelPermalink }}">
|
||||||
|
<img alt="{{ .Title }}" src="{{.Params.gallery}}"/>
|
||||||
|
</a>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
<div style="clear: both;"></div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$("#all").justifiedGallery({
|
||||||
|
rowHeight : 250,
|
||||||
|
margins : 5,
|
||||||
|
lastRow : 'nojustify',
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
```
|
14
content/posts/2020-10-28-Mqtt-At-Home.md
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
---
|
||||||
|
title: "MQTT at Home"
|
||||||
|
date: 2020-10-28T21:32:53+02:00
|
||||||
|
draft: true
|
||||||
|
description: "How I use MQTT at Home to connect stuff."
|
||||||
|
tags: ["MQTT", "IoT", "Blog"]
|
||||||
|
categories: ["Programming"]
|
||||||
|
startpage: true
|
||||||
|
lang: gb
|
||||||
|
---
|
||||||
|
Ok i live in a small appartment, but at least I have three Window and a little bit stuff to connect with each other. I startes with [Ikea TRÅDFRI](https://www.ikea.com/de/de/cat/ikea-home-smart-beleuchtung-36812/) and some selfe made components based Arudino/Wemos. About one year ago I tried [zigbee2mqtt](https://www.zigbee2mqtt.io/) to connect the ikea bulbs to MQTT without using my own buggy code. I used a MQTT-Broker on a Virtual Server somewhere in the internet and develop some PHP-Application with lumen (some of them running in kubernetes) to connect everything.
|
||||||
|
|
||||||
|
|
||||||
|
I still use [Mqtt Dash](https://play.google.com/store/apps/details?id=net.routix.mqttdash&hl=de&gl=US) at my Android Device do control most things.
|
29
layouts/shortcodes/figure.html
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
<!--
|
||||||
|
Put this file in /layouts/shortcodes/figure.html
|
||||||
|
NB this overrides Hugo's built-in "figure" shortcode but is backwards compatible
|
||||||
|
Documentation and licence at https://github.com/liwenyip/hugo-easy-gallery/
|
||||||
|
-->
|
||||||
|
<!-- count how many times we've called this shortcode; load the css if it's the first time -->
|
||||||
|
{{- if not ($.Page.Scratch.Get "figurecount") }}<link rel="stylesheet" href="/css/hugo-easy-gallery.css" />{{ end }}
|
||||||
|
{{- $.Page.Scratch.Add "figurecount" 1 -}}
|
||||||
|
<!-- use either src or link-thumb for thumbnail image -->
|
||||||
|
{{- $thumb := .Get "src" | default (printf "%s." (.Get "thumb") | replace (.Get "link") ".") }}
|
||||||
|
<div class="box{{ with .Get "caption-position" }} fancy-figure caption-position-{{.}}{{end}}{{ with .Get "caption-effect" }} caption-effect-{{.}}{{end}}" {{ with .Get "width" }}style="max-width:{{.}}"{{end}}>
|
||||||
|
<figure {{ with .Get "class" }}class="{{.}}"{{ end }} itemprop="associatedMedia" itemscope itemtype="http://schema.org/ImageObject">
|
||||||
|
<div class="img"{{ if .Parent }} style="background-image: url('{{ $thumb | relURL }}');"{{ end }}{{ with .Get "size" }} data-size="{{.}}"{{ end }}>
|
||||||
|
<img itemprop="thumbnail" src="{{ $thumb | relURL }}" {{ with .Get "alt" | default (.Get "caption") }}alt="{{.}}"{{ end }}/><!-- <img> hidden if in .gallery -->
|
||||||
|
</div>
|
||||||
|
{{ with .Get "link" | default (.Get "src") }}<a href="{{.}}" itemprop="contentUrl"></a>{{ end }}
|
||||||
|
{{- if or (or (.Get "title") (.Get "caption")) (.Get "attr")}}
|
||||||
|
<figcaption>
|
||||||
|
{{- with .Get "title" }}<h4>{{.}}</h4>{{ end }}
|
||||||
|
{{- if or (.Get "caption") (.Get "attr")}}
|
||||||
|
<p>
|
||||||
|
{{- .Get "caption" -}}
|
||||||
|
{{- with .Get "attrlink"}}<a href="{{.}}">{{ .Get "attr" }}</a>{{ else }}{{ .Get "attr"}}{{ end -}}
|
||||||
|
</p>
|
||||||
|
{{- end }}
|
||||||
|
</figcaption>
|
||||||
|
{{- end }}
|
||||||
|
</figure>
|
||||||
|
</div>
|
20
layouts/shortcodes/gallery-all.html
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
<link rel="stylesheet" href="/css/justifiedGallery.min.css" />
|
||||||
|
<script src="/js/jquery-3.5.1.min.js"></script>
|
||||||
|
<script src="/js/jquery.justifiedGallery.min.js"></script>
|
||||||
|
{{ $pages := where (where .Site.RegularPages "Type" "in" .Site.Params.mainSections) ".Params.gallery" "!=" nil }}
|
||||||
|
<div id="all" >
|
||||||
|
{{ range $pages }}
|
||||||
|
<a style="border-bottom: 5px solid transparent" href="{{ .RelPermalink }}">
|
||||||
|
<img alt="{{ .Title }}" src="{{.Params.gallery}}"/>
|
||||||
|
</a>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
<div style="clear: both;"></div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$("#all").justifiedGallery({
|
||||||
|
rowHeight : 250,
|
||||||
|
margins : 5,
|
||||||
|
lastRow : 'nojustify',
|
||||||
|
});
|
||||||
|
</script>
|
41
layouts/shortcodes/gallery.html
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
<!--
|
||||||
|
Put this file in /layouts/shortcodes/gallery.html
|
||||||
|
Documentation and licence at https://github.com/liwenyip/hugo-easy-gallery/
|
||||||
|
-->
|
||||||
|
<!-- count how many times we've called this shortcode; load the css if it's the first time -->
|
||||||
|
{{- if not ($.Page.Scratch.Get "figurecount") }}<link rel="stylesheet" href="/css/hugo-easy-gallery.css" />{{ end }}
|
||||||
|
{{- $.Page.Scratch.Add "figurecount" 1 }}
|
||||||
|
{{ $baseURL := .Site.BaseURL }}
|
||||||
|
<div class="gallery caption-position-{{ with .Get "caption-position" | default "bottom" }}{{.}}{{end}} caption-effect-{{ with .Get "caption-effect" | default "slide" }}{{.}}{{end}} hover-effect-{{ with .Get "hover-effect" | default "zoom" }}{{.}}{{end}} {{ if ne (.Get "hover-transition") "none" }}hover-transition{{end}}" itemscope itemtype="http://schema.org/ImageGallery">
|
||||||
|
{{- with (.Get "dir") -}}
|
||||||
|
<!-- If a directory was specified, generate figures for all of the images in the directory -->
|
||||||
|
{{- $files := readDir (print "/static/" .) }}
|
||||||
|
{{- range $files -}}
|
||||||
|
<!-- skip files that aren't images, or that inlcude the thumb suffix in their name -->
|
||||||
|
{{- $thumbext := $.Get "thumb" | default "-thumb" }}
|
||||||
|
{{- $isthumb := .Name | findRE ($thumbext | printf "%s\\.") }}<!-- is the current file a thumbnail image? -->
|
||||||
|
{{- $isimg := lower .Name | findRE "\\.(gif|jpg|jpeg|tiff|png|bmp)" }}<!-- is the current file an image? -->
|
||||||
|
{{- if and $isimg (not $isthumb) }}
|
||||||
|
{{- $caption := .Name | replaceRE "\\..*" "" | humanize }}<!-- humanized filename without extension -->
|
||||||
|
{{- $linkURL := print $baseURL ($.Get "dir") "/" .Name | absURL }}<!-- absolute URL to hi-res image -->
|
||||||
|
{{- $thumb := .Name | replaceRE "(\\.)" ($thumbext | printf "%s.") }}<!-- filename of thumbnail image -->
|
||||||
|
{{- $thumbexists := where $files "Name" $thumb }}<!-- does a thumbnail image exist? -->
|
||||||
|
{{- $thumbURL := print $baseURL ($.Get "dir") "/" $thumb | absURL }}<!-- absolute URL to thumbnail image -->
|
||||||
|
<div class="box">
|
||||||
|
<figure itemprop="associatedMedia" itemscope itemtype="http://schema.org/ImageObject">
|
||||||
|
<div class="img" style="background-image: url('{{ if $thumbexists }}{{ $thumbURL }}{{ else }}{{ $linkURL }}{{ end }}');" >
|
||||||
|
<img itemprop="thumbnail" src="{{ if $thumbexists }}{{ $thumbURL }}{{ else }}{{ $linkURL }}{{ end }}" alt="{{ $caption }}" /><!-- <img> hidden if in .gallery -->
|
||||||
|
</div>
|
||||||
|
<figcaption>
|
||||||
|
<p>{{ $caption }}</p>
|
||||||
|
</figcaption>
|
||||||
|
<a href="{{ $linkURL }}" itemprop="contentUrl"></a><!-- put <a> last so it is stacked on top -->
|
||||||
|
</figure>
|
||||||
|
</div>
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
{{- else -}}
|
||||||
|
<!-- If no directory was specified, include any figure shortcodes called within the gallery -->
|
||||||
|
{{ .Inner }}
|
||||||
|
{{- end }}
|
||||||
|
</div>
|
75
layouts/shortcodes/load-photoswipe-theme.html
Normal file
|
@ -0,0 +1,75 @@
|
||||||
|
<!--
|
||||||
|
Put this file in /layouts/shortcodes/load-photoswipe.html
|
||||||
|
Documentation and licence at https://github.com/liwenyip/hugo-easy-gallery/
|
||||||
|
-->
|
||||||
|
|
||||||
|
<!-- prevent this shortcode from being loaded more than once per page -->
|
||||||
|
{{ if not ($.Page.Scratch.Get "photoswipeloaded") }}
|
||||||
|
{{ $.Page.Scratch.Set "photoswipeloaded" 1 }}
|
||||||
|
|
||||||
|
<!--
|
||||||
|
*** jQuery must be loaded before load-photoswipe.js ***
|
||||||
|
- If your template already loads jQuery in the header then you don't need to load it again here.
|
||||||
|
- If your template already loads jQuery in the footer, then you could load load-photoswipe.js from the footer instead
|
||||||
|
-->
|
||||||
|
<!-- these files are loaded in the theme footer
|
||||||
|
<script src="https://code.jquery.com/jquery-1.12.4.min.js" integrity="sha256-ZosEbRLbNQzLpnKIkEdrPv7lOy9C27hHQ+Xp8a4MxAQ=" crossorigin="anonymous"></script>
|
||||||
|
<script src="/js/load-photoswipe.js"></script>
|
||||||
|
-->
|
||||||
|
|
||||||
|
<!-- Photoswipe css/js libraries -->
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe.min.css" integrity="sha256-sCl5PUOGMLfFYctzDW3MtRib0ctyUvI9Qsmq2wXOeBY=" crossorigin="anonymous" />
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/default-skin/default-skin.min.css" integrity="sha256-BFeI1V+Vh1Rk37wswuOYn5lsTcaU96hGaI7OUVCLjPc=" crossorigin="anonymous" />
|
||||||
|
<!-- these files are loaded in the theme footer
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe.min.js" integrity="sha256-UplRCs9v4KXVJvVY+p+RSo5Q4ilAUXh7kpjyIP5odyc=" crossorigin="anonymous"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe-ui-default.min.js" integrity="sha256-PWHOlUzc96pMc8ThwRIXPn8yH4NOLu42RQ0b9SpnpFk=" crossorigin="anonymous"></script>
|
||||||
|
-->
|
||||||
|
|
||||||
|
<!-- Root element of PhotoSwipe. Must have class pswp. -->
|
||||||
|
<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">
|
||||||
|
<!-- Background of PhotoSwipe.
|
||||||
|
It's a separate element, as animating opacity is faster than rgba(). -->
|
||||||
|
<div class="pswp__bg"></div>
|
||||||
|
<!-- Slides wrapper with overflow:hidden. -->
|
||||||
|
<div class="pswp__scroll-wrap">
|
||||||
|
<!-- Container that holds slides.
|
||||||
|
PhotoSwipe keeps only 3 of them in DOM to save memory.
|
||||||
|
Don't modify these 3 pswp__item elements, data is added later on. -->
|
||||||
|
<div class="pswp__container">
|
||||||
|
<div class="pswp__item"></div>
|
||||||
|
<div class="pswp__item"></div>
|
||||||
|
<div class="pswp__item"></div>
|
||||||
|
</div>
|
||||||
|
<!-- Default (PhotoSwipeUI_Default) interface on top of sliding area. Can be changed. -->
|
||||||
|
<div class="pswp__ui pswp__ui--hidden">
|
||||||
|
<div class="pswp__top-bar">
|
||||||
|
<!-- Controls are self-explanatory. Order can be changed. -->
|
||||||
|
<div class="pswp__counter"></div>
|
||||||
|
<button class="pswp__button pswp__button--close" title="Close (Esc)"></button>
|
||||||
|
<button class="pswp__button pswp__button--share" title="Share"></button>
|
||||||
|
<button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button>
|
||||||
|
<button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>
|
||||||
|
<!-- Preloader demo http://codepen.io/dimsemenov/pen/yyBWoR -->
|
||||||
|
<!-- element will get class pswp__preloader--active when preloader is running -->
|
||||||
|
<div class="pswp__preloader">
|
||||||
|
<div class="pswp__preloader__icn">
|
||||||
|
<div class="pswp__preloader__cut">
|
||||||
|
<div class="pswp__preloader__donut"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
|
||||||
|
<div class="pswp__share-tooltip"></div>
|
||||||
|
</div>
|
||||||
|
<button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
|
||||||
|
</button>
|
||||||
|
<button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)">
|
||||||
|
</button>
|
||||||
|
<div class="pswp__caption">
|
||||||
|
<div class="pswp__caption__center"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
71
layouts/shortcodes/load-photoswipe.html
Normal file
|
@ -0,0 +1,71 @@
|
||||||
|
<!--
|
||||||
|
Put this file in /layouts/shortcodes/load-photoswipe.html
|
||||||
|
Documentation and licence at https://github.com/liwenyip/hugo-easy-gallery/
|
||||||
|
-->
|
||||||
|
|
||||||
|
<!-- prevent this shortcode from being loaded more than once per page -->
|
||||||
|
{{ if not ($.Page.Scratch.Get "photoswipeloaded") }}
|
||||||
|
{{ $.Page.Scratch.Set "photoswipeloaded" 1 }}
|
||||||
|
|
||||||
|
<!--
|
||||||
|
*** jQuery must be loaded before load-photoswipe.js ***
|
||||||
|
- If your template already loads jQuery in the header then you don't need to load it again here.
|
||||||
|
- If your template already loads jQuery in the footer, then you could load load-photoswipe.js from the footer instead
|
||||||
|
-->
|
||||||
|
<script src="https://code.jquery.com/jquery-1.12.4.min.js" integrity="sha256-ZosEbRLbNQzLpnKIkEdrPv7lOy9C27hHQ+Xp8a4MxAQ=" crossorigin="anonymous"></script>
|
||||||
|
<script src="/js/load-photoswipe.js"></script>
|
||||||
|
|
||||||
|
<!-- Photoswipe css/js libraries -->
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe.min.css" integrity="sha256-sCl5PUOGMLfFYctzDW3MtRib0ctyUvI9Qsmq2wXOeBY=" crossorigin="anonymous" />
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/default-skin/default-skin.min.css" integrity="sha256-BFeI1V+Vh1Rk37wswuOYn5lsTcaU96hGaI7OUVCLjPc=" crossorigin="anonymous" />
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe.min.js" integrity="sha256-UplRCs9v4KXVJvVY+p+RSo5Q4ilAUXh7kpjyIP5odyc=" crossorigin="anonymous"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe-ui-default.min.js" integrity="sha256-PWHOlUzc96pMc8ThwRIXPn8yH4NOLu42RQ0b9SpnpFk=" crossorigin="anonymous"></script>
|
||||||
|
|
||||||
|
<!-- Root element of PhotoSwipe. Must have class pswp. -->
|
||||||
|
<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">
|
||||||
|
<!-- Background of PhotoSwipe.
|
||||||
|
It's a separate element, as animating opacity is faster than rgba(). -->
|
||||||
|
<div class="pswp__bg"></div>
|
||||||
|
<!-- Slides wrapper with overflow:hidden. -->
|
||||||
|
<div class="pswp__scroll-wrap">
|
||||||
|
<!-- Container that holds slides.
|
||||||
|
PhotoSwipe keeps only 3 of them in DOM to save memory.
|
||||||
|
Don't modify these 3 pswp__item elements, data is added later on. -->
|
||||||
|
<div class="pswp__container">
|
||||||
|
<div class="pswp__item"></div>
|
||||||
|
<div class="pswp__item"></div>
|
||||||
|
<div class="pswp__item"></div>
|
||||||
|
</div>
|
||||||
|
<!-- Default (PhotoSwipeUI_Default) interface on top of sliding area. Can be changed. -->
|
||||||
|
<div class="pswp__ui pswp__ui--hidden">
|
||||||
|
<div class="pswp__top-bar">
|
||||||
|
<!-- Controls are self-explanatory. Order can be changed. -->
|
||||||
|
<div class="pswp__counter"></div>
|
||||||
|
<button class="pswp__button pswp__button--close" title="Close (Esc)"></button>
|
||||||
|
<button class="pswp__button pswp__button--share" title="Share"></button>
|
||||||
|
<button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button>
|
||||||
|
<button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>
|
||||||
|
<!-- Preloader demo http://codepen.io/dimsemenov/pen/yyBWoR -->
|
||||||
|
<!-- element will get class pswp__preloader--active when preloader is running -->
|
||||||
|
<div class="pswp__preloader">
|
||||||
|
<div class="pswp__preloader__icn">
|
||||||
|
<div class="pswp__preloader__cut">
|
||||||
|
<div class="pswp__preloader__donut"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
|
||||||
|
<div class="pswp__share-tooltip"></div>
|
||||||
|
</div>
|
||||||
|
<button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
|
||||||
|
</button>
|
||||||
|
<button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)">
|
||||||
|
</button>
|
||||||
|
<div class="pswp__caption">
|
||||||
|
<div class="pswp__caption__center"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
1
layouts/shortcodes/test.html
Normal file
|
@ -0,0 +1 @@
|
||||||
|
<b>Foo</b><i>Bar</i> Sample
|
134
static/code/ir-wemos-mosfet.txt
Normal file
|
@ -0,0 +1,134 @@
|
||||||
|
#include <IRremoteESP8266.h>
|
||||||
|
#include <Arduino.h>
|
||||||
|
#include <IRrecv.h>
|
||||||
|
#include <IRsend.h>
|
||||||
|
#include <ESP8266WiFi.h>
|
||||||
|
#include <PubSubClient.h>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const char* ssid = "";
|
||||||
|
const char* password = "";
|
||||||
|
const char* mqtt_server = "";
|
||||||
|
const char* mqtt_user = "";
|
||||||
|
const char* mqtt_pass = "";
|
||||||
|
const char* mqtt_client_id = "edifier-remote";
|
||||||
|
const char* mqtt_status_topic = "status/edifier-remote";
|
||||||
|
|
||||||
|
|
||||||
|
WiFiClient espClient;
|
||||||
|
PubSubClient client(espClient);
|
||||||
|
|
||||||
|
|
||||||
|
//IRrecv irrecv(RECV_PIN);
|
||||||
|
IRsend irsend(0);
|
||||||
|
//decode_results results;
|
||||||
|
|
||||||
|
void setup_wifi() {
|
||||||
|
|
||||||
|
delay(10);
|
||||||
|
// We start by connecting to a WiFi network
|
||||||
|
Serial.println();
|
||||||
|
Serial.print("Connecting to ");
|
||||||
|
Serial.println(ssid);
|
||||||
|
|
||||||
|
WiFi.mode(WIFI_STA);
|
||||||
|
WiFi.begin(ssid, password);
|
||||||
|
|
||||||
|
while (WiFi.status() != WL_CONNECTED) {
|
||||||
|
delay(500);
|
||||||
|
Serial.print(".");
|
||||||
|
}
|
||||||
|
|
||||||
|
randomSeed(micros());
|
||||||
|
|
||||||
|
Serial.println("");
|
||||||
|
Serial.println("WiFi connected");
|
||||||
|
Serial.println("IP address: ");
|
||||||
|
Serial.println(WiFi.localIP());
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void callback(char* topic, byte* payload, unsigned int length) {
|
||||||
|
|
||||||
|
Serial.print("Message arrived [");
|
||||||
|
Serial.print(topic);
|
||||||
|
Serial.print("] ");
|
||||||
|
for (int i = 0; i < length; i++) {
|
||||||
|
Serial.print((char)payload[i]);
|
||||||
|
}
|
||||||
|
Serial.println();
|
||||||
|
|
||||||
|
if(String(topic)=="musik/power") {
|
||||||
|
irsend.sendNEC(149389439, 32);
|
||||||
|
Serial.println("EDIFIER: Power");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/mute") {
|
||||||
|
irsend.sendNEC(149356799, 32);
|
||||||
|
Serial.println("EDIFIER: Mute");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/down") {
|
||||||
|
irsend.sendNEC(149369039, 32);
|
||||||
|
Serial.println("EDIFIER: Down");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/up") {
|
||||||
|
irsend.sendNEC(149393519, 32);
|
||||||
|
Serial.println("EDIFIER: UP");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/bluetooth") {
|
||||||
|
irsend.sendNEC(149377199, 32);
|
||||||
|
Serial.println("EDIFIER: Bluetooth");
|
||||||
|
}
|
||||||
|
|
||||||
|
if(String(topic)=="musik/line") {
|
||||||
|
irsend.sendNEC(149399639, 32);
|
||||||
|
Serial.println("EDIFIER: Line");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void reconnect() {
|
||||||
|
Serial.println("Reconnect!");
|
||||||
|
// Loop until we're reconnected
|
||||||
|
while (!client.connected()) {
|
||||||
|
Serial.print("Attempting MQTT connection...");
|
||||||
|
// Attempt to connect
|
||||||
|
if (client.connect(mqtt_client_id, mqtt_user, mqtt_pass, mqtt_status_topic, 1, true, "0")) {
|
||||||
|
Serial.println("connected");
|
||||||
|
// Once connected, publish an announcement...
|
||||||
|
client.publish(mqtt_status_topic, "1");
|
||||||
|
// ... and resubscribe
|
||||||
|
client.subscribe("musik/#");
|
||||||
|
} else {
|
||||||
|
Serial.print("failed, rc=");
|
||||||
|
Serial.print(client.state());
|
||||||
|
Serial.println(" try again in 5 seconds");
|
||||||
|
// Wait 5 seconds before retrying
|
||||||
|
delay(5000);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void setup()
|
||||||
|
{
|
||||||
|
Serial.begin(9600);
|
||||||
|
irsend.begin();
|
||||||
|
Serial.println("Start");
|
||||||
|
Serial.println("Start");
|
||||||
|
setup_wifi();
|
||||||
|
client.setServer(mqtt_server, 1883);
|
||||||
|
client.setCallback(callback);
|
||||||
|
}
|
||||||
|
|
||||||
|
void loop() {
|
||||||
|
if (!client.connected()) {
|
||||||
|
reconnect();
|
||||||
|
}
|
||||||
|
client.loop();
|
||||||
|
}
|
164
static/css/hugo-easy-gallery.css
Normal file
|
@ -0,0 +1,164 @@
|
||||||
|
/*
|
||||||
|
Put this file in /static/css/hugo-easy-gallery.css
|
||||||
|
Documentation and licence at https://github.com/liwenyip/hugo-easy-gallery/
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
Grid Layout Styles
|
||||||
|
*/
|
||||||
|
.gallery {
|
||||||
|
overflow: hidden;
|
||||||
|
margin: 10px;
|
||||||
|
max-width: 768px;
|
||||||
|
--hovercolor: none;
|
||||||
|
}
|
||||||
|
.gallery .box {
|
||||||
|
float: left;
|
||||||
|
position: relative;
|
||||||
|
/* Default: 1 tile wide */
|
||||||
|
width: 100%;
|
||||||
|
padding-bottom: 100%;
|
||||||
|
}
|
||||||
|
@media only screen and (min-width : 365px) {
|
||||||
|
/* Tablet view: 2 tiles */
|
||||||
|
.gallery .box {
|
||||||
|
width: 50%;
|
||||||
|
padding-bottom: 50%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media only screen and (min-width : 480px) {
|
||||||
|
/* Small desktop / ipad view: 3 tiles */
|
||||||
|
.gallery .box {
|
||||||
|
width: 33.3%;
|
||||||
|
padding-bottom: 33.3%; /* */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media only screen and (min-width : 9999px) {
|
||||||
|
/* Medium desktop: 4 tiles */
|
||||||
|
.box {
|
||||||
|
width: 25%;
|
||||||
|
padding-bottom: 25%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Transition styles
|
||||||
|
*/
|
||||||
|
.gallery.hover-transition figure,
|
||||||
|
.gallery.hover-effect-zoom .img,
|
||||||
|
.gallery:not(.caption-effect-appear) figcaption,
|
||||||
|
.fancy-figure:not(.caption-effect-appear) figcaption {
|
||||||
|
-webkit-transition: all 0.3s ease-in-out;
|
||||||
|
-moz-transition: all 0.3s ease-in-out;
|
||||||
|
-o-transition: all 0.3s ease-in-out;
|
||||||
|
transition: all 0.3s ease-in-out;
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
figure styles
|
||||||
|
*/
|
||||||
|
figure {
|
||||||
|
position:relative; /* purely to allow absolution positioning of figcaption */
|
||||||
|
overflow: hidden;
|
||||||
|
--hovercolor: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.gallery figure {
|
||||||
|
position: absolute;
|
||||||
|
left: 5px;
|
||||||
|
right: 5px;
|
||||||
|
top: 5px;
|
||||||
|
bottom: 5px;
|
||||||
|
}
|
||||||
|
.gallery.hover-effect-grow figure:hover {
|
||||||
|
transform: scale(1.05);
|
||||||
|
}
|
||||||
|
.gallery.hover-effect-shrink figure:hover {
|
||||||
|
transform: scale(0.95);
|
||||||
|
}
|
||||||
|
.gallery.hover-effect-slidedown figure:hover {
|
||||||
|
transform: translateY(5px);
|
||||||
|
}
|
||||||
|
.gallery.hover-effect-slideup figure:hover {
|
||||||
|
transform: translateY(-5px);
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
img / a styles
|
||||||
|
*/
|
||||||
|
|
||||||
|
.gallery .img {
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
top: 0;
|
||||||
|
bottom: 0;
|
||||||
|
background-size: cover;
|
||||||
|
background-position: 50% 50%;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
}
|
||||||
|
.gallery.hover-effect-zoom figure:hover .img {
|
||||||
|
transform: scale(1.05);
|
||||||
|
}
|
||||||
|
.gallery img {
|
||||||
|
display: none; /* only show the img if not inside a gallery */
|
||||||
|
}
|
||||||
|
figure a {
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
top: 0;
|
||||||
|
bottom: 0;
|
||||||
|
border-bottom: 0px;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
figcaption styles
|
||||||
|
*/
|
||||||
|
.gallery figcaption,
|
||||||
|
.fancy-figure figcaption {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
background: #000;
|
||||||
|
color: #FFF;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 75%; /* change this if you want bigger text */
|
||||||
|
background: rgba(0, 0, 0, 0.5);
|
||||||
|
opacity: 1;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
.gallery.caption-position-none figcaption,
|
||||||
|
.fancy-figure.caption-position-none figcaption {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
.gallery.caption-position-center figcaption,
|
||||||
|
.fancy-figure.caption-position-center figcaption {
|
||||||
|
top: 0;
|
||||||
|
padding: 40% 5px;
|
||||||
|
}
|
||||||
|
.gallery.caption-position-bottom figcaption,
|
||||||
|
.fancy-figure.caption-position-bottom figcaption {
|
||||||
|
padding: 5px;
|
||||||
|
}
|
||||||
|
.gallery.caption-effect-fade figure:not(:hover) figcaption,
|
||||||
|
.gallery.caption-effect-appear figure:not(:hover) figcaption,
|
||||||
|
.fancy-figure.caption-effect-fade figure:not(:hover) figcaption,
|
||||||
|
.fancy-figure.caption-effect-appear figure:not(:hover) figcaption {
|
||||||
|
background: rgba(0, 0, 0, 0);
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
.gallery.caption-effect-slide.caption-position-bottom figure:not(:hover) figcaption,
|
||||||
|
.fancy-figure.caption-effect-slide.caption-position-bottom figure:not(:hover) figcaption {
|
||||||
|
margin-bottom: -100%;
|
||||||
|
}
|
||||||
|
.gallery.caption-effect-slide.caption-position-center figure:not(:hover) figcaption,
|
||||||
|
.fancy-figure.caption-effect-slide.caption-position-center figure:not(:hover) figcaption {
|
||||||
|
top: 100%;
|
||||||
|
}
|
||||||
|
figcaption p {
|
||||||
|
margin: auto; /* override style in theme */
|
||||||
|
}
|
||||||
|
|
110
static/css/justifiedGallery.min.css
vendored
Normal file
|
@ -0,0 +1,110 @@
|
||||||
|
/*!
|
||||||
|
* justifiedGallery - v3.8.0
|
||||||
|
* http://miromannino.github.io/Justified-Gallery/
|
||||||
|
* Copyright (c) 2020 Miro Mannino
|
||||||
|
* Licensed under the MIT license.
|
||||||
|
*/
|
||||||
|
.justified-gallery {
|
||||||
|
width: 100%;
|
||||||
|
position: relative;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.justified-gallery > a,
|
||||||
|
.justified-gallery > div,
|
||||||
|
.justified-gallery > figure {
|
||||||
|
position: absolute;
|
||||||
|
display: inline-block;
|
||||||
|
overflow: hidden;
|
||||||
|
/* background: #888888; To have gray placeholders while the gallery is loading with waitThumbnailsLoad = false */
|
||||||
|
filter: "alpha(opacity=10)";
|
||||||
|
opacity: 0.1;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
.justified-gallery > a > img,
|
||||||
|
.justified-gallery > div > img,
|
||||||
|
.justified-gallery > figure > img,
|
||||||
|
.justified-gallery > a > a > img,
|
||||||
|
.justified-gallery > div > a > img,
|
||||||
|
.justified-gallery > figure > a > img,
|
||||||
|
.justified-gallery > a > svg,
|
||||||
|
.justified-gallery > div > svg,
|
||||||
|
.justified-gallery > figure > svg,
|
||||||
|
.justified-gallery > a > a > svg,
|
||||||
|
.justified-gallery > div > a > svg,
|
||||||
|
.justified-gallery > figure > a > svg {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
border: none;
|
||||||
|
filter: "alpha(opacity=0)";
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
.justified-gallery > a > .jg-caption,
|
||||||
|
.justified-gallery > div > .jg-caption,
|
||||||
|
.justified-gallery > figure > .jg-caption {
|
||||||
|
display: none;
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
padding: 5px;
|
||||||
|
background-color: #000000;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
margin: 0;
|
||||||
|
color: white;
|
||||||
|
font-size: 12px;
|
||||||
|
font-weight: 300;
|
||||||
|
font-family: sans-serif;
|
||||||
|
}
|
||||||
|
.justified-gallery > a > .jg-caption.jg-caption-visible,
|
||||||
|
.justified-gallery > div > .jg-caption.jg-caption-visible,
|
||||||
|
.justified-gallery > figure > .jg-caption.jg-caption-visible {
|
||||||
|
display: initial;
|
||||||
|
filter: "alpha(opacity=70)";
|
||||||
|
opacity: 0.7;
|
||||||
|
-webkit-transition: opacity 500ms ease-in;
|
||||||
|
-moz-transition: opacity 500ms ease-in;
|
||||||
|
-o-transition: opacity 500ms ease-in;
|
||||||
|
transition: opacity 500ms ease-in;
|
||||||
|
}
|
||||||
|
.justified-gallery > .jg-entry-visible {
|
||||||
|
filter: "alpha(opacity=100)";
|
||||||
|
opacity: 1;
|
||||||
|
background: none;
|
||||||
|
}
|
||||||
|
.justified-gallery > .jg-entry-visible > img,
|
||||||
|
.justified-gallery > .jg-entry-visible > a > img,
|
||||||
|
.justified-gallery > .jg-entry-visible > svg,
|
||||||
|
.justified-gallery > .jg-entry-visible > a > svg {
|
||||||
|
filter: "alpha(opacity=100)";
|
||||||
|
opacity: 1;
|
||||||
|
-webkit-transition: opacity 500ms ease-in;
|
||||||
|
-moz-transition: opacity 500ms ease-in;
|
||||||
|
-o-transition: opacity 500ms ease-in;
|
||||||
|
transition: opacity 500ms ease-in;
|
||||||
|
}
|
||||||
|
.justified-gallery > .jg-filtered {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
.justified-gallery > .jg-spinner {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
margin-left: -24px;
|
||||||
|
padding: 10px 0 10px 0;
|
||||||
|
left: 50%;
|
||||||
|
filter: "alpha(opacity=100)";
|
||||||
|
opacity: 1;
|
||||||
|
overflow: initial;
|
||||||
|
}
|
||||||
|
.justified-gallery > .jg-spinner > span {
|
||||||
|
display: inline-block;
|
||||||
|
filter: "alpha(opacity=0)";
|
||||||
|
opacity: 0;
|
||||||
|
width: 8px;
|
||||||
|
height: 8px;
|
||||||
|
margin: 0 4px 0 4px;
|
||||||
|
background-color: #000;
|
||||||
|
border-radius: 6px;
|
||||||
|
}
|
BIN
static/img/2020/06/kaserne-vogelsang/DSC03511.jpg
Normal file
After Width: | Height: | Size: 2.8 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03513.jpg
Normal file
After Width: | Height: | Size: 1.8 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03515.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03518.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03520.jpg
Normal file
After Width: | Height: | Size: 1 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03521.jpg
Normal file
After Width: | Height: | Size: 1,012 KiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03533.jpg
Normal file
After Width: | Height: | Size: 2.3 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03540.jpg
Normal file
After Width: | Height: | Size: 1.7 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03545.jpg
Normal file
After Width: | Height: | Size: 968 KiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03547.jpg
Normal file
After Width: | Height: | Size: 3.7 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03549.jpg
Normal file
After Width: | Height: | Size: 1.2 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03551.jpg
Normal file
After Width: | Height: | Size: 1.6 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03554.jpg
Normal file
After Width: | Height: | Size: 1.7 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03559.jpg
Normal file
After Width: | Height: | Size: 1.3 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03561.jpg
Normal file
After Width: | Height: | Size: 1.2 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03563.jpg
Normal file
After Width: | Height: | Size: 4.3 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03570.jpg
Normal file
After Width: | Height: | Size: 1.3 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03572.jpg
Normal file
After Width: | Height: | Size: 1.3 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03586.jpg
Normal file
After Width: | Height: | Size: 1.1 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03592.jpg
Normal file
After Width: | Height: | Size: 925 KiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03598.jpg
Normal file
After Width: | Height: | Size: 1 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03602.jpg
Normal file
After Width: | Height: | Size: 1 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03610.jpg
Normal file
After Width: | Height: | Size: 986 KiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03612.jpg
Normal file
After Width: | Height: | Size: 1.8 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03615.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03623.jpg
Normal file
After Width: | Height: | Size: 2 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03631.jpg
Normal file
After Width: | Height: | Size: 4.9 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03635.jpg
Normal file
After Width: | Height: | Size: 3.3 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03645.jpg
Normal file
After Width: | Height: | Size: 1.7 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03647.jpg
Normal file
After Width: | Height: | Size: 548 KiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03650.jpg
Normal file
After Width: | Height: | Size: 1,000 KiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03651.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03653.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03657.jpg
Normal file
After Width: | Height: | Size: 1.1 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03664.jpg
Normal file
After Width: | Height: | Size: 3.1 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03670.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03674.jpg
Normal file
After Width: | Height: | Size: 1.2 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03675.jpg
Normal file
After Width: | Height: | Size: 996 KiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03677.jpg
Normal file
After Width: | Height: | Size: 2.8 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03679.jpg
Normal file
After Width: | Height: | Size: 1.2 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03682.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03688.jpg
Normal file
After Width: | Height: | Size: 1.2 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03692.jpg
Normal file
After Width: | Height: | Size: 1.1 MiB |
BIN
static/img/2020/06/kaserne-vogelsang/DSC03693.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03963.jpg
Normal file
After Width: | Height: | Size: 401 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03964.jpg
Normal file
After Width: | Height: | Size: 442 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03971.jpg
Normal file
After Width: | Height: | Size: 850 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03973.jpg
Normal file
After Width: | Height: | Size: 863 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03976.jpg
Normal file
After Width: | Height: | Size: 927 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03977.jpg
Normal file
After Width: | Height: | Size: 481 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03982.jpg
Normal file
After Width: | Height: | Size: 867 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03985.jpg
Normal file
After Width: | Height: | Size: 369 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03990.jpg
Normal file
After Width: | Height: | Size: 476 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03991.jpg
Normal file
After Width: | Height: | Size: 960 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03994.jpg
Normal file
After Width: | Height: | Size: 874 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC03998.jpg
Normal file
After Width: | Height: | Size: 396 KiB |
BIN
static/img/2020/07/koenigin-elisabeth-hospital/DSC04000.jpg
Normal file
After Width: | Height: | Size: 431 KiB |
BIN
static/img/2020/07/meseberg/DSC03705.jpg
Normal file
After Width: | Height: | Size: 1.5 MiB |
BIN
static/img/2020/07/meseberg/DSC03707.jpg
Normal file
After Width: | Height: | Size: 1,022 KiB |
BIN
static/img/2020/07/meseberg/DSC03710.jpg
Normal file
After Width: | Height: | Size: 1 MiB |
BIN
static/img/2020/07/meseberg/DSC03714.jpg
Normal file
After Width: | Height: | Size: 984 KiB |
BIN
static/img/2020/07/meseberg/DSC03718.jpg
Normal file
After Width: | Height: | Size: 982 KiB |
BIN
static/img/2020/07/meseberg/DSC03720.jpg
Normal file
After Width: | Height: | Size: 1.2 MiB |
BIN
static/img/2020/07/meseberg/DSC03736.jpg
Normal file
After Width: | Height: | Size: 1.3 MiB |
BIN
static/img/2020/07/meseberg/DSC03742.jpg
Normal file
After Width: | Height: | Size: 1.3 MiB |
BIN
static/img/2020/07/meseberg/DSC03781.jpg
Normal file
After Width: | Height: | Size: 1 MiB |
BIN
static/img/2020/07/natur/DSC03370.jpg
Normal file
After Width: | Height: | Size: 2.2 MiB |
BIN
static/img/2020/07/natur/DSC03387.jpg
Normal file
After Width: | Height: | Size: 1 MiB |
BIN
static/img/2020/07/natur/DSC03393.jpg
Normal file
After Width: | Height: | Size: 972 KiB |
BIN
static/img/2020/07/natur/DSC03405.jpg
Normal file
After Width: | Height: | Size: 1.4 MiB |
BIN
static/img/2020/07/natur/DSC03411.jpg
Normal file
After Width: | Height: | Size: 763 KiB |
BIN
static/img/2020/07/natur/DSC03416.jpg
Normal file
After Width: | Height: | Size: 1.2 MiB |