EDF - OnePIC MCU  v1.1.0
source/base/include/OnePIC_timer.h File Reference
#include <stdint.h>
#include "Compiler.h"
Include dependency graph for OnePIC_timer.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void EDF_TMR_ClockSourceSelect (TMR_MODULE_ID index, EDF_TMR_CLOCK_SOURCE source)
 selects whether or not the source will be internal or external
void EDF_TMR_StopInIdleDisable (TMR_MODULE_ID index)
 disables the timer source
void EDF_TMR_GateDisable (TMR_MODULE_ID index)
 disables the timer's gate if used
void EDF_TMR_PrescalerSet (TMR_MODULE_ID index, EDF_TMR_PRESCALE prescaler)
 sets the prescaler for the timer
void EDF_TMR_Start (TMR_MODULE_ID index)
 starts te timer
void EDF_TMR_Stop (TMR_MODULE_ID index)
 stops the timer
void EDF_TMR_CounterSet (TMR_MODULE_ID index, uint16_t value)
 loads the respective period register (PR) register
enum  TMR_MODULE_ID_tag {
  TMR_0, TMR_1, TMR_2, TMR_4,
  TMR_6
}
 Contains ONLY timer related sources for the 8bit. More...
enum  EDF_TMR_CLOCK_SOURCE_tag { TMR_SOURCE_INS_CLK = 0, TMR_SOURCE_EXT_CLK = 1 }
 Contains the source of the clocks such as: More...
enum  EDF_TMR_PRESCALE_tag {
  TMR_PRESCALE_1_256 = 0x03, TMR_PRESCALE_1_64 = 0x02, TMR_PRESCALE_1_8 = 0x01, TMR_PRESCALE_1_1 = 0x00,
  TMR246_PRESCALE_1_64 = 0b11, TMR246_PRESCALE_1_16 = 0b10, TMR246_PRESCALE_1_4 = 0b01, TMR246_PRESCALE_1_1 = 0b00,
  TMR1_PRESCALE_1_8 = 0b11, TMR1_PRESCALE_1_4 = 0b10, TMR1_PRESCALE_1_2 = 0b01, TMR1_PRESCALE_1_1 = 0b00,
  TMR0_PRESCALE_1_256 = 0b111, TMR0_PRESCALE_1_128 = 0b110, TMR0_PRESCALE_1_64 = 0b101, TMR0_PRESCALE_1_32 = 0b100,
  TMR0_PRESCALE_1_16 = 0b011, TMR0_PRESCALE_1_8 = 0b010, TMR0_PRESCALE_1_4 = 0b001, TMR0_PRESCALE_1_2 = 0b000
}
 Contains all prescaler settings for All timers. More...
typedef enum TMR_MODULE_ID_tag TMR_MODULE_ID
typedef enum
EDF_TMR_CLOCK_SOURCE_tag 
EDF_TMR_CLOCK_SOURCE
typedef enum EDF_TMR_PRESCALE_tag EDF_TMR_PRESCALE

Detailed Description

Definition in file OnePIC_timer.h.


Enumeration Type Documentation

Contains the source of the clocks such as:

  • Fosc
  • capactivie sensing oscillator
  • Fosc/4
  • dedicated oscillator circuit
Enumerator:
TMR_SOURCE_INS_CLK 

internal source

TMR_SOURCE_EXT_CLK 

extenral source

Definition at line 48 of file OnePIC_timer.h.

Contains all prescaler settings for All timers.

Enumerator:
TMR246_PRESCALE_1_64 

timer 2,4, & 6 1:64 prescaler

TMR246_PRESCALE_1_16 

timer 2,4, & 6 1:16 prescaler

TMR246_PRESCALE_1_4 

timer 2,4, & 6 1:4 prescaler

TMR246_PRESCALE_1_1 

timer 2,4, & 6 1:1 prescaler

TMR1_PRESCALE_1_8 

timer 1 1:8 prescaler

TMR1_PRESCALE_1_4 

timer 1 1:4 prescaler

TMR1_PRESCALE_1_2 

timer 1 1:2 prescaler

TMR1_PRESCALE_1_1 

timer 1 1:1 prescaler

TMR0_PRESCALE_1_256 

timer 0 1:256 prescaler

TMR0_PRESCALE_1_128 

timer 0 1:128 prescaler

TMR0_PRESCALE_1_64 

timer 0 1:64 prescaler

TMR0_PRESCALE_1_32 

timer 0 1:32 prescaler

TMR0_PRESCALE_1_16 

timer 0 1:16 prescaler

TMR0_PRESCALE_1_8 

timer 0 1:8 prescaler

TMR0_PRESCALE_1_4 

timer 0 1:4 prescaler

TMR0_PRESCALE_1_2 

timer 0 1:2 prescaler

Definition at line 92 of file OnePIC_timer.h.

Contains ONLY timer related sources for the 8bit.

Enumerator:
TMR_0 

TMR0

TMR_1 

TMR1

TMR_2 

TMR2

TMR_4 

TMR5

TMR_6 

TMR6

Definition at line 26 of file OnePIC_timer.h.