Mosfetboard Dimmy - Licht per Taster steuern

Hallo zusammen,
ich teste im Moment, das zur Verfügung gestellte Mosfetboard. Soweit funktionier alles: ich kann die Mosfets über das Display bzw. Smartphone steuern. Ich würde allerdings die Mosfets auch per Taster / Lichtschalter ein-/ausschalten bzw. dimmen. Ist das umsetzbar? Wenn ja, wie?

Danke im Voraus
Chris

Hey Chris,

schön das es soweit klappt.

Du kannst dein LED wie folgt auf Masse schalten. So lange der Schalter dann aber geschlossen ist kannst du sie nicht dimmen…

Wichtig sind die Sicherung nach den Ausgängen. Diese bitte nicht vergessen.

1 Like

Zerstören kann ich da aber nichts? :wink:

Aber direkt dimmen an dem Schalter kann das aber nicht? Ich habe jetzt einen Schalter abgeschlossen. Wenn ich auf 50% gestimmt habe und den Schalter betätige, habe ich 100%

Solange du alles gut abgesichert hast, passiert nichts :wink:

Genau der Mosfet wird damit überbrückt und du kannst die LED´s direkt schalten. Dies ist praktisch wenn man testet aber das Licht an bleiben soll oder die Wifi Verbindung Probleme macht.

Alternativ kannst du die Masse auch über ein Relay vom Relayboard schalten. Sollte der Wemos d1 und Tasmota also nach einem Neustart noch 2-3min brauchen um sich zu verbinden, kannst du immer noch das Licht über ein Relay schalten ohne das man im dunkeln sitzt.

Ahh okay verstehe, aber direkt dimmen am schalter, z.b. einmal drücken = an / gedrückt halten = heller bzw. dunkler ist nicht möglich?

Moin zusammen, die Funktion das Relaisboard pro Schaltkreis um beliebige Taster zu erweitern, ist denke ich unerlässlich. Beispiel: Wenn ich in den Van komme möchte ich an dr Schiebetür mit einem Taster schnell und unkompliziert das Licht anschalten können. Oder dann am Bett auch wieder ausschalten etc. Nur über die App zu schalten wäre für mich keine Option und über den Schalter zu eingeschränkt, weil ich immer wieder zur Tür zurück muss….

Gruß
Michael

1 Like

Können wir nicht beliebig mit einem ESP32 erweitern und damit quasi digitale Tester ins system bauen?

wäre halt noch ein Teil mehr. Ich denke an/aus via Taster muss schon sein. Zur Tür rein Licht an, ins Bett und Licht wieder aus. Oder Trittstufe ausfahren an der Schiebetür und Einfahren vom Fahrersitz aus. Normale Schalter brauche ich kaum.

Gruß
Michael

Absolut. “Workaround” eben.

Ich würde ebenfalls gerne an diversen stellen zusätzliche Taster einbauen wollen. Aufrgund Node Red müsste dann ja problemlos der Taster als “Allerlei-Knopf” fungieren können.

1 Like

Hallo Pekaway Team,

Mitte der Woche ist mein Dimmy Board gekommen.
Da war ich schon ein wenig geschockt.
Ich habe extra das komplette Set geholt, weil ich gedacht habe da hab ich weniger Arbeit.
Flashen aufstecken In Betrieb nehmen, Leider Fehlanzeige.
Auf dem Board sind keine Stecker, so wie auf dem Relais Board für den PI.
Die Stecker die im Tütchen vom ESP32 sind zu wenig, und zu kurz, keine 10 Pole sondern nur 8.
In meinem Sammelsurium hab ich noch 4 Buchenreihen gefunden, und aufgelötet.
Dan wollte ich den ESP flashen
Wenn ich den ESP32 einstecke erscheint im Gerätemanager „Silicon Labs CP210x USB to UART Bridge (COM6)“
Dann gehe ich mit dem Chrom Browser auf flashesp | Pekaway - VANPI the AIO CamperUnit, klicke auf Connect,
verbind mich mit dem ESP auf COM 6, Install PEKAWAY TASMOTA, und dann erscheint:

Installing Pekaway Tasmota
??
Your ESP32 board is not supported.

Was mache ich falsch, wie bekomme ich Abhilfe, wie geht’s weiter???
MfG
Arno

Moin Arno,
ich habe mein Dimmy auch bekommen. Die ganzen Einzelteile zusammenbauen musste ich auch, aber der ESP war schon geflasht. Also “nur” noch Strom drauf und fertig.
Viele Grüße
Frederik

Eigentlich geht es hier doch um Taster oder? :wink:

Ich bin gerade auf der Suche nach einer Möglichkeit per Taster einen Zustand zu “erzwingen”. Sprich ich möchte wie mit den Philipps Hue-Tastern einfach etwas “programmieren”.

Beispiel: Ich betätige Taster 1 am Eingang der Schiebetüre, dann geht jegliche Beleuchtung am Auto aus, aber am Einsteig die Leuchte für das Trittbrett an.

Wo aber könnte ich so ein “Eingang” hinzimmern? Ich brauch ja nur zwei Litzen die zu einem Taster führen, nur an welcher Stelle können wir diesen Schaltvorgang überwachen und dann auch einer “Aktion” zuordnen?

Hey Arno,

das DimmyBoard kann sowohl mit dem Wemos d1 mini (esp8266) als auch mit dem Wemos d1 pro (esp32) bespielt werden.

Wir haben im Shop und als Software (PekawayMota) bis jetzt nur das Wemos d1 mini.
Also das was du von uns bekommen hast (einen Wemos d1 mini esp8266 mit einer 8 Pin Leiste) solltest du auch über Chrome oder den OnboardFlasher auf dem Raspberry Flashen können.

Esp32 folgt.

Ansonsten bitte auch Fragen zur Bestellung direkt über die Webseite oder per Mail. :wink:

@Karl Danke für die schnelle Hilfe.

@BT6100 Taster geht auch :wink:

Nach dem Karl mir den Wemos d1 mini (esp8266) geschickt hat, habe ich das Ganze in meinem Versuchsaufbau montiert, und ein bisschen in Node Red ausprobiert.

Ich habe das „alte Relay-Board“ und einem machgerüsteten i2C Ausgang, mit einem MC23017 für die Eingänge

von den 8 Eingängen nutze ich jetzt die ersten 4 für das Mosfet Board um die Ausgänge zu schalten.

On=eingestellter Wert über den Schieberegler (Memory Funktion).

Da auf dem esp8266 noch 8 GPIO´s frei sind, versuche ich demnächst alles über das Dimmyboard zu machen.

Für alle die es interessiert, ein paar Bilder und den Flow


[{"id":"cb5f48f44725f232","type":"tab","label":"ExterneSchalter","disabled":false,"info":"","env":[]},{"id":"ea293678b60f7ec7","type":"link out","z":"cb5f48f44725f232","d":true,"name":"switch connect 1","mode":"link","links":["e9ffa3ef.cde5d"],"x":1235,"y":120,"wires":[]},{"id":"2674907ca540146b","type":"link out","z":"cb5f48f44725f232","d":true,"name":"switch connect 4","mode":"link","links":["f14867fc.930ab8"],"x":1235,"y":300,"wires":[]},{"id":"edde7283845b7ecb","type":"link out","z":"cb5f48f44725f232","name":"switch connect 5","links":["8cde3678.94ac88","1d05179e.1f1a78","1e0f28f7.6b3347","a17061ed.e682d"],"x":1235,"y":340,"wires":[]},{"id":"5579abdd1f35f98b","type":"link out","z":"cb5f48f44725f232","name":"switch connect 6","links":["a45ee432.b7ef98","c9adec52.63ae6","f4303c75.d5b1c","31dcf86e.085898"],"x":1235,"y":380,"wires":[]},{"id":"da76a9767fa76e3b","type":"link out","z":"cb5f48f44725f232","name":"switch connect 7","links":["e97a5ba1.09c7e8","38796905.f4b7f6","de881e69.90777","3f2d3621.ced3da"],"x":1235,"y":420,"wires":[]},{"id":"da96a72d8b83cf4e","type":"link out","z":"cb5f48f44725f232","name":"switch connect 8","links":["95089e82.5785e","2840c10.f61294","f38ca7b2.7594d8","c946b435.21b198"],"x":1235,"y":460,"wires":[]},{"id":"3a7e6e56b8426cd3","type":"link out","z":"cb5f48f44725f232","d":true,"name":"switch connect 2","mode":"link","links":["7255f9f4.6304d8"],"x":1235,"y":180,"wires":[]},{"id":"72ce8a3f13a877b0","type":"link out","z":"cb5f48f44725f232","d":true,"name":"switch connect 3","mode":"link","links":["c698c6e8.416b58"],"x":1235,"y":240,"wires":[]},{"id":"0e679b012a2498b9","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":460,"wires":[]},{"id":"3a1d3e9288b183f5","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":420,"wires":[]},{"id":"999e67b773b6c908","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"7","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":460,"wires":[["da96a72d8b83cf4e","0e679b012a2498b9"]]},{"id":"6b6e17c2a49e21f3","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"6","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":420,"wires":[["da76a9767fa76e3b","3a1d3e9288b183f5"]]},{"id":"43e6f7a6f01a1c08","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":380,"wires":[]},{"id":"f690687a0907615b","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"5","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":380,"wires":[["5579abdd1f35f98b","43e6f7a6f01a1c08"]]},{"id":"57a4f8d476396f25","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":340,"wires":[]},{"id":"45168b9c1733652a","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":300,"wires":[]},{"id":"f31782f60cc1cd59","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"4","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":340,"wires":[["edde7283845b7ecb","57a4f8d476396f25"]]},{"id":"07f488cd0a69369b","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"3","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":300,"wires":[["c36d31c0c17e56e1","45168b9c1733652a","2674907ca540146b"]]},{"id":"75f9d6d9ec592080","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":240,"wires":[]},{"id":"712bf14eb50f3ef3","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":180,"wires":[]},{"id":"ccd48f3c83b539d8","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"2","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":240,"wires":[["17c9bf52fea9a3e5","72ce8a3f13a877b0","75f9d6d9ec592080"]]},{"id":"ec0b070f6386b884","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"1","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":180,"wires":[["108eca4720828cba","712bf14eb50f3ef3","3a7e6e56b8426cd3"]]},{"id":"9b372d708ba245d7","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":970,"y":120,"wires":[]},{"id":"449f9de136427704","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"0","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":120,"wires":[["ea293678b60f7ec7","5570c85237081198","9b372d708ba245d7"]]},{"id":"bd32befb61d6c1c9","type":"comment","z":"cb5f48f44725f232","name":"mcp23017chip","info":"","x":210,"y":80,"wires":[]},{"id":"a9a74e13a2614e4e","type":"comment","z":"cb5f48f44725f232","name":"Achtung Pekaway verwendet die Gleiche Adresse 20","info":"","x":750,"y":80,"wires":[]},{"id":"d9af6084a0454db1","type":"mqtt out","z":"cb5f48f44725f232","name":"","topic":"","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"0ddb07c65cbb68bc","x":1530,"y":680,"wires":[]},{"id":"f50d8139531f7089","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":4,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":680,"wires":[["07cd5a4c59219153","c622b22719356e5c","a6de0d99506da97e"]]},{"id":"39c391eb92c55d77","type":"link in","z":"cb5f48f44725f232","name":"dimmer0 value/name","links":["ee271eb64628fc0a"],"x":305,"y":600,"wires":[["64667e58c9ddc644"]]},{"id":"5ee6246f8ed4a254","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer0\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":600,"wires":[["6a2a9f6e0d05a6aa"]]},{"id":"6a2a9f6e0d05a6aa","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,0,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":600,"wires":[["d9af6084a0454db1"]]},{"id":"07cd5a4c59219153","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer1\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":680,"wires":[["5ce7cb147e3d0b03"]]},{"id":"5ce7cb147e3d0b03","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,1,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":680,"wires":[["d9af6084a0454db1"]]},{"id":"e8bcdbb5a8c1115f","type":"link in","z":"cb5f48f44725f232","name":"dimmer1 value/name","links":["c6b55fd009e69ef0"],"x":305,"y":680,"wires":[["9d6f7b66cd576232"]]},{"id":"9cc34554a258c383","type":"link in","z":"cb5f48f44725f232","name":"dimmer2 value/name","links":["325d9614f6237827"],"x":305,"y":760,"wires":[["8f965550de64f127"]]},{"id":"f653138c9b3cbe2b","type":"link in","z":"cb5f48f44725f232","name":"dimmer3 value/name","links":["31f94e298e95c2b4"],"x":305,"y":840,"wires":[["ca9d03feb97bdfbc"]]},{"id":"1376f8955ba6e1e0","type":"link in","z":"cb5f48f44725f232","name":"dimmer4 value/name","links":["9d8da021cba66085"],"x":305,"y":920,"wires":[["f9a83844e17422bc"]]},{"id":"d79673761db440f4","type":"link in","z":"cb5f48f44725f232","name":"dimmer5 value/name","links":["3b589471ad93efe2"],"x":305,"y":1000,"wires":[["2e599513c0434d6b"]]},{"id":"4bb6225a277597c9","type":"link in","z":"cb5f48f44725f232","name":"dimmer6 value/name","links":["6ce111f8c4860e01"],"x":305,"y":1080,"wires":[["0668502e608f8bd0"]]},{"id":"59d84bf44afeb5bf","type":"link in","z":"cb5f48f44725f232","name":"dimmer7 value/name","links":["fa4a585a780c2772"],"x":305,"y":1160,"wires":[["21a8e71ad55a68b8"]]},{"id":"5c27aee58f56ce6d","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":6,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":760,"wires":[["c28d50fab0225f06","c622b22719356e5c","21e9ef7430aee699"]]},{"id":"b404e169f4078976","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":8,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":840,"wires":[["435a60704973aaec","c622b22719356e5c","38b9cf440622088b"]]},{"id":"e1b68b892bf16c77","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":10,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":920,"wires":[["9005d5b8312165fd","c622b22719356e5c","b9e099d398477262"]]},{"id":"09eab325530d7a1c","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":12,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":1000,"wires":[["b396ae2905870e4c","c622b22719356e5c","8f91c45a65d44107"]]},{"id":"cf160e500d124906","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":14,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":1080,"wires":[["8fdd6b97de81c144","c622b22719356e5c","6962ab70812067e9"]]},{"id":"8be7759755ab5498","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":16,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":1160,"wires":[["f195d5cc86667539","c622b22719356e5c","15180c374d4c0430"]]},{"id":"c28d50fab0225f06","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer2\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":760,"wires":[["0454156606c27d05"]]},{"id":"0454156606c27d05","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,2,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":760,"wires":[["d9af6084a0454db1"]]},{"id":"435a60704973aaec","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer3\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":840,"wires":[["0e4bb57c8378b90b"]]},{"id":"0e4bb57c8378b90b","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,3,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":840,"wires":[["d9af6084a0454db1"]]},{"id":"9005d5b8312165fd","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer4\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":920,"wires":[["5267c7bec312db58"]]},{"id":"5267c7bec312db58","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,4,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":920,"wires":[["d9af6084a0454db1"]]},{"id":"b396ae2905870e4c","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer5\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":1000,"wires":[["977168a8e183a713"]]},{"id":"977168a8e183a713","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,5,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":1000,"wires":[["d9af6084a0454db1"]]},{"id":"8fdd6b97de81c144","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer6\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":1080,"wires":[["af90f0f35da3a1ba"]]},{"id":"af90f0f35da3a1ba","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,6,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":1080,"wires":[["d9af6084a0454db1"]]},{"id":"f195d5cc86667539","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer7\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":1160,"wires":[["f8327e1c45eb288e"]]},{"id":"f8327e1c45eb288e","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,7,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":1160,"wires":[["d9af6084a0454db1"]]},{"id":"bc6e4874c450ef34","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":2,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":600,"wires":[["c622b22719356e5c","5ee6246f8ed4a254","bc3034f50653dfb7"]]},{"id":"64667e58c9ddc644","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer0\");\nvar check = global.get(\"dimmone\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":600,"wires":[["bc6e4874c450ef34"]]},{"id":"c622b22719356e5c","type":"function","z":"cb5f48f44725f232","name":"save relay status","func":"var check2 = flow.get(\"Rupdate\");\n\n\nif (check2 != true)\n{\n\nmsg.payload = { \"dimmone\":global.get(\"dimmone\"),\n\"dimmtwo\":global.get(\"dimmtwo\"),\n\"dimmthree\":global.get(\"dimmthree\"),\n\"dimmfour\":global.get(\"dimmfour\"),\n\"dimmfive\":global.get(\"dimmfive\"),\n\"dimmsix\":global.get(\"dimmsix\"),\n\"dimmseven\":global.get(\"dimmseven\"),\n\"dimmeight\":global.get(\"dimmeight\")\n}\nreturn msg;\n}","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1050,"y":1240,"wires":[["0f759d2f8b678f56"]]},{"id":"0f759d2f8b678f56","type":"file","z":"cb5f48f44725f232","name":"","filename":"pekaway/SwDimmstatusload","appendNewline":true,"createDir":false,"overwriteFile":"true","encoding":"none","x":1310,"y":1240,"wires":[[]]},{"id":"6510e56a43ada11a","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmone","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmone\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmone\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmone\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":580,"wires":[["bc6e4874c450ef34"]]},{"id":"5570c85237081198","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":370,"y":120,"wires":[["6510e56a43ada11a"],[]]},{"id":"9d6f7b66cd576232","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer1\");\nvar check = global.get(\"dimmtwo\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":680,"wires":[["f50d8139531f7089"]]},{"id":"8f965550de64f127","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer2\");\nvar check = global.get(\"dimmthree\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":760,"wires":[["5c27aee58f56ce6d"]]},{"id":"ca9d03feb97bdfbc","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer3\");\nvar check = global.get(\"dimmfour\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":840,"wires":[["b404e169f4078976"]]},{"id":"f9a83844e17422bc","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer4\");\nvar check = global.get(\"dimmfive\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":920,"wires":[["e1b68b892bf16c77"]]},{"id":"2e599513c0434d6b","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer5\");\nvar check = global.get(\"dimmsix\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":1000,"wires":[["09eab325530d7a1c"]]},{"id":"0668502e608f8bd0","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer6\");\nvar check = global.get(\"dimmseven\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":1080,"wires":[["cf160e500d124906"]]},{"id":"21a8e71ad55a68b8","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer7\");\nvar check = global.get(\"dimmeight\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":1160,"wires":[["8be7759755ab5498"]]},{"id":"108eca4720828cba","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":370,"y":180,"wires":[["c7cdeffe5c226f37"],[]]},{"id":"17c9bf52fea9a3e5","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":380,"y":240,"wires":[["454b0b2c4274a51a"],[]]},{"id":"c36d31c0c17e56e1","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"},{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":380,"y":300,"wires":[["253b4a923f4c8cdf"],[]]},{"id":"c7cdeffe5c226f37","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmtwo","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmtwo\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmtwo\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmtwo\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":660,"wires":[["f50d8139531f7089"]]},{"id":"454b0b2c4274a51a","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmothree","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmthree\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmthree\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmthree\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":740,"wires":[["5c27aee58f56ce6d"]]},{"id":"253b4a923f4c8cdf","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmfour","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmfour\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmfour\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmfour\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":820,"wires":[["b404e169f4078976"]]},{"id":"928f1dde39c7932d","type":"file in","z":"cb5f48f44725f232","name":"","filename":"pekaway/SwDimmstatusload","format":"utf8","chunk":false,"sendError":false,"encoding":"none","allProps":false,"x":440,"y":1300,"wires":[["89f5560aa6a1de5d"]]},{"id":"bc3034f50653dfb7","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmone\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":560,"wires":[[]]},{"id":"a6de0d99506da97e","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmtwo\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":640,"wires":[[]]},{"id":"21e9ef7430aee699","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmthree\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":720,"wires":[[]]},{"id":"38b9cf440622088b","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmfour\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":800,"wires":[[]]},{"id":"b9e099d398477262","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmfive\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":880,"wires":[[]]},{"id":"8f91c45a65d44107","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmsix\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":960,"wires":[[]]},{"id":"6962ab70812067e9","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmseven\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":1040,"wires":[[]]},{"id":"15180c374d4c0430","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmeight\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":1120,"wires":[[]]},{"id":"ae42518a70c05794","type":"inject","z":"cb5f48f44725f232","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":"10","topic":"","payload":"","payloadType":"date","x":180,"y":1300,"wires":[["928f1dde39c7932d"]]},{"id":"89f5560aa6a1de5d","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":670,"y":1300,"wires":[]},{"id":"f32fe13c5fb7c682","type":"link in","z":"cb5f48f44725f232","name":"pekaway display dimmer","links":["8d2726e6672c69f0"],"x":355,"y":640,"wires":[["64667e58c9ddc644","21a8e71ad55a68b8","0668502e608f8bd0","2e599513c0434d6b","f9a83844e17422bc","8f965550de64f127","9d6f7b66cd576232","ca9d03feb97bdfbc"]]},{"id":"7d707a6fc0325b8c","type":"mcp23017chip","addr":"0x20","interval":"100"},{"id":"0ddb07c65cbb68bc","type":"mqtt-broker","name":"","broker":"http://localhost","port":"1883","clientid":"","usetls":false,"protocolVersion":"4","keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","birthMsg":{},"closeTopic":"","closeQos":"0","closePayload":"","closeMsg":{},"willTopic":"","willQos":"0","willPayload":"","willMsg":{},"sessionExpiry":""},{"id":"b39a769e1a5ab2d0","type":"ui_group","name":"Dimmer","tab":"c7e50f4d.33f09","order":4,"disp":true,"width":"6","collapse":false,"className":""},{"id":"c7e50f4d.33f09","type":"ui_tab","name":"Switches","icon":"mi-toggle_on","order":2,"disabled":false,"hidden":false}]

Da ich nicht der Progammierer vor dem Herr binn,(meine Welt ist FUP Programmierung) gibt es sicher bessere Möglichkeiten, aber es funktioniert. Innerhalb der ersten ca. 10 minuten nach dem Laden, macht das Ding komische Sachen???, aber danach funktioniert es einwandfrei.

Gruß Arno

Hallo Kai?? BT6100
Um auf deine Frage zu Antworten.
Da wirst du etwas basteln müssen. Wenn du das neue Relaiy Bord hast, da ist eine I2C Buchse dran.
Bei dem alten kann man eine Nachrüsten. Wenn du das Mosfet Board hast nimmst du dir einen freien GPIO.
Dann musst du “Nur” noch in Node Red etwas zusammen basteln. Im Prinzip ist in dem Projekt alles verbaut, man muss es sich nur zusammenkopieren, und ein bischen im WWW nach Nod Red Googlen.
Oder hier fragen, vielleicht macht dir einer einen Flow.
Gruß Arno

1 Like

Danke für den Hinweis. Teste ich.

Ich warte schon sehnsüchtig auf meine Boards! :slight_smile:

Grüße Kai
BT6100 - ist der Sprinter der den HighTec-Einbau bekommt! :smiley:

Mosfetboard - Licht per Taster steuern Teil 2

Ich habe jetzt im Mosfetboard 8 Taster nachgerüstet.

Zuerst habe ich mir einen neuen ESP8266 genommen, und habe nur die GPIO´s die benötigt werden mit dem Board verbunden.
GPIO 2 DS18, GPIO 4 + 5 I2C, GND, 5V, 3V, RST, und A0.
An GPIO 0, 1, 3, 12-16, GND, und 3V, habe ich Strippen angelötet, die ich mit Einbaustecker verbunden habe. Bei den 3 pol Steckern ist der mittlere GND, und am 4 pol ist der 1, und der 3. 3,3V
Die Stecher auf ein Stück Platine gelötet, und mit Heißkleber an den Deckel geklebt.
GPIO 0, 1, 3, 12,13,14 werden gegen GND, und GPIO 15,16, gegen +3.2V geschaltet.

In Tasmota muss dann nur noch GPIO 0, 1, 3, 12-16 als Switch 1-8 konfiguriert werden.
und über die Konsole SwitchMode1-8 15 (SwitchMode1 15, SwitchMode2 15, …) einstellen.
Ich habe das einzeln eingegeben, ich weiß nicht ob man das in einem zusammenhängenden Befehl machen kann.

mit dem MCP 23017 habe ich jetzt 8 Taster zur Verfügung das sollte reichen :upside_down_face:.

@Karl
Wäre das nicht ein Upgrate für Mosfetboard2
ist in der Herstellung sicher nicht so aufwendig wie das nachbasteln.
und die Schalter Leute würden Euch dankbar sein das die Bastelei aufhört. :smiley:




Gruß Arno

3 Likes

Der Code passte nicht mehr :slight_smile:

[{"id":"cb5f48f44725f232","type":"tab","label":"ExterneSchalter","disabled":false,"info":"","env":[]},{"id":"ea293678b60f7ec7","type":"link out","z":"cb5f48f44725f232","name":"switch connect 1","mode":"link","links":["e9ffa3ef.cde5d"],"x":665,"y":120,"wires":[]},{"id":"2674907ca540146b","type":"link out","z":"cb5f48f44725f232","name":"switch connect 4","mode":"link","links":["f14867fc.930ab8"],"x":665,"y":300,"wires":[]},{"id":"edde7283845b7ecb","type":"link out","z":"cb5f48f44725f232","name":"switch connect 5","links":["8cde3678.94ac88","1d05179e.1f1a78","1e0f28f7.6b3347","a17061ed.e682d"],"x":665,"y":340,"wires":[]},{"id":"5579abdd1f35f98b","type":"link out","z":"cb5f48f44725f232","name":"switch connect 6","links":["a45ee432.b7ef98","c9adec52.63ae6","f4303c75.d5b1c","31dcf86e.085898"],"x":665,"y":380,"wires":[]},{"id":"da76a9767fa76e3b","type":"link out","z":"cb5f48f44725f232","name":"switch connect 7","links":["e97a5ba1.09c7e8","38796905.f4b7f6","de881e69.90777","3f2d3621.ced3da"],"x":665,"y":420,"wires":[]},{"id":"da96a72d8b83cf4e","type":"link out","z":"cb5f48f44725f232","name":"switch connect 8","links":["95089e82.5785e","2840c10.f61294","f38ca7b2.7594d8","c946b435.21b198"],"x":665,"y":460,"wires":[]},{"id":"3a7e6e56b8426cd3","type":"link out","z":"cb5f48f44725f232","name":"switch connect 2","mode":"link","links":["7255f9f4.6304d8"],"x":665,"y":180,"wires":[]},{"id":"72ce8a3f13a877b0","type":"link out","z":"cb5f48f44725f232","name":"switch connect 3","mode":"link","links":["c698c6e8.416b58"],"x":665,"y":240,"wires":[]},{"id":"0e679b012a2498b9","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":490,"y":460,"wires":[]},{"id":"3a1d3e9288b183f5","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":490,"y":420,"wires":[]},{"id":"999e67b773b6c908","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"7","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":460,"wires":[["da96a72d8b83cf4e","0e679b012a2498b9"]]},{"id":"6b6e17c2a49e21f3","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"6","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":420,"wires":[["da76a9767fa76e3b","3a1d3e9288b183f5"]]},{"id":"43e6f7a6f01a1c08","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":490,"y":380,"wires":[]},{"id":"f690687a0907615b","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"5","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":380,"wires":[["5579abdd1f35f98b","43e6f7a6f01a1c08"]]},{"id":"57a4f8d476396f25","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":490,"y":340,"wires":[]},{"id":"45168b9c1733652a","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":490,"y":300,"wires":[]},{"id":"f31782f60cc1cd59","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"4","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":210,"y":340,"wires":[["edde7283845b7ecb","57a4f8d476396f25"]]},{"id":"07f488cd0a69369b","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"3","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":300,"wires":[["45168b9c1733652a","2674907ca540146b"]]},{"id":"75f9d6d9ec592080","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":490,"y":240,"wires":[]},{"id":"712bf14eb50f3ef3","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":490,"y":180,"wires":[]},{"id":"ccd48f3c83b539d8","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"2","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":240,"wires":[["72ce8a3f13a877b0","75f9d6d9ec592080"]]},{"id":"ec0b070f6386b884","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"1","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":180,"wires":[["712bf14eb50f3ef3","3a7e6e56b8426cd3"]]},{"id":"9b372d708ba245d7","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":490,"y":120,"wires":[]},{"id":"449f9de136427704","type":"mcp23017input","z":"cb5f48f44725f232","name":"","chip":"7d707a6fc0325b8c","bitNum":"0","pullUp":true,"invert":false,"debounce":200,"onMsg":false,"offMsg":true,"x":220,"y":120,"wires":[["ea293678b60f7ec7","9b372d708ba245d7"]]},{"id":"bd32befb61d6c1c9","type":"comment","z":"cb5f48f44725f232","name":"mcp23017chip","info":"","x":210,"y":80,"wires":[]},{"id":"a9a74e13a2614e4e","type":"comment","z":"cb5f48f44725f232","name":"Achtung Pekaway verwendet die Gleiche Adresse 20","info":"","x":750,"y":80,"wires":[]},{"id":"d9af6084a0454db1","type":"mqtt out","z":"cb5f48f44725f232","name":"","topic":"","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"0ddb07c65cbb68bc","x":1530,"y":680,"wires":[]},{"id":"f50d8139531f7089","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":4,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":680,"wires":[["07cd5a4c59219153","c622b22719356e5c","a6de0d99506da97e"]]},{"id":"39c391eb92c55d77","type":"link in","z":"cb5f48f44725f232","name":"dimmer0 value/name","links":["ee271eb64628fc0a"],"x":305,"y":600,"wires":[["64667e58c9ddc644"]]},{"id":"5ee6246f8ed4a254","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer0\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":600,"wires":[["6a2a9f6e0d05a6aa"]]},{"id":"6a2a9f6e0d05a6aa","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,0,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":600,"wires":[["d9af6084a0454db1"]]},{"id":"07cd5a4c59219153","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer1\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":680,"wires":[["5ce7cb147e3d0b03"]]},{"id":"5ce7cb147e3d0b03","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,1,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":680,"wires":[["d9af6084a0454db1"]]},{"id":"e8bcdbb5a8c1115f","type":"link in","z":"cb5f48f44725f232","name":"dimmer1 value/name","links":["c6b55fd009e69ef0"],"x":305,"y":680,"wires":[["9d6f7b66cd576232"]]},{"id":"9cc34554a258c383","type":"link in","z":"cb5f48f44725f232","name":"dimmer2 value/name","links":["325d9614f6237827"],"x":305,"y":760,"wires":[["8f965550de64f127"]]},{"id":"f653138c9b3cbe2b","type":"link in","z":"cb5f48f44725f232","name":"dimmer3 value/name","links":["31f94e298e95c2b4"],"x":305,"y":840,"wires":[["ca9d03feb97bdfbc"]]},{"id":"1376f8955ba6e1e0","type":"link in","z":"cb5f48f44725f232","name":"dimmer4 value/name","links":["9d8da021cba66085"],"x":305,"y":920,"wires":[["f9a83844e17422bc"]]},{"id":"d79673761db440f4","type":"link in","z":"cb5f48f44725f232","name":"dimmer5 value/name","links":["3b589471ad93efe2"],"x":305,"y":1000,"wires":[["2e599513c0434d6b"]]},{"id":"4bb6225a277597c9","type":"link in","z":"cb5f48f44725f232","name":"dimmer6 value/name","links":["6ce111f8c4860e01"],"x":305,"y":1080,"wires":[["0668502e608f8bd0"]]},{"id":"59d84bf44afeb5bf","type":"link in","z":"cb5f48f44725f232","name":"dimmer7 value/name","links":["fa4a585a780c2772"],"x":305,"y":1160,"wires":[["21a8e71ad55a68b8"]]},{"id":"5c27aee58f56ce6d","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":6,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":760,"wires":[["c28d50fab0225f06","c622b22719356e5c","21e9ef7430aee699"]]},{"id":"b404e169f4078976","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":8,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":840,"wires":[["435a60704973aaec","c622b22719356e5c","38b9cf440622088b"]]},{"id":"e1b68b892bf16c77","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":10,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":920,"wires":[["9005d5b8312165fd","c622b22719356e5c","b9e099d398477262"]]},{"id":"09eab325530d7a1c","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":12,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":1000,"wires":[["b396ae2905870e4c","c622b22719356e5c","8f91c45a65d44107"]]},{"id":"cf160e500d124906","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":14,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":1080,"wires":[["8fdd6b97de81c144","c622b22719356e5c","6962ab70812067e9"]]},{"id":"8be7759755ab5498","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":16,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":1160,"wires":[["f195d5cc86667539","c622b22719356e5c","15180c374d4c0430"]]},{"id":"c28d50fab0225f06","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer2\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":760,"wires":[["0454156606c27d05"]]},{"id":"0454156606c27d05","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,2,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":760,"wires":[["d9af6084a0454db1"]]},{"id":"435a60704973aaec","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer3\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":840,"wires":[["0e4bb57c8378b90b"]]},{"id":"0e4bb57c8378b90b","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,3,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":840,"wires":[["d9af6084a0454db1"]]},{"id":"9005d5b8312165fd","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer4\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":920,"wires":[["5267c7bec312db58"]]},{"id":"5267c7bec312db58","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,4,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":920,"wires":[["d9af6084a0454db1"]]},{"id":"b396ae2905870e4c","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer5\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":1000,"wires":[["977168a8e183a713"]]},{"id":"977168a8e183a713","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,5,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":1000,"wires":[["d9af6084a0454db1"]]},{"id":"8fdd6b97de81c144","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer6\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":1080,"wires":[["af90f0f35da3a1ba"]]},{"id":"af90f0f35da3a1ba","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,6,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":1080,"wires":[["d9af6084a0454db1"]]},{"id":"f195d5cc86667539","type":"change","z":"cb5f48f44725f232","name":"on=global dimmer","rules":[{"t":"change","p":"payload","pt":"msg","from":"on","fromt":"str","to":"\"dimmer7\"","tot":"global"}],"action":"","property":"","from":"","to":"","reg":false,"x":1050,"y":1160,"wires":[["f8327e1c45eb288e"]]},{"id":"f8327e1c45eb288e","type":"function","z":"cb5f48f44725f232","name":"set topic & payload","func":"msg.topic = \"pkw/cmnd/PekawayMOTA/driver15\";\nvar value = parseInt(msg.payload)*40;\n\nmsg.payload = \"pwm,7,\" + value;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1270,"y":1160,"wires":[["d9af6084a0454db1"]]},{"id":"bc6e4874c450ef34","type":"ui_switch","z":"cb5f48f44725f232","name":"","label":"{{Dimmname}}","tooltip":"","group":"b39a769e1a5ab2d0","order":2,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","topicType":"str","style":"","onvalue":"on","onvalueType":"str","onicon":"","oncolor":"","offvalue":"off","offvalueType":"str","officon":"","offcolor":"","animate":true,"className":"","x":870,"y":600,"wires":[["c622b22719356e5c","5ee6246f8ed4a254","bc3034f50653dfb7"]]},{"id":"64667e58c9ddc644","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer0\");\nvar check = global.get(\"dimmone\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":600,"wires":[["bc6e4874c450ef34"]]},{"id":"c622b22719356e5c","type":"function","z":"cb5f48f44725f232","name":"save relay status","func":"var check2 = flow.get(\"Rupdate\");\n\n\nif (check2 != true)\n{\n\nmsg.payload = { \"dimmone\":global.get(\"dimmone\"),\n\"dimmtwo\":global.get(\"dimmtwo\"),\n\"dimmthree\":global.get(\"dimmthree\"),\n\"dimmfour\":global.get(\"dimmfour\"),\n\"dimmfive\":global.get(\"dimmfive\"),\n\"dimmsix\":global.get(\"dimmsix\"),\n\"dimmseven\":global.get(\"dimmseven\"),\n\"dimmeight\":global.get(\"dimmeight\")\n}\nreturn msg;\n}","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1050,"y":1240,"wires":[["0f759d2f8b678f56"]]},{"id":"0f759d2f8b678f56","type":"file","z":"cb5f48f44725f232","name":"","filename":"pekaway/SwDimmstatusload","appendNewline":true,"createDir":false,"overwriteFile":"true","encoding":"none","x":1310,"y":1240,"wires":[[]]},{"id":"6510e56a43ada11a","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmone","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmone\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmone\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmone\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":580,"wires":[["bc6e4874c450ef34"]]},{"id":"9d6f7b66cd576232","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer1\");\nvar check = global.get(\"dimmtwo\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":680,"wires":[["f50d8139531f7089"]]},{"id":"8f965550de64f127","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer2\");\nvar check = global.get(\"dimmthree\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":760,"wires":[["5c27aee58f56ce6d"]]},{"id":"ca9d03feb97bdfbc","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer3\");\nvar check = global.get(\"dimmfour\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":840,"wires":[["b404e169f4078976"]]},{"id":"f9a83844e17422bc","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer4\");\nvar check = global.get(\"dimmfive\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":920,"wires":[["e1b68b892bf16c77"]]},{"id":"2e599513c0434d6b","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer5\");\nvar check = global.get(\"dimmsix\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":1000,"wires":[["09eab325530d7a1c"]]},{"id":"0668502e608f8bd0","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer6\");\nvar check = global.get(\"dimmseven\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":1100,"wires":[["cf160e500d124906"]]},{"id":"21a8e71ad55a68b8","type":"function","z":"cb5f48f44725f232","name":"","func":"msg.Dimmname = global.get(\"Ndimmer7\");\nvar check = global.get(\"dimmeight\");\nmsg.payload = check;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":1180,"wires":[["8be7759755ab5498"]]},{"id":"c7cdeffe5c226f37","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmtwo","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmtwo\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmtwo\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmtwo\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":660,"wires":[["f50d8139531f7089"]]},{"id":"454b0b2c4274a51a","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmothree","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmthree\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmthree\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmthree\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":740,"wires":[["5c27aee58f56ce6d"]]},{"id":"253b4a923f4c8cdf","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmfour","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmfour\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmfour\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmfour\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":820,"wires":[["b404e169f4078976"]]},{"id":"928f1dde39c7932d","type":"file in","z":"cb5f48f44725f232","name":"","filename":"pekaway/SwDimmstatusload","format":"utf8","chunk":false,"sendError":false,"encoding":"none","allProps":false,"x":390,"y":1720,"wires":[["89f5560aa6a1de5d"]]},{"id":"bc3034f50653dfb7","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmone\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":560,"wires":[[]]},{"id":"a6de0d99506da97e","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmtwo\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":640,"wires":[[]]},{"id":"21e9ef7430aee699","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmthree\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":720,"wires":[[]]},{"id":"38b9cf440622088b","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmfour\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":800,"wires":[[]]},{"id":"b9e099d398477262","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmfive\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":880,"wires":[[]]},{"id":"8f91c45a65d44107","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmsix\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":960,"wires":[[]]},{"id":"6962ab70812067e9","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmseven\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":1040,"wires":[[]]},{"id":"15180c374d4c0430","type":"function","z":"cb5f48f44725f232","name":"set Global","func":"global.set(\"dimmeight\", msg.payload);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1020,"y":1120,"wires":[[]]},{"id":"ae42518a70c05794","type":"inject","z":"cb5f48f44725f232","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":"10","topic":"","payload":"","payloadType":"date","x":130,"y":1720,"wires":[["928f1dde39c7932d"]]},{"id":"89f5560aa6a1de5d","type":"debug","z":"cb5f48f44725f232","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":620,"y":1720,"wires":[]},{"id":"f32fe13c5fb7c682","type":"link in","z":"cb5f48f44725f232","name":"pekaway display dimmer","links":["8d2726e6672c69f0"],"x":355,"y":640,"wires":[["64667e58c9ddc644","21a8e71ad55a68b8","0668502e608f8bd0","2e599513c0434d6b","f9a83844e17422bc","8f965550de64f127","9d6f7b66cd576232","ca9d03feb97bdfbc"]]},{"id":"64c23e9f22719e99","type":"mqtt in","z":"cb5f48f44725f232","name":"","topic":"pkw/tele/PekawayMOTA/SENSOR","qos":"2","datatype":"auto","broker":"0ddb07c65cbb68bc","nl":false,"rap":true,"rh":0,"inputs":0,"x":240,"y":1600,"wires":[["9b301d9261b21278"]]},{"id":"d273a10da8006dd3","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"Switch1","vt":"str"},{"t":"cont","v":"Switch2","vt":"str"},{"t":"cont","v":"Switch3","vt":"str"},{"t":"cont","v":"Switch4","vt":"str"},{"t":"cont","v":"Switch5","vt":"str"},{"t":"cont","v":"Switch6","vt":"str"},{"t":"cont","v":"Switch7","vt":"str"},{"t":"cont","v":"Switch8","vt":"str"}],"checkall":"true","repair":false,"outputs":8,"x":210,"y":1480,"wires":[["b58b6f962bf17bdf"],["8047109872e89e15"],["7a858dc806b4c700"],["0269c10b5500682f"],["de327356958c97d5"],["09d69c202b7e0932"],["62f6974f4050a1d3"],["43bd8c9c8588f714"]]},{"id":"9b301d9261b21278","type":"split","z":"cb5f48f44725f232","name":"","splt":",","spltType":"str","arraySplt":1,"arraySpltType":"len","stream":false,"addname":"","x":490,"y":1600,"wires":[["d273a10da8006dd3"]]},{"id":"b58b6f962bf17bdf","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"OFF","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1260,"wires":[["6510e56a43ada11a"]]},{"id":"b8c0056dc31012d3","type":"function","z":"cb5f48f44725f232","name":"globalVariable set Dimmseven","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmseven\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmseven\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmseven\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":1060,"wires":[["cf160e500d124906"]]},{"id":"8047109872e89e15","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"OFF","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1280,"wires":[["c7cdeffe5c226f37"]]},{"id":"7a858dc806b4c700","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"OFF","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1300,"wires":[["454b0b2c4274a51a"]]},{"id":"0269c10b5500682f","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"OFF","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1320,"wires":[["253b4a923f4c8cdf"]]},{"id":"de327356958c97d5","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"OFF","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1340,"wires":[["bfcbd71effa3c214"]]},{"id":"09d69c202b7e0932","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"OFF","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1360,"wires":[["ab1b167d4685b742"]]},{"id":"62f6974f4050a1d3","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"ON","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1380,"wires":[["b8c0056dc31012d3"]]},{"id":"43bd8c9c8588f714","type":"switch","z":"cb5f48f44725f232","name":"","property":"payload","propertyType":"msg","rules":[{"t":"cont","v":"ON","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":1400,"wires":[["c83f9be83093ad6f","7e7a08b566526603"]]},{"id":"c83f9be83093ad6f","type":"debug","z":"cb5f48f44725f232","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":690,"y":1400,"wires":[]},{"id":"7e7a08b566526603","type":"function","z":"cb5f48f44725f232","name":"globalVariable set dimmeight","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmeight\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmeight\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmeight\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":1140,"wires":[["8be7759755ab5498"]]},{"id":"bfcbd71effa3c214","type":"function","z":"cb5f48f44725f232","name":"globalVariable set dimmfive","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmfive\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmfive\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmfive\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":900,"wires":[["e1b68b892bf16c77"]]},{"id":"ab1b167d4685b742","type":"function","z":"cb5f48f44725f232","name":"globalVariable set dimmsix","func":"\nvar check2 = flow.get(\"Rupdate\");\n \n\nvar check = global.get(\"dimmsix\");\n\n\nif(check2 === \"on\")\n{\n    return\n}\nelse\n{\nif (check === \"on\")\n   { \n   check= \"off\"; \n   global.set(\"dimmsix\", \"off\");\n       \n   }\n    else\n    {\n    check = \"on\"; \n      global.set(\"dimmsix\", \"on\");\n    }\n    \nmsg.payload = check;\nreturn msg;\n}\n\n\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":980,"wires":[["09eab325530d7a1c"]]},{"id":"7d707a6fc0325b8c","type":"mcp23017chip","addr":"0x20","interval":"100"},{"id":"0ddb07c65cbb68bc","type":"mqtt-broker","name":"","broker":"http://localhost","port":"1883","clientid":"","usetls":false,"protocolVersion":"4","keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","birthMsg":{},"closeTopic":"","closeQos":"0","closePayload":"","closeMsg":{},"willTopic":"","willQos":"0","willPayload":"","willMsg":{},"sessionExpiry":""},{"id":"b39a769e1a5ab2d0","type":"ui_group","name":"Dimmer","tab":"c7e50f4d.33f09","order":4,"disp":true,"width":"6","collapse":false,"className":""},{"id":"c7e50f4d.33f09","type":"ui_tab","name":"Switches","icon":"mi-toggle_on","order":2,"disabled":false,"hidden":false}]

Sieht gut aus!
Sollte kein Problem sein das Dimmy Board so zu erweitern.

Alternativ können auf dem VANPI - Board auch die MCP23017 Eingänge benutzt werden. Ich werde dazu mal ein Tutorial machen…

1 Like

Hallo @Karl

Ich habe gerade den Schaltplan gecheckt. NOCH habe ich Stirnrunzeln. Die Idee gefällt mir außerordentlich gut. An dem Tutorial wäre ich brennend interessiert.

@ahtdf Danke. Mir gefällt beides! I2C auf dem Relay um zu erweitern und überhaupt die ungenutzten GPIOs zu nutzen. Das ist doch perfekt!

1 Like