tmr_read_plan.h
Go to the documentation of this file.
00001 /* ex: set tabstop=2 shiftwidth=2 expandtab cindent: */
00002 #ifndef _TMR_READ_PLAN_H
00003 #define _TMR_READ_PLAN_H
00004 
00011 /*
00012  * Copyright (c) 2009 ThingMagic, Inc.
00013  *
00014  * Permission is hereby granted, free of charge, to any person obtaining a copy
00015  * of this software and associated documentation files (the "Software"), to deal
00016  * in the Software without restriction, including without limitation the rights
00017  * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
00018  * copies of the Software, and to permit persons to whom the Software is
00019  * furnished to do so, subject to the following conditions:
00020  *
00021  * The above copyright notice and this permission notice shall be included in
00022  * all copies or substantial portions of the Software.
00023  * 
00024  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
00025  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
00026  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
00027  * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
00028  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
00029  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
00030  * THE SOFTWARE.
00031  */
00032 
00033 #include "tmr_tag_protocol.h"
00034 #include "tmr_filter.h"
00035 #include "tmr_tagop.h"
00036 
00037 #ifdef  __cplusplus
00038 extern "C" {
00039 #endif
00040 
00041 
00054 typedef struct TMR_ReadPlan TMR_ReadPlan;
00055 typedef struct TMR_SimpleReadPlan TMR_SimpleReadPlan;
00056 typedef struct TMR_MultiReadPlan TMR_MultiReadPlan;
00057 typedef struct TMR_StopOnTagCount TMR_StopOnTagCount;
00058 typedef struct TMR_TagObservationTrigger TMR_TagObservationTrigger;
00059 typedef struct TMR_StopTrigger TMR_StopTrigger;
00060 typedef struct TMR_GPITriggerRead TMR_GPITriggerRead;
00061 
00065 /*struct TMR_TagObservationTrigger
00066 {
00067 };
00068 
00069 struct TMR_StopTrigger
00070 {
00071   TMR_TagObservationTrigger stopTrigger; 
00072 };*/
00073 
00080 struct TMR_StopOnTagCount
00081 {
00082   /* option for stop N trigger */
00083   bool stopNTriggerStatus;
00084 
00085   /* Number of tags to be read */
00086   uint32_t noOfTags;
00087 };
00088 
00095 struct TMR_GPITriggerRead
00096 {
00097   /* option for trigger read */
00098   bool enable;
00099   /* RFU - The list of GPI ports */
00100   TMR_uint8List gpiList;
00101 };
00102 
00115 struct TMR_SimpleReadPlan
00116 {
00118   TMR_uint8List antennas;
00120   TMR_TagProtocol protocol;
00122   TMR_TagFilter *filter;
00124   TMR_TagOp *tagop;
00126   bool useFastSearch;
00128   TMR_StopOnTagCount stopOnCount;
00130   TMR_GPITriggerRead triggerRead;
00131 };
00132 
00144 struct TMR_MultiReadPlan
00145 {
00147   TMR_ReadPlan **plans;
00148   uint32_t totalWeight; 
00150   uint8_t planCount;
00151 };
00152 
00154 typedef enum TMR_ReadPlanType
00155 {
00156   TMR_READ_PLAN_TYPE_INVALID,
00160   TMR_READ_PLAN_TYPE_SIMPLE,
00162   TMR_READ_PLAN_TYPE_MULTI
00163 } TMR_ReadPlanType;
00164 
00169 struct TMR_ReadPlan
00170 {
00172   TMR_ReadPlanType type;
00174   uint32_t weight;
00176   bool enableAutonomousRead;
00177   union
00178   {
00180     TMR_SimpleReadPlan simple;
00182     TMR_MultiReadPlan multi;
00183   } u;
00184 };
00185 
00186 TMR_Status TMR_RP_init_simple(TMR_ReadPlan *plan, uint8_t antennaCount,
00187                               uint8_t *antennaList, TMR_TagProtocol protocol,
00188                               uint32_t weight);
00189 
00190 TMR_Status TMR_RP_init_multi(TMR_ReadPlan *plan, TMR_ReadPlan **plans,
00191                              uint8_t planCount, uint32_t weight);
00192 
00193 TMR_Status TMR_GPITR_init_enable(TMR_GPITriggerRead *triggerRead, bool enable);
00194 
00195 TMR_Status TMR_RP_set_filter(TMR_ReadPlan *plan, TMR_TagFilter *filter);
00196 
00197 TMR_Status TMR_RP_set_tagop(TMR_ReadPlan *plan, TMR_TagOp *tagop);
00198 TMR_Status TMR_RP_set_enableTriggerRead(TMR_ReadPlan *plan, TMR_GPITriggerRead *triggerRead);
00199 
00200 TMR_Status TMR_RP_set_useFastSearch(TMR_ReadPlan *plan, bool useFastSearch);
00201 TMR_Status TMR_RP_set_stopTrigger(TMR_ReadPlan *plan, uint32_t count);
00202 TMR_Status TMR_RP_set_enableAutonomousRead(TMR_ReadPlan *plan, bool autonomousRead);
00207 #ifdef  __cplusplus
00208 }
00209 #endif
00210 
00211 #endif /* _TMR_READ_PLAN_H_ */


thingmagic_rfid
Author(s): Brian Bingham
autogenerated on Thu May 16 2019 03:01:24