zpl.tools
CommandsSystem configuration

^CO - Cache On

Adjusts character cache memory for scalable fonts

^CO - Cache On

Overview

The ^CO command changes the size of the character cache used for storing scalable font characters. The cache improves printing performance by storing rendered characters for quick retrieval. Default cache is 22K; maximum single character size without adjustment is 450x450 dots.

Syntax

^COa,b,c

Parameters

  • a = Cache On setting
    • Y = Yes, enable/resize cache (default)
    • N = No, disable cache
  • b = Additional memory in KB to add to cache
    • Default: 40K (if not specified)
    • Recommended: 300 for Kanji fonts (v16.5.0+)
  • c = Cache type (v16.5.0+)
    • 0 = Cache Buffer for normal fonts (default)
    • 1 = Internal Buffer for Kanji fonts

Description

  • Manages scalable font character caching
  • Improves performance by storing rendered characters
  • Allows larger character sizes
  • Critical for Kanji and international fonts
  • Cache memory reduces available space for other objects

Usage Notes

  • Cache can be resized as needed
  • Existing cached characters lost when resized
  • Memory used reduces space for bitmaps, graphics, fonts
  • Cache memory is not contiguous (separate blocks)
  • Performance degrades if cache too large
  • Kanji fonts greatly reduce available printer memory

Cache Sizes

ConfigurationTotal SizeUse Case
Default (none)22KStandard ASCII fonts
+40K62KLarger scalable fonts
+100K122KVery large characters
+300K322KKanji fonts, international

Maximum Character Sizes

Cache SizeMax Char DotsMax Char Inches
22K (default)450x4502.2x2.2" (203 DPI)
62K900x9004.4x4.4"
122K1200x12005.9x5.9"
322K1500x15007.4x7.4"

Examples

Default Cache

^XA
^A0N,50,50^FDText^FS
^XZ

Uses default 22K cache.

Resize to 62K

^XA
^COY,40
^A0N,50,50^FDLarger Text^FS
^XZ

Allocates 62K cache (40K + 22K default).

Resize to 122K

^XA
^COY,100
^A0N,80,80^FDMuch Larger Text^FS
^XZ

Allocates 122K cache for very large characters.

Kanji Font Cache

^XA
^COY,300,1
^A0N,80,80^FDKanji Text^FS
^XZ

Allocates 322K cache with internal buffer for Kanji.

Disable Cache

^XA
^CON
^A0N,50,50^FDNo Cache^FS
^XZ

Disables character caching.

Considerations

Advantages

  • Faster character rendering
  • Smoother label printing
  • Better performance with large fonts
  • Essential for Kanji support

Disadvantages

  • Reduces memory for other objects
  • Cache uses non-contiguous memory
  • Larger cache may impact performance if too large
  • Takes effect immediately
  • ^A - Scalable/Bitmapped Font
  • ~DT - Download TrueType Font
  • ~DU - Download Unbounded Unicode TrueType Font
  • ^CW - Font Identifier

See Also