Advertisement
Guest User

test

a guest
Jul 28th, 2015
368
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.44 KB | None | 0 0
  1. test = peripheral.wrap("back")
  2. m = peripheral.wrap("top")
  3. max = test.getMaxEnergyStored()
  4. current = test.getEnergyStored()
  5.  
  6. while true do
  7. m.clear()
  8. m.setBackgroundColour(colors.green)
  9. m.setCursorPos(1,2)
  10. m.setTextColor(colors.black)
  11. m.setTextScale(1)
  12. m.write("Power: "..test.getEnergyStored())
  13. m.setCursorPos(1,4)
  14. m.write("Total: "..max)
  15. m.setCursorPos(1,5)
  16. usage = current-test.getEnergyStored()
  17. m.write("Usage: "..usage)
  18. sleep(01)
  19. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement