simbad.sim
Class RobotFactory

java.lang.Object
  extended bysimbad.sim.Factory
      extended bysimbad.sim.RobotFactory

public class RobotFactory
extends Factory

A helper class to aid building robot bodies and sensors. It only contains only static methods and thus should not be instanciated.


Constructor Summary
RobotFactory()
           
 
Method Summary
static RangeSensorBelt addBumperBeltSensor(Agent agent)
          Adds a prebuild belt of bumpers sensor to the agent.
static RangeSensorBelt addBumperBeltSensor(Agent agent, int nbSensors)
          Adds a prebuild belt of bumpers sensor to the agent.
static CameraSensor addCameraSensor(Agent agent)
          Adds a prebuild camera sensor to the agent.
static LampActuator addLamp(Agent agent)
          Adds a prebuild lamp actuator on the top of the agent .
static LightSensor addLightSensor(Agent agent)
          Adds a prebuild light sensor to the agent.
static LightSensor addLightSensor(Agent agent, javax.vecmath.Vector3d pos, float angle, java.lang.String label)
          Adds a prebuild light sensor to the agent at a given position.
static LightSensor addLightSensorLeft(Agent agent)
          Adds a prebuild light sensor on the left of the agent .
static LightSensor addLightSensorRight(Agent agent)
          Adds a prebuild light sensor on the right of the agent .
static RangeSensorBelt addSonarBeltSensor(Agent agent)
          Adds a prebuild belt of sonar sensor to the agent.
static RangeSensorBelt addSonarBeltSensor(Agent agent, int nbSonars)
          Adds a prebuild belt of sonar sensor to the agent.
static DifferentialKinematic setDifferentialDriveKinematicModel(Agent agent)
          Sets the kinematic model to be DifferentialDrive (instead of DefaultKinematic)
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RobotFactory

public RobotFactory()
Method Detail

addCameraSensor

public static CameraSensor addCameraSensor(Agent agent)
Adds a prebuild camera sensor to the agent. Image resolution is 100x100 pixels. Camera is situated on the top of the agent.

Parameters:
agent -
Returns:
the sensor object

addSonarBeltSensor

public static RangeSensorBelt addSonarBeltSensor(Agent agent)
Adds a prebuild belt of sonar sensor to the agent.

Parameters:
agent -
Returns:
the sensor object

addSonarBeltSensor

public static RangeSensorBelt addSonarBeltSensor(Agent agent,
                                                 int nbSonars)
Adds a prebuild belt of sonar sensor to the agent.

Parameters:
agent -
nbSonars - the number of sonars.
Returns:
the sensor object

addBumperBeltSensor

public static RangeSensorBelt addBumperBeltSensor(Agent agent)
Adds a prebuild belt of bumpers sensor to the agent.

Parameters:
agent -
Returns:
the sensor object

addBumperBeltSensor

public static RangeSensorBelt addBumperBeltSensor(Agent agent,
                                                  int nbSensors)
Adds a prebuild belt of bumpers sensor to the agent. Specify the number of sensors.

Parameters:
agent -
nbSensors -
Returns:
the sensor object

addLightSensor

public static LightSensor addLightSensor(Agent agent)
Adds a prebuild light sensor to the agent.

Parameters:
agent -
Returns:
the sensor object

addLightSensor

public static LightSensor addLightSensor(Agent agent,
                                         javax.vecmath.Vector3d pos,
                                         float angle,
                                         java.lang.String label)
Adds a prebuild light sensor to the agent at a given position.

Parameters:
agent -
Returns:
the sensor object

addLightSensorLeft

public static LightSensor addLightSensorLeft(Agent agent)
Adds a prebuild light sensor on the left of the agent .

Parameters:
agent -
Returns:
the sensor object

addLightSensorRight

public static LightSensor addLightSensorRight(Agent agent)
Adds a prebuild light sensor on the right of the agent .

Parameters:
agent -
Returns:
the sensor object

addLamp

public static LampActuator addLamp(Agent agent)
Adds a prebuild lamp actuator on the top of the agent .

Parameters:
agent -
Returns:
the actuator object

setDifferentialDriveKinematicModel

public static DifferentialKinematic setDifferentialDriveKinematicModel(Agent agent)
Sets the kinematic model to be DifferentialDrive (instead of DefaultKinematic)

Parameters:
agent -