Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
| Beide Seiten der vorigen RevisionVorhergehende Überarbeitung | |||
| alarmsystem [14.01.2018 18:24] – havelock | alarmsystem [20.01.2018 20:01] (aktuell) – [Software] havelock | ||
|---|---|---|---|
| Zeile 92: | Zeile 92: | ||
| Das Fahrzeug /Mein Auto/ wird gerade bewegt. | Das Fahrzeug /Mein Auto/ wird gerade bewegt. | ||
| EOF | EOF | ||
| + | </ | ||
| + | |||
| + | Dynamische Steuerung des Client-WLANs im Fahrzeug. | ||
| + | |||
| + | Erster Entwurf: | ||
| + | <file lua meshcheck.lua> | ||
| + | # | ||
| + | |||
| + | function neighbourcount() | ||
| + | local handle = io.popen(" | ||
| + | local result = handle: | ||
| + | handle: | ||
| + | return result | ||
| + | end | ||
| + | |||
| + | function ifstate() | ||
| + | local file = io.open("/ | ||
| + | local result = file: | ||
| + | file: | ||
| + | return result | ||
| + | end | ||
| + | |||
| + | state = ifstate() | ||
| + | if neighbourcount() == 0 then | ||
| + | if state == " | ||
| + | os.execute(" | ||
| + | end | ||
| + | else | ||
| + | if state == " | ||
| + | os.execute(" | ||
| + | end | ||
| + | end | ||
| </ | </ | ||