⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 user-client.apt

📁 关于 RFID 读写器的相关内容
💻 APT
📖 第 1 页 / 共 2 页
字号:
    <id>4</id>
    <resultCode>0</resultCode>
    <trigger>
        <create>
            <returnValue>nt</returnValue>
        </create>
    </trigger>
</ns2:reply>
+--------------------------------------------------------------------------

  [[5]] Create a notification channel:

    * Select 'NotificationChannel' in the Object drop-down list.

    * Select 'create' in the Command drop-down list.

    * Add a String parameter 'nc' (name) and 'tcp://localhost:9999?mode=connect'
      (address) to the parameter list.

    * Hit the 'Create Command' button. The command in the Request text field
      should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:command xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>6</id>
    <targetName></targetName>
    <notificationChannel>
        <create>
            <name>nc</name>
            <address>http://localhost:9999?mode=connect</address>
        </create>
    </notificationChannel>
</ns2:command>
+--------------------------------------------------------------------------

    * Hit the 'Send' button. The reply in the Response text field without
      the HTTP header should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:reply xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>6</id>
    <resultCode>0</resultCode>
    <notificationChannel>
        <create>
            <returnValue>nc</returnValue>
        </create>
    </notificationChannel>
</ns2:reply>
+--------------------------------------------------------------------------

  [[6]] Add the notification trigger to the notification channel:

    * Select 'NotificationChannel' in the Object drop-down list.

    * Select 'addNotificationTriggers' in the Command drop-down list.

    * Write 'nc' as the target name in the Target text field.

    * Add an Array parameter 'nt' (trigger name) to the parameter list.

    * Hit the 'Create Command' button. The command in the Request text field
      should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:command xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>8</id>
    <targetName>nc</targetName>
    <notificationChannel>
        <addNotificationTriggers>
            <triggers>
                <list>
                    <value>nt</value>
                </list>
            </triggers>
        </addNotificationTriggers>
    </notificationChannel>
</ns2:command>
+--------------------------------------------------------------------------

    * Hit the 'Send' button. The reply in the Response text field without
      the HTTP header should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:reply xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>8</id>
    <resultCode>0</resultCode>
    <notificationChannel>
        <addNotificationTriggers/>
    </notificationChannel>
</ns2:reply>
+--------------------------------------------------------------------------

  [[7]] Add the source to the notification channel:

    * Select 'NotificationChannel' in the Object drop-down list.

    * Select 'addSources' in the Command drop-down list.

    * Write 'nc' as the target name in the Target text field.

    * Add an Array parameter 'Shelf1' (source name) to the parameter list.

    * Hit the 'Create Command' button. The command in the Request text field
      should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:command xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>10</id>
    <targetName>nc</targetName>
    <notificationChannel>
        <addSources>
            <sources>
                <list>
                    <value>Shelf1</value>
                </list>
            </sources>
        </addSources>
    </notificationChannel>
</ns2:command>
+--------------------------------------------------------------------------

    * Hit the 'Send' button. The reply in the Response text field without
      the HTTP header should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:reply xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>10</id>
    <resultCode>0</resultCode>
    <notificationChannel>
        <addSources/>
    </notificationChannel>
</ns2:reply>
+--------------------------------------------------------------------------

  [[8]] Add the read trigger to the source:

    * Select 'Source' in the Object drop-down list.

    * Select 'addReadTriggers' in the Command drop-down list.

    * Write 'Shelf1' as the target name in the Target text field.

    * Add an Array parameter 'rt' (read trigger name) to the parameter list.

    * Hit the 'Create Command' button. The command in the Request text field
      should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:command xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>12</id>
    <targetName>Shelf1</targetName>
    <source>
        <addReadTriggers>
            <triggers>
                <list>
                    <value>rt</value>
                </list>
            </triggers>
        </addReadTriggers>
    </source>
</ns2:command>
+--------------------------------------------------------------------------

    * Hit the 'Send' button. The reply in the Response text field without
      the HTTP header should look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:reply xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>12</id>
    <resultCode>0</resultCode>
    <source>
        <addReadTriggers/>
    </source>
</ns2:reply>
+--------------------------------------------------------------------------

  [[9]] The reader is now configured. Add a new tag to the Fosstrak Reader
    Simulator and drag it over the Antenna with the name 'Shelf1'. The event
    sink should show a notification text formated in XML. An example of such a
    notification could look like this:

+--------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:notification xmlns:ns2="urn:epcglobal:rp:xsd:1">
    <id>1</id>
    <reader>
        <readerEPC>ReaderEPC</readerEPC>
        <readerName>MyReader</readerName>
        <readerHandle>0</readerHandle>
        <readerRole>ReaderRole</readerRole>
    </reader>
    <notifyTriggerName>NotificationTrigger</notifyTriggerName>
    <notifyChannelName>NotificationChannel</notifyChannelName>
    <readReport>
        <sourceReport>
            <sourceInfo>
                <sourceName>Shelf1</sourceName>
                <sourceFrequency>0</sourceFrequency>
                <sourceProtocol>not supported</sourceProtocol>
            </sourceInfo>
            <tag>
                <tagID>9204F0004B000000</tagID>
                <tagIDAsPureURI>urn:epc:raw:64.x9204F0004B000000</tagIDAsPureURI>
                <tagIDAsTagURI>urn:epc:raw:64.x9204F0004B000000</tagIDAsTagURI>
                <tagType>not supported</tagType>
                <tagEvent>
                    <eventType>evGlimpsed</eventType>
                    <eventTriggers>
                        <trigger>ReadTrigger</trigger>
                    </eventTriggers>
                    <time>
                        <eventTimeTick>1199287632796</eventTimeTick>
                        <eventTimeUTC>2008-01-02T16:27:12.796+01:00</eventTimeUTC>
                    </time>
                </tagEvent>
                <tagEvent>
                    <eventType>evNew</eventType>
                    <eventTriggers>
                        <trigger>NoTrigger</trigger>
                    </eventTriggers>
                    <time>
                        <eventTimeTick>1199287632796</eventTimeTick>
                        <eventTimeUTC>2008-01-02T16:27:12.796+01:00</eventTimeUTC>
                    </time>
                </tagEvent>
            </tag>
        </sourceReport>
    </readReport>
</ns2:notification>
+--------------------------------------------------------------------------

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -