LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-15-2011, 03:29 PM   #1
matiasar
Member
 
Registered: Nov 2006
Location: Argentina
Distribution: Debian
Posts: 321
Blog Entries: 1

Rep: Reputation: 31
Any idea for a "headless" scan server


I'm setting up a print server (samba+cups) for a small office.
Printer is an HP F380 All-in-one. Linux acts as print server and give service to both windows and Linux workstations. This Box ("server") is gui-less, just CLI and ssh.

I configured also sane and hplip driver in order to the scanner works. Scanner is recognized and I can scan image throgh the tool:

Code:
scanimage > imagen.pnm
What I'd really like to achieve is a headless box, so any person could just press the button "Scan" onto the HP printer and a new file would be available in a directory shared, through samba.

Does anybody know if such solution is possible?
Or there's no other way than installing a wm and rest of gui for scanning?

Thanks in advance, regards,
Matías
 
Old 02-15-2011, 03:54 PM   #2
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004
If anything, can't you use a bash script to automate moving the scanned image? As far as just scanning without any physical input to the system, check this following link out. I can't view it from work; I think it has to do with what you are talking about.

gregable.com/2010/12/network-aware-sheetfed-scanner.html
 
Old 02-16-2011, 07:17 AM   #3
matiasar
Member
 
Registered: Nov 2006
Location: Argentina
Distribution: Debian
Posts: 321

Original Poster
Blog Entries: 1

Rep: Reputation: 31
thanks!

Thanks for your reply and link.
Really the project from the link you provided seems a similar one. Actually I don't plan to use some kind of shetfeed in order to scan a bunch of documentes automaticaly. That would be just great...

Well, today in the morning (everything seems clearer at morning...) I found this this article: http://www.linux.com/archive/feature/59138?theme=print that drived me to http://scanbuttond.sourceforge.net/

Scanbutton seems to be exactly what I was looking for. I'll take a look ant test it.

Regards,
Matías
 
Old 02-16-2011, 11:48 AM   #4
matiasar
Member
 
Registered: Nov 2006
Location: Argentina
Distribution: Debian
Posts: 321

Original Poster
Blog Entries: 1

Rep: Reputation: 31
Unfortunately, both scanbuttond and KScannerbuttons doesn't seem to support the device I'm using (HP Deskjet F380 all-in-one).

I think I'd rather keep on doing some research to see if is there any other way to get if a scanner button was pressed.
 
Old 02-16-2011, 11:56 AM   #5
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004
Yup, that's what you need!

---------- Post added 02-16-11 at 05:57 PM ----------

This is linux, it isn't easy as windows...
 
Old 02-16-2011, 08:08 PM   #6
jefro
Moderator
 
Registered: Mar 2008
Posts: 19,514

Rep: Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017Reputation: 3017
We use a business class HP product that allows one to send scans to a ftp server. You may need to up your scanner if you want features like you posted. I pondered this question and have no other solution.
 
Old 03-03-2011, 11:32 AM   #7
matiasar
Member
 
Registered: Nov 2006
Location: Argentina
Distribution: Debian
Posts: 321

Original Poster
Blog Entries: 1

Rep: Reputation: 31
Well I finally found a workaroung for this issue by building an external button, and connecting to RING signal of an rs-232 port.
Wrote a little program to read the status of that pin, and when it goes high (button pressed) the program trigger the scan script.

Thanks for your help and ideas fellows.
 
Old 03-03-2011, 11:40 AM   #8
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004
Oh nice, glad to hear you got it working man. It's been a while since I worked with any rs-232 communications; does RING have to be grounded to get signal, or am I thinking of another pin?
 
1 members found this post helpful.
Old 03-04-2011, 07:25 AM   #9
matiasar
Member
 
Registered: Nov 2006
Location: Argentina
Distribution: Debian
Posts: 321

Original Poster
Blog Entries: 1

Rep: Reputation: 31
Hello Corp,

For me it was a long time no using rs-232 port too.
So, I chose to use RNG or DCD bits as long as they are "inputs", from modems for example. As far as I know for serial rs-232 signal levels: -12V means Low state and +12V is High state. So I only set RNG bit high when I want to trigger some action, in this case scanning a document.

So the little program I wrote is very simple, it opens a serial port defined by user, and keeps in a loop reading RING bit. When it detects that RNG went to high state it executes the script to do the scan.
My main guide researching on this topic was this book: http://www.easysw.com/~mike/serial/serial.html

If you are interested I could publish the little program (C lang.) somewhere in my blog.

Regards,
Matías
 
Old 03-04-2011, 09:59 AM   #10
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004
That would be awesome if you could, I have a few old computers laying around with serial ports, I would actually like to do something with them.
 
Old 03-04-2011, 04:20 PM   #11
matiasar
Member
 
Registered: Nov 2006
Location: Argentina
Distribution: Debian
Posts: 321

Original Poster
Blog Entries: 1

Rep: Reputation: 31
Sure, I'll publish the little code next week, cos' we have a long weekend (Carnival) here and left the code at work. But as soon as it' published I'll let you know.
 
Old 03-04-2011, 06:03 PM   #12
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004
Sweet, thanks man.

Josh
 
Old 03-09-2011, 08:41 AM   #13
matiasar
Member
 
Registered: Nov 2006
Location: Argentina
Distribution: Debian
Posts: 321

Original Poster
Blog Entries: 1

Rep: Reputation: 31
Notes and code

Hi Josh,

Finally I published the little code and notes here in LQ's blog space:

http://www.linuxquestions.org/questi...232-port-3639/

Hope could be usefull for some applications. And sorry for the languages, both my english and C aren't "pristines".

Regards,
Matías
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
SecurityMetrics scan of CentOS 5 web server is "inconclusive" PopeInnocent Linux - Security 2 06-01-2009 08:35 AM
"foum jump" selection/page layout suggestion/idea akuthia LQ Suggestions & Feedback 6 03-18-2009 07:56 PM
Using society's "eniviro bias" to popularize linux - a viable idea? chickenlinux Linux - General 3 01-13-2009 08:25 PM
svn: "Can't set position pointer in file" - any idea what that means? BrianK Linux - General 1 11-07-2007 04:35 PM
GRUB boot on a "headless system" Gabbiadini Linux - General 3 09-03-2007 03:45 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:12 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration