00001 /****************************************************************************** 00002 * 00003 * $Id$ 00004 * 00005 * Copyright (C) 2006-2008 Florian Pose, Ingenieurgemeinschaft IgH 00006 * 00007 * This file is part of the IgH EtherCAT Master. 00008 * 00009 * The IgH EtherCAT Master is free software; you can redistribute it and/or 00010 * modify it under the terms of the GNU General Public License version 2, as 00011 * published by the Free Software Foundation. 00012 * 00013 * The IgH EtherCAT Master is distributed in the hope that it will be useful, 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General 00016 * Public License for more details. 00017 * 00018 * You should have received a copy of the GNU General Public License along 00019 * with the IgH EtherCAT Master; if not, write to the Free Software 00020 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00021 * 00022 * --- 00023 * 00024 * The license mentioned above concerns the source code only. Using the 00025 * EtherCAT technology and brand is only permitted in compliance with the 00026 * industrial property and similar rights of Beckhoff Automation GmbH. 00027 * 00028 *****************************************************************************/ 00029 00035 /*****************************************************************************/ 00036 00037 #ifndef __EC_PDO_LIST_H__ 00038 #define __EC_PDO_LIST_H__ 00039 00040 #include <linux/list.h> 00041 00042 #include "globals.h" 00043 #include "pdo.h" 00044 00045 /*****************************************************************************/ 00046 00049 typedef struct { 00050 struct list_head list; 00051 } ec_pdo_list_t; 00052 00053 /*****************************************************************************/ 00054 00055 void ec_pdo_list_init(ec_pdo_list_t *); 00056 void ec_pdo_list_clear(ec_pdo_list_t *); 00057 00058 void ec_pdo_list_clear_pdos(ec_pdo_list_t *); 00059 00060 ec_pdo_t *ec_pdo_list_add_pdo(ec_pdo_list_t *, uint16_t); 00061 int ec_pdo_list_add_pdo_copy(ec_pdo_list_t *, const ec_pdo_t *); 00062 00063 int ec_pdo_list_copy(ec_pdo_list_t *, const ec_pdo_list_t *); 00064 00065 uint16_t ec_pdo_list_total_size(const ec_pdo_list_t *); 00066 int ec_pdo_list_equal(const ec_pdo_list_t *, const ec_pdo_list_t *); 00067 00068 ec_pdo_t *ec_pdo_list_find_pdo(const ec_pdo_list_t *, uint16_t); 00069 const ec_pdo_t *ec_pdo_list_find_pdo_const(const ec_pdo_list_t *, 00070 uint16_t); 00071 const ec_pdo_t *ec_pdo_list_find_pdo_by_pos_const( 00072 const ec_pdo_list_t *, unsigned int); 00073 unsigned int ec_pdo_list_count(const ec_pdo_list_t *); 00074 00075 void ec_pdo_list_print(const ec_pdo_list_t *); 00076 00077 /*****************************************************************************/ 00078 00079 #endif
1.5.6