From owner-freebsd-questions@FreeBSD.ORG Thu Aug 4 05:26:56 2011 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 63DDE106566B for ; Thu, 4 Aug 2011 05:26:56 +0000 (UTC) (envelope-from olivares14031@gmail.com) Received: from mail-iy0-f172.google.com (mail-iy0-f172.google.com [209.85.210.172]) by mx1.freebsd.org (Postfix) with ESMTP id 2E67D8FC0A for ; Thu, 4 Aug 2011 05:26:56 +0000 (UTC) Received: by iye7 with SMTP id 7so2994112iye.17 for ; Wed, 03 Aug 2011 22:26:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=04n23LICI4pCo5tR2lvAKBt5rQ/a4xFHZf+Ka5RvG4A=; b=M9u/l1XPZ/6LHrGxlwcbKIxPuRJnF679Vp75K4qRzKWDmPb46XLCEwyclxHB2Jho0z OLXyoO0P9IR+dFxJq5i0stDS07PtTqRkiyDHok+y8Dn+EwrFGSuamrSQ5PZzYHL2OWvF VRF4o81e/aAMq/3rG6E9yL6t2MSkqGy7WQb5k= MIME-Version: 1.0 Received: by 10.42.144.68 with SMTP id a4mr326678icv.427.1312435615700; Wed, 03 Aug 2011 22:26:55 -0700 (PDT) Received: by 10.42.165.200 with HTTP; Wed, 3 Aug 2011 22:26:55 -0700 (PDT) In-Reply-To: References: Date: Thu, 4 Aug 2011 00:26:55 -0500 Message-ID: From: Antonio Olivares To: Warren Block Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: FreeBSD Questions Subject: Re: help setup an HP 3300C scanner X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Aug 2011 05:26:56 -0000 On Thu, Aug 4, 2011 at 12:09 AM, Warren Block wrote: > On Wed, 3 Aug 2011, Antonio Olivares wrote: > >> Thank you for your message. =A0I have added the following: >> >> # AAO >> # detect HP ScanJet 3300C >> attach 20 { >> =A0 =A0 =A0device-name "ugen[0-9].[0-9]"; >> =A0 =A0 =A0match "vendor" "0x03f0"; >> =A0 =A0 =A0match "product" "0x0205"; >> =A0 =A0 =A0action "usb_devaddr=3D`echo $device-name | sed 's#^ugen##'` &= & \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0chown root:saned /dev/usb/${usb_devaddr}.* &&= \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0chmod 0660 /dev/usb/${usb_devaddr}.* && \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0su saned -c '/usr/local/bin/scanbuttond \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0-s /usr/local/etc/scanbuttond/buttonpressed.s= h \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0-S /usr/local/etc/scanbuttond/initscanner.sh = \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0-b /usr/local/lib/libscanbtnd-backend_epson.s= o'"; >> }; > > The last part of the action tries to run scanbuttond when the scanner is > turned on. =A0That can be removed if you don't use scanbuttond. > > =A0 =A0 =A0 action "usb_devaddr=3D`echo $device-name | sed 's#^ugen##'` &= & \ > =A0 =A0 =A0 =A0 =A0 =A0 =A0 chown root:saned /dev/usb/${usb_devaddr}.* &&= \ > =A0 =A0 =A0 =A0 =A0 =A0 =A0 chmod 0660 /dev/usb/${usb_devaddr}.*"; > >> # AAO >> # remove HP ScanJet 3300C >> detach 20 { >> =A0 =A0 =A0device-name "ugen[0-9].[0-9]"; >> =A0 =A0 =A0match "vendor" "0x03f0"; >> =A0 =A0 =A0match "product" "0x0205"; >> =A0 =A0 =A0action "/usr/bin/pkill scanbuttond"; >> }; > > Similarly, the detach isn't needed if you're not running scanbuttond. > I added scanbuttond from ports to be safe :), I just copied your example (not looking that it was customized for epson :( libscanbtnd-backend_epson.so, but I have removed that and left it as you have suggested :) I was glad that it worked and I did not notice that. The good thing is that it* scanner is working and thanks to your kind example/suggestion. Regards, Antonio