- testé le mode deep sleep avec dsleep.lua

- fait un petit ping avec ping.lua pour tester si une machine est présente
This commit is contained in:
Christian Zufferey
2018-11-13 20:44:42 +01:00
parent 1d839f8aaa
commit 3bfc2949d2
19 changed files with 377 additions and 8 deletions

20
make_ping.lua Normal file
View File

@@ -0,0 +1,20 @@
-- programme pour faire des ping en permanence
print("\n make_ping.lua zf181113.1947 \n")
zLED=0
gpio.mode(zLED, gpio.OUTPUT)
ztmr_LED = tmr.create()
value = true
dofile("ping.lua")
tmr.alarm(ztmr_LED, 500, tmr.ALARM_AUTO, function ()
if value then
gpio.write(zLED, gpio.HIGH)
else
gpio.write(zLED, gpio.LOW)
Ping("192.168.0.102")
end
value = not value
end)