Artoo: Ruby on Robots

From Artoo, a ruby framework, that supports 15 platforms including ARrone, Crazyflie, Sphero, and Arduino:

Modular Example

require 'artoo/robot'

SPHEROS = ["4567", "4568", "4569", "4570", "4571"]

class SpheroRobot < Artoo::Robot
  connection :sphero, :adaptor => :sphero
  device :sphero, :driver => :sphero

  work do
    every(3.seconds) do
      sphero.roll 90, rand(360)
    end
  end
end

robots = []
SPHEROS.each {|p|
  robots << SpheroRobot.new(:connections => 
                              {:sphero => 
                                {:port => p}})
}

SpheroRobot.work!(robots)

more information (here) and at (github)

Comments (0)

This post does not have any comments. Be the first to leave a comment below.


Post A Comment

You must be logged in before you can post a comment. Login now.

Featured Product

Knight Optical - Unlocking Precision for the Robotics and Automation Revolution

Knight Optical - Unlocking Precision for the Robotics and Automation Revolution

In the era of Industry 4.0, automation and machine learning drive the future. Knight Optical stands at the forefront, collaborating globally to supply precision optical components that power the robotics and automation sector. From UAVs, drones, and robotics to machine vision, LiDAR-driven car sensors, and renewable energy, our optics empower innovation. Optical components play an important role within the industry, including: Optical windows and domes safeguard systems in unmanned vehicles while preserving the field of view for cameras. Infrared lenses with aspheric surfaces elevate thermal imaging. Optical filters excel in machine vision, with colour glass, interference, and dichroic filters in our stock. Knight Optical provides stock components and custom solutions made to your exact specs. With every component undergoing rigorous metrology and QA checks before shipment, you are sure to experience true precision, innovation, and assurance.