Advertisement
popatop15

Receiver Program

Jul 21st, 2016
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. -- Receiver Program
  2. local monitorSide = "top"
  3. local modemSide = "right"
  4. local noteblockSide = "left"
  5.  
  6. local mon = peripheral.wrap(monitorSide)
  7. rednet.open(modemSide)
  8. while true
  9. do
  10. local id, message = rednet.receive()
  11. redstone.setOutput(noteblockSide)
  12. mon.clear()
  13. mon.setCursorPos(1,1)
  14. mon.write("From: "..id)
  15. mon.setCursorPos(1,2)
  16. mon.write("Message: "..message)
  17. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement