ContentsIntroductionThe package RMaxicode contains the classes you need to create Maxicode barcodes within your java applications. Maxicode is a two-dimensional (2D) and fixed-size matrix symbology which is made up of offset rows of hexagonal modules arranged around a unique finder pattern. The size of Maxicode is 1.11 x 1.054 inches and it can contain up to 93 data characters of information (a total of 144 including error correction codewords). The symbol was created by United Parcel Service for fast scanning and sorting of packages.RMaxicode supports the following features:
Symbol structure MaxiCode symbols are divided into a primary and a secondary message, each of which contains data and error correction codewords. The primary message is made of 10 codewords and 10 error correction codewords. The primary message is used in mode 2 and 3 to encode the Postal Code, the Service class and the country. Error correction MaxiCode symbols have error correction codewords, based on Reed-Solomon error correction algorithms, which can be used to detect errors and correct erroneous symbols. There are two error levels; standard and enhanced (mode 5). Maxicode modes Modes 2 and 3 are designed for use in the transport industry. They encode the destination address and the class of service as defined by the carrier. Mode 2 uses a 9 digit numeric postal code and mode 3 uses a 6 character alphanumeric postal code. The Service class and the country are both a 3 digit number in both modes. Mode 4 can encode up to 93 characters or 138 digits. Mode 5 can only encode up to 77 characters but it provides more error correction capabilities (enhanced mode than mode 4. Mode 6 indicates that the symbol encodes a message used to program the reader system (scanner). Structured append Up to eight MaxiCode symbols may be appended in a structured format. This allows files of data to be represented in up to 8 MaxiCode symbols.
Sample applicationIn order to run the sample application you must execute example.bat. You need to use JDK 1.3. The reason is the following:
Note: the sample application needs java 1.3, not RMaxicode, the java Bean or the servlet can work with java 1.1 or 1.2.
In the sample application you can set following properties:
and execute the following command:
Note: Tilde Processing: You can use the format ~ddd if you want to specify the ascii code of the character to be encoded. For example, if you enter the following text in the Data field: ~066AA you will actually be encoding BAA because ~066 will be replaced with the character ascii character 66, which is B. You must use ~~ in order to encode the ~ character. If you want to deactivate this behaviour you must call the method setProcessTilde(false). The class
Click here to see the java documentation on the RMaxiCode class.
The Servlet
RMaxicode comes with a standard servlet (RMaxicodeServlet) you can use to create maxicode images. The paramters for the servlet can be sent using GET or POST commands. The parameters are:
For example, if you want to test the servlet using JSWDK 1.0 you must do the following:
Read also Tilde Processing.
Important Note: In order to property print a maxicode barcode created with the servlet you must use the <IMG> tag. In this way you can embed the image in your HTML page. Note that you will need to use the attibutes height and width in order to achieve the correct size of the maxicode on the printed page. This is a simple HTML page that contains a maxicode barcode:
ReferencesYou can find more information about maxicode at: |