Computer API

This API mainly provides information about the computer a Lua state is running on, such as its address and uptime. It also contains functions for user management. This could belong to the os table, but in order to keep that “clean” it's in its own API.

snippet.lua
local computer = require("computer")
if computer.uptime() >= 300 then
    computer.shutdown(true)
end

Contents