#ifndef __APCIE1564_EVENTS_H__
#define __APCIE1564_EVENTS_H__

/* @file apcie1564-events.h
  * 
  * @brief Defines the event type for the board. 
  * 
  * This board implement a event system that allows a user-mode process (or thread) to know when a specific change happened on the board.
  * 
  * This is done by using a blocking ioctl call.  
  *
  */

/** @par LICENCE
 * 
 *  @verbatim
  Copyright (C) 2004,2005 ADDI-DATA GmbH for the source code of this module.
  
         ADDI-DATA GmbH
         Dieselstrasse 3
         D-77833 Ottersweier
         Tel: +19(0)7223/9493-0
         Fax: +49(0)7223/9493-92
         http://www.addi-data-com
         info@addi-data.com
 
 This library is free software; you can redistribute it and/or modify it under 
 the terms of the GNU Lesser General Public License as published by the 
 Free Software Foundation; either version 2.1 of the License, 
 or (at your option) any later version.
 
 This library is distributed in the hope that it will be useful, 
 but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
 or FITNESS FOR A PARTICULAR PURPOSE. 
 See the GNU Lesser General Public License for more details.
 
 You should have received a copy of the GNU Lesser General Public License 
 along with this library; if not, write to the Free Software Foundation, 
 Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 
 
 You also shoud find the complete LGPL in the LGPL.txt file accompanying 
 this source code.
 
 @endverbatim
**/

typedef enum {APCIE1564_EVT_FROM_DIGITAL_INPUT,APCIE1564_EVT_FROM_COUNTER,APCIE1564_EVT_FROM_DIGOUT} event_source_t;

typedef
struct
{
	event_source_t source; /**< the subsystem that generated the event */
	unsigned long param1; /**< for APCIE1564_EVT_FROM_DIGITAL_INPUT,APCIE1564_EVT_FROM_COUNTER, this is the bitmask of digital inputs that generated the event */
	unsigned long param2; /**< for APCIE1564_EVT_FROM_DIGOUT, this is the cause of the interrupt  CC or VCC ) */
} apcie1564_event_t;


#endif /*__APCIE1564_EVENTS_H__*/
