main.c

Go to the documentation of this file.
00001 /*This file is prepared for Doxygen automatic documentation generation.*/
00079 
00080 /* Copyright (c) 2009 Atmel Corporation. All rights reserved.
00081  *
00082  * Redistribution and use in source and binary forms, with or without
00083  * modification, are permitted provided that the following conditions are met:
00084  *
00085  * 1. Redistributions of source code must retain the above copyright notice,
00086  * this list of conditions and the following disclaimer.
00087  *
00088  * 2. Redistributions in binary form must reproduce the above copyright notice,
00089  * this list of conditions and the following disclaimer in the documentation
00090  * and/or other materials provided with the distribution.
00091  *
00092  * 3. The name of Atmel may not be used to endorse or promote products derived
00093  * from this software without specific prior written permission.
00094  *
00095  * 4. This software may only be redistributed and used in connection with an Atmel
00096  * AVR product.
00097  *
00098  * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED
00099  * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
00100  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE EXPRESSLY AND
00101  * SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT,
00102  * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
00103  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
00104  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
00105  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
00106  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
00107  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00108  */
00109  
00110 //_____  I N C L U D E S ___________________________________________________
00111 
00112 #include "config.h"
00113 #include "modules/scheduler/scheduler.h"
00114 #include "lib_mcu/wdt/wdt_drv.h"
00115 #include "lib_mcu/power/power_drv.h"
00116 #include "lib_mcu/usb/usb_drv.h"
00117 
00118 //_____ M A C R O S ________________________________________________________
00119 
00120 //_____ D E F I N I T I O N S ______________________________________________
00121 
00122 int main(void)
00123 {
00124    Usb_enable_regulator();
00125    wdtdrv_disable();
00126    Clear_prescaler();
00127    scheduler();
00128    return 0;
00129 }
00130 
00134 #ifdef  __GNUC__
00135 // Locate low level init function before RAM init (init3 section)
00136 // and remove std prologue/epilogue
00137 char __low_level_init(void) __attribute__ ((section (".init3"),naked));
00138 #endif
00139 
00140 #ifdef __cplusplus
00141 extern "C" {
00142 #endif
00143 char __low_level_init()
00144 {
00145   Clear_prescaler();
00146   return 1;
00147 }
00148 #ifdef __cplusplus
00149 }
00150 #endif

Generated on Fri Sep 11 14:39:50 2009 for ATMEL by  doxygen 1.5.3