diff options
author | imushir | 2015-12-28 16:08:36 +0530 |
---|---|---|
committer | imushir | 2015-12-28 16:08:36 +0530 |
commit | eb760e0368b6be3bc0f0a7f076bc74d25df0df62 (patch) | |
tree | 64d0fdc06c92478f9e15dd2b6def6fe4b369383b /macros/Hardware/AVR/AVRTimerSetup.sci | |
parent | b8c97a6580ea62ca9480504e66be2b2f5b1dc2ef (diff) | |
parent | d166736e0eb384156d30bcea45711d4c8d474ee1 (diff) | |
download | Scilab2C_fossee_old-eb760e0368b6be3bc0f0a7f076bc74d25df0df62.tar.gz Scilab2C_fossee_old-eb760e0368b6be3bc0f0a7f076bc74d25df0df62.tar.bz2 Scilab2C_fossee_old-eb760e0368b6be3bc0f0a7f076bc74d25df0df62.zip |
Merge branch 'master' of https://github.com/siddhu8990/Scilab2C
Fetching master
Diffstat (limited to 'macros/Hardware/AVR/AVRTimerSetup.sci')
-rw-r--r-- | macros/Hardware/AVR/AVRTimerSetup.sci | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/macros/Hardware/AVR/AVRTimerSetup.sci b/macros/Hardware/AVR/AVRTimerSetup.sci new file mode 100644 index 0000000..6316cdd --- /dev/null +++ b/macros/Hardware/AVR/AVRTimerSetup.sci @@ -0,0 +1,31 @@ +function AVRTimerSetup(timer, prescalar) +// Function to set the prescalar for timer. +// +// Calling Sequence +// AVRTimerSetup(timer, prescalar) +// +// Parameters +// timer: timer to be set up (0,1,2) +// prescalar: prescalar to be used for generating PWM waveform (0-7) +// ***Refer datasheet for more description about timer +// +// Description +// This function sets prescalr for timers. 'timer' decides which of the +// three (0,1,2) timers available to be used. The 'prescalar' is needed for +// deciding timer clock. Select appropriate prescalar depending on MCU clock +// and requirement. +// +// +// Examples +// AVRTimerSetup(0,1) //Timer 0 with no scaling +// +// See also +// AVRGetTimerValue +// +// Authors +// Siddhesh Wani +// + +// This is curretly dummy function. It provides no functionality but is required +// for providing support for generating C code for AVR. +endfunction |