Telepen

The Telepen coding scheme has a number of variants - Telepen Numeric, Telepen ASCII, and either with various begin and end codes. You will need to determine which variant you are attempting to create barcodes for.

The Telepen ASCII scheme provides the full ASCII character set. For convenience of handling characters with ASCII values of less than 32 are reproduced in the font at the character positions chr$(192) - chr$(223). The space character, ASCII 32, is reproduced at ASCII 159 and 160.

Some Telepen symbols require the first character (after start) be an ASCII Shift In character, and the last character (before stop) to be a Shift Out character.  The ASCII ESC character is required on some Telepen Numeric systems as the first character after to the start character. If you are using a Telepen system your system manual describes the scheme you require.

All Telepen codes must begin with a start character and must end with a stop character. The start character is § (Chr$(167)) and the stop character is ¬ (Chr$(172)).

Telepen ASCII normally uses a Modulo 127 check digit as shown below. However, there seem to be a wide variety of schemes for calculating Telepen check digits and the user is recommended to consult his Telepen system documentation.

n = Len(xx$)  ‘ xx$ is the code
t1 = 0
For i = 1 To n
    y$ = Mid$(xx$, i, 1)
        z = Asc(y$) ' ASCII value of character
        If (z > 127) Then z = z - 128
        t1 = t1 + z
        Next i

    chn = t1 Mod 127  ' checksum
    If chn > 0 Then chn = 127 - chn
    If (chn < 32) Then chn = chn + 192 ‘ make it visible in font
    chd$ = Chr$(chn)   ‘ set check character

The dFont program provided with the dLSoft Barcode fonts check digit for Telepen codes, and the source code is provided and may be adapted to the users needs - for example, for automating the calculation in a spreadsheet or database.   

The extra Telepen_N barcode type provides the begin data end sequence required on some systems for Telepen Numeric.       

 

More:

Supporting software