Re: New version (Re: How to open & write to a USB port?)



From dos program text file prints immediately, via spooler
also. Printing invoice with bar code makes no diffrence.

So the delay is avoidable, and it should be solved. Just wondering: is
the last character of the text file an EOF (26)?

/* LASTCHAR.CMD (not tested) */
CALL CharOut '','What file? '
PARSE PULL filename
IF Pos('"',filename',1)>0 THEN DO
PARSE VAR filename '"' filename '"' .
END
size=Stream(filename'C','QUERY SIZE')
IF size<>'' THEN SAY 'Last:' C2D(CharIn(filename,size,1))

If not,(what's the last character,) and assuming the last page is
always printed with a delay: what happens if you print a space
character, and add an EOF to this near-empty text file (or print a dot
instead of a space, if your printer ignores blank pages)? To create
such a file:

REXXTRY CALL CharOut 'Print.Me!',' '||D2C(26)

Or try printing this file twice, quickly (i.e. clearly within the
delay of a few minutes):

REXXTRY CALL CharOut 'PrintMe!.too',' '

Considerations: maybe the printer is waiting for an (explicit
end-of-job XOR time-out) when this OS/2 method is in use. If so, the
created file "Print.Me!" should eject faster because it adds an EOF.
The file "PrintMe!.too" can produce 2 pages (one page per job), or one
page (with a job implicitly continued within the delay). Again,
replace the spaces between the '' characters with e.g. a dot if your
printer ignores blank pages.

BTW, chances are the local helpdesk of the manufacturer of your
printer (HP, isn't it?) is more than willing to help the author of a
(generic) printer "driver", without you (the developer) having to RTFM
of a product you don't own). Just tell what you (the developer) are
doing, and try to not mention OS/2 (too easy to say it isn't
supported). Try explaining it in a generic way instead.


--
.



Relevant Pages

  • ATmega8535 and USART post-initialisation delay required?
    ... Is there a requirement to delay using the USART (at least for asynchronous ... enabling interupts until transmitting the first character? ... character, ... The ATmega8535 datasheet does not seem to say that a delay is required. ...
    (comp.arch.embedded)
  • Re: One problem relates to termio
    ... TAB3 are values for the delay mask for tabs. ... fill character to be ... TABDLY is set to XTABS the tab character will be converted to ... To unset the delay or tab expansion, set TABDLY to TAB0. ...
    (comp.unix.programmer)
  • Re: MIDI conjunction device
    ... I would agree on a one byte delay with UARTs, ... Ignoring bit-banged receivers and transmitter, ... If we queue each character for transmission as thery are received, ...
    (comp.arch.embedded)
  • Re: trouble with Serial Port class vs Hyperterminal
    ... There is no problem sending full strings that I know of (I do it all the ... Your device may expect a delay between each character (just as ...
    (microsoft.public.dotnet.framework)