ConOpSys V2970
P004.07
ANVILEX control operating system
|
High precision timer base class. More...
#include <High_Precision_Timer_Base.h>
Public Member Functions | |
virtual U64 | Get_Actual_Time_U64 ()=0 |
Get actual system time in timer counts as U64. More... | |
VOID | Delay (F32 f32_Delay_Value) |
Perform blocked delay given in s. More... | |
F32 | Get_Delta_Time (U64 u64_Start_Timestamp, U64 u64_End_Timestamp) |
Get delta time in seconds. More... | |
BOOL | Is_Timeout (U64 u64_Start_Timestamp, F32 f32_Timeout) |
Return statis of the timeout. More... | |
VOID | Interrupt () |
High precision timer interrupt method. More... | |
Public Member Functions inherited from TTimer_Base | |
TTimer_Base () | |
User timer class constructor method. More... | |
virtual | ~TTimer_Base () |
User timer class destructor method. More... | |
VOID | Interrupt () |
User timer interrupt method. More... | |
virtual BOOL | Configure_Clock (U32 u32_Clock) |
Set user timer input clock frequency method. More... | |
BOOL | Set_Interrupt_Frequency (F32 f32_Frequency) |
Set user timer interrupt frequency method. More... | |
virtual VOID | Interrupt_Enable (U32 u32_Interrupt_Priority)=0 |
Enable interrupt method. More... | |
virtual VOID | Interrupt_Disable ()=0 |
Disable interrupt method. More... | |
virtual VOID | Start ()=0 |
Start timer operation method. More... | |
virtual VOID | Stop ()=0 |
Stop timer operation method. More... | |
F32 | Get_Resolution_s () |
Get timer resolution in seconds. More... | |
F32 | Get_Resolution_ms () |
Get timer resolution in miliseconds. More... | |
F32 | Get_Resolution_us () |
Get timer resolution in microseconds. More... | |
F32 | Get_Resolution_ns () |
Get timer resolution in nanoseconds. More... | |
F32 | Get_Interrupt_Frequency () |
Get Get interrupt frequency in herz. More... | |
F32 | Get_Interrupt_Period () |
Get interrupt period in seconds. More... | |
U32 | Time_To_Execution_Loops (F32 f32_Time_Span) |
Convert time to interrupt loops method. More... | |
VOID | Init () |
User timer initialisation method. More... | |
VOID | Done () |
User timer finalisation method. More... | |
Protected Attributes | |
U32 | u32_Extended_Counter = (U32)0 |
Extended counter. More... | |
Protected Attributes inherited from TTimer_Base | |
BOOL | bool_Initialisation_Error = (BOOL)false |
Initialisation error. More... | |
F32 | f32_Input_Clock = (F32)0.0f |
Timer input frequency in Hz. More... | |
U32 | u32_Timer_Clock = (U32)0 |
Timer clock in herz. More... | |
U32 | u32_Timer_Counts = (U32)0 |
Timer counter preset value. More... | |
F32 | f32_Resolution_s = (F32)0.0f |
Timer resolution in seconds. More... | |
F32 | f32_Resolution_ms = (F32)0.0f |
Timer resolution in miliseconds. More... | |
F32 | f32_Resolution_us = (F32)0.0f |
Timer resolution in microseconds. More... | |
F32 | f32_Resolution_ns = (F32)0.0f |
Timer resolution in nanoseconds. More... | |
F32 | f32_Interrupt_Frequency = (F32)0.0f |
Interrupt frequency in herz. More... | |
F32 | f32_Interrupt_Period = (F32)0.0f |
Interrupt period in seconds. More... | |
High precision timer base class.
Perform blocked delay given in s.
[in] | f32_Delay_Value | - Blocked delay time in seconds. |
References TTimer_Base::f32_Resolution_s, and Get_Actual_Time_U64().
Referenced by TP019_14_KG3_DIO2_T1::Chip_Reset(), TSPI2_P014_51_CB::CS_Activate(), TSPI5_P014_51_CB::CS_Activate(), TSPI2_P015_09_CB::CS_Activate(), TSPI4_P015_09_CB::CS_Activate(), TSPI5_P015_09_CB::CS_Activate(), TSPI2_P015_27_V1_0_CB::CS_Activate(), TSPI5_P015_27_V1_0_CB::CS_Activate(), TSPI2_P017_39_KG3_CB::CS_Activate(), TSPI4_P017_39_KG3_CB::CS_Activate(), TSPI5_P017_39_KG3_CB::CS_Activate(), TSPI2_P014_51_CB::CS_Deactivate(), TSPI5_P014_51_CB::CS_Deactivate(), TSPI2_P015_09_CB::CS_Deactivate(), TSPI4_P015_09_CB::CS_Deactivate(), TSPI5_P015_09_CB::CS_Deactivate(), TSPI2_P015_27_V1_0_CB::CS_Deactivate(), TSPI5_P015_27_V1_0_CB::CS_Deactivate(), TSPI2_P017_39_KG3_CB::CS_Deactivate(), TSPI4_P017_39_KG3_CB::CS_Deactivate(), TSPI5_P017_39_KG3_CB::CS_Deactivate(), ETH_ConfigMAC(), ETH_FlushTransmitFIFO(), ETH_MACDMAConfig(), ETH_MACReceptionDisable(), ETH_MACReceptionEnable(), ETH_MACTransmissionDisable(), ETH_MACTransmissionEnable(), TFM25V02::Exit_Sleep_Mode(), PHY_ETH_Init(), TP019_14_KG3_DIO2_T1::Processing_Measured_Data(), TFM25V02::Read_Buffer(), TFM25V02::Read_Device_ID(), TFM25V02::Read_Memory(), TFM25V02::Read_Serial_Number(), TFM25V02::Read_Status_Register(), TS25FL512::Reset(), TP013_49_V1_0_RTD::RTD_Wait(), TP015_09_V1_0_RTD::RTD_Wait(), TP017_41_KG3_RTD::RTD_Wait(), TFM25V02::Verify_Buffer(), TFM25V02::Write_Buffer(), TFM25V02::Write_Memory(), and TFM25V02::Write_Status_Register().
|
pure virtual |
Get actual system time in timer counts as U64.
None |
Implemented in TTIMER2_STM32F429, and TTIMER5_STM32F410CBU6.
Referenced by Delay(), and Is_Timeout().
Get delta time in seconds.
[in] | u64_Start_Timestamp | - Timer start timestamp. |
[in] | u64_End_Timestamp | - Timer end timestamp. |
References TTimer_Base::f32_Resolution_s.
Referenced by TProtocol_MODBUS_Over_UART::Execute_1ms(), Is_Timeout(), and TMODBUS_Request_FIFO::Pop().
VOID THigh_Precision_Timer_Base::Interrupt | ( | ) |
High precision timer interrupt method.
References u32_Extended_Counter.
Referenced by TTIMER2_STM32F429::Interrupt().
Return statis of the timeout.
[in] | u64_Start_Timestamp | - Timer start timestamp. |
[in] | f32_Timeout | - Timeout value in seconds. |
false | - Timeout elapsed |
true | - Timeout in progress |
References Get_Actual_Time_U64(), and Get_Delta_Time().
Referenced by TS25FL512::Wait_For_Operation_Done().
Extended counter.
Referenced by TTIMER5_STM32F410CBU6::Get_Actual_Time_U64(), TTIMER2_STM32F429::Get_Actual_Time_U64(), and Interrupt().