   , 1000
   res.send('beats started')
 
-
-
 app.get '/toggle/18', (req, res) ->
   if io[18].state == 0
     io[18].set()

io[22].on 'change', (val) ->
  io[23].set(val)


app.listen app.get('port'), ->
  console.log "Listening on port #{app.get('port')}"

app.get '/on/18', (req, res) ->
  io[18].set()
  res.send('on')

app.get '/off/18', (req, res) ->
  io[18].reset()
