#include <SpikeDelayLine.h>
Public Member Functions | |
SpikeDelayLine (double theDelay=2.0) | |
Delay of the line. | |
virtual | ~SpikeDelayLine () |
Destructor. | |
unsigned | step (double dt, bool pushSpike) |
Step the delay line. | |
unsigned | setDelay (double theDelay, bool dumpSpikes=true) |
Set a new value for the delay. | |
double | getDelay () |
Get the current delay. | |
bool | spikeInLine () const |
Returns there is one (or more) spike in the delay line. | |
unsigned | spikeCount () const |
Returns the number of spike in the delay line. | |
Protected Member Functions | |
unsigned | dumpOldSpikes () |
Pop all the spikes that are beyond the current delay. | |
Protected Attributes | |
double | delay |
Length of the delay line. | |
double | totalInterval |
Current total time the in the intervals. | |
double | timeSinceLastSpike |
Time since last spike pushed in the line. | |
bool | spikePresent |
True if spike are in line. | |
std::queue< double > | intervals |
Inter-spike intervals. |
|
Pop all the spikes that are beyond the current delay.
|
|
Set a new value for the delay. In case the delay is reduced, it is possible to dump spikes that are beyond the new delay immediately or to wait for the next time-step. In the last case, the function always returns 0.
|
|
Step the delay line.
|