3.2 KiB
Use this if you want to know how to use the OS.
Commands
Disk
Interact with a disk drive.
Synopsys:
disk lslist all disk drives and its contentdisk play <drive>play an audio disk inside a disk drivedisk stop <drive>stops playing audiodisk eject <drive>ejects the diskdisk lable <dive> [lable]Reads or sets a lable on a disk.
GPS
Interact with the buildin GPS and INS (Inertial Navigation System) system. The INS is used to update a turtle's position when it is moving.
The GPS has 4 states of accuracy:
0Unknown position1Position from INS or its best guess2Position from manual input or the last known position3Position from GPS
In case of a turtle the GPS accuracy will be set to 1.
Synopsys:
gps set <x> <y> <z>set the position manually. This will get saved.gps statusprints the current GPS accuracy, position and INS status.gps locatetry to locate the current position. Accuracy will be set to3if successful.gps insperform an INS alignment. Used to get the current heading.
KSettings
Get and set Kernel settings.
Current settings are:
hostnamethe hostname of the computersitecontrollerthe id of the site controller
Synopsys:
ks get <setting>print the value of a settingks set <setting> <value>set the value of a settingks listlist all settings
LSPS
List all processes running on the computer. Very simple and not very useful other than for debugging.
Net
Interact with the network stack.
Synopsys:
net routeprint the routing tablenet ifacelist all network interfacesnet protolist all network currently active protocolsnet ping <id>ping a remote computer by id
Peripherals
Interact with the peripherals connected to the computer.
Synopsys:
perf inspect <peripheral>print all types and methods of a peripheralperf listlist all peripherals
Redstone
Interact with the redstone. Support for Project Red's Bundle Cable is partialy implemented.
Synopsys:
rs on <side>turn on redstone on a siders off <side>turn off redstone on a siders get <side>get the redstone state on a side
Service
Interact with the service manager. A service is a program that runs in the background and can be automatically started when the computer boots.
A service is a normal program. In order to create a new service you must register a command with arguments under a name. After that you can start the service by its name. If it is running you can enable it so it will be started when the computer boots.
Synopsys:
srv start <name>start a servicesrv stop <name>stop a servicesrv register <name> <binary> [args...]register a servicesrv unregister <name>unregister a servicesrv listlist all servicessrv enable <name>enable a service. Must be started before it can be enabled.
Turtle
Interact with a turtle. Very simple. More to come maybe.
Synopsys:
turtle forwardmove the turtle forwardturtle backmove the turtle backturtle upmove the turtle upturtle downmove the turtle downturtle leftturn the turtle leftturtle rightturn the turtle right