NTRT Simulator  Version: Master
 All Classes Namespaces Files Functions Variables Typedefs Friends Pages
colSpineSine Class Reference

#include <colSpineSine.h>

Inheritance diagram for colSpineSine:
Collaboration diagram for colSpineSine:

Public Member Functions

 colSpineSine (std::string args, std::string resourcePath="")
 
virtual void onSetup (BaseSpineModelLearning &subject)
 
virtual void onStep (BaseSpineModelLearning &subject, double dt)
 
virtual void onTeardown (BaseSpineModelLearning &subject)
 
virtual void onAttach (BaseSpineModelLearning &subject)
 

Protected Member Functions

virtual void setupWaves (BaseSpineModelLearning &subject)
 

Protected Attributes

std::vector
< tgSineStringControl * > 
m_sineControllers
 
double m_updateTime
 
double m_controlTime
 
std::vector< double > initConditions
 
std::string controlFilename
 
std::string controlFilePath
 

Detailed Description

Inherits from BaseSpineCPGControl, and overrides setupCPGs so different muscle groups can have different ImpedanceControl parameters Modified from htSpineSine to accomidate additional segments

Definition at line 41 of file colSpineSine.h.

Constructor & Destructor Documentation

colSpineSine::colSpineSine ( std::string  args,
std::string  resourcePath = "" 
)

Defining the adapters here assumes the controller is around and attached for the lifecycle of the learning runs. I.E. that the setup and teardown functions are used for tgModel

Definition at line 58 of file colSpineSine.cpp.

Here is the call graph for this function:

Member Function Documentation

virtual void tgObserver< BaseSpineModelLearning >::onAttach ( BaseSpineModelLearning subject)
inlinevirtualinherited

Notify the observers when an attach action has occurred. Will only occur once, typically before setup

Parameters
[in,out]subjectthe subject being observed

Definition at line 55 of file tgObserver.h.

void colSpineSine::onSetup ( BaseSpineModelLearning subject)
virtual

Notify the observers when a setup action has occurred.

Parameters
[in,out]subjectthe subject being observed

Reimplemented from tgObserver< BaseSpineModelLearning >.

Definition at line 74 of file colSpineSine.cpp.

Here is the call graph for this function:

void colSpineSine::onStep ( BaseSpineModelLearning subject,
double  dt 
)
virtual

Notify the observers when a step action has occurred.

Parameters
[in,out]subjectthe subject being observed
[in]thenumber of seconds since the previous call; must be positive

Basically nothing to do. Sine controllers will take care of themselves

Implements tgObserver< BaseSpineModelLearning >.

Definition at line 85 of file colSpineSine.cpp.

void colSpineSine::onTeardown ( BaseSpineModelLearning subject)
virtual

Notify the observers when a teardown action has occurred.

Parameters
[in,out]subjectthe subject being observed

Reimplemented from tgObserver< BaseSpineModelLearning >.

Definition at line 96 of file colSpineSine.cpp.

void colSpineSine::setupWaves ( BaseSpineModelLearning subject)
protectedvirtual
Todo:
should this throw an exception instead??
Todo:
get top, left, right offset, add bodywaves back in.

Definition at line 137 of file colSpineSine.cpp.

Here is the caller graph for this function:


The documentation for this class was generated from the following files: