/** ###################################################################
**     THIS BEAN MODULE IS GENERATED BY THE TOOL. DO NOT MODIFY IT.
**     Filename  : Inhr1.H
**     Project   : lab_tone_det
**     Processor : MC56F8006_48_LQFP
**     Beantype  : ExtInt
**     Version   : Bean 02.090, Driver 02.01, CPU db: 3.00.177
**     Compiler  : Metrowerks DSP C Compiler
**     Date/Time : 11/15/2008, 4:35 PM
**     Abstract  :
**         This bean "ExtInt" implements an external 
**         interrupt, its control methods and interrupt/event 
**         handling procedure.
**         The bean uses one pin which generates interrupt on 
**         selected edge.
**     Settings  :
**         Interrupt name              : INT_GPIO_B
**         User handling procedure     : Inhr1_OnInterrupt
**
**         Used pin                    :
**             ----------------------------------------------------
**                Number (on package)  |    Name
**             ----------------------------------------------------
**                       25            |  GPIOB2_ANA2_ANB2_MISO_TIN2_CMP0_OUT
**             ----------------------------------------------------
**
**         Port name                   : GPIOB
**
**         Bit number (in port)        : 2
**         Bit mask of the port        : 0004
**
**         Signal edge/level           : falling
**         Priority                    : 0
**         Pull option                 : up
**         Initial state               : Enabled
**
**         Edge register               : GPIO_B_IPOLR [F1A6]
**         Enable register             : GPIO_B_IENR [F1A5]
**         Request register            : GPIO_B_IESR [F1A8]
**
**         Port data register          : GPIO_B_DR [F1A1]
**         Port control register       : GPIO_B_DDR [F1A2]
**         Port function register      : GPIO_B_PER [F1A3]
**     Contents  :
**         GetVal     - bool Inhr1_GetVal(void);
**         ConnectPin - void Inhr1_ConnectPin(void);
**
**     (c) Copyright UNIS, a.s. 1997-2008
**     UNIS, a.s.
**     Jundrovska 33
**     624 00 Brno
**     Czech Republic
**     http      : www.processorexpert.com
**     mail      : info@processorexpert.com
** ###################################################################*/

#ifndef __Inhr1_H
#define __Inhr1_H

/* MODULE Inhr1. */

/*Including shared modules, which are used in the whole project*/
#include "PE_Types.h"
#include "PE_Error.h"
#include "PE_Const.h"
#include "IO_Map.h"
#include "BTN1.h"
#include "Cpu.h"


#define Inhr1_PIN_MASK          ((byte)0x04) /* Pin mask */

void Inhr1_Interrupt(void);
/*
** ===================================================================
**     Method      :  Inhr1_Interrupt (bean ExtInt)
**
**     Description :
**         The method services the interrupt of the selected peripheral(s)
**         and invokes the beans event.
**         This method is internal. It is used by Processor Expert only.
** ===================================================================
*/

#define Inhr1_GetVal() ((bool)(getRegBits(GPIO_B_RAWDATA,Inhr1_PIN_MASK)))
/*
** ===================================================================
**     Method      :  Inhr1_GetVal (bean ExtInt)
**
**     Description :
**         Returns the actual value of the input pin of the bean.
**     Parameters  : None
**     Returns     :
**         ---             - Returned input value. Possible values:
**                           FALSE - logical "0" (Low level)
**                           TRUE - logical "1" (High level)
** ===================================================================
*/

/*
** ===================================================================
**     Method      :  Inhr1_ConnectPin (bean ExtInt)
**
**     Description :
**         This method reconnects the selected pin of this bean.
**         This method is available only for CPU derivatives and
**         peripherals that support the runtime pin sharing with
**         other internal on-chip peripherals.
**     Parameters  : None
**     Returns     : Nothing
** ===================================================================
*/
#define Inhr1_ConnectPin() (clrRegBits(GPIO_B_PER,Inhr1_PIN_MASK))

/* END Inhr1. */

#endif /* __Inhr1_H*/
/*
** ###################################################################
**
**     This file was created by UNIS Processor Expert 2.99 [04.17]
**     for the Freescale 56800 series of microcontrollers.
**
** ###################################################################
*/
