On Thu, Jan 16, 2014 at 09:02:21AM +0000, Stuart Henderson wrote: > But if this code is to do some necessary initialization for a particular > printer that can be matched by IDs, adding support right in the ulpt(4) > driver would probably be better,
Agreed. > there's already some framework for matching > things by ID for printers which need firmware to be uploaded, so you could > possibly hook into this. In particular, the ulpt_ucode_loader_hp() function writes a firmware image as raw bytes to the printer. Re-using code from this function you should be able to write arbitrary data to the printer. Fun fact: The implementation of ulpt_ucode_loader_hp() was based on code from ugen_do_write(), i.e. ulpt behaves like ugen while it uploads firmware to HP printers.
