File control/src/Sensor/ControlSensor.hpp#

Go to the source code of this file

A generic control sensor

class ControlSensor : public Sensor
#include <ControlSensor.hpp>

Generic control Sensor to get the output of the system.

Subclassed by LinearSensor

Public Functions

virtual void initialize(const NonSmoothDynamicalSystem &nsds)

initialize sensor data.


nsds – the Model

unsigned int getYDim() const

Get the dimension of the output.


an unsigned int

inline const SiconosVector &y() const

Get a pointer to the output.


SP::SiconosVector to the output

inline SP::SiconosVector yTk() const#
virtual void capture() = 0

capture data when the SensorEvent is processed => set data[SensorEvent]=…

Protected Functions

inline ControlSensor()#

Default constructor.

inline ControlSensor(unsigned int type, SP::DynamicalSystem ds, double delay = 0)#

Simple Constructor.

  • type – the type of the Sensor

  • ds – the SP::DynamicalSystem it observes

  • delay – the delay between the measurement and the avaibility of the data

Protected Attributes

SP::SiconosVector _storedY#

A vector for the current value of the output.

double _delay#

delay between the measurement on the DynamicalSystem and the avaibility of the value

boost::circular_buffer<SP::SiconosVector> _bufferY#

A buffer to store the value of \( y_k \) if there is a delay.

Private Functions