Editing Blinkencontrol

From Chaosdorf Wiki
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 5: Line 5:
|location=Laptop Lounge
|location=Laptop Lounge
|image=blinkencontrol hardware.jpg
|image=blinkencontrol hardware.jpg
|status=obsolete
|status=beta
|people={{U|derf}}
|people={{U|derf}}
|source=https://github.com/derf/dorfmap{{!}}github
|source=https://github.com/derf/dorfmap{{!}}github
}}
}}
[[File:Blinkencontrol.png|Schaltplan für RGB|200x200px|thumb|right]]


Aktuell gibts zwei Instanzen:
[[File:Blinkencontrol.png|Schaltplan für RGB|200x200px|framed|right]]
* [[Laptop Lounge]] an {{H|donationprint}} (RGB-Streifen im Fenster, eigenes 9V-Netzteil)
* [[Hackcenter]] an {{H|feedback}} (oberes Regal neben dem Drucker, [[Kabelbaum]]-Netzteil)


Angeschlossen via [[SI2C]], Ansteuerung per [http://dorfmap.chaosdorf.dn42 dorfmap] (siehe [[Lichtsteuerung]]).
Eine Instanz hängt in der [[Laptop Lounge]] und steuert den RGB-Streifen im Schaufenster. Angeschlossen per GPIO an {{H|donationprint}}, Ansteuerung wie gewohnt per [http://dorfmap/blinkencontrol/lounge_rggb dorfmap] (siehe [[Lichtsteuerung]]).


== Protokoll ==
== Protokoll ==
Line 29: Line 26:


<tt>red</tt>, <tt>green</tt> und <tt>blue</tt> sind PWM-Level von 0 (aus) bis 255 (maximale Helligkeit). Beachten: Es findet derzeit keine Helligkeitsanpassung statt, d.h. es wird linear gefadet, während das menschliche Auge Helligkeit [http://www.mikrocontroller.net/articles/LED-Fading logarithmisch wahrnimmt].
<tt>red</tt>, <tt>green</tt> und <tt>blue</tt> sind PWM-Level von 0 (aus) bis 255 (maximale Helligkeit). Beachten: Es findet derzeit keine Helligkeitsanpassung statt, d.h. es wird linear gefadet, während das menschliche Auge Helligkeit [http://www.mikrocontroller.net/articles/LED-Fading logarithmisch wahrnimmt].
== netcat-API ==
Obiges Protokoll (teils in Variationen) kann zur Ansteuerung diverser Geräte benutzt wrden. Die erste Zeile wählt das Blinkendevice aus (z.B. "blinkencontrol1" oder "charwrite1"), alle weiteren gehen an das jeweilige Programm. Nach den Daten muss teilweise noch die 16bit-Adresse übertragen werden, erst high byte, dann low byte. Der Daemon lauscht auf <tt>donationprint:25465</tt>.
Diese netcat-API wird bald abgeschaltet und durch eine API in der [[Lichtsteuerung]] (dorfmap) ersetzt.
=== charwrite1 ===
Nimmt vier Zeichen (ASCII, 0-9a-zA-Z) an und überträgt sie bei einer Newline. Zum Beispiel:
<source lang="bash">
echo "charwrite1\nohai" | nc donationprint 25465
</source>
Please note that all contributions to Chaosdorf Wiki are considered to be released under the Attribution 3.0 Unported (see Chaosdorf Wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!
Cancel Editing help (opens in new window)