LinuxCommandLibrary

foo2oak-wrapper

Convert Ghostscript output to OAK format

SYNOPSIS

foo2oak-wrapper [-pprinter] [-z#] [foo2oak-options] [<input.pcl> [output.pcl]]

PARAMETERS

-pprinter or --printer=printer
    Select printer model, e.g., -pokilaserjet600, -pokib4200

-z# or --compression=#
    Set compression level (1-9, default 3)

-d# or --density=#
    Toner density (0-100, default 100)

-rxres[xyres] or --dpi=xres[xyres]
    Resolution, e.g., -r600 or -r600x300

-D or --debug
    Enable debug output

-P or --ppd
    Print equivalent PPD options

-L or --noduplex
    Disable duplex printing

-n#
    Process only first # pages

DESCRIPTION

The foo2oak-wrapper is a shell script filter used primarily with CUPS (Common Unix Printing System) to process print jobs for printers based on Oak Technology print controllers, such as certain Oki LaserJet models (e.g., Oki C5100, B4100 series) and compatible Lexmark devices. It converts PostScript or PDF input into the printer's proprietary raster format by invoking Ghostscript for rasterization and foo2oak for encoding the Oak Technology OAKT protocol.

This wrapper simplifies integration with Linux printing systems, automatically handling options based on the printer model specified in the CUPS PPD file. Users typically do not invoke it directly but configure it via lpadmin or printer setup tools. For manual use, it accepts PCL or raw input and outputs printer-ready data.

Key features include support for duplex printing, toner density adjustment, resolution selection (300/600 DPI), and compression to optimize data transfer. It's part of the open-source foo2zjs driver suite, filling gaps in official drivers for older or non-mainstream printers. Installation often requires downloading firmware blobs for specific models during setup.

CAVEATS

Requires Ghostscript and foo2zjs package. Firmware download needed for some models via getweb 1018. Limited to specific Oki/Lexmark printers; test compatibility. High resolutions increase processing time.

SUPPORTED PRINTERS

Oki C5100, C5150, B4100, B4200, B4300; Lexmark Optra Color 40. Check foo2oak manpage for full list.

FIRMWARE SETUP

Run foo2zjs-getweb 1018 or model-specific to fetch required blobs into ~/.foo2zjs.

INSTALLATION

On Debian/Ubuntu: sudo apt install printer-driver-foo2zjs; then add printer with PPD from /usr/share/ppd/foo2zjs.

HISTORY

Developed by Toby Thain around 2004-2005 as part of the foo2zjs project to reverse-engineer and provide open-source drivers for HP ZJS-compatible and Oak Technology printers. Evolved through community contributions; now maintained in distro packages like printer-driver-foo2zjs (Debian/Ubuntu). Widely used pre-2010 for unsupported office lasers.

SEE ALSO

Copied to clipboard