InfernalRobotics#

Provides functionality to interact with the Infernal Robotics Next mod. Tested with Infernal Robotics Next 3.1.22. Provides the following classes:

Example#

The following example gets the control group named “MyGroup”, prints out the names and positions of all of the servos in the group, then moves all of the servos to the right for 1 second.

local krpc = require 'krpc'
local socket = require 'socket'

local conn = krpc.connect('InfernalRobotics Example')
local vessel = conn.space_center.active_vessel

local group =
  conn.infernal_robotics.servo_group_with_name(vessel, 'MyGroup')
if not group then
  print('Group not found')
  os.exit(1)
end

for _,servo in ipairs(group.servos) do
  print(servo.name, servo.position)
end

group:move_right()
socket.sleep(1)
group:stop()