Ejemplo n.º 1
0
 internal void ResultHandlerASyncGetEPCsASync(CRRU4 pRRU4,
                                              tComingGoingFlag enComingGoingFlag,
                                              tExtendedResultFlagMask enExtendedResultFlag,
                                              tEPCListEntry[] rgEPCList)
 {
     Console.WriteLine();
     Console.WriteLine(string.Format("Tag coming/going = {0}, tags received:",
                                     enComingGoingFlag));
     foreach (tEPCListEntry epcListEnry in rgEPCList)
     {
         Console.WriteLine(epcListEnry.pEPC);
         if (epcListEnry.pEPC.ToString() != string.Empty)
         {
             tagsRead.Add(epcListEnry.pEPC.ToString());
         }
     }
     Console.WriteLine();
 }
Ejemplo n.º 2
0
        internal RfidReader()
        {
            reader = new CRRU4();
            reader.SetResultHandlerASyncGetEPCs(ResultHandlerASyncGetEPCsSync,
                                                ResultHandlerASyncGetEPCsASync);

            var comConfigData = new tCommunicationConfigData
            {
                enCommunicationType = tCommunicationType.CT_Ethernet
            };

            comConfigData.stEthernet.bIsIPAddress    = false;
            comConfigData.stEthernet.enIPAddressType = tIPAddressType.IPAT_IPv4;
            comConfigData.stEthernet.sNetworkName    = "192.168.0.1";

            if (reader.ConnectReader(comConfigData) == tReaderErrorCode.REC_NoError)
            {
                Console.WriteLine("Connected");
            }
            else
            {
                Console.WriteLine("Error connecting");
            }
        }
Ejemplo n.º 3
0
 internal void ResultHandlerASyncGetEPCsSync(CRRU4 pRRU4, tResultFlag enResultFlag)
 {
     Console.WriteLine(string.Format("ResultHandlerASyncGetEPCsSync called, enResultFlag = {0}",
                                     enResultFlag));
 }