TimerInstance_Class

setPrescaler()

Description

This method sets the timer clock prescaler (void).

Syntax

timer1.setPrescaler(pres)

Parameters

timer1: a variable of type TimerInstance_Class

pres: the new prescalar value, type: unsigned

Example

(:source lang=c :)

  1. include <Timer.h>

TimerInstance_class timer1;

void setup () {

   timer1.setPrescaler(0);
   timer1.setComparator(10);
   timer1.setCounter(0);
   timer1.setUpDirection(True);

} (:sourceend:)

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 |