Show
Ignore:
Timestamp:
08/05/08 21:34:59 (5 months ago)
Author:
liamstask
Message:

- revamp AppLed? doc

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • firmware/trunk/libraries/appled/appled.c

    r771 r782  
    6363 
    6464/** 
    65   Attempts to gain access to the I/O lines associated the given LED. 
     65  Enable an LED in the AppLed subsystem. 
    6666  @param index An integer specifying which LED (0-3). 
    6767  @param state An integer specifying locked/active (1) or unlocked/inactive (0). 
    6868  @return Zero on success. 
     69   
     70  \b Example 
     71  \code 
     72  // enable LED 0 
     73  AppLed_SetActive(0, 1); 
     74  \endcode 
    6975*/ 
    7076int AppLed_SetActive( int index, int state ) 
     
    8086 
    8187/** 
    82   Returns whether the I/O lines associated with the LED are available. 
     88  Read whether an AppLed is enabled. 
    8389  @param index An integer specifying which LED (0-3). 
    8490  @return Zero if available, otherwise non-zero. 
     91   
     92  \b Example 
     93  \code 
     94  if(AppLed_GetActive(1)) 
     95  { 
     96    // LED 1 is enabled 
     97  } 
     98  else 
     99  { 
     100    // LED 1 is not enabled 
     101  } 
     102  \endcode 
    85103*/ 
    86104int AppLed_GetActive( int index ) 
     
    92110 
    93111/**  
    94   Control an LED on the Application Board. 
     112  Turn an LED on or off. 
    95113  Sets whether the specified LED on the Application Board is on or off. 
    96114  @param index an integer specifying which LED (0-3). 
     
    98116  @return Zero on success, otherwise error code. 
    99117 
    100   \par Example 
     118  \b Example 
    101119  \code 
    102120  // turn on LED 2 
     
    128146 
    129147/**  
    130   Read the state of an LED on the Application Board. 
     148  Read whether an LED is on or off. 
    131149  @param index An integer specifying which LED (0-3). 
    132150  @return the LED state, or zero on error. 
     151   
     152  \b Example 
     153  \code 
     154  if(AppLed_GetState(2)) 
     155  { 
     156    // LED 2 is currently on 
     157  } 
     158  else 
     159  { 
     160    // LED 2 is currently off 
     161  } 
     162  \endcode 
    133163*/ 
    134164int AppLed_GetState( int index )