Make sure the led is off after blinking

This commit is contained in:
Petros Angelatos 2013-07-21 02:31:21 +01:00
parent 2525241669
commit f5760ffd09

View File

@ -64,6 +64,7 @@ app.post('/blink', (req, res) ->
interval = setInterval(toggleLed, settings.BLINK_STEP)
setTimeout(->
clearInterval(interval)
fs.writeFileSync(settings.LED_FILE, 0)
res.send(200)
, 5000)
)