PPFA: BarCode EAN UCC 128 Set C using BCOCA

ITEM: RTA000155263



Q:                                                                              
Topic thread:                                                                   
Printer Systems (PRINT - NA/ATS)                                                
 PSF/AIX                                                                        
                                                                                
I need to print Barcode EAN UCC 128 Set C. Boulder sent me a                    
document about it, I understood it, but I'm having some errors, for             
example, my data ASCII is: 012345.                                              
01 is Position 1                                                                
23 is Position 2                                                                
45 is Position 3                                                                
Then I multiply these values for your position,                                 
Start C = 105                                                                   
01 x 1 = 01                                                                     
23 x 2 = 46                                                                    
45 x 3 = 135                                                                    
I add these values 105+01+46+135=287                                            
Check Digit is 81                                                               
So I have: 8921374D718A (Hexadecimal Code)                                      
89 is START C                                                                   
21 is 01 in SubSet C                                                            
37 is 23 in SubSet C                                                            
4D is 45 in SubSet C                                                            
71 is 81 in SubSet C (Check Digit)                                              
8A is STOP                                                                      
                                                                                
Again I printed this stream with Barcode CODE 128 (8921374D718A), but           
I'm having some errors on the printer. (Invalid Characters). I don't            
understand why.                                                                 
                                                                               
My Environment is: RS/6000 AIX 4.2.1, PSF/6000 V2.1 and InfoPrint 4000          
Printer. PTFs on the RS/6000: UQ20896, UQ18457, U447344, U458721,               
U457551, U453812, U459171.                                                      
                                                                                
Thanks for your help..                                                          
                                                                                
A:                                                                              
How are you specifying to use the barcode?  There are two ways for an           
InfoPrint 4000 - either (1) through calling a font or (2) through coding        
a pagedef using the BARCODE subcommand of the FIELD command that the            
the printer will resolve into BCOCA.  Which are you using?                      
                                                                                
If you are using the first option (a font), what font are you using?            
Please provide the names of the coded font (X0???), the character set           
(C0???), and the codepage (T1???).  Also, are you using an ACIF input          
record exit to convert the ASCII into EBCDIC (for example, apka2e or            
asciinpe) before printing?                                                      
                                                                                
If you're using the second option (BCOCA), please provide the source            
for the pagedef (or at least that section of the pagedef).                      
                                                                                
Also, please ALWAYS provide all error messages including both the               
error number and the complete error text.  I do appreciate your                 
including the PTF levelsą                                                       
                                                                                
Returning to you for additional information.                                    
                                                                                
Q:                                                                              
1. I'm using Barcode command in field command.                                  
2. I'm using /usr/lpp/psf/bin/apka2e                                           
3. Pagedef EANU                                                                 
      Width 8.5                                                                 
      Height 11                                                                 
      Replace Yes;                                                              
   PageFormat PF1;                                                              
      PrintLine Channel 1 Position 0 0;                                         
         Field Start 1 Length 5 Position 1 1 Barcode CODE128 Type 17            
            Hri On Ssasterisk Off ModWidth 12 Height 0.5;                       
   EndSubPage;                                                                  
4. Errors:                                                                      
   0420-478 The printer reported a character that was not defined in the        
            code page.                                                          
   0420-429 PSF received IPDS exception X'0821..00' action code X'01'           
            from the printer.                                                   
   0420-098 The error occurred while printing page 1 of copy 1 of this         
            print job.                                                          
   0420-254 The printer an error that caused PSF to stop processing the         
            page.                                                               
Thanks in advance..                                                             
                                                                                
A:                                                                              
I've been doing some testing here, and have successfully printed                
Code128 with a pagedef and bcoca to a 3130.  I don't have the                   
documentation that Boulder sent you, but I don't understand why you             
did all the calculations that you did to come up with those hex values          
(which are not valid in the codepage used for the HRI) or for the               
check digit (since PPFA can do that for you).                                   
                                                                                
What book did Boulder send you?  If it is the Bar Code Fonts User's             
Guide (S544-3190-02), then it doesn't apply to what you are doing.             
                                                                                
My data file consisted of the following:                                        
---------------------------------------------------------------                 
This is a test of Code 128 BCOCA in pagedef.                                    
                                                                                
012345                                                                          
012345                                                                          
---------------------------------------------------------------                 
                                                                                
My pagedef looks like this:                                                     
---------------------------------------------------------------                 
PAGEDEF C128                                                                    
  REPLACE YES;                                                                  
  FONT FONT01 GT10;                                                             
  FONT FONT02 GT15;                                                            
                                                                                
  PAGEFORMAT PAGE1                                                              
    WIDTH 2040 PELS 2640 PELS DIRECTION ACROSS;                                 
                                                                                
/* Two line testcase identifier                    */                           
  PRINTLINE POSITION 720 PELS 100 PELS FONT FONT01;                             
  PRINTLINE POSITION 720 PELS 124 PELS FONT FONT01;                             
                                                                                
/* One line of text followed by Code 128 barcode   */                           
  PRINTLINE POSITION 60 PELS 200 PELS FONT FONT01;                              
  PRINTLINE POSITION 60 PELS 300 PELS FONT FONT01;                              
   FIELD START 1 LENGTH 6                                                       
      BARCODE CODE128 TYPE 17 MOD 2 HRI BELOW                                   
      SSAST OFF HEIGHT 0.5 MODWIDTH 12 ;                                        
---------------------------------------------------------------                
                                                                                
The MOD 2 should tell PPFA to calculate the check digit for you,                
rather than you having to calculate it yourself.                                
                                                                                
I got printout that looks okay to me, though I have no way to figure            
out if it calculated the right check digit or not.  It does look like           
it automatically includes the START and STOP characters.                        
                                                                                
I've talked with our PPFA expert, she agrees with my sample pagedef.            
If you're using PPFA and BCOCA, you should not be calculating values            
for START, STOP or CHECK; PPFA will handle that all for you -- you will         
have to code "MOD 2" for it to calculate the check digit for Code128.           
The hex values you were passing in were not valid; please see the PPFA          
User's Guide (S544-5284-01), Figure 75, page 223, for a list of the             
valid hex characters for Code128 barcodes.                                     
                                                                                
Please reopen if you have additional questions.                                 
                                                                                
 (2/1999)                                                                       
                                                                                
S e a r c h - k e y w o r d s:                                                  
ppfa barcode code128 ucc ean bcoca psf/6000 psf/aix infoprint psf               
start stop check digit printline field subroutine                               
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                               


WWQA: ITEM: RTA000155263 ITEM: RTA000155263
Dated: 02/1999 Category: XPSF6000
This HTML file was generated 99/06/24~12:43:43
Comments or suggestions? Contact us