Radio frequency identification (RFID) technology uses radio waves to identify and track items. A typical RFID system consists of RFID tags, RFID readers, and back-end systems that process RFID events. An RFID tag contains a microchip and antennae for transmitting data stored in the microchip. The data contained on the microchip, such as a serial number, is used to uniquely identify an item. RFID readers "read" the data stored on the microchip and make it available for consumption by back-end systems.
IBM® WebSphere RFID Premises Server (hereafter called Premises Server) and WebSphere RFID Device Infrastructure are new offerings from IBM that provide an infrastructure for processing RFID events. The WebSphere RFID solution provides components that interact with RFID devices such as readers and printers, control I/O devices, filter and process RFID events, and send data to and receive data from back-end systems. The WebSphere RFID products provide several default solutions, or usage scenarios, that you can extend to provide additional capabilities to meet your requirements.
One of these default solutions is Print, Verify, and Ship (hereafter called PVS). PVS allows you to print RFID labels, associate cases with containers, validate that outgoing containers contain the correct cases, and generate shipping reports. In this article, you'll learn about the print resources and the configuration required to print an RFID label using the WebSphere RFID solution. In the example in this article, you'll learn how to print an RFID label using a Printronix SL5000r RFID printer.
The examples provided in this article require the following software and hardware:
- IBM WebSphere RFID Premises Server Version 1.1 or later
- IBM WebSphere RFID Device Infrastructure Version 1.1 or later
- Printronix SL5204r RFID printer with firmware Version 1.4.3.3 or later
This article assumes you're familiar with WebSphere RFID terminology and the distribution of the WebSphere RFID solution components. Figure 1 illustrates the system topology used for testing the printing examples in this article:
Figure 1. WebSphere RFID topology
- The WebSphere RFID Premises Server is installed on a machine running Windows 2003. The default Location (P1) and Edge Controller (E1) definitions are used in the printing examples.
- WebSphere Studio Device Developer (hereafter called Device Developer) is installed on a second machine running Windows XP. The WebSphere RFID Tracking Kit is installed in Device Developer. A Service Management Framework (SMF) runtime is created in Device Developer and the bundles required to communicate with the Premises Server and the Printronix printer are installed in the SMF runtime. This SMF runtime configuration is referred to as an Edge Controller. In a real deployment, the Edge Controller would be deployed on a special computing device that would be deployed on the edge of the RFID system, close to the RFID readers and printers. Running an Edge Controller inside of Device Developer is supported only for development purposes.
Set up and configure the Printronix printer
In this article, we'll use the factory default printer configuration with a few minor changes, as shown in Table 1. The changes reflect the type of labels used in the examples and how the WebSphere RFID products are configured to communicate with the printer. These configuration changes are shown in the table below.
The RFID labels used in the examples are Printronix RFID Smart Labels. The labels are thermal transfer, 4 x 6 roll stock with 96-bit Alien Squiggle tags. If you’re using a different type of label , you'll need to set the QUICK SETUP options and the RFID CONTROL tag type option to reflect the type of tag you plan to use.
After updating the printer configuration, run Auto Calibrate on the printer.
Table 1. General printer configuration changes
| Menu | Option | Value |
|---|---|---|
|
PRINTER CONTROL |
Admin User |
Enable. You must enable the Admin User in order to make some of the other configuration settings available. |
|
QUICK SETUP |
Printer Mode Media Handling Label Length Label Width Orientation Gap/Mark Sensor Active IGP Emul |
Transfer (default) Continuous 6 4.1 Inv. Portrait Mark IGP/PGL (default) |
|
IGL/PGL SETUP |
Preparser Port Ret. Status Port |
Ethernet E-NET Data Port |
|
RFID CONTROL |
RFID Reader Tag Type |
Enable (default) Alien Squig 96 (default) |
You need to make sure you can print a label manually before moving on to printing with the IBM WebSphere RFID solution. The Printronix SL5204r printer allows you to manually print labels using FTP. To do this, you need to:
- Create a text file containing the printer commands required to generate your label.
- Put this file in one of the printer's pre-defined logical printer destinations using the FTP
putcommand.
Step 1: Create the printer command file
Let's get started by building a baseline printer command file that we'll extend in the subsequent examples. As shown in Table 1, the Intelligent Graphics Printing emulation (Active IGP Emul) is set to IGP/PGL, which means that the printer can process IGP/PGL commands. Therefore, you need to use the IGP/PGL command set to build the printer command file. For this example, you'll create a printer command file to print a company name, a barcode, a barcode value, and program the embedded RFID tag. Listing 1 shows the PGL commands required to print a RFID label with XYZ Company as the company name, a barcode with the value of 112233445566778899001127, the barcode value and program the RFID tag with the value of 112233445566778899001127.
Printer command file
~CREATE;simple;432 RFWTAG;96 64;H;*1122334455667788* 32;H;*99001127* STOP ALPHA 14;8;2;2;*XYZ COMPANY* STOP BARCODE C128B;H8;17;1 *112233445566778899001127* PDF STOP END ~EXECUTE;simple ~NORMAL |
IGP/PGL commands and parameters
Following are the IGP/PGL commands you'll use when using the Printronix FTP printing capability. For a complete description of the commands and parameters, refer to the Printronix documentation.
CREATE places the IGP/PGL emulator in the Create Form mode, in which forms and form elements can be defined using the appropriate commands:
simple- the name of the form432- the length of the form in dot rows
RFWTAG programs the RFID tag:
96- the size of the tag in bits64, 32- 96-bit value is broken into a 64-bit value and a 32-bit valueH- indicates that the data value used to program the RFID tag is in hexadecimal format*1122334455667788*- 64-bit data value*99001127*- 32-bit data valueSTOP- ends the RFWTAG command
ALPHA defines and positions alphanumeric data on a static or dynamic data field:
14- starting row of the data8- starting column of the data2- defines the vertical expansion factor to enlarge characters vertically2- defines the horizontal expansion factor to enlarge characters horizontally*XYZ Company*- static data to print on the labelSTOP- ends the ALPHA command
BARCODE starts the barcode processing:
C128B- specifies a bar code type of 128 BH8adjusts the height of the barcode. Height adjustments are made in 0.1-inch increments17- starting row for the barcode1- starting column for the barcode*112233445566778899001127*- barcode data fieldPDF- causes the barcode data field to be printedSTOP- ends the BARCODE command
END terminates the Create Form mode.
EXECUTE executes the simple form.
NORMAL returns the IGP/PGL emulator to the Normal mode.
Note: The command file must have a CR/LF after the last command for the label to print successfully.
To print the label, complete the following steps:
- Use a text editor to create a file called test.gpl and enter the IGP/PGL commands shown above. To keep things simple, you can copy and paste the commands. Remember to add a CR/LF after the NORMAL command to ensure the label will print.
- To print the label, do the following as shown in Figure 2:
- FTP to the Printronix printer.
- Specify
rootas the user. - The default printer configuration requires no password. If you’re prompted for a password, you’ll need to enter the correct password.
- Change to the dest/d1prn directory.
- Specify the transfer as binary using the FTP
bincommand. - Use the FTP
putcomment to put the test.gpl.
Figure 2. Print the label
Your printed label should resemble the one shown in Figure 3:
Figure 3. Resulting label
Now that you've successfully created and printed a basic label, you're ready to print using WebSphere RFID. In the previous example, all the information required to print the label and program the RFID tag was contained in the printer command file. In this example, you'll modify the printer command file to include dynamic data fields that will be filled in by the WebSphere RFID components when a print job is submitted and executed. The printer command file is combined with other resources to create a print template. Once you've created the print template, you'll create configurations for the template and the Printronix printer using the Premises Server administration console. These configurations define the print template and the printer to WebSphere RFID so that they can be used in a print job.
The Premises Server PVS function provides a print application that you can configure and use to submit a print job. Submitted print jobs are sent from the Premises Server to the Edge Controller for execution. The Edge Controller, which in our example is running inside of Device Developer, contains the Device Infrastructure bundles that communicate with the Printronix printer and the Premises Server. When the Edge Controller receives the print job from the Premises Server, it fetches the print template and sends it to the printer. All dynamic data fields are filled in by the Edge Controller with data (EPC value, company name, and so on) generated by the Premises Server. As part of the printing process, the Printronix printer reads the programmed RFID tag data and pass it back to the Edge Controller. This data is used to verify that the RFID tag was programmed with the correct data.
Create a simple print template
In WebSphere RFID PVS, printer command files are packaged with other resource files to form print templates. A print template is a ZIP file that contains the resources necessary to print a label and program an RFID tag. A print template contains the following files:
- Printer command file: contains the printer commands required to generate a label and program an RFID tag. test.gpl is an example of a printer command file.
- Parameter map file: maps the dynamic data fields specified in the printer command file to variables populated with data generated by the Premises Server.
- resource.propertiesfile: a manifest file that describes the print template.
- Graphics files (optional): one or more graphics files specified in the printer command file that are to be printed on the label.
The naming convention for the print template file is
<manufacturer>-<template_name>-template.zip. For this example, use simple for the template_name. We'll call the completed template printronix-simple-template.zip.
You need to add dynamic data fields to the printer command file you created in the first example to dynamically fill in the RFID tag and barcode data. This data will be generated by the Premises Server when the print job is submitted, and sent to the printer when the print job is processed. You'll package the updated printer command file with a parameter map file and a resource.properties file to create a print template.
Step 1: Create the printer command file
The naming convention of the printer command file is: template_name.GPL for Printronix printers and template_name.ZPL for Zebra printers. The file names are case-sensitive and extensions must be capitalized. Since our template_name is simple, we'll call the printer command file is simple.GPL.
Modify the test.gpl printer command file used in the previous example to create the simple.GPL printer command file as shown in in Table 2:
Table 2. Printer configuration changes for simple print template
| test.gpl | simple.GPL |
|---|---|
~CREATE;simple;432
|
~CREATE;simple;432
|
IGP/PGL commands and parameters
Following is a list of the modified and additional IGP/PGL commands used in the simple.GPL printer command file. For a complete description of the commands and parameters, refer to the Printronix documentation.
RFWTAG programs the RFID tag. In the example above, we modified the parameters for this command to add dynamic data fields that will be populated with an EPC value generated by the Premises Server:
96- the size of the tag in bits.64, 32- 96-bit value is broken into a 64-bit value and a 32-bit value.DF1- defines a dynamic data field that is populated with a 64-bit value when the command file is executed. This field is populated with EPC data generated by the Premises Server.DF2- defines a dynamic data field that is populated with a 32-bit value when the command file is executed. This field is populated with EPC data generated by the Premises Server.H- indicates that the data value used to program the RFID tag is in hexadecimal format.STOP- ends the RFWTAG command.
RFRTAG reads the content of an RFID tag into a dynamic data field. We added this command to read the RFID tag previously programmed with the RFWTAG command:
96- size of the tag in bits.64, 32- 96-bit value is broken into a 64-bit value and a 32-bit value.DF500- defines a dynamic data field that will be populated with a 64 bit value read from the programmed RFID tag.DF501- defines a dynamic data field that will be populated with a 32 bit value read from the programmed RFID tag.H- indicates that the data value is in hexadecimal format.STOP- ends the RFRTAG command.
VERIFY sends the contents of a dynamic data field to the host program submitting the print job. The VERIFYcommand is used in conjunction with RFRTAG to validate that the RFID tag was programmed with the correct data:
DF500- defines a dynamic field containing the 64-bit value that will be sent to the host program. This data is sent to the Edge Controller (that is, the host program) to verify that the RFID tag was programmed with the correct data.DF501- defines a dynamic field containing the 32-bit value that will be sent to the host program. This data is sent to the Edge Controller (that is, the host program) to verify that the RFID tag was programmed with the correct data.H- indicates that the data value is in hexadecimal format.RFWTAGn96;H=- a character string, which is followed by the RFID data to be sent by the printer to the host.STOP- ends the VERIFY command.
BARCODE starts the barcode processing:
C128B- specifies a barcode type of 128 BH8- adjusts the height of the barcode. Height adjustments are made in 0.1-inch increments.BF1- defines a dynamic field containing the bar code value. This field is populated with data generated by the WebSphere RFID Premises Server.24- number of characters if the bar code data.17- starting row for the barcode1- starting column for the barcodePDF- causes the barcode data field to be printedSTOP- ends theBARCODEcommand
Step 2: Create the parameter map file
The parameter map file maps the dynamic data fields specified in the print template to variables populated with data generated by the Premises Server when a print job is submitted for processing. The naming convention for the parameter map file is template_name.CSV. The file name is case-sensitive and the extension must be capitalized. Since the template_name for this example is simple, the name of the parameter map file is simple.CSV. The format of this file is common across all printers, and is shown below:
<template variable number>, <variable type>, <logical variable key> … <template variable number>, <variable type>, <logical variable key> |
For this example, we want to dynamically generate the EPC and barcode values. The RFWTAG and BARCODE commands in our printer command file now specify dynamic data fields. In order to populate those data fields when the print job is processed, you must map them to Premises Server variables.
Create the following simple.CSV parameter map file to populate the dynamic data fields specified in the simple.GPL printer command file:
1,DATA,$TAG_UPPER_64_BITS 2,DATA,$TAG_LOWER_32_BITS 1,BARCODE,$TAG |
$TAG_UPPER_64_BITSmaps the upper 64 bits of the generated EPC value to the dynamic data field DF1 specified on the RFWTAG command.$TAG_LOWER_32_BITSmaps the lower 32 bits of the generated EPC value to the dynamic data field DF2 specified on the RFWTAG command.$TAGmaps the generated EPC value to the dynamic data field BF1 specified on theBARCODEcommand.
Step 3: Create the template resource file
Print templates contain one or more resources, as well as a manifest file called resource.properties that defines the resources (or files) included in the print template. The resource.properties file must contain the property resource.names, which lists the names of the resources included in the print template ZIP file. Resource names are separated by commas and have the following formats:
- templates: <printer type>-<template_name>-template
- graphics: <printer type>-<graphic_name>-graphic
In this simple example, we won't add any graphics to the label. Since our template_name is simple, the value of the resource.names property is:
resource.names=printronix-simple-template.
Each resource name is used to define additional properties specific to that resource. For our example, define the following three template properties in the resource.properties file:
- printronix-simple-template.resource.type=template
- printronix-simple-template.template.name=simple
- printronix-simple-template.template.type=PrintronixPrinterAgent
The complete resource.properties file is shown in Figure 4:
Figure 4. resource.properties file
Step 4: Create the print template ZIP file
Now that you've built the required print resources, it's time to package those resources into the print template ZIP file. Create a ZIP file called printronix-simple-template.zip containing the following files:
- simple.GPL
- simple.CSV
- resource.properties
Figure 5. Print template files
Step 5: Define the printer to WebSphere RFID
WebSphere RFID supports two kinds of RFID printers: physical printers and logical printers. A physical printer is connected to WebSphere RFID through the Edge Controller. A connection (such as TCP) is established between the Edge Controller and the printer, enabling WebSphere RFID to communicate with the printer. Logical printers are connected to WebSphere RFID using file drops. When a print job for a logical printer is submitted, a file is generated with the print data and written to the file system. This file can then be picked up by a third-party print application, such as Loftware.
In order to submit a print job to either a logical or physical printer, you first need to define the printer to WebSphere RFID using the Premises Server administration console. To define the printer for this example, complete the following steps, as shown in Figure 6:
- Start the Premises Server administration console by selecting Start => Programs => IBM WebSphere RFID => Premises Server => Administration Console.
- Select Printers.
- Select New Printer.
- In the Create a New Printer dialog, specify the following as shown in Figure 6:
- Specify
1for Printer Id. - Specify
Printronix Printerfor Printer Name. - Select Printronix as the Printer Type.
- Ensure that the default Location of P1 is selected.
- Specify the Printer IP address and Printer IP Port Number.
- Click Create.
Figure 6. Define the printer on the Premises Server
- Specify
Step 6: Define the print template
As with printers, you must also define print templates to WebSphere RFID before using them to print labels. A print template definition consists of the following:
- template name
- printer type
- template file location - the URL of the print template ZIP file. The Edge Controller uses this URL to fetch the print template when a print job specifying this template is submitted for processing. You need to make sure to put the printronix-simple-template.zip on an HTTP server where it can be accessed by the Edge Controller.
To define the printronix-simple-template you just created:
- Start the Premises Server administration console by selecting Start => Programs => IBM WebSphere RFID => Premises Server => Administration Console.
- Select Print Templates.
- Select New.
- In the Create Print Template dialog, specify the following as shown in Figure 7:
- Specify
simpleas the Print Template Name - Specify
Printronixas the Printer Type. - For the Properties Location Url, specify the URL of the print template ZIP file. The template file name is printronix-simple-template.zip. To ensure you have the correct URL, try typing it in a browser to see if the HTTP server returns your template.
- Click Create.
Figure 7. Define the print template on the Premises Server
- Specify
Step 7: Update the printer agent properties
You need to make one last configuration change before testing the template. You must set the PrintronixPrinterAgent property pxml.transport.remoteport to 0. This is required because we set the Printronix property Ret. Status Port to E-NET Data Port. This means that communication back to the host computer (in this case, the Edge Controller) will be on the E-NET Data Port. To update this property, do the following:
- Start the Premises Server administration console by selecting Start => Programs => IBM WebSphere RFID => Premises Server v1.1 => Administration Console.
- Select Agent Configuration.
- In the Edit Agent Properties dialog, do the following as shown in Figure 8:
- For Reader Agent, select PrintronixPrinterAgent.
- For Agent Property, select pxml.transport.remoteport.
- Enter
0for the Property Value. - Click on Update.
Figure 8. Update printer agent properties
Step 8: Verify the printronix-simple-template definition
Before you go any further, it's a good idea to check the print template for simple mistakes that might prevent a successful print. Especially, you should make sure the template_name (simple) is used consistently, including capitalization, across the various resources. Failure to correctly name the resources will cause the print to fail.
We defined the print template simple using the Premises Server administration console. This definition dictates the template_name that must be specified in the print resource files and used in the print resource file names. The various places the template_name (simple) must be used are listed below. They're also illustrated in Figures 9 and 10 using red and blue circles.
- The name of the printer command file name must be simple.GPL. The form name specified on the CREATE command must be simple.
- The name of the of the parameter map file must be simple.CSV.
- The name of the print template file must be printronix-simple-template.zip.
- The resource.names property in the resources.properties file must be printronix-simple-template.
- The property names in resources.properties file are prefixed with printronix-simple-template.
- The printronix-simple-template.template.name property in the resources.properties file must be simple.
Figure 9. Verify the print template
Figure 10. Verify the print template on the Premises Server
Step 9: Configure the Edge Controller
Now that you've created and defined the print template and defined the Printonix printer, you need to create an Edge Controller to receive print jobs from the Premises Server and to communicate with the printer to process the jobs. For our samples, we'll load the Edge Controller bundles into an SMF runtime executing inside of Device Developer. In order to create the Edge Controller runtime, you must have installed and configured the RFID Tracking Kit in Device Developer.
The RFID Tracking Kit has a number of pre-defined loader bundles that you can use to load an SMF runtime with the bundles necessary to communicate with the Premises Server and the target device. The loader bundle we'll use for the Printronix printer is called TOGA_PRINTRONIX_DEMO_LOADER. You can find the source code for this bundle in the TogaPrintronixPrinterDevelopment project. If you loaded and configured the RFID Tracking Kit in Device Developer, the TOGA_PRINTRONIX_DEMO_LOADER bundle should be installed on your SMF bundle server. If not, you'll need to submit the bundle to your bundle server.
To install TOGA_PRINTRONIX_DEMO_LOADER to the SMF runtime, do the following:
- In Device Developer, select Runtime => Run and create a new SMF runtime launch configuration.
- Add the following VM arguments:
-Dedge.id=E1 –Dpremises.ip==<Premises Server IP address:9080>
Note that the edge ID, E1, refers to an edge configuration defined to the Premises Server. This document assumes you're using the default WebSphere RFID configuration, which pre-defines E1.
- Click Apply.
- Click Run.
- The SMF runtime starts with only the SMF System Bundle[0] installed.
- Install the TOGA_PRINTRONIX_DEMO_LOADER bundle. Switch to the SMF Bundle Servers view, expand the list under Bundles. Right-click TOGA_PRINTRONIX_DEMO_LOADER bundle and select Install . The loader bundle returns a list of bundles that will be installed into the SMF runtime. The installed bundle set provides the Edge Controller functions needed to communicate with the Premises Server and the Printronix printer
Figure 11. Install the Edge Controller components
Step 10: Submit the print job using WebSphere PVS
WebSphere RFID includes a Print, Verify and Ship (PVS) User Interface for managing the shipping process. This Web-based interface contains the following functions:
- Print: prints RFID tags using products from purchase orders or catalog data
- Verify: creates associations between cases and containers
- Ship: validates outgoing containers to ensure they contain the correct cases
- Report: generates reports on items that have been printed
For our simple print example, we'll only be using the Print function.
The Premises Server includes a set of pre-defined profiles, product orders and product data. This pre-defined data is used to create and submit a print job to the Edge Controller for processing. To submit a print job using PVS:
- Start the PVS User Interface by selecting Start => Programs => IBM WebSphere Premises Server => PVS Reference User Interface
- Select print from the print | verify | ship | report navigation links.
- Click the Setup tab.
- On the Setup page, do the following, as shown in Figure 12:
- Select Default96 as the Profile.
- Select PO103001 as the Existing purchase order.
Figure 12. Select profile and purchase order
- Click the Select tab
- You should see an item from the selected purchase order in the Item field, as shown in Figure 13. Click Add to select the item for printing.
Figure 13. Select purchase order item to print
- The selected item should display at the bottom of the page under Review selections, as shown in Figure 14. Make sure simple is selected in the Label field. If not, select it from the list and click Update.
Figure 14. Select the simple print template
- Click the Print tab.
- Select Printronix Printer as the Printer, as shown in Figure 15, and click Submit.
Figure 15. Submit the print job
- The Print tab is refreshed with the print job id, as shown in Figure 16. Click Status to get the status of the print job.
Figure 16. Check status of print job
- When the job is complete, the status changes from "Job printing" to "Job complete".
The resulting RFID label from our print job is shown in Figure 17:
Figure 17. Print results using the simple print template
Create a complex print template
Now let's add some additional fields and a graphic image to the label. The additional fields will provide date, ship to, and description information. The graphics image will display the IBM logo at the bottom of the label. To add these fields and the image to the label, you need to modify all the components of the print template. In addition, you need to add the graphics image file to the print template ZIP file. We'll use the template_name complex for this example.
To add the date, ship to, and description information and the IBM logo to the label, you need to update the printer command file to do the following:
- Position and add and the static data Date:
- Position and add the dynamically generated date
- Position and add and the static data Ship to:
- Position and add the dynamic ship to information
- Position and add and the static data Description:
- Position and add the user-defined description
- Position and add the IBM logo
Modify the simple.GPL printer command file used in the previous example to create the complex.GPL printer command file as shown in in Table 2:
Table 3. Printer configuration changes for complex print template
| simple.GPL | complex.GPL | ||
|---|---|---|---|
|
|
The static and dynamic fields are added to the ALPHA command. The dynamic data fields are defined using the AF dynamic data field parameter. The dynamically generated date is mapped to data field AF2, the ship to information is mapped to AF3, and the description is mapped to AF4. For the IBM logo, the LOGO command is used to select and position the logo.
Step 1: Update the parameter map file
You need to add three additional mappings to map the date, ship to, and description data to the AF2, AF3 and AF4 data fields.
The date value is provided by adding an entry and specifying the $DATE map variable. The $DATE map variable will be populated with the current date and time by the Edge Controller. The $DATE variable is mapped to the AF2 data field.
The ship to and description values are provided by adding two entries that specify the shiptoname and description map variables. The shiptoname and description map variables will be populated with data from a properties file (to be created) by the PVS application when a print job is submitted. The shiptoname value is mapped to the AF3 data field and the description value is mapped to the AF4 data field.
The name of the updated parameter map file is complex.CSV. The completed map file is shown below:
Figure 18. complex print template - parameter map file
Step 2: Create a label properties file
You can use property files to add dynamic and static data to an RFID label. Static data is fetched directly from the properties file; dynamic data is fetched from one or more Premises Server tables using variables specified in the properties file. The property file must have the same name as the template_name with a file extension of properties. For our example, the name of the properties file is complex .properties. The location used to fetch the properties file is specified by the pvsapp.properties file. This default location for the label properties file is:
<WAS_HOME>\installedApps\<hostname_or_nodename>\IBM_Premise_PVS_Console.ear\
ibmrfid_premises_pvsapp.war\config
Figure 19. Label properties file location
The complex .properties file has two entries, as shown in Figure 20:
Figure 20. Label properties file contents
The value for description is Big Widgets. This value is hard-coded in the properties file. The value for shiptoname is $SHIPTONAME. Values that begin with a $ represent dynamic data that will be fetched from one of the Premises Server tables. The $SHIPTONAME value is fetched from the PVS.PODATA table. The specific value is retrieved from the SHIPTONAME column of the row that corresponds to the purchase order selected using the print function in the PVS User Interface. When you printed the RFID tag for our simple example, you chose the purchase order PO103001. In this case, the $SHIPTONAME variable value would be fetched from the PVS.PODATA table where PONUMBER=P0103001. Using the default PVS data, the $SHIPTONAME variable would be populated with a value of TarMart.
Figure 21. SHIPTONAME in the PODATA table
Step 3: Update the template resource file
As described earlier, the template resource file, resource.properties, defines the resources included in the print template ZIP file. You need to update this file to reflect the new name of the print template and to specify the graphic resource. Update the template resource file as shown in Figure 22:
Figure 22. Update resource.properties file
The changes and additions to the resource.properties file are:
- The value of the resource.names property is
printronix-complex-template. - All property names are now prefixed with the value:
printronix-complex-template. - The printronix-comple-template.template.name is set to
complex. - The
template.requiresproperty is added to specify the graphics file to be printed on the label. The graphics file format used in the complex example is PCX. For information on the other supported formats, refer to the Printronix documentation. The name of the graphics file is IBMLOGO.PCX which means the template.requires property must be set toIBMLOGOG.PCX.
Step 4: Create the print template ZIP file
Create a print template ZIP file containing the files shown in Figure 23. The name of the print template ZIP file is printronix-complex-template.zip. In addition to the template command, mapping and resource files, the ZIP file now contains the graphics file IBMLOGO.PCX.
Figure 23. Complex print template ZIP file contents
Step 5: Define a new print template and print using PVS
Using the same procedures as you used in Steps 5 - 10 of our simple example, define a new print template called complex using the Premises Server administration console. Once you've defined the new template, use the PVS User Interface to submit a print job using the complex template. The RFID tag printed using the complex print template should resemble that shown in Figure 24:
Figure 24. Print results using the complex print template
In this article, you learned about the configuration requirements and print resources needed to print RFID labels with the WebSphere RFID solution. You created a simple printer command file and printed an RFID label from the file using the printer's FTP print capability. You then modified this command file and packaged it with other resources to create print templates that could be used with the WebSphere RFID solution to print simple and complex RFID labels.
| Description | Name | Size | Download method |
|---|---|---|---|
| Sample code for this article | websphere-rfid-print.zip | 3KB | FTP |
Information about download methods
-
WebSphere RFID Information Center
-
Printronix manuals
-
developerWorks Wireless with WebSphere zone
-
developerWorks Wireless zone
-
IBM WebSphere RFID Handbook: A Solution Guide
-
Develop an Agent with IBM RFID Tracking Kit and WebSphere Studio Device Developer
-
Integrate Your Enterprise Application with IBM WebSphere RFID Middleware

Allen Smith is a Senior Software Engineer with the Pervasive Computing Group in Research Triangle Park, North Carolina. He works with business partners to design solutions that use IBM's pervasive middleware. You can contact Allen at allens@us.ibm.com.
Comments (Undergoing maintenance)





