Specifications

No
EPSON
TITLE
EPSON Advanced Printer Driver for TM series
StatusAPI
Reference Manual
Revision
L
NEXT
58
SHEET
57
3.40.BiSCNSetReadBackFunction
[Function]
Executes image scanning by the function BiSCNReadImage and registers the callback function’s address called when
sending notification of the results as well as the memory addresses for setting each type of scanned information.
[Format]
int BiSCNSetReadBackFunction( int nHandle, int (CALLBACK EXPORT *pScnCB)(void),
LPDWORD pBuffSize, LPBYTE pBuff, LPBYTE pImageXsize,
LPBYTE pStatus, LPBYTE pDetail)
[Argument]
int nHandle
Specifies the handle value of the printer executing the function. The return value in BiOpenMonPrinter() is specified.
int (CALLBACK EXPORT * pScnCB)( void )
Specifies the callback function address for sending notification of the results of image scanning.
LPDWORD pBuffSize
Specifies the size of memory where image data are to be set. After execution of this function, the actual size of the
scanned data is set.
LPBYTE pBuff
Specifies the memory address where image data are set.
LPBYTE pImageXsize
Specifies the memory address where the number of data (bytes) of image data in the X direction is set.
LPBYTE pStatus
Specifies the memory address where the read status is stored. Concerning the returned status, refer to the image scanning
status items below.
LPBYTE pDetail
Specifies the memory address where detailed information is set after scanning ends with an error. Concerning the
returned status, see the detailed image information below.
[Return Values]
If execution is successful, 0 is returned. If an error occurs, the following error codes (negative values) are returned.
ERR_HANDLE The handle value specified for the printer is incorrect.
ERR_NO_MEMORY Memory is insufficient.
ERR_PARAM
Parameter error
ERR_NOT_SUPPORT Not supported
ERR_OFFLINE It was opened in the offline state, so it cannot be used until the online state is recovered.
[Explanation]
Image Read Status
For the TM-H6000II
Bit 7 is ON when status API fail to receive the scanning data from the printer. In this case, the contents of pBuff is not correct.
Value
Bit Function
0 1
0 Reserved Fixed at 0.
1 Reserved Fixed at 0.
2 Reserved Fixed at 0.
3 Reserved Fixed at 0.
4 Rescanned Possible Not (Fixed)
5 Scanning results Ends normally. Ends with an error.
6 Scanning data overflow No overflow Overflow
7 Scanning data translation error No error Error