Advertisement
carlosjuero

ccSensors Automated Lights App - Receiver

Sep 13th, 2012
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.33 KB | None | 0 0
  1. rednet.open("right") -- Change this to reflect the side your modem is connected to
  2. while true do
  3.   local id, msg = rednet.receive()
  4.   if msg == "lightson" then
  5.     rs.setOutput("left", true) -- change this to reflect what side the redstone wiring is connected to for the lights
  6.   else
  7.     rs.setOutput("left", false)
  8.   end
  9. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement