Forums › TWAIN Classic › Can be the lamp warm up disable via twain functions ? › Reply To: Can be the lamp warm up disable via twain functions ?
- Topics - 9
- Replies - 583
- Total Posts - 592
short answer: no, not really.
longer answer that starts out sounding more promising but ends like a Dicapprio boat movie: The specification does *seem* to define a couple capabilities and even a couple device events for what you’re asking. Whether the capabilities are present/available/helpful will depend (heavily) on your driver/device as the capabilities are not mandatory and they’re a little.. whats the word.. hackish.
Icap_LampState *may* accept msg_set but generally is used to indicate whether the lamp is on. I wouldn’t bet heavily on this capability even being present – if you find a device that supports it lemme know.
CAP_POWERSAVETIME seems to be the closest to what you’re asking about. But there are at least two problems with using cap_powerSaveTime. The first is that it is defined in relation to cameras with no mention of scanners. Although not a show stopper that strikes me as odd. The second problem is a little trickier – the capability seems awkwardly missing from every twain header I’ve ever read. Little harder to tell the device to disable the powersave feature without the capabilityId…
Then you have 2 device events, TWDE_POWERSAVE is documented as ‘The device has powered down to save energy’ and TWDE_POWERSAVENOTIFY as ‘The device is about to power down to save energy.’ but I’ve yet to meet a device that supports device events, ymmv.
If you find a device that supported either it ought to be somewhat simple to cause the device to preform a scan then toss the image causing the device to stay on. I might have been known to schedule a scan every 20 or 30 minutes to achieve a similar result, but looking back I wonder if that weren’t why the device didn’t last 8 months…
From there, if I were really intent on pulling this off, I would probably contact the vendor looking for custom capabilities to mange the power/lamp/energystar or ask them if there were a another solution.
I would do this with the utmost patience as my experience with contacting vendors with questions about their custom capabilities has been… err unfavorable.