TimerInstance_Class

hasPrescaler()

Description

When activated, the timer prescaler divides the main clock by a chosen value from the timerPrescalarDividers table. This method returns whether the timer instance has prescaler support: True if prescaler is implemented, False otherwise.

Syntax

timer1.hasPrescaler()

Parameters

timer1: a variable of type TimerInstance_Class

Example

(:source lang=c :)

  1. include <VGALiquidCrystal.h>;
  2. include <Timer.h>

TimerInstance_class timer1; LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

void setup () {

   if (timer1.hasPrescaler())
   lcd.print ("Prescaler enabled"); 

} (:sourcend:)

See also

Corrections, suggestions, and new documentation can be added directly to the wiki page. Scroll to the bottom, choose "Edit Page" and use "Papilio" as the password.

  

Share |