ISF  2.1
Intelligent Sensing Framework for Kinetis with Processor Expert
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
BMTimer1.h File Reference

This TimerUnit component provides a low level API for unified hardware access across various timer devices using the Prescaler-Counter-Compare-Capture timer structure. More...

#include "PE_Types.h"
#include "PE_Error.h"
#include "PE_Const.h"
#include "IO_Map.h"
#include "PIT_PDD.h"
#include "Cpu.h"
Include dependency graph for BMTimer1.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define __BWUserType_BMTimer1_TValueType
 
#define BMTimer1_CNT_INP_FREQ_U_0   0x016E3600UL /* Counter input frequency in Hz */
 
#define BMTimer1_CNT_INP_FREQ_R_0   23999808.00153599F /* Counter input frequency in Hz */
 
#define BMTimer1_CNT_INP_FREQ_COUNT   0U /* Count of predefined counter input frequencies */
 
#define BMTimer1_PERIOD_TICKS   0x016E3600UL /* Initialization value of period in 'counter ticks' */
 
#define BMTimer1_NUMBER_OF_CHANNELS   0x00U /* Count of predefined channels */
 
#define BMTimer1_COUNTER_WIDTH   0x20U /* Counter width in bits */
 
#define BMTimer1_COUNTER_DIR   DIR_DOWN /* Direction of counting */
 
#define BMTimer1_PRPH_BASE_ADDRESS   0x40037000U
 
#define BMTimer1_Init_METHOD_ENABLED
 
#define BMTimer1_Deinit_METHOD_ENABLED
 
#define BMTimer1_Enable_METHOD_ENABLED
 
#define BMTimer1_Disable_METHOD_ENABLED
 
#define BMTimer1_SetPeriodTicks_METHOD_ENABLED
 
#define BMTimer1_GetPeriodTicks_METHOD_ENABLED
 
#define BMTimer1_ResetCounter_METHOD_ENABLED
 
#define BMTimer1_GetCounterValue_METHOD_ENABLED
 
#define BMTimer1_OnCounterRestart_EVENT_ENABLED
 

Typedefs

typedef uint32_t BMTimer1_TValueType
 

Functions

LDD_TDeviceData * BMTimer1_Init (LDD_TUserData *UserDataPtr)
 Initializes the device. Allocates memory for the device data structure, allocates interrupt vectors and sets interrupt priority, sets pin routing, sets timing, etc. If the property ["Enable in init. code"] is set to "yes" value then the device is also enabled (see the description of the [Enable] method). In this case the [Enable] method is not necessary and needn't to be generated. This method can be called only once. Before the second call of Init the [Deinit] must be called first. More...
 
void BMTimer1_Deinit (LDD_TDeviceData *DeviceDataPtr)
 Deinitializes the device. Switches off the device, frees the device data structure memory, interrupts vectors, etc. More...
 
LDD_TError BMTimer1_Enable (LDD_TDeviceData *DeviceDataPtr)
 Enables the component - it starts the signal generation. Events may be generated (see SetEventMask). The method is not available if the counter can't be disabled/enabled by HW. More...
 
LDD_TError BMTimer1_Disable (LDD_TDeviceData *DeviceDataPtr)
 Disables the component - it stops signal generation and events calling. The method is not available if the counter can't be disabled/enabled by HW. More...
 
LDD_TError BMTimer1_SetPeriodTicks (LDD_TDeviceData *DeviceDataPtr, BMTimer1_TValueType Ticks)
 The method sets timer re-initialization period (in timer ticks). This method is available only if the property ["Counter restart"] is switched to 'on-match' value. More...
 
LDD_TError BMTimer1_GetPeriodTicks (LDD_TDeviceData *DeviceDataPtr, BMTimer1_TValueType *TicksPtr)
 Returns the number of counter ticks before re-initialization. See also method [SetPeriodTicks]. This method is available only if the property ["Counter restart"] is switched to 'on-match' value. More...
 
LDD_TError BMTimer1_ResetCounter (LDD_TDeviceData *DeviceDataPtr)
 Resets counter. If counter is counting up then it is set to zero. If counter is counting down then counter is updated to the reload value. The method is not available if HW doesn't allow resetting of the counter. More...
 
BMTimer1_TValueType BMTimer1_GetCounterValue (LDD_TDeviceData *DeviceDataPtr)
 Returns the content of counter register. This method can be used both if counter is enabled and if counter is disabled. The method is not available if HW doesn't allow reading of the counter. More...
 
void BMTimer1_Interrupt (LDD_RTOS_TISRParameter _isrParameter)
 

Detailed Description

This TimerUnit component provides a low level API for unified hardware access across various timer devices using the Prescaler-Counter-Compare-Capture timer structure.

Version
01.11

Definition in file BMTimer1.h.