[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Use Ruby to monitor a printer?

Ak 756

3/27/2007 7:56:00 AM

Hi,everyone!
I want to write a program to monitor a network printer and give
statistic data as whom at what time print how many pages.

Is it possible to do this using Ruby? Which library shall I use to do
this?

--
Posted via http://www.ruby-....

3 Answers

Robert Klemme

3/27/2007 9:27:00 AM

0

On 27.03.2007 09:55, Ak 756 wrote:
> I want to write a program to monitor a network printer and give
> statistic data as whom at what time print how many pages.
>
> Is it possible to do this using Ruby? Which library shall I use to do
> this?

What interface does the printer support? Generally Ruby comes with a
whole bunch of networking support libraries. It really depends on what
your printer offers.

Kind regards

robert

Ak 756

3/27/2007 9:39:00 AM

0

Robert Klemme wrote:
> On 27.03.2007 09:55, Ak 756 wrote:
>> I want to write a program to monitor a network printer and give
>> statistic data as whom at what time print how many pages.
>>
>> Is it possible to do this using Ruby? Which library shall I use to do
>> this?
>
> What interface does the printer support? Generally Ruby comes with a
> whole bunch of networking support libraries. It really depends on what
> your printer offers.
>
> Kind regards
>
> robert

The printer is connected in a Windows2000 server. All the computers in
the local network can reach the printer. The printer is HP LaserJet
1000. I don't know what interface it support. Shall I interface directly
with the printer or through the Win2000 server?

--
Posted via http://www.ruby-....

Richard Conroy

3/27/2007 9:44:00 AM

0

On 3/27/07, Robert Klemme <shortcutter@googlemail.com> wrote:
> On 27.03.2007 09:55, Ak 756 wrote:
> > I want to write a program to monitor a network printer and give
> > statistic data as whom at what time print how many pages.
> >
> > Is it possible to do this using Ruby? Which library shall I use to do
> > this?
>
> What interface does the printer support? Generally Ruby comes with a
> whole bunch of networking support libraries. It really depends on what
> your printer offers.

The best library for monitoring printers is SNMP. All major manufacturers
will support it. There is a ruby-SNMP project, but it leans a lot on
C libraries for basic support of the protocol (like using your printer
manufacturers MIB file).

Alternatively you could scrape the Web UI of the printer, there must be
at least 6 different Ruby libraries for doing this now.