#ifndef __SENSOR_MCF52259_H__
#define __SENSOR_MCF52259_H__
/**HEADER********************************************************************
* 
* Copyright (c) 2010 Avnet Japan Co.,Ltd (NIKE Borad Project.)
* All Rights Reserved
*
**************************************************************************
*
* $FileName: sensor_mcf522xx.h$
* $Version : 0.1.0.0$
* $Date    : Jan-29-2010$
*
* Comments:
*
*   CPU specific Sensor driver header file
*
*END************************************************************************/

/*----------------------------------------------------------------------*/
/*
**                          CONSTANT DEFINITIONS
*/

#ifdef __cplusplus
extern "C" {
#endif

#define SENSOR_ADC_HW_CHANNELS         8

#define SENSOR_ADC_RESOLUTION_12BIT   0x1000
#define SENSOR_ADC_RESOLUTION_DEFAULT SENSOR_ADC_RESOLUTION_12BIT

#define SENSOR_ADC_SOURCE_AN0       0x00
#define SENSOR_ADC_SOURCE_AN1       0x01
#define SENSOR_ADC_SOURCE_AN2       0x02
#define SENSOR_ADC_SOURCE_AN3       0x03
#define SENSOR_ADC_SOURCE_AN4       0x04
#define SENSOR_ADC_SOURCE_AN5       0x05
#define SENSOR_ADC_SOURCE_AN6       0x06
#define SENSOR_ADC_SOURCE_AN7       0x07

#define SENSOR_ADC_SOURCE_AN0_AN1   0x08
#define SENSOR_ADC_SOURCE_AN2_AN3   0x09
#define SENSOR_ADC_SOURCE_AN4_AN5   0x10
#define SENSOR_ADC_SOURCE_AN6_AN7   0x11
#define SENSOR_ADC_SOURCE_MAX       0x11

#define SENSOR_IO_G_SEL                      (0x01)
#define SENSOR_IO_0G_DET                     (0x02)
#define SENSOR_IO_SELTEST                    (0x03)

#define SENSOR_IO_TYPE_MASK  (0xF0)
#define SENSOR_IO_BLK_GROUP_UB  0x00

_mqx_int _sensor_port_set( uchar type);
_mqx_int _sensor_port_clr( uchar type);
_mqx_int _sensor_port_in( uchar type);
_mqx_int _sensor_port_get( uchar type, uchar_ptr pData);

#ifdef __cplusplus
}
#endif

#endif

/* EOF */
