From 2657f0a3583fe043bc68ae9b7a48f4a2b3df60d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Voltz?= Date: Tue, 11 May 2010 22:26:21 +0200 Subject: [PATCH] all motor modes/optical are working --- backend/genesys_devices.c | 10 +++++----- backend/genesys_gl847.c | 34 +++------------------------------- 2 files changed, 8 insertions(+), 36 deletions(-) diff --git a/backend/genesys_devices.c b/backend/genesys_devices.c index 106b448b1..31a5d3b2c 100644 --- a/backend/genesys_devices.c +++ b/backend/genesys_devices.c @@ -786,7 +786,7 @@ static Genesys_Motor Motor[] = { { /* motor slopes */ { /* power mode 0 */ { 2343, 1017, 32, 0.80}, /* full step */ - { 3675, 2034, 32, 0.80}, /* half step */ + { 4678, 2034, 16, 0.80}, /* half step */ { 4*2034, 4*2034, 32, 0.80}, /* quarter step */ /* extra values kept for documentation */ { 2343, 864, 32, 0.80}, /* full step */ @@ -929,13 +929,13 @@ static Genesys_Model canon_lide_100_model = { GENESYS_GL847, NULL, - {1200, 600, 400, 300, 200, 150, 75, 0}, /* possible x-resolutions */ - {1200, 600, 400, 300, 200, 150, 75, 0}, /* possible y-resolutions */ + {1200, 600, 300, 150, 75, 0}, /* possible x-resolutions */ + {1200, 600, 300, 150, 75, 0}, /* possible y-resolutions */ {16, 8, 0}, /* possible depths in gray mode */ {16, 8, 0}, /* possible depths in color mode */ - SANE_FIX (6.42), /* Start of scan area in mm (x) */ - SANE_FIX (10.0), /* Start of scan area in mm (y) 7.9 */ + SANE_FIX (6.42), /* Start of scan area in mm (x) */ + SANE_FIX (10.0), /* Start of scan area in mm (y) */ SANE_FIX (217.44), /* Size of scan area in mm (x) */ SANE_FIX (299.0), /* Size of scan area in mm (y) */ diff --git a/backend/genesys_gl847.c b/backend/genesys_gl847.c index 8130c25b0..bab315f2c 100644 --- a/backend/genesys_gl847.c +++ b/backend/genesys_gl847.c @@ -1789,31 +1789,6 @@ independent of our calculated values: if (used_pixels * xres < pixels * optical_res) used_pixels++; -/* dummy */ - /* dummy lines: may not be usefull, for instance 250 dpi works with 0 or 1 - dummy line. Maybe the dummy line adds correctness since the motor runs - slower (higher dpi) - */ -/* for cis this creates better aligned color lines: -dummy \ scanned lines - 0: R G B R ... - 1: R G B - R ... - 2: R G B - - R ... - 3: R G B - - - R ... - 4: R G B - - - - R ... - 5: R G B - - - - - R ... - 6: R G B - - - - - - R ... - 7: R G B - - - - - - - R ... - 8: R G B - - - - - - - - R ... - 9: R G B - - - - - - - - - R ... - 10: R G B - - - - - - - - - - R ... - 11: R G B - - - - - - - - - - - R ... - 12: R G B - - - - - - - - - - - - R ... - 13: R G B - - - - - - - - - - - - - R ... - 14: R G B - - - - - - - - - - - - - - R ... - 15: R G B - - - - - - - - - - - - - - - R ... - -- pierre - */ dummy = 0; /* slope_dpi */ @@ -1826,10 +1801,7 @@ dummy \ scanned lines slope_dpi = slope_dpi * (1 + dummy); -/* scan_step_type */ -/* Try to do at least 4 steps per line. if that is impossible we will have to - live with that - */ + /* scan_step_type */ if (yres * 4 < dev->motor.base_ydpi || dev->motor.max_step_type <= 0) scan_step_type = 0; else if (yres * 4 < dev->motor.base_ydpi * 2 @@ -1862,8 +1834,8 @@ dummy \ scanned lines scan_power_mode++; } - DBG (DBG_info, "gl847_init_scan_regs : exposure_time=%d pixels\n", - exposure_time); + DBG (DBG_info, "gl847_init_scan_regs : exposure_time=%d pixels\n", exposure_time); + DBG (DBG_info, "gl847_init_scan_regs : scan_step_type=%d\n", scan_step_type); /*** optical parameters ***/ /* in case of dynamic lineart, we use an internal 8 bit gray scan