Index: Tekkotsu/project/Makefile
diff -c Tekkotsu/project/Makefile:1.59 Tekkotsu/project/Makefile:1.61
*** Tekkotsu/project/Makefile:1.59	Mon Feb  2 17:36:51 2004
--- Tekkotsu/project/Makefile	Tue Mar 16 22:40:55 2004
***************
*** 57,63 ****
  CXXFLAGS= \
  	-g -pipe -O2 -frename-registers -fomit-frame-pointer -ffast-math -fno-common \
  	-Wall -W -Wshadow -Wlarger-than-8192 -Wpointer-arith -Wcast-qual \
! 	-Woverloaded-virtual -Weffc++ -Winline -Wdeprecated -Wnon-virtual-dtor \
  	-I"`pwd`" -I$(TEKKOTSU_ROOT) \
  	-isystem $(TEKKOTSU_ROOT)/Shared/jpeg-6b \
  	-isystem $(OPENRSDK_ROOT)/OPEN_R/include/MCOOP \
--- 57,63 ----
  CXXFLAGS= \
  	-g -pipe -O2 -frename-registers -fomit-frame-pointer -ffast-math -fno-common \
  	-Wall -W -Wshadow -Wlarger-than-8192 -Wpointer-arith -Wcast-qual \
! 	-Woverloaded-virtual -Weffc++ -Wdeprecated -Wnon-virtual-dtor \
  	-I"`pwd`" -I$(TEKKOTSU_ROOT) \
  	-isystem $(TEKKOTSU_ROOT)/Shared/jpeg-6b \
  	-isystem $(OPENRSDK_ROOT)/OPEN_R/include/MCOOP \
***************
*** 191,196 ****
--- 191,199 ----
  # Hopefully, you shouldn't have to change anything down here,
  # except one or two little things ;)
  
+ # Location of Aperios (the Aibo's OS) binary executables
+ SYSTEM_BINARIES:=$(OPENRSDK_ROOT)/OPEN_R/MS_$(if $(findstring $(TEKKOTSU_TARGET_MODEL),TGT_ERS7),ERS7,ERS200)/WCONSOLE/nomemprot
+ 
  # List of all components for all processes, sorted to
  # remove duplicates.
  COMPONENTS:=$(sort $(foreach proc,$(PROCESS_OBJS),$($(proc)_COMP)))
***************
*** 231,252 ****
  
  compile: reportTarget cleanTemps updateTools $(USERLIBS) $(INSTALL_BINS)
  	@image="$(BUILDDIR)/$(notdir $(MEMSTICK_ROOT))" ; \
! 	if [ $(TEKKOTSU_ROOT)/TARGET_MODEL -nt $$image ] ; then \
  		echo "Deleting old cached OPEN-R binaries"; \
! 		rm -rf $$image ; \
  	fi; \
! 	if [ \! -d $$image ] ; then \
! 		if [ \! -d $(OPENRSDK_ROOT)/OPEN_R/MS/WCONSOLE/nomemprot ] ; then \
  			echo "Could not find OPEN-R system binaries" ; \
  			exit 1 ; \
  		fi ; \
  		echo "Copying system files..." ; \
! 		cp -r $(OPENRSDK_ROOT)/OPEN_R/MS/WCONSOLE/nomemprot $$image ; \
! 		chmod -R u+w $$image ; \
! 		(cd $$image; $(CONVERTCASE) -r . ); \
! 		rm -f $$image/open-r/mw/conf/connect.cfg $$image/open-r/mw/conf/object.cfg $$image/open-r/system/conf/wlandflt.txt ; \
  		curt=`date +%Y%m%d%H%M`; \
! 		find $$image -exec touch -ft $$curt \{\} \; ; \
  	fi
  
  
--- 234,255 ----
  
  compile: reportTarget cleanTemps updateTools $(USERLIBS) $(INSTALL_BINS)
  	@image="$(BUILDDIR)/$(notdir $(MEMSTICK_ROOT))" ; \
! 	if [ "$(TEKKOTSU_ROOT)/TARGET_MODEL" -nt "$$image" ] ; then \
  		echo "Deleting old cached OPEN-R binaries"; \
! 		rm -rf "$$image" ; \
  	fi; \
! 	if [ \! -d "$$image" ] ; then \
! 		if [ \! -d "$(SYSTEM_BINARIES)" ] ; then \
  			echo "Could not find OPEN-R system binaries" ; \
  			exit 1 ; \
  		fi ; \
  		echo "Copying system files..." ; \
! 		cp -r "$(SYSTEM_BINARIES)" "$$image" ; \
! 		chmod -R u+w "$$image" ; \
! 		(cd "$$image" && $(CONVERTCASE) -r . ); \
! 		rm -f "$$image/open-r/mw/conf/connect.cfg" "$$image/open-r/mw/conf/object.cfg" "$$image/open-r/system/conf/wlandflt.txt" ; \
  		curt=`date +%Y%m%d%H%M`; \
! 		find "$$image" -exec touch -ft $$curt \{\} \; ; \
  	fi
  
  
***************
*** 455,461 ****
  newstick:
  	$(TEKKOTSU_ROOT)/tools/mntmem $(MEMSTICK_ROOT)
  	rm -rf $(MEMSTICK_ROOT)/*
! 	cp -r $(OPENRSDK_ROOT)/OPEN_R/MS/WCONSOLE/nomemprot/* $(MEMSTICK_ROOT)
  	$(TEKKOTSU_ROOT)/tools/umntmem $(MEMSTICK_ROOT)
  
  $(FILTERSYSWARN):
--- 458,464 ----
  newstick:
  	$(TEKKOTSU_ROOT)/tools/mntmem $(MEMSTICK_ROOT)
  	rm -rf $(MEMSTICK_ROOT)/*
! 	cp -r $(SYSTEM_BINARIES)/* $(MEMSTICK_ROOT)
  	$(TEKKOTSU_ROOT)/tools/umntmem $(MEMSTICK_ROOT)
  
  $(FILTERSYSWARN):
Index: Tekkotsu/project/StartupBehavior.cc
diff -c Tekkotsu/project/StartupBehavior.cc:1.55 Tekkotsu/project/StartupBehavior.cc:1.59
*** Tekkotsu/project/StartupBehavior.cc:1.55	Mon Jan 19 17:04:02 2004
--- Tekkotsu/project/StartupBehavior.cc	Wed Feb 18 16:13:48 2004
***************
*** 9,15 ****
  #include "Behaviors/Controls/ShutdownControl.h"
  
  #include "Motion/MotionCommand.h"
- #include "Motion/PostureMC.h"
  #include "Motion/EmergencyStopMC.h"
  #include "Motion/PIDMC.h"
  #include "Motion/MotionSequenceMC.h"
--- 9,14 ----
***************
*** 41,114 ****
  	//first in case later stuff wants to reference the vision stages)
  	initVision();
  
! 	//This will "fade" in the PIDs so the joints don't jerk to full power, also looks cooler
! 	pid_id=motman->addMotion(SharedObject<PIDMC>(0),MotionManager::kEmergencyPriority+1,false);
! 	//also, pause before we start fading in, PIDs take effect right away, before the emergencystop is picked up
  	erouter->addTimer(this,0,4*FrameTime*NumFrames,true);
  
! 	//This is the default emergency stop
  	const SharedObject<EmergencyStopMC> stop;
! 	stop->LoadFile("/ms/data/motion/liedown.pos"); //This *should* be replaced by the current position, but just in case, better than setting everything to 0's
! 	stop->setStopped(true,false); //if you want to start off paused
! 	//sndman->StopPlay(); //so it doesn't play the halt sound the first time (but the false in previous line does that now)
  	stop_id=motman->addMotion(stop,MotionManager::kEmergencyPriority);
  	
! 	//This displays the current battery conditions
  	BatteryCheckControl batchk;
  	batchk.activate(MotionManager::invalid_MC_ID,NULL);
! 	//	const SharedObject<LedMC> led; //! @todo LedMC's don't support autopruning yet, it should for uses like this, or could the one in Controller
  	//	batchk.activate(motman->addMotion(led,true));
  	batchk.deactivate();
  
! 	//This is for the menu system
  	Controller * controller=new Controller;
  	controller->DoStart();
  	controller->setEStopID(stop_id);
! 	controller->setRoot(SetupMenus());
  	wireless->setReceiver(sout, Controller::console_callback);
  	spawned.push_back(controller);
  	
  	sndman->PlayFile("roar.wav");
  
! 	//This will close the mouth so it doesn't look stupid
! 	//Now done by setting the emergency stop directly in processEvent, but left as demo code:
! 	/*	const SharedObject<PostureMC> closemouth;
! 			closemouth->setJointCmd(MouthOffset,outputRanges[MouthOffset][MaxRange],1);
! 			motman->addMotion(closemouth,MotionCommand::kEmergencyPriority+2,true);
! 	*/
  
! 	//if you didn't want to start off paused, you should throw an un-estop event:
! 	//erouter->postEvent(EventBase(EventBase::estopEGID,MotionManager::invalid_MC_ID,EventBase::deactivateETID,0));
  }
  
  void StartupBehavior::DoStop() {
! 	for(std::vector<BehaviorBase*>::iterator it=spawned.begin(); it!=spawned.end(); it++)
  		(*it)->DoStop();
  	motman->removeMotion(stop_id);
  	BehaviorBase::DoStop();
  }
  
  /*!Uses a few timer events at the beginning to fade in the PID values, and closes the mouth too*/
! void StartupBehavior::processEvent(const EventBase&) {
! 	static unsigned int start_time=-1U;
! 	const unsigned int tot_time=2000; 
! 	if(start_time==-1U) { //first time
! 		start_time=get_time();
! 		MMAccessor<EmergencyStopMC>(stop_id)->takeSnapshot(); //take new snapshot with hopefully valid data
! 	} else {
! 		float power=(get_time()-start_time)/(float)tot_time;
! 		if(power>1)
! 			power=1;
! 		{ MMAccessor<PIDMC>(pid_id)->setAllPowerLevel(power); }
  		if(state->robotDesign & WorldState::ERS210Mask)
! 			{ MMAccessor<EmergencyStopMC>(stop_id)->setOutputCmd(ERS210Info::MouthOffset,outputRanges[ERS210Info::MouthOffset][MaxRange]); }
  		if(state->robotDesign & WorldState::ERS7Mask)
! 			{ MMAccessor<EmergencyStopMC>(stop_id)->setOutputCmd(ERS7Info::MouthOffset,outputRanges[ERS7Info::MouthOffset][MaxRange]); }
! 	}
! 	if((get_time()-start_time)>=tot_time) {
! 		erouter->removeTimer(this);
! 		motman->removeMotion(pid_id);
! 		pid_id=MotionManager::invalid_MC_ID;
  	}
  }
  
--- 40,146 ----
  	//first in case later stuff wants to reference the vision stages)
  	initVision();
  
! 	//This will "fade" in the PIDs so the joints don't jerk to full
! 	//power, also looks cooler
! 	pid_id=motman->addMotion(SharedObject<PIDMC>(0),MotionManager::kEmergencyPriority+2,false);
! 	//also, pause before we start fading in, PIDs take effect right
! 	//away, before the emergencystop is picked up
  	erouter->addTimer(this,0,4*FrameTime*NumFrames,true);
  
! 	//This sets up the default emergency stop
  	const SharedObject<EmergencyStopMC> stop;
! 	//if you want to start off unpaused, either change 'true' to
! 	//'false', or just comment out the next line (estop's efault is off)
! 	//Note that if you don't want to start in estop, you should then
! 	//also uncomment the line at the end of this function
! 	stop->setStopped(true,false); 
  	stop_id=motman->addMotion(stop,MotionManager::kEmergencyPriority);
  	
! 	//This displays the current battery conditions on the console
  	BatteryCheckControl batchk;
  	batchk.activate(MotionManager::invalid_MC_ID,NULL);
! 	//	const SharedObject<LedMC> led; //! @todo LedMC's don't support autopruning yet, it should for uses like this
  	//	batchk.activate(motman->addMotion(led,true));
  	batchk.deactivate();
  
! 	//This is what runs the menu system
  	Controller * controller=new Controller;
  	controller->DoStart();
  	controller->setEStopID(stop_id);
! 	controller->setRoot(SetupMenus()); //this triggers the layout of the menus themselves
  	wireless->setReceiver(sout, Controller::console_callback);
  	spawned.push_back(controller);
  	
  	sndman->PlayFile("roar.wav");
  
! 	//This will close the mouth so it doesn't look stupid or get in the
! 	//way of head motions (ERS-210 or ERS-7 only)
! 	unsigned int mouthOffset=-1U;
! 	if(state->robotDesign & WorldState::ERS210Mask)
! 		mouthOffset=ERS210Info::MouthOffset;
! 	if(state->robotDesign & WorldState::ERS7Mask)
! 		mouthOffset=ERS7Info::MouthOffset;
! 	if(mouthOffset!=-1U) {
! 		SharedObject<MotionSequenceMC<MotionSequence::SizeTiny> > closeMouth;
! 		closeMouth->setPlayTime(3000); //take 3 seconds to close the mouth
! 		closeMouth->setOutputCmd(mouthOffset,outputRanges[mouthOffset][MaxRange]);
! 		closeMouth->setPlayTime(3500); //and hold it for another .5 seconds
! 		closeMouth->setOutputCmd(mouthOffset,outputRanges[mouthOffset][MaxRange]);
! 		motman->addMotion(closeMouth,MotionManager::kEmergencyPriority+1,true);
! 		erouter->addTimer(this,1,3250,false);
! 	}
  
! 	//if you didn't want to start off paused, you should throw an
! 	//un-estop event.  This will make it clear to any background
! 	//behaviors (namely WorldStateVelDaemon) that we're not in estop
! 	//erouter->postEvent(new EventBase(EventBase::estopEGID,MotionManager::invalid_MC_ID,EventBase::deactivateETID,0));
  }
  
  void StartupBehavior::DoStop() {
! 	for(std::vector<BehaviorBase*>::iterator it=spawned.begin(); it!=spawned.end(); it++) {
! 		cout << "StartupBehavior stopping spawned: " << (*it)->getName() << endl;
  		(*it)->DoStop();
+ 	}
  	motman->removeMotion(stop_id);
  	BehaviorBase::DoStop();
  }
  
  /*!Uses a few timer events at the beginning to fade in the PID values, and closes the mouth too*/
! void StartupBehavior::processEvent(const EventBase& event) {
! 	if(event.getGeneratorID()==EventBase::timerEGID && event.getSourceID()==0) {
! 		//this will do the work of fading in the PID values.  It helps the joints
! 		//to power up without twitching
! 		static unsigned int start_time=-1U;
! 		const unsigned int tot_time=2000; 
! 		if(start_time==-1U) { //first time
! 			start_time=get_time();
! 		} else {
! 			float power=(get_time()-start_time)/(float)tot_time;
! 			if(power>1)
! 				power=1;
! 			MMAccessor<PIDMC>(pid_id)->setAllPowerLevel(power*power);
! 		}
! 		if((get_time()-start_time)>=tot_time) {
! 			erouter->removeTimer(this,0);
! 			motman->removeMotion(pid_id);
! 			pid_id=MotionManager::invalid_MC_ID;
! 		}
! 	}
! 
! 	if(event.getGeneratorID()==EventBase::timerEGID && event.getSourceID()==1) {
! 		//we're done closing the mouth... set the mouth to closed in the estop too
! 		//otherwise it might twitch a little when the MotionSequence expires and the estop takes over
! 		// (little == +/-.1 radians, aka estop's threshold for resetting an "out of place" joint) (details, details)
! 		unsigned int mouthOffset=-1U;
  		if(state->robotDesign & WorldState::ERS210Mask)
! 			mouthOffset=ERS210Info::MouthOffset;
  		if(state->robotDesign & WorldState::ERS7Mask)
! 			mouthOffset=ERS7Info::MouthOffset;
! 		if(mouthOffset!=-1U) {
! 			MMAccessor<EmergencyStopMC> estop(stop_id);
! 			float weight=estop->getOutputCmd(mouthOffset).weight;
! 			estop->setOutputCmd(mouthOffset,OutputCmd(outputRanges[mouthOffset][MaxRange],weight));
! 		}
  	}
  }
  
Index: Tekkotsu/project/StartupBehavior.h
diff -c Tekkotsu/project/StartupBehavior.h:1.10 Tekkotsu/project/StartupBehavior.h:1.11
*** Tekkotsu/project/StartupBehavior.h:1.10	Tue Dec  9 18:56:58 2003
--- Tekkotsu/project/StartupBehavior.h	Mon Feb  9 17:45:29 2004
***************
*** 9,26 ****
  class Controller; // defined in Controller.h, don't actually need header file yet
  class ControlBase; // defined in ControlBase.h, don't actually need header file yet
  
! //! This Behavior is the only hardcoded behavior by the framework to start up once all the data structures and such are set up
  
  /*! This is done by assigning an instance of StartupBehavior to the
!  *  global ::startupBehavior variable.  Note that there's nothing
!  *  special about the type of this class, it's just another
!  *  BehaviorBase - ::startupBehavior could be any behavior.  If you
!  *  want some other behavior to run automatically at startup, simply
!  *  remove StartupBehavior from the project and assign an instance of
!  *  your own class to ::startupBehavior instead.
   *
!  *  By default, this behavior is similar in idea to the init process
!  *  in unix/linux. */
  class StartupBehavior : public BehaviorBase {
  public:
  	//! Constructor
--- 9,43 ----
  class Controller; // defined in Controller.h, don't actually need header file yet
  class ControlBase; // defined in ControlBase.h, don't actually need header file yet
  
! //! This is the default init behavior - it launches daemons, builds the Controller menu structure, does some nice things to fade the joints in to full power (reduces twitch)
  
  /*! This is done by assigning an instance of StartupBehavior to the
!  *  global ProjectInterface::startupBehavior variable.  Note that
!  *  there's nothing special about the type of this class, it's just
!  *  another BehaviorBase - ProjectInterface::startupBehavior could be
!  *  any behavior.
!  *  
!  *  If you want some other behavior to handle the root initialization,
!  *  simply remove the assignment of ::theStartup to startupBehavior at
!  *  the beginning of StartupBehavior.cc.  Then you can substitute your
!  *  own behavior instead.  Probably a good way to distribute project
!  *  code when you're all done with development and want to ship a
!  *  single-purpose memory stick (assuming your users won't want to get
!  *  access to things like the Controller anymore... up to you.)
   *
!  *  If all you want to do is get your behavior to launch at startup,
!  *  you don't need to replace this.  Just add a menu entry.  (in say,
!  *  the Mode Switch menu, which is separated out into
!  *  StartupBehavior_SetupModeSwitch.cc for reduced recompilation after
!  *  header files are modified) If you use a BehaviorSwitchControl, you
!  *  can call its BehaviorSwitchControl::start() method to start the
!  *  behavior it controls as you add it to the menu.  There are several
!  *  examples of this usage in the Background Behaviors menu
!  *  (StartupBehavior_SetupBackgroundBehaviors.cc)
!  *
!  *  This behavior is similar in idea to the init process in
!  *  unix/linux.
!  */
  class StartupBehavior : public BehaviorBase {
  public:
  	//! Constructor
***************
*** 51,60 ****
  	virtual void initVision(); //!< Sets up the vision pipelines (held in StartupBehavior_SetupVision.cc)
  
  	virtual void startSubMenu(); //!< future calls to addItem() will be placed under the most recently added item
! 	virtual void addItem(ControlBase * control); //!< inserts a control at the end of the menu
  	virtual ControlBase* endSubMenu();  //!< closes out a submenu so that future calls to addItem() will be added to the enclosing menu, returns the menu being closed out
  
! 	std::vector<BehaviorBase*> spawned; //!< Behaviors spawned from DoStart, so they can automatically be stopped on DoStop
  	std::stack<ControlBase*> setup;     //!< only used during setup - easier than passing it around all the functions
  	MotionManager::MC_ID stop_id; //!< the main EmergencyStopMC
  	MotionManager::MC_ID pid_id; //!< used to fade in the PIDs up to full strength (from initial zero) This is so the joints don't jerk on startup.
--- 68,77 ----
  	virtual void initVision(); //!< Sets up the vision pipelines (held in StartupBehavior_SetupVision.cc)
  
  	virtual void startSubMenu(); //!< future calls to addItem() will be placed under the most recently added item
! 	virtual void addItem(ControlBase * control); //!< inserts a control at the end of the current menu
  	virtual ControlBase* endSubMenu();  //!< closes out a submenu so that future calls to addItem() will be added to the enclosing menu, returns the menu being closed out
  
! 	std::vector<BehaviorBase*> spawned; //!< Holds pointers to all the behaviors spawned from DoStart, so they can automatically be stopped on DoStop (should only happen on shutdown, but ensures cleanliness)
  	std::stack<ControlBase*> setup;     //!< only used during setup - easier than passing it around all the functions
  	MotionManager::MC_ID stop_id; //!< the main EmergencyStopMC
  	MotionManager::MC_ID pid_id; //!< used to fade in the PIDs up to full strength (from initial zero) This is so the joints don't jerk on startup.
Index: Tekkotsu/project/StartupBehavior_SetupVision.cc
diff -c Tekkotsu/project/StartupBehavior_SetupVision.cc:1.12 Tekkotsu/project/StartupBehavior_SetupVision.cc:1.14
*** Tekkotsu/project/StartupBehavior_SetupVision.cc:1.12	Thu Feb  5 14:35:47 2004
--- Tekkotsu/project/StartupBehavior_SetupVision.cc	Mon Feb 23 11:17:15 2004
***************
*** 40,61 ****
  	unsigned int numSystemLayers=3;
  
  	defRawCameraGenerator = new RawCameraGenerator(numSystemLayers,numLayers,EventBase::visOFbkEGID,0,visRawCameraSID);
- 	defRawCameraGenerator->DoStart();
- 	spawned.push_back(defRawCameraGenerator);
  
  	defInterleavedYUVGenerator = new InterleavedYUVGenerator(EventBase::visRawCameraEGID,visRawCameraSID,visInterleaveSID,RawCameraGenerator::CHAN_Y,RawCameraGenerator::CHAN_U,RawCameraGenerator::CHAN_V);
- 	defInterleavedYUVGenerator->DoStart();
- 	spawned.push_back(defInterleavedYUVGenerator);
  
  	defColorJPEGGenerator = new JPEGGenerator(EventBase::visInterleaveEGID,visInterleaveSID,visColorJPEGSID,JPEGGenerator::SRC_AUTO);
- 	defColorJPEGGenerator->DoStart();
  	defColorJPEGGenerator->setName("ColorJPEGGenerator");
- 	spawned.push_back(defColorJPEGGenerator);
  
  	defGrayscaleJPEGGenerator = new JPEGGenerator(EventBase::visRawCameraEGID,visRawCameraSID,visGrayscaleJPEGSID,JPEGGenerator::SRC_AUTO);
- 	defGrayscaleJPEGGenerator->DoStart();
  	defGrayscaleJPEGGenerator->setName("GrayscaleJPEGGenerator");
- 	spawned.push_back(defGrayscaleJPEGGenerator);
  
  	// the hardware level CDT generator allows faster, but less flexible
  	// segmenting it still needs a little work though before it can be
--- 40,53 ----
***************
*** 66,83 ****
  	segcol->loadColorInfo(config->vision.colors);
  	for(unsigned int i=0; i<config->vision.thresh.size(); i++)
  		segcol->loadThresholdMap(config->vision.thresh[i]);
- 	if(config->vision.colors!="" && config->vision.thresh.size()>0) {
- 		defSegmentedColorGenerator->DoStart();
- 		spawned.push_back(defSegmentedColorGenerator);
- 	}
  
  	defRLEGenerator = new RLEGenerator(EventBase::visSegmentEGID,visSegmentSID,visRLESID);
- 	defRLEGenerator->DoStart();
- 	spawned.push_back(defRLEGenerator);
  	
  	defRegionGenerator = new RegionGenerator(EventBase::visRLEEGID,visRLESID,visRegionSID);
- 	defRegionGenerator->DoStart();
- 	spawned.push_back(defRegionGenerator);
  	
  	// for lack of a better idea, the object recognizers below will all
  	// use the config->vision.rlecam_channel for picking the threshold
--- 58,67 ----
***************
*** 100,121 ****
  	if(pinkIdx!=-1U) {
  		pball = new BallDetectionGenerator(EventBase::visRegionEGID,visRegionSID,visPinkBallSID,pinkIdx,threshChan,noiseFiltering,confidenceThreshold);
  		pball->setName("PinkBallDetectionGenerator");
- 		pball->DoStart();
- 		spawned.push_back(pball);
  	}
  	unsigned int blueIdx=segcol->getColorIndex("blue");
  	if(blueIdx!=-1U) {
  		bball = new BallDetectionGenerator(EventBase::visRegionEGID,visRegionSID,visBlueBallSID,blueIdx,threshChan,noiseFiltering,confidenceThreshold);
! 		pball->setName("BlueBallDetectionGenerator");
! 		bball->DoStart();
! 		spawned.push_back(bball);
  	}
  	unsigned int skinIdx=segcol->getColorIndex("brown");
  	if(skinIdx!=-1U) {
  		handball = new BallDetectionGenerator(EventBase::visRegionEGID,visRegionSID,visHandSID,skinIdx,threshChan,noiseFiltering,confidenceThreshold);
! 		pball->setName("HandBallDetectionGenerator");
! 		handball->DoStart();
! 		spawned.push_back(handball);
  	}
  }
  
--- 84,99 ----
  	if(pinkIdx!=-1U) {
  		pball = new BallDetectionGenerator(EventBase::visRegionEGID,visRegionSID,visPinkBallSID,pinkIdx,threshChan,noiseFiltering,confidenceThreshold);
  		pball->setName("PinkBallDetectionGenerator");
  	}
  	unsigned int blueIdx=segcol->getColorIndex("blue");
  	if(blueIdx!=-1U) {
  		bball = new BallDetectionGenerator(EventBase::visRegionEGID,visRegionSID,visBlueBallSID,blueIdx,threshChan,noiseFiltering,confidenceThreshold);
! 		bball->setName("BlueBallDetectionGenerator");
  	}
  	unsigned int skinIdx=segcol->getColorIndex("brown");
  	if(skinIdx!=-1U) {
  		handball = new BallDetectionGenerator(EventBase::visRegionEGID,visRegionSID,visHandSID,skinIdx,threshChan,noiseFiltering,confidenceThreshold);
! 		handball->setName("HandBallDetectionGenerator");
  	}
  }
  
***************
*** 124,139 ****
  	addItem(new ControlBase("Vision Pipeline","Start/Stop stages of the vision pipeline"));
  	startSubMenu();
  	{ 
! 		addItem(new BehaviorSwitchControlBase(defRawCameraGenerator));
! 		addItem(new BehaviorSwitchControlBase(defInterleavedYUVGenerator));
! 		addItem(new BehaviorSwitchControlBase(defColorJPEGGenerator));
! 		addItem(new BehaviorSwitchControlBase(defGrayscaleJPEGGenerator));
! 		addItem(new BehaviorSwitchControlBase(defSegmentedColorGenerator));
! 		addItem(new BehaviorSwitchControlBase(defRLEGenerator));
! 		addItem(new BehaviorSwitchControlBase(defRegionGenerator));
! 		addItem(new BehaviorSwitchControlBase(pball));
! 		addItem(new BehaviorSwitchControlBase(bball));
! 		addItem(new BehaviorSwitchControlBase(handball));
  	}
  	return endSubMenu();
  }
--- 102,120 ----
  	addItem(new ControlBase("Vision Pipeline","Start/Stop stages of the vision pipeline"));
  	startSubMenu();
  	{ 
! 		addItem((new BehaviorSwitchControlBase(defRawCameraGenerator))->start());
! 		addItem((new BehaviorSwitchControlBase(defInterleavedYUVGenerator))->start());
! 		addItem((new BehaviorSwitchControlBase(defColorJPEGGenerator))->start());
! 		addItem((new BehaviorSwitchControlBase(defGrayscaleJPEGGenerator))->start());
! 		if(config->vision.colors!="" && config->vision.thresh.size()>0)
! 			addItem((new BehaviorSwitchControlBase(defSegmentedColorGenerator))->start());
! 		else
! 			addItem(new BehaviorSwitchControlBase(defSegmentedColorGenerator));
! 		addItem((new BehaviorSwitchControlBase(defRLEGenerator))->start());
! 		addItem((new BehaviorSwitchControlBase(defRegionGenerator))->start());
! 		addItem((new BehaviorSwitchControlBase(pball))->start());
! 		addItem((new BehaviorSwitchControlBase(bball))->start());
! 		addItem((new BehaviorSwitchControlBase(handball))->start());
  	}
  	return endSubMenu();
  }
Index: Tekkotsu/project/StartupBehavior_SetupWalkEdit.cc
diff -c Tekkotsu/project/StartupBehavior_SetupWalkEdit.cc:1.6 Tekkotsu/project/StartupBehavior_SetupWalkEdit.cc:1.7
*** Tekkotsu/project/StartupBehavior_SetupWalkEdit.cc:1.6	Fri Jan 16 00:14:39 2004
--- Tekkotsu/project/StartupBehavior_SetupWalkEdit.cc	Wed Feb 25 20:03:00 2004
***************
*** 9,18 ****
   * @author PA Gov. School for the Sciences 2003 Team Project - Motion group: Haoqian Chen, Yantian Martin, Jon Stahlman (creators)
   * 
   * $Author: ejt $
!  * $Name: HEAD $
!  * $Revision: 1.1 $
   * $State: Exp $
!  * $Date: 2004/03/17 04:36:38 $
   */
  
  #include "StartupBehavior.h"
--- 9,18 ----
   * @author PA Gov. School for the Sciences 2003 Team Project - Motion group: Haoqian Chen, Yantian Martin, Jon Stahlman (creators)
   * 
   * $Author: ejt $
!  * $Name: HEAD $
!  * $Revision: 1.1 $
   * $State: Exp $
!  * $Date: 2004/03/17 04:36:38 $
   */
  
  #include "StartupBehavior.h"
***************
*** 126,132 ****
  		startSubMenu();
  		{ 
  			addItem(new WalkCalibration());
! 			addItem(new LoadCalibration<3,11>(walker->getWalkMC()->getCP().f_calibration,walker->getWalkMC()->getCP().b_calibration));
  			addItem(new ValueEditControl<float>("forward max_accel",&walker->getWalkMC()->getCP().max_accel[WalkMC::CalibrationParam::forward]));
  			addItem(new ValueEditControl<float>("reverse max_accel",&walker->getWalkMC()->getCP().max_accel[WalkMC::CalibrationParam::reverse]));
  			addItem(new ValueEditControl<float>("strafe max_accel",&walker->getWalkMC()->getCP().max_accel[WalkMC::CalibrationParam::strafe]));
--- 126,132 ----
  		startSubMenu();
  		{ 
  			addItem(new WalkCalibration());
! 			addItem(new LoadCalibration(&walker->getWalkMC()->getCP()));
  			addItem(new ValueEditControl<float>("forward max_accel",&walker->getWalkMC()->getCP().max_accel[WalkMC::CalibrationParam::forward]));
  			addItem(new ValueEditControl<float>("reverse max_accel",&walker->getWalkMC()->getCP().max_accel[WalkMC::CalibrationParam::reverse]));
  			addItem(new ValueEditControl<float>("strafe max_accel",&walker->getWalkMC()->getCP().max_accel[WalkMC::CalibrationParam::strafe]));
Index: Tekkotsu/project/ms/config/ball.tm
Index: Tekkotsu/project/ms/config/ttt.col
diff -c /dev/null Tekkotsu/project/ms/config/ttt.col:1.1
*** /dev/null	Tue Mar 16 23:08:34 2004
--- Tekkotsu/project/ms/config/ttt.col	Wed Mar  3 18:14:44 2004
***************
*** 0 ****
--- 1,10 ----
+ 0 (128 128 128) "unclassified" 8 1.00
+ 1 (43 60 77) "blue" 8 0.75
+ 2 (75 128 45) "green" 8 0.75
+ 3 (142 95 33) "orange" 8 0.75
+ 4 (192 126 142) "pink" 8 0.75
+ 5 (234 21 56) "red" 8 0.75
+ 6 (249 249 9) "yellow" 8 0.75
+ 7 (9 244 225) "cyan" 8 0.75
+ 8 (200 14 204) "magenta" 8 0.75
+ 9 (76 254 247) "lime" 8 0.75
Index: Tekkotsu/project/ms/config/ttt.tm
Index: Tekkotsu/project/ms/config/ttt_old.tm
Index: Tekkotsu/project/ms/data/motion/README.txt
diff -c Tekkotsu/project/ms/data/motion/README.txt:1.2 Tekkotsu/project/ms/data/motion/README.txt:removed
*** Tekkotsu/project/ms/data/motion/README.txt:1.2	Sat Apr 26 17:17:05 2003
--- Tekkotsu/project/ms/data/motion/README.txt	Tue Mar 16 23:08:34 2004
***************
*** 1,43 ****
- .mot files are for use by the MotionSequence classes.
-      http://www.tekkotsu.org/dox/classMotionSequence.html
- .pos files are for use by the PositionEngine classes.
-      http://www.tekkotsu.org/dox/classPostureEngine.html
- 
- Both are text files and are human-editable.  See documentation for details.
- 
- The following motion files were converted from CMPack'02 files and fall under
- their license:
- *   Misc: dance.mot
- * Getups: gu_back.mot gu_front.mot gu_side.mot 
- *  Kicks: k_bump.mot k_diag.mot k_dive.mot k_fwd.mot k_grab.mot
-           k_head.mot k_heads.mot k_hold.mot k_punch.mot
- 
- See tools/convertmot for the conversion code and original motion files.
- 
-   LICENSE:
-   =========================================================================
-     CMPack'02 Source Code Release for OPEN-R SDK v1.0
-     Copyright (C) 2002 Multirobot Lab [Project Head: Manuela Veloso]
-     School of Computer Science, Carnegie Mellon University
-   -------------------------------------------------------------------------
-     This software is distributed under the GNU General Public License,
-     version 2.  If you do not have a copy of this licence, visit
-     www.gnu.org, or write: Free Software Foundation, 59 Temple Place,
-     Suite 330 Boston, MA 02111-1307 USA.  This program is distributed
-     in the hope that it will be useful, but WITHOUT ANY WARRANTY,
-     including MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-   -------------------------------------------------------------------------
-     Additionally licensed to Sony Corporation under the following terms:
- 
-     This software is provided by the copyright holders AS IS and any
-     express or implied warranties, including, but not limited to, the
-     implied warranties of merchantability and fitness for a particular
-     purpose are disclaimed.  In no event shall authors be liable for
-     any direct, indirect, incidental, special, exemplary, or consequential
-     damages (including, but not limited to, procurement of substitute
-     goods or services; loss of use, data, or profits; or business
-     interruption) however caused and on any theory of liability, whether
-     in contract, strict liability, or tort (including negligence or
-     otherwise) arising in any way out of the use of this software, even if
-     advised of the possibility of such damage.
-   =========================================================================
--- 0 ----
Index: Tekkotsu/project/ms/data/motion/clearcal.txt
diff -c Tekkotsu/project/ms/data/motion/clearcal.txt:1.1 Tekkotsu/project/ms/data/motion/clearcal.txt:1.2
*** Tekkotsu/project/ms/data/motion/clearcal.txt:1.1	Fri Jan 16 00:14:52 2004
--- Tekkotsu/project/ms/data/motion/clearcal.txt	Wed Feb 25 20:03:05 2004
***************
*** 1,3 ****
--- 1,4 ----
+ 180 180 140 1.8
  1 0 0 0 0 0 0 0 0 0 0
  0 1 0 0 0 0 0 0 0 0 0
  0 0 1 0 0 0 0 0 0 0 0
Index: Tekkotsu/project/ms/data/motion/readme.txt
diff -c /dev/null Tekkotsu/project/ms/data/motion/readme.txt:1.1
*** /dev/null	Tue Mar 16 23:08:34 2004
--- Tekkotsu/project/ms/data/motion/readme.txt	Wed Feb 18 16:14:14 2004
***************
*** 0 ****
--- 1,43 ----
+ .mot files are for use by the MotionSequence classes.
+      http://www.tekkotsu.org/dox/classMotionSequence.html
+ .pos files are for use by the PositionEngine classes.
+      http://www.tekkotsu.org/dox/classPostureEngine.html
+ 
+ Both are text files and are human-editable.  See documentation for details.
+ 
+ The following motion files were converted from CMPack'02 files and fall under
+ their license:
+ *   Misc: dance.mot
+ * Getups: gu_back.mot gu_front.mot gu_side.mot 
+ *  Kicks: k_bump.mot k_diag.mot k_dive.mot k_fwd.mot k_grab.mot
+           k_head.mot k_heads.mot k_hold.mot k_punch.mot
+ 
+ See tools/convertmot for the conversion code and original motion files.
+ 
+   LICENSE:
+   =========================================================================
+     CMPack'02 Source Code Release for OPEN-R SDK v1.0
+     Copyright (C) 2002 Multirobot Lab [Project Head: Manuela Veloso]
+     School of Computer Science, Carnegie Mellon University
+   -------------------------------------------------------------------------
+     This software is distributed under the GNU General Public License,
+     version 2.  If you do not have a copy of this licence, visit
+     www.gnu.org, or write: Free Software Foundation, 59 Temple Place,
+     Suite 330 Boston, MA 02111-1307 USA.  This program is distributed
+     in the hope that it will be useful, but WITHOUT ANY WARRANTY,
+     including MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+   -------------------------------------------------------------------------
+     Additionally licensed to Sony Corporation under the following terms:
+ 
+     This software is provided by the copyright holders AS IS and any
+     express or implied warranties, including, but not limited to, the
+     implied warranties of merchantability and fitness for a particular
+     purpose are disclaimed.  In no event shall authors be liable for
+     any direct, indirect, incidental, special, exemplary, or consequential
+     damages (including, but not limited to, procurement of substitute
+     goods or services; loss of use, data, or profits; or business
+     interruption) however caused and on any theory of liability, whether
+     in contract, strict liability, or tort (including negligence or
+     otherwise) arising in any way out of the use of this software, even if
+     advised of the possibility of such damage.
+   =========================================================================
Index: Tekkotsu/project/ms/data/motion/walk.prm
Index: Tekkotsu/project/ms/data/motion/walkcal.txt
diff -c Tekkotsu/project/ms/data/motion/walkcal.txt:1.1 Tekkotsu/project/ms/data/motion/walkcal.txt:1.3
*** Tekkotsu/project/ms/data/motion/walkcal.txt:1.1	Fri Jan 16 00:14:53 2004
--- Tekkotsu/project/ms/data/motion/walkcal.txt	Fri Feb 27 20:58:55 2004
***************
*** 1,6 ****
!    1.1114950e+00   4.3793349e-02   3.6191516e+00  -2.8528403e-02  -1.0704690e+01  -1.6630287e+00  -1.0161892e-03  -1.9307957e-01  -1.0145463e-03   1.4387497e-01   2.5358894e+01
!   -1.5982849e-01   1.0121667e+00   8.4120978e+00  -1.3995280e-01  -5.7703782e+00   1.3642099e+01   1.1882969e-03  -1.1940036e-01   1.6860327e-03   2.2186785e-01   8.3247298e-01
!   -4.4086430e-04   3.6943915e-04   8.7219349e-01  -2.5621177e-04  -3.3549634e-02  -1.9053515e-03   2.5930239e-06  -7.8055622e-04   5.3484361e-06  -5.1855276e-05  -5.6217769e-03
!    1.4482688e+00  -2.8729604e-02   4.5315047e+00  -8.5684548e-02  -5.6070133e+00   1.6249840e+00   1.0114119e-03   2.0565857e-02   1.0163411e-03   2.9049390e-02   1.5138783e+01
!    1.8276090e-01   9.3280284e-01   8.4702686e+00  -2.6450978e-01  -8.3210648e+00   1.8642117e+01   1.8136075e-03  -1.1893791e-01  -6.1321027e-03   2.3487379e-01   6.6955859e+00
!   -3.4424686e-04   8.9065162e-04   8.7164554e-01   6.7355169e-04  -2.3861994e-02  -3.3616614e-02  -6.0636630e-06   3.8511214e-05   2.4927650e-05   9.4197067e-05  -2.2472680e-02
--- 1,7 ----
!    1.6000000e+02   1.5600000e+02   1.0300000e+02   2.0300000e+00
!    1.0479296e+00   2.0957160e-02   8.8388537e-01  -9.5867538e-02  -1.5343588e+01   9.1434057e-01  -7.2849794e-04  -1.9043844e-01  -9.4217255e-04   1.3391235e-01   3.0318738e+01
!   -1.2401241e-01   1.2913247e+00   8.8065656e+00  -1.2531225e-01  -1.9330677e+00  -9.6356296e+00   9.7583905e-04   1.2609761e-02   2.6829485e-04   1.8947370e-01  -2.9499687e-01
!   -7.4470449e-04   2.0721810e-04   8.5081328e-01  -3.9949940e-04  -3.6176833e-02   1.2013283e-01   4.4201870e-06  -2.2070940e-03   6.4104057e-06  -4.0661670e-04   2.2978403e-03
!    1.6386469e+00   4.4100098e-03   8.9295190e-01  -2.8468175e-01  -1.4036527e+01   3.1974737e+00   2.0310144e-03   2.8690882e-02   8.2136973e-04   6.5590462e-02   2.7178124e+01
!    1.1518999e-01   1.3083468e+00   8.6445766e+00  -2.2024709e-01  -4.5113527e+00  -9.3532091e+00   1.3076631e-03  -2.2767081e-01  -4.0793505e-03   2.2162944e-01   4.5452246e+00
!    2.0441291e-04   1.2304346e-04   8.5184341e-01   2.9945103e-04  -4.0769178e-02   1.1502130e-01  -3.1701517e-06   1.2370161e-03   1.9654829e-05  -3.6545940e-04   5.2478263e-03
