/* ###################################################################
**     This component module is generated by Processor Expert. Do not modify it.
**     Filename    : M2_HU_F8.h
**     Project     : MAPS-MC-2IN1_DualServo_release
**     Processor   : MC56F84789VLL
**     Component   : InputPin
**     Version     : Component 01.006, Driver 01.14, CPU db: 3.50.001
**     Compiler    : CodeWarrior DSP C Compiler
**     Date/Time   : 2019-04-03, 17:51, # CodeGen: 0
**     Abstract    :
**         This component implements a one-bit input. Use of the component 
**         is convenient if selected pin is used by some on-chip 
**         peripheral device (asychronous serial channel, 
**         synchronous serial channel,...) and there is some reason 
**         to read state on this pin. This is why component neither 
**         allocates nor inicializes this pin. This component can be used 
**         for autodiagnostics, where on-chip peripheral device is 
**         verified on functionality, for example sending and 
**         receiving of data by asychronous serial channel or 
**         synchronous serial channel or generating periodic signal 
**         by Timer.
**     Settings    :
**          Component name                                 : M2_HU_F8
**          Pin for Input                                  : GPIOF8/RXD0/TB1/CMPD_O
**          Pin signal                                     : 
**     Contents    :
**         GetVal - bool M2_HU_F8_GetVal(void);
**
**     Copyright : 1997 - 2014 Freescale Semiconductor, Inc. 
**     All Rights Reserved.
**     
**     Redistribution and use in source and binary forms, with or without modification,
**     are permitted provided that the following conditions are met:
**     
**     o Redistributions of source code must retain the above copyright notice, this list
**       of conditions and the following disclaimer.
**     
**     o Redistributions in binary form must reproduce the above copyright notice, this
**       list of conditions and the following disclaimer in the documentation and/or
**       other materials provided with the distribution.
**     
**     o Neither the name of Freescale Semiconductor, Inc. nor the names of its
**       contributors may be used to endorse or promote products derived from this
**       software without specific prior written permission.
**     
**     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
**     ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
**     WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
**     DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
**     ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
**     (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
**     LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
**     ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
**     (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
**     SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**     
**     http: www.freescale.com
**     mail: support@freescale.com
** ###################################################################*/
/*!
** @file M2_HU_F8.h
** @version 01.14
** @brief
**         This component implements a one-bit input. Use of the component 
**         is convenient if selected pin is used by some on-chip 
**         peripheral device (asychronous serial channel, 
**         synchronous serial channel,...) and there is some reason 
**         to read state on this pin. This is why component neither 
**         allocates nor inicializes this pin. This component can be used 
**         for autodiagnostics, where on-chip peripheral device is 
**         verified on functionality, for example sending and 
**         receiving of data by asychronous serial channel or 
**         synchronous serial channel or generating periodic signal 
**         by Timer.
*/         
/*!
**  @addtogroup M2_HU_F8_module M2_HU_F8 module documentation
**  @{
*/         

#ifndef __M2_HU_F8
#define __M2_HU_F8

/* MODULE M2_HU_F8. */

/*Include shared modules, which are used for whole project*/
#include "PE_Types.h"
#include "PE_Error.h"
#include "PE_Const.h"
#include "IO_Map.h"
/* Include inherited beans */
#include "Cpu.h"


#define M2_HU_F8_PIN_MASK       ((word)0x0100) /* Pin mask */
#define M2_HU_F8_PIN_MASK_SHIFTED ((byte)0x01) /* Shifted pin mask by 8, if pin mask is greater than 128 */

/*
** ===================================================================
**     Method      :  M2_HU_F8_GetVal (component InputPin)
**     Description :
**         Return the value on the pin.
**     Parameters  : None
**     Returns     :
**         ---             - Input value
** ===================================================================
*/
#define M2_HU_F8_GetVal() ((bool)((getReg(GPIOF_RAWDATA) >> 8) & M2_HU_F8_PIN_MASK_SHIFTED))

/* END M2_HU_F8. */

#endif /* ifndef __M2_HU_F8 */
/*!
** @}
*/
/*
** ###################################################################
**
**     This file was created by Processor Expert 10.3 [05.09]
**     for the Freescale 56800 series of microcontrollers.
**
** ###################################################################
*/

