[Gambas-user] Fwd: Scanner problems
Fabien Bodard
gambas.fr at ...626...
Sun Dec 21 00:22:42 CET 2014
---------- Forwarded message ----------
From: Fabien Bodard <gambas.fr at ...626...>
Date: 2014-12-21 0:22 GMT+01:00
Subject: Re: Scanner problems
To: Jørn Erik Mørne <epost at ...3323...>
2014-12-21 0:20 GMT+01:00 Fabien Bodard <gambas.fr at ...626...>:
> Private hSCan As Scanner
>
>
> Public Sub main()
>
>
> Dim s As String
>
> hSCan = New Scanner("v4l:/dev/video0")
>
> For Each s In hSCan
> If hSCan[s].IsRange Then
> Print "IsRange : ", s, " ", "==>", "min : ", hSCan[s].MinValue,
> "Max :", hSCan[s].MaxValue
Print "IsRange : ", s, " ", "==>", "min : ", hSCan[s].MinValue, "Max
:", hSCan[s].MaxValue, "Units : ", hSCan[s].Unit
> Else
> Print "IsList : ", s, " ", "==>", hSCan[s].List.Join()
> Endif
> Next
>
> End
>
> 2014-12-21 0:12 GMT+01:00 Fabien Bodard <gambas.fr at ...626...>:
>> well... it seem that your scanner don't have Color mode :-)
>>
>> you see options to see what is possible
>>
>> scanimage - A --device-name='smfp:usb;04e8;3413;8J21BAJYA08601M.'
>>
>> can you send me some code ?
>>
>> 2014-12-20 22:56 GMT+01:00 Jørn Erik Mørne <epost at ...3323...>:
>>> Salut Fabien!
>>>
>>> Tried your gb.scanner component today :)
>>>
>>> It would not work, it failed with 'unable to load image'.
>>>
>>> Then I found the Debug option, and it gave me this in the Gambas konsole:
>>> scanimage --device-name=smfp:usb;04e8;3413;8J21BAJYA08601M. --mode=Color
>>> --resolution=300 -p --format=tiff > /tmp/gambas.1000/6888/1.tmp
>>>
>>> When I pasted this in the linux terminal, scanlite says:
>>> scanimage: open of device smfp:usb failed: Invalid argument
>>> bash: 04e8: command not found
>>> bash: 3413: command not found
>>> bash: 8J21BAJYA08601M.: command not found
>>>
>>> I then tried to do this:
>>> scanimage --device-name='smfp:usb;04e8;3413;8J21BAJYA08601M.' --mode=Color
>>> --resolution=300 -p --format=tiff > /tmp/gambas.1000/6888/1.tmp
>>>
>>> Then scanlite says:
>>> scanimage: setting of option --mode failed (Invalid argument)
>>>
>>> Finally, this worked:
>>> scanimage --device-name='smfp:usb;04e8;3413;8J21BAJYA08601M.'
>>> --resolution=300 -p --format=tiff > /tmp/gambas.1000/6629/1.tmp
>>>
>>> --
>>> Kind regards
>>> Jørn Erik
>>
>>
>>
>> --
>> Fabien Bodard
>
>
>
> --
> Fabien Bodard
--
Fabien Bodard
--
Fabien Bodard
More information about the User
mailing list