diff options
Diffstat (limited to '2.3-1/macros/Hardware/AVR/AVRUARTSetup.sci')
-rw-r--r-- | 2.3-1/macros/Hardware/AVR/AVRUARTSetup.sci | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/2.3-1/macros/Hardware/AVR/AVRUARTSetup.sci b/2.3-1/macros/Hardware/AVR/AVRUARTSetup.sci index 32e5db86..896674b3 100644 --- a/2.3-1/macros/Hardware/AVR/AVRUARTSetup.sci +++ b/2.3-1/macros/Hardware/AVR/AVRUARTSetup.sci @@ -10,6 +10,36 @@ function AVRUARTSetup(mode, baudrate, stopbits, parity) // Function to Setup Serial Communication i.e UART or USART in ATmega16. +<<<<<<< HEAD +// +// Parameters +// mode : integer, from 0 to 2 +// baudrate : Enter one of the following available baudrates (2400 , 4800 , 9600 , 14400 , 19200 , 28800 , 38400 , 57600 , 768000 , 115200 , 230400 , 250000 , 1000000) +// stopbits : integer, (0 for one stopbit) or (1 for two stopbits) +// parity : integer, from 0 to 2 +// +// Description +// This function Setup the UART or USART for Serial Communicaion between ATmega16 +// and different micro controllers or between ATmega16 and Computer. +// +// mode can take values: +// <itemizedlist> +// <listitem><para>0 for Asynchronous Normal mode</para></listitem> +// <listitem><para>1 for Asynchronous Double Speed mode</para></listitem> +// <listitem><para>2 for Synchronous mode</para></listitem> +// </itemizedlist> +// +// parity can take values: +// <itemizedlist> +// <listitem><para>0 for parity disabled</para></listitem> +// <listitem><para>1 for even parity</para></listitem> +// <listitem><para>2 for odd parity</para></listitem> +// </itemizedlist> +// +// This is curretly dummy function. It provides no functionality but is required +// for providing support for generating C code for AVR. +// +======= // Description // This function Setup the UART or USART for Serial Communicaion between ATmega16 // and different micro controllers or between ATmega16 and Computer. @@ -33,6 +63,7 @@ function AVRUARTSetup(mode, baudrate, stopbits, parity) // 1 for even parity // 2 for odd parity // +>>>>>>> 9e5793a7b05b23e6044a6d7a9ddd5db39ba375f0 //Examples // AVRUARTSetup(0,9600,0,0); //This function will enable UART Communication for ATmega16 // with 9600 as baudrate,one stop bit and parity disabled @@ -43,8 +74,12 @@ function AVRUARTSetup(mode, baudrate, stopbits, parity) // Authors // Ashish Kamble // +<<<<<<< HEAD + +======= // This is curretly dummy function. It provides no functionality but is required // for providing support for generating C code for AVR. +>>>>>>> 9e5793a7b05b23e6044a6d7a9ddd5db39ba375f0 if(mode>=3) then disp("Error : Invalid input argument ''mode'' in AVRUARTSetup function."); end |