canonselphy: We need to match the full 8-bit papercode for all models other than the CP790.

This commit is contained in:
Solomon Peachy 2014-01-29 21:05:21 -05:00
parent 882eda8ad1
commit 1eefa82b64
1 changed files with 17 additions and 7 deletions

View File

@ -658,12 +658,22 @@ top:
/* Make sure paper is correct */
if (ctx->paper_code != -1) {
if ((rdbuf[ctx->printer->paper_code_offset] & 0x0f) !=
(ctx->paper_code & 0x0f)) {
ERROR("Incorrect paper loaded (%02x vs %02x), aborting job!\n",
ctx->paper_code,
rdbuf[ctx->printer->paper_code_offset]);
return 3; /* Hold this job, don't stop queue */
if (ctx->printer->type == P_ES40_CP790) {
if ((rdbuf[ctx->printer->paper_code_offset] & 0x0f) !=
(ctx->paper_code & 0x0f)) {
ERROR("Incorrect paper loaded (%02x vs %02x), aborting job!\n",
ctx->paper_code,
rdbuf[ctx->printer->paper_code_offset]);
return 3; /* Hold this job, don't stop queue */
}
} else {
if (rdbuf[ctx->printer->paper_code_offset] !=
ctx->paper_code) {
ERROR("Incorrect paper loaded (%02x vs %02x), aborting job!\n",
ctx->paper_code,
rdbuf[ctx->printer->paper_code_offset]);
return 3; /* Hold this job, don't stop queue */
}
}
}
@ -792,7 +802,7 @@ top:
struct dyesub_backend canonselphy_backend = {
.name = "Canon SELPHY CP/ES",
.version = "0.70",
.version = "0.71",
.multipage_capable = 1,
.uri_prefix = "canonselphy",
.init = canonselphy_init,