#!/usr/bin/expect # Fix 3400e Printers, set max label length, set width. # Requires: expect. Check path if you have it and this still doesn't work spawn telnet 10.8.0.223 9100 expect "Escape character is \'\^\]\'\." send "L{4000};W{800};"