HawkSimulator.H

00001 // File:    HawkSimulator.H
00002 // Author:  Prithvi Balaram <balaram@usc.edu>
00003 // Date:    April 2010
00004 
00005 // TODO: Build Voxel class for displaying the map in OpenGL
00006 // TODO: Build basic OpenGL Simulation display class
00007 
00008 #include <string>
00009 #include <Ice/Ice.h>
00010 #include "Robots/BeoHawk/core/HawkMessages.ice.H"
00011 #include "Robots/BeoHawk/computer/HawkAgent.H"
00012 
00013 class HawkSimulator : public HawkAgent {
00014  public:
00015   // These functions must be defined in all HawkAgents
00016   HawkSimulator(std::string myName, int argc, char* argv[]);
00017 
00018   // Scheduler, CS201 agent style
00019   bool scheduler();
00020 
00021   // Register some messages that we're listening for over ICE
00022   void registerTopics();
00023 
00024   // Catch an ICE message -- equivalent of CS201 messaging
00025   void catchMessage(const HawkMessages::MessagePtr& msg, const Ice::Current&);
00026 
00027  private:
00028   // These functions are specific to the individual agents
00029   enum States {LOOP};
00030   States state;
00031 
00032   // Publish the Sensor Data Message over ICE
00033   void sendSensorDataMessage();
00034 
00035   // Get the readings from LRF based upon current position
00036   void laserScan();
00037 
00038   // Start displaying the OpenGL Simulation
00039   void startDisplay();
00040 
00041   // Stop displaying the OpenGL Simulation
00042   void stopDisplay();
00043 
00044   // Update the OpenGL Simulation with some new information
00045   void updateDisplay();
00046 };
Generated on Sun May 8 08:41:20 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3