Class for utilizing the input capture from the uC.
More...
#include <inputcapture.h>
|
virtual | ~InputCapture ()=default |
|
virtual unsigned int | ticksPerSecond () const =0 |
| Returns the the number of ticks per second (Hardware timer frequency). More...
|
|
virtual void | setMaxTicks (unsigned int maxTicks)=0 |
| Set the maximum number of ticks at which the tick counter will overflow. More...
|
|
virtual unsigned int | maxTicks () const =0 |
| Get the maximum number of ticks from the timer. More...
|
|
virtual void | start ()=0 |
|
virtual void | stop ()=0 |
|
virtual unsigned int | ticks ()=0 |
| Get the latest number of ticks (at the last change of the input). More...
|
|
virtual void | setTrigger (Trigger trigger)=0 |
| Sets the trigger source. More...
|
|
Class for utilizing the input capture from the uC.
Definition at line 23 of file inputcapture.h.
◆ Trigger
Trigger settings of the input capture.
Enumerator |
---|
RisingEdge | |
FallingEdge | |
RisingAndFallingEdge | |
Definition at line 27 of file inputcapture.h.
◆ ~InputCapture()
virtual semf::InputCapture::~InputCapture |
( |
| ) |
|
|
virtualdefault |
◆ maxTicks()
virtual unsigned int semf::InputCapture::maxTicks |
( |
| ) |
const |
|
pure virtual |
Get the maximum number of ticks from the timer.
- Returns
- The maximum number of ticks from the timer.
Implemented in semf::Stm32InputCapture.
◆ setMaxTicks()
virtual void semf::InputCapture::setMaxTicks |
( |
unsigned int |
maxTicks | ) |
|
|
pure virtual |
Set the maximum number of ticks at which the tick counter will overflow.
- Parameters
-
maxTicks | Number of ticks at which the tick counter will overflow. |
Implemented in semf::Stm32InputCapture.
◆ setTrigger()
virtual void semf::InputCapture::setTrigger |
( |
Trigger |
trigger | ) |
|
|
pure virtual |
◆ start()
virtual void semf::InputCapture::start |
( |
| ) |
|
|
pure virtual |
◆ stop()
virtual void semf::InputCapture::stop |
( |
| ) |
|
|
pure virtual |
◆ ticks()
virtual unsigned int semf::InputCapture::ticks |
( |
| ) |
|
|
pure virtual |
Get the latest number of ticks (at the last change of the input).
- Returns
- The timer ticks at the last change of the input.
Implemented in semf::Stm32InputCapture.
◆ ticksPerSecond()
virtual unsigned int semf::InputCapture::ticksPerSecond |
( |
| ) |
const |
|
pure virtual |
Returns the the number of ticks per second (Hardware timer frequency).
- Returns
- Ticks per second.
Implemented in semf::Stm32InputCapture.
◆ dataAvailable
Signal semf::InputCapture::dataAvailable |
Gets emitted when a new period has been sampled.
Definition at line 67 of file inputcapture.h.
◆ error
Gets emitted when an error occurred.
Definition at line 69 of file inputcapture.h.