/**
  @page COMP_AnalogWatchdog COMP Analog Watchdog example
  
  @verbatim
  ******************** (C) COPYRIGHT 2015 STMicroelectronics *******************
  * @file    COMP/COMP_AnalogWatchdog/readme.txt 
  * @author  MCD Application Team
  * @version V1.1.3
  * @date    15-December-2021
  * @brief   Description of the COMP Analog Watchdog Example
  ******************************************************************************
  *
  * Copyright (c) 2015 STMicroelectronics.
  * All rights reserved.
  *
  * This software is licensed under terms that can be found in the LICENSE file
  * in the root directory of this software component.
  * If no LICENSE file comes with this software, it is provided AS-IS.
  *
  ******************************************************************************
   @endverbatim

@par Example Description 

This example shows how to make an analog watchdog using the STM32F30x COMPs 
peripherals in window mode:
  - The upper threshold is set to VREFINT = 1.22V
  - The lower threshold is set to VREFINT / 4 = 1.22V = 0.305V
  - The input voltage is configured to be connected to PA.01

If the input voltage is above the higher threshold, LD3 and LD1 are turned On.
If the input voltage is under the lower threshold, LD2 and LD4 are turned On.
If the input voltage is within the thresholds, the MCU remains in STOP mode
 

@par Directory contents 

  - COMP/COMP_AnalogWatchdog/stm32f30x_conf.h    Library Configuration file
  - COMP/COMP_AnalogWatchdog/stm32f30x_it.c      Interrupt handlers
  - COMP/COMP_AnalogWatchdog/stm32f30x_it.h      Interrupt handlers header file
  - COMP/COMP_AnalogWatchdog/main.c              Main program
  - COMP/COMP_AnalogWatchdog/main.h              Main Header file
  - COMP/COMP_AnalogWatchdog/system_stm32f30x.c  STM32F30x system source file
  
@note The "system_stm32f30x.c" is generated by an automatic clock configuration 
      system and can be easily customized to your own configuration. 
      To select different clock setup, use the "STM32F30x_Clock_Configuration_V1.0.0.xls" 
      provided with the AN4152 package available on <a href="http://www.st.com/internet/mcu/family/141.jsp">  ST Microcontrollers </a>
         
@par Hardware and Software environment

  - This example runs on STM32F30x Devices.
  
  - This example has been tested with STMicroelectronics STM32303C-EVAL (STM32F30x)
    evaluation board and can be easily tailored to any other supported device 
    and development board.

  - STM32303C-EVAL Set-up
    - Use LED1, LED2, LED3 and LED4 connected respectively to PE.08, PE.09 ,PE.10
      and PE.11 pins
      @note This example run in stand alone mode.
    - Use a wire to connect Potentiometer RV2 (PC.01 pin) to COMP2 non inverting input (PA.01)


@par How to use it ? 

In order to make the program work, you must do the following :
 - Copy all source files from this example folder to the template folder under
   Projects\STM32F30x_StdPeriph_Templates
 - Open your preferred toolchain
 - Add the following files to the project source list
    - Utilities\STM32_EVAL\STM32303C_EVAL\stm32303c_eval.c
 - Rebuild all files and load your image into target memory
 - Run the example
    

 */
