MAV'RIC
|
00001 /*This file is prepared for Doxygen automatic documentation generation.*/ 00018 /* Copyright (c) 2009 Atmel Corporation. All rights reserved. 00019 * 00020 * Redistribution and use in source and binary forms, with or without 00021 * modification, are permitted provided that the following conditions are met: 00022 * 00023 * 1. Redistributions of source code must retain the above copyright notice, this 00024 * list of conditions and the following disclaimer. 00025 * 00026 * 2. Redistributions in binary form must reproduce the above copyright notice, 00027 * this list of conditions and the following disclaimer in the documentation 00028 * and/or other materials provided with the distribution. 00029 * 00030 * 3. The name of Atmel may not be used to endorse or promote products derived 00031 * from this software without specific prior written permission. 00032 * 00033 * 4. This software may only be redistributed and used in connection with an Atmel 00034 * AVR product. 00035 * 00036 * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED 00037 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 00038 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE 00039 * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR 00040 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 00041 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 00042 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 00043 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00044 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 00045 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE 00046 * 00047 */ 00048 00049 #ifndef _LED_H_ 00050 #define _LED_H_ 00051 00052 #ifdef __cplusplus 00053 extern "C" { 00054 #endif 00055 00056 #include <stdint.h> 00057 #include <stdbool.h> 00058 00061 00062 #define LED0 0x01 00063 #define LED1 0x02 00064 #define LED2 0x04 00065 #define LED3 0x08 00066 00067 00068 00075 extern uint32_t LED_Read_Display(void); 00076 00083 extern void LED_Display(uint32_t leds); 00084 00093 extern uint32_t LED_Read_Display_Mask(uint32_t mask); 00094 00103 extern void LED_Display_Mask(uint32_t mask, uint32_t leds); 00104 00114 extern bool LED_Test(uint32_t leds); 00115 00122 extern void LED_Off(uint32_t leds); 00123 00130 extern void LED_On(uint32_t leds); 00131 00138 extern void LED_Toggle(uint32_t leds); 00139 00150 extern uint32_t LED_Read_Display_Field(uint32_t field); 00151 00160 extern void LED_Display_Field(uint32_t field, uint32_t leds); 00161 00174 extern uint8_t LED_Get_Intensity(uint32_t led); 00175 00186 extern void LED_Set_Intensity(uint32_t leds, uint8_t intensity); 00187 00188 #ifdef __cplusplus 00189 } 00190 #endif 00191 00192 #endif // _LED_H_