Installation imprimante

22 risposte [Ultimo contenuto]
Sisco
Offline
Iscritto: 11/04/2015

Bonjour,

De nouveau je sollicite votre aide, je galère pour effectuer l'installation de mon imprimante Brother DCP195C. Après beaucoup de recherches et essais, j'ai trouvé un script d'installation sur le forum d'Ubuntu "https://forum.ubuntu-fr.org/viewtopic.php?id=652931" qui me paraît relativement facile à mettre en oeuvre mais je bloque au niveau de "Note 2 : si vous utilisez Ubuntu version 64 bits, il faut activer le dépôt universe". Etant en version Trisquel 64 bits et comme je ne sais pas du tout ce qu'est le dépôt Universe je n'arrive pas à finaliser ce script.

Merci pour votre aide.

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Ces instructions ne sont sûrement plus valables. http://download.brother.com/welcome/dlf006893/linux-brprinter-installer-2.0.0-1.gz contient un script pour tout installer. Le script en soi est libre. Les licences des pilotes pour l'imprimante et le scanner (installés par le script en question) semblent OK. L'ennui c'est que je ne trouve pas le code source de ces pilotes...

J'espère donc que tu n'installeras ces pilotes qu'après t'être assuré qu'ils respectent tes libertés fondamentales. Si ce n'est pas le cas (et/ou pour ton prochain achat), opte pour une imprimante HP supportée : https://trisquel.info/forum/hp-laserjet-printer-p1005-printer-not-working-trisquel-60#comment-77026

Sisco
Offline
Iscritto: 11/04/2015

Merci Magic Banana pour ton aide, j'ai cherché sur différents sites de Brother le code source et je ne l'ai pas vraiment trouvé. L'adresse suivante renvoi au téléchargement du code source "http://support.brother.com/g/b/downloadhowto.aspx?c=fr&lang=fr&prod=dcp195c_all&os=128&dlid=dlf006680_000&flang=4&type3=576" mais je t'avoue ne pas être plus renseigné.
Peut-être peut tu regarder et me dire ce qu'il en est? Merci.

l'imprimante DCP-195C que j'essaie d'installer est celle que j'utilisais avec Windows et j'aurai aimé pouvoir continuer de l'utiliser avec Trisquel. Si ce n'est pas possible je rachèterai une HP avec un code source compatible.

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

De ce que je comprends, il y a deux systèmes différents d'impression : CUPS (installé par défaut dans Trisquel) et LPR (non installé par défaut mais disponible dans le dépôt). http://support.brother.com/g/b/downloadlist.aspx?c=fr&lang=fr&prod=dcp195c_all&os=128&flang=English propose le téléchargement de pilotes pour les deux systèmes.

Je ne trouve pas les sources du pilote LPR. Mais concentrons-nous sur le pilote CUPS puisqu'il s'agit du système qu'utilise Trisquel par défaut. Le code source semble entièrement disponible (le lien que tu as pointé). Mais "code source" est un bien grand mot puisqu'il semble s'agir que d'un fichier PPD qu'un script (libre) copie à l'endroit qui va bien. Le script ne télécharge rien (comme je le craignais). Bon, il y a aussi un petit programme de configuration, lui aussi libre.

Je ne comprends pas pourquoi le PPD ne serait pas installable depuis le gestionnaire de paquets. Je me dis qu'un PPD générique fait peut-être aussi bien. Que se passe-t-il exactement lorsque tu essaies d'ajouter l'imprimante ? L'utilitaire par défaut n'est pas terrible. Installe donc le paquet "system-config-printer-gnome", par exemple depuis le "Gestionnaire de paquets Synaptic" dans les "Paramètres système". Essaie ensuite d'ajouter l'imprimante depuis cet utilitaire.

Si tu n'y parviens pas, nous essaierons d'exécuter le script cupswrappencdp195c de Brother et donc d'utiliser leur fichier PPD.

Qu'en est-il du scanner ? A-t-il fonctionné tout de suite ? Parce que, cette fois, il n'y a qu'un pilote sur le site de Brother et je ne trouve pas ses sources.

pako543
Offline
Iscritto: 10/04/2015

Juste pour témoignage, j'ai aussi une imprimante brother, un autre modèle, j'ai installé en ligne de commande les drivers linux qu'on trouve ici :
http://support.brother.com/g/b/downloadtop.aspx?c=fr&lang=fr&prod=dcp195c_all
Je ne me rappelle plus si c'était rpm ou deb, j'ai téléchargé "Driver Install Tool". Les lignes de commande pour installer sont indiquées et ça a fonctionné du premier coup sans problèmes.

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Sais-tu si tout ce que le "Driver Install Tool" installe (LPR, CUPSwrapper et le pilote scanner) est libre ? J'ai l'impression que seul CUPSwrapper est libre. Sais-tu si tu tu utilise CUPS ou LPR (ou les deux et je n'ai rien compris) pour imprimer ?

pako543
Offline
Iscritto: 10/04/2015

Salut Magic Banana, je ne sais répondre à tes question, je suis dépassé.
Mon modèle de Brother c'est la MFC-L2700DW
Je viens d'imprimer une page test via le menu imprimante des paramètres systèmes de Trisquel.
Sur la page des résultats une ligne mentionne - Make and Model: Brother MFC-L2700DW for CUPS

Et aussi si ça peut aider, Driver: MFCL2700.PDD Version 1.00

Si vous voulez d'autre test envoyez moi les commandes et j'exécute.

édit : dans synaptic j'ai trouvé ces deux paquets installés :

- mfcl2700dwcupswrapper:i386
Brother MFC-L2700DW CUPS wrapper driver

- mfcl2700dwlpr:i386
Brother MFC-L2700DW LPR driver

Les deux indiquent : (Converted from a rpm package by alien version 8.64.)

Si ça peut aider...

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Make and Model: Brother MFC-L2700DW for CUPS

Tu utilises donc CUPS, le système d'impression installé par défaut dans Trisquel. Ça tombe bien : c'est sur celui là que je suis parti pour aider Sisco.

Les deux paquets que tu listes ont été installés par le script de Brother. Malheureusement, ces paquets ne spécifient pas de licences (je les ai déjà ouverts dans le "Gestionnaire d'archives" pour voir).

pako543
Offline
Iscritto: 10/04/2015

En dessous je colle le Contrat de licence utilisateur final (CLUF), que Brother demande d'accepter avant de télécharger les paquets. L'anglais me saoule, je n'ai pas tout compris, mais ça n'a pas l'air d'ềtre une licence libre.

License Agreement

This Agreement provides terms and conditions for license grant from Brother Industries, Ltd ("Broher"). Brother, who owns all copyrights to the software that is distributed with this Agreement ("Software") to recipients thereof ("User"), for use of the Software. User shall have the right to use the Software only in accordance with the terms and conditions of this Agreement. Any use by User of the Software shall be deemed as its agreement hereto.
Note:
Please click on "I Accept" while holding down "Shift" or right click on "I Accept" and select "Save Target As,,," from the menu.

Brother retains any and all copyrights to the Software. In no case this Agreement shall be construed to assign or otherwise transfer from Brother to User any copyrights or other intellectual property rights to whole or any part of the Software.

Brother grants User a non-exclusive license: to reproduce and/or distribute (via Internet or in any other manner) the Software. Further, Brother grants User a non-exclusive license to modify, alter, translate or otherwise prepare derivative works of the Software and to reproduce and distribute (via Internet or in any other manner) such modification, alteration, translation or other derivative works for any purpose.

The license of the Software from Brother hereunder is granted "AS IS." BROTHER HEREBY DISCLAIMS ANY WARRANTIES WITH RESPECT TO THE SOFTWARE, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO WARRANTY FOR THE QUALITY, MERCHANTABILITY, FITNESS FOR PARTICULAR PURPOSE OR NON-INFRINGEMENT. Brother shall have no liability in contract, tort (including negligence or breach of statutory duty) or otherwise for any interruption of use, loss of data, or for any indirect, incidental, punitive or consequential loss or damage, or for any loss of profit, revenue, data, goodwill or anticipated savings that arises under, out of, or in contemplation of this Agreement or otherwise arises due to any error, inaccuracy or defect in the Software even if Brother has been advised of the possibility of such loss or damage. Further, Brother shall have no liability to disclose and/or distribute the source cord of the Software to User under any circumstances. In no case shall the above license by Brother to modify, alter, translate or otherwise prepare derivative works of the Software be construed as Brother's implied agreement or undertakings to disclose and/or distribute the source cord of the Software.

Sisco
Offline
Iscritto: 11/04/2015

Bonsoir,

Après avoir suivi vos discussions sur ce forum, il apparaît qu'il n'est pas certain que les pilotes pour l'imprimante Brother dcp195c soit libre et dans ce cas il me semble préférable de ne pas l'installer! Dommage car j'ai reçu par courriel une confirmation que le script d'installation que j'avais soumis en début de ticket fonctionne toujours, je vous en fait une copie:

"Bonjour

Ce script marche bien j'ai installé la vieille imprimante de mon épouse
sous GNU/Linux; c'était une Tout-en-un Brother DCP-115C.

Ouvrir un terminal ctrl+alt+t
L'*imprimante ne doit pas être connecter* en USB à l'ordinateur

Si l'imprimante est d'une architecture de 64 bits il faut d'abord
ajouter les paquets faits pour l'architecture 32 bits.

Pour activer Multiarch-­support,
taper la commande suivante:

sudo dpkg --­­add­-architecture i386

puis installer le paquet dont auront besoin les pilotes :
sudo apt-­get install libc6:i386

Ouvrir un terminal (ctrl+alt+t)

Télécharge l'archive dans le Terminal :
wget http://demonipuch.free.fr/brother.tar.gz

Extraire le contenu de l'archive
tar zxvf brother.tar.gz

Se placer dans le dossier brother
cd brother

Accorder le droit d’exécution au fichier install.sh
chmod +x install.sh

Lancer le script
sudo ./install.sh

il faudra à un moment quand le script sera lancé choisir le nom de
l'imprimante et sa référence il y aura une petite fenêtre, valider

connecter l'imprimante en USB
et l'ajouter"

Je me prends encore quelques jours de réflexion pour prendre la décision d'acheter une autre imprimante;

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Lis de nouveau https://trisquel.info/forum/installation-imprimante#comment-93105 et réponds si tu veux mon aide.

Sisco
Offline
Iscritto: 11/04/2015

Bonjour,

Merci Magic Banana de continuer à me proposer ton aide, mais j'ai énormément de difficulté à comprendre tout ce qui se dit sur le forum et je privilégie donc les solutions les plus simples et c'est pour quoi je n'ai pas répondu à ta proposition première, mais j'accepte ton aide bien-sur.

Dans un premier temps je suis allé dans le "Gestionnaire de paquets Synaptic" pour installer le paquet "system-config-printer-gnome"; celui-ci était déjà installé. Ensuite j'ai essayé d'aller dans cet utilitaire mais je n'y suis pas arrivé et je n'ai donc pas pu tenter d'ajouter l'imprimante.
Quand je branche l'imprimante en USB sur l'ordi j'ai une fenêtre qui s'ouvre et qui m'indique d'abord "configuration de l'imprimante" et ensuite "aucun pilote d'imprimante pour Brother DCP-195C". Je clic sur rechercher et bien sur je n'ai pas de réponses.
Si je vais dans "Imprimantes" dans les "paramètres du Menu Applications", j'ai une fenêtre nommée "Localhost" qui s'ouvre, je clic sur ajouter et dans la nouvelle fenêtre le nom de l'imprimante apparaît "Brother DCP195-C(BROE2F368492).
Ensuite je clic sur "suivant" et une nouvele fenêtre s'ouvre en me disant de choisir un pilote depuis la base de donnée ou fournir un fichier PPD ou recherche d'un pilote à télécharger. Si je clic dans la base de données sur Brother, une liste de modèles DCP s'affiche mais pas de modèle DCP-195C. Cette liste me propose un modèle DCP-1200(recommandé) mais je n'ose pas continuer.
Pour ce modèle DCP-1200 il est indiqué 3 pilotes:
1) brother DCP-1200 Foomatic/hl1250[en](recommandé)
2) brother DCP-1200-CUPS+Gutenprint v5.2.10-pre2[en]
3) brother DCP-1200 Foomatic/ljet2p [en].
Pour le scanner je ne l'ai pas encore essayé du fait que je n'ai rien configuré.

Voilà les informations que je peux te donner.

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

À ta place, je suivrais les recommandations : un même pilote peut servir à plusieurs imprimantes.

Si cela ne fonctionne pas, ou pas bien, alors :

  1. Télécharge http://download.brother.com/welcome/dlf006680/dcp195c_cupswrapper_GPL_source_1.1.3-1.tar.gz
  2. Clic droit sur l'archive téléchargée puis "Extraire ici"
  3. Clic droit sur le dossier "dcp195c_cupswrapper_GPL_source_1.1.3-1" qui s'est créé puis "Ouvrir dans un terminal"
  4. Copie-colle 'sh cupswrapper/cupswrapperdcp195c' (sans les apostrophes) puis tape [Entrée] pour exécuter ce script (libre) qui copie le fichier PPD pour ton imprimante dans /usr/share/cups/model/Brother/
  5. Vois si ton imprimante fonctionne et, si ce n'est pas le cas, ajoute-la comme tu as fait précédemment mais spécifie un fichier PPD : celui dans /usr/share/cups/model/Brother/

http://download.brother.com/welcome/dlf006680/dcp195c_cupswrapper_GPL_source_1.1.3-1.tar.gz contient aussi le code (libre) d'un programme de configuration de l'imprimante. Si tu le souhaites, je t'aiderai à compiler ce programme et à l'exécuter.

Sisco
Offline
Iscritto: 11/04/2015

J'ai d'abord suivi les recommandations avec le pilote recommandé mais l'imprimante ne fonctionne pas, quand je lance une page à imprimer l'afficheur de l'imprimante marque "réception des données" mais ensuite elle s'arrête.
Ensuite j'ai téléchargé e ouvert dans un terminal "http://download.brother.com/welcome/dlf006680/dcp195c_cupswrapper_GPL_source_1.1.3-1.tar.gz" mais lorsque je lance le script j'ai l'information suivante qui veut dire il me semble qu'il n'arrive pas à l'ouvrir:

utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$ sh cupswrapper/cupswrapperdcp195c
sh: 0: Can't open cupswrapper/cupswrapperdcp195c
utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Curieux ce message d'erreur. Quoi qu'il en soit, j'ai oublié le 'sudo' :
$ sudo sh cupswrapper/cupswrapperdcp195c
Il te faut, en effet, les permissions nécessaires à l'écriture de fichiers système.

Sisco
Offline
Iscritto: 11/04/2015

Bonjour,

J'ai relancé le script en ajoutant le sudo et j'ai le même message d'erreur:

utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$ sudo sh cupswrapper/cupswrapperdcp195c
[sudo] password for utilisateur:
sh: 0: Can't open cupswrapper/cupswrapperdcp195c
utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

Dans le dossier "dcp195c_cupswrapper_GPL_source_1.1.3-1", as-tu bien un sous-dossier "cupswrapper" qui contient un fichier "cupswrapperdcp195c" ? Par exemple, en ouvrant le terminal comme expliqué précédemment, la commande suivante te montre-t-elle un script (le contenu du fichier "cupswrapperdcp195c" que nous cherchons à exécuter) ?
$ cat cupswrapper/cupswrapperdcp195c

Sisco
Offline
Iscritto: 11/04/2015

J'ai fait la commande "$ cat cupswrapper/cupswrapperdcp195c" et apparemment j'ai un script qui s'affiche! Mais il est souvent inscrit ERROR, je te fais parvenir la copie du script:

utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$ cat cupswrapper/cupswrapperdcp195c
#! /bin/sh
#
# Brother Print filter
# Copyright (C) 2005-2011 Brother. Industries, Ltd.

# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the Free
# Software Foundation; either version 2 of the License, or (at your option)
# any later version.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
# more details.
#
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Software Foundation, Inc., 59 Temple
# Place, Suite 330, Boston, MA 02111-1307 USA
#

printer_model=""dcp195c""
printer_name=`echo $printer_model | tr '[a-z]' '[A-Z]'`
device_name=`echo $printer_name | eval sed -e 's/MFC/MFC-/' -e 's/DCP/DCP-/' -e 's/FAX/FAX-/'`
pcfilename=`echo $printer_name | tr -d '[A-Z]'`
device_model="Printers"
tmp_filter=/var/tmp/brlpdwrapper${printer_model}

if [ -d "/usr/share/cups/model" ]; then
mkdir -p /usr/share/cups/model/Brother
else
mkdir -p /usr/share/ppd/Brother
fi

if [ -d "/usr/share/ppd" ]; then
mkdir -p /usr/share/ppd/Brother
else
mkdir -p /usr/share/cups/model/Brother
fi

if [ "$1" = '-e' ]; then
lpadmin -x ${printer_name}
rm -f /usr/share/cups/model/Brother/brother_${printer_model}_printer_en.ppd
rm -f /usr/share/ppd/Brother/brother_${printer_model}_printer_en.ppd
rm -f /usr/lib/cups/filter/brlpdwrapper${printer_model}
rm -f /usr/lib64/cups/filter/brlpdwrapper${printer_model}
rm -f /opt/brother/${device_model}/${printer_model}/cupswrapper/brcupsconfpt1
# rm -f /usr/local/Brother/${device_model}/${printer_model}/cupswrapper/brcupsconfpt1
if [ -e /etc/init.d/cups ]; then
/etc/init.d/cups restart
elif [ -e /etc/init.d/cupsys ]; then
/etc/init.d/cupsys restart
fi
# /etc/init.d/cups restart
exit 0
fi
if [ "$1" = "-r" ]; then
lpadmin -x ${printer_name}
if [ -e /etc/init.d/cups ]; then
/etc/init.d/cups restart
elif [ -e /etc/init.d/cupsys ]; then
/etc/init.d/cupsys restart
fi
# /etc/init.d/cups restart
exit 0
fi
if [ "$1" = "help" ] || [ "$1" = "-h" ]; then
echo 'option -h : help'
echo ' -i : install'
echo ' -e : uninstall'
echo ' -r : remove printer'
exit 0
fi
#mkdir -p /opt/brother/${device_model}/${printer_model}/filter
#mkdir -p /usr/lib/cups/filter

if [ -e "/opt/brother/${device_model}/${printer_model}/lpd/filter${printer_model}" ]; then
:
else
echo "ERROR : Brother LPD filter is not installed."
fi
rm -f /usr/share/cups/model/Brother/brother_${printer_model}_printer_en.ppd
if [ -d "/usr/share/cups/model" ]; then
ppd_file_name=/usr/share/cups/model/Brother/brother_${printer_model}_printer_en.ppd
else
ppd_file_name=/usr/share/ppd/Brother/brother_${printer_model}_printer_en.ppd
fi

if [ -e "/opt/brother/${device_model}/${printer_model}/cupswrapper/brother_${printer_model}_printer_en.ppd" ]; then
cp "/opt/brother/${device_model}/${printer_model}/cupswrapper/brother_${printer_model}_printer_en.ppd" $ppd_file_name
else
echo "ERROR : copy failed."
echo "/opt/brother/${device_model}/${printer_model}/cupswrapper/brother_${printer_model}_printer_en.ppd."
echo "/opt/brother/${device_model}/${printer_model}/cupswrapper/brother_${printer_model}_printer_en.ppd"
fi

chmod 644 $ppd_file_name

if [ -d /usr/share/ppd ]
then
if [ -d /usr/share/cups/model ]
then
cp $ppd_file_name /usr/share/ppd/Brother/brother_${printer_model}_printer_en.ppd
chmod 644 /usr/share/ppd/Brother/brother_${printer_model}_printer_en.ppd
fi
fi

#
# create temporary CUPS Filter
#

cat <$tmp_filter
#! /bin/sh
#
# Brother Print filter >>
# Copyright (C) 2005-2011 Brother. Industries, Ltd.
# Ver1.10

# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the Free
# Software Foundation; either version 2 of the License, or (at your option)
# any later version.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
# more details.
#
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Software Foundation, Inc., 59 Temple
# Place, Suite 330, Boston, MA 02111-1307 USA
#

LOGFILE="/dev/null"
LOGLEVEL="1"
LOGCLEVEL="7"
DEBUG=0
NUPENABLE=1
LOG_LATESTONLY=1
errorcode=0

if [ \$DEBUG != 0 ]; then
LOGFILE=/tmp/br_cupsfilter_debug_log
fi

PPDC=\`printenv | grep "PPD="\`
PPDC=\`echo \$PPDC | sed -e 's/PPD=//'\`

if [ "\$PPDC" = "" ]; then
PPDC="/usr/share/cups/model/Brother/brother_${printer_model}_printer_en.ppd"
fi

if [ \$LOGFILE != "/dev/null" ]; then
if [ \$LOG_LATESTONLY == "1" ]; then
rm -f \$LOGFILE
date >\$LOGFILE
else
if [ -e \$LOGFILE ]; then
date >>\$LOGFILE
else
date >\$LOGFILE
fi
fi
echo "arg0 = \$0" >>\$LOGFILE
echo "arg1 = \$1" >>\$LOGFILE
echo "arg2 = \$2" >>\$LOGFILE
echo "arg3 = \$3" >>\$LOGFILE
echo "arg4 = \$4" >>\$LOGFILE
echo "arg5 = \$5" >>\$LOGFILE
echo "arg6 = \$6" >>\$LOGFILE
echo "PPD = \$PPD" >>\$LOGFILE
fi

INPUT_TEMP_PS=\`mktemp /tmp/br_input_ps.XXXXXX\`

nup="cat"
if [ "`echo \$5 | grep 'Nup='`" != '' ] && [ \$NUPENABLE != 0 ]; then

if [ "`echo \$5 | grep 'Nup=64'`" != '' ]; then
nup="psnup -64"
elif [ "`echo \$5 | grep 'Nup=32'`" != '' ]; then
nup="psnup -32"
elif [ "`echo \$5 | grep 'Nup=25'`" != '' ]; then
nup="psnup -25"
elif [ "`echo \$5 | grep 'Nup=16'`" != '' ]; then
nup="psnup -16"
elif [ "`echo \$5 | grep 'Nup=8'`" != '' ]; then
nup="psnup -8"
elif [ "`echo \$5 | grep 'Nup=6'`" != '' ]; then
nup="psnup -6"
elif [ "`echo \$5 | grep 'Nup=4'`" != '' ]; then
nup="psnup -4"
elif [ "`echo \$5 | grep 'Nup=2'`" != '' ]; then
nup="psnup -2"
elif [ "`echo \$5 | grep 'Nup=1'`" != '' ]; then
nup="cat"
fi
echo "NUP=\$nup" >>\$LOGFILE
if [ -e /usr/bin/psnup ]; then
if [ \$# -ge 7 ]; then
cat \$6 | \$nup > \$INPUT_TEMP_PS
else
cat | \$nup > \$INPUT_TEMP_PS
fi
else
if [ \$# -ge 7 ]; then
cp \$6 \$INPUT_TEMP_PS
else
cat > \$INPUT_TEMP_PS
fi
fi
else
if [ \$# -ge 7 ]; then
cp \$6 \$INPUT_TEMP_PS
else
cat > \$INPUT_TEMP_PS
fi
fi
if [ -e "/opt/brother/${device_model}/${printer_model}/lpd/filter${printer_model}" ]; then
:
else
echo "ERROR: /opt/brother/${device_model}/${printer_model}/lpd/filter${printer_model} does not exist" >>\$LOGFILE
errorcode=30
exit
fi

CUPSOPTION=\`echo "\$5 Copies=\$4" | sed -e 's/BrMirror=OFF/MirrorPrint=OFF/' -e 's/BrMirror=ON/MirrorPrint=ON/' -e 's/BrChain/Chain/' -e 's/BrBrightness/Brightness/' -e 's/BrContrast/Contrast/' -e 's/BrHalfCut/HalfCut/' -e 's/BrAutoTapeCut/AutoCut/' -e 's/BrHalftonePattern/Halftone/' -e 's/Binary/Binary/' -e 's/Dither/Dither/' -e 's/ErrorDiffusion/ErrorDiffusion/' -e 's/PageSize/media/' -e 's/BrSheets/Sheets/' -e 's/multiple-document-handling/Collate/' -e 's/separate-documents-collated-copies/ON/' -e 's/separate-documents-uncollated-copies/OFF/'\`
if [ -e "/opt/brother/${device_model}/${printer_model}/cupswrapper/brcupsconfpt1" ]; then
if [ \$DEBUG = 0 ]; then
/opt/brother/${device_model}/${printer_model}/cupswrapper/brcupsconfpt1 ${printer_name} \$PPDC 0 "\$CUPSOPTION" "${printer_model}">> /dev/null
else
/opt/brother/${device_model}/${printer_model}/cupswrapper/brcupsconfpt1 ${printer_name} \$PPDC \$LOGCLEVEL "\$CUPSOPTION" "${printer_model}">>\$LOGFILE
fi
fi

if [ \$DEBUG -lt 10 ]; then
cat \$INPUT_TEMP_PS | /opt/brother/${device_model}/${printer_model}/lpd/filter${printer_model} "\$\$" "CUPS" "USB"

if [ \$LOGLEVEL -gt 2 ]; then
if [ \$LOGFILE != "/dev/null" ]; then
echo "" >>\$LOGFILE
echo " ------PostScript Data-------" >>\$LOGFILE
cat \$INPUT_TEMP_PS >>\$LOGFILE
fi
fi
fi
rm -f \$INPUT_TEMP_PS

exit $errorcode

!ENDOFWFILTER!

chmod 755 $tmp_filter

#
# check /usr/lib/cups/filter
#
if [ -d /usr/lib/cups/filter ]; then
brotherlpdwrapper=/usr/lib/cups/filter/brlpdwrapper${printer_model}
rm -f $brotherlpdwrapper
cp $tmp_filter $brotherlpdwrapper
fi

#
# check /usr/lib64/cups/filter
#
if [ -e /usr/lib64/cups/filter ]; then
brotherlpdwrapper64=/usr/lib64/cups/filter/brlpdwrapper${printer_model}
rm -f $brotherlpdwrapper64
cp $tmp_filter $brotherlpdwrapper64
fi

#
# remove temporary script file
#
rm -f $tmp_filter

chmod a+w /opt/brother/${device_model}/${printer_model}/inf/br${printer_model}rc
chmod a+w /opt/brother/${device_model}/${printer_model}/inf
if [ -e /etc/init.d/lpd ]; then
/etc/init.d/lpd stop
fi
if [ -e /etc/init.d/lprng ]; then
/etc/init.d/lprng stop
fi

if [ -e /etc/init.d/cups ]; then
/etc/init.d/cups restart
elif [ -e /etc/init.d/cupsys ]; then
/etc/init.d/cupsys restart
fi

sleep 2s

port2=`lpinfo -v | grep -i 'usb://Brother/${device_name}' | head -1`
if [ "$port2" = '' ];then
port2=`lpinfo -v | grep 'usb://Brother' | head -1`
fi

if [ "$port2" = '' ];then
port2=`lpinfo -v | grep 'usb://' | head -1`
fi
port=`echo $port2| sed s/direct//g`

if [ "$port" = '' ];then
port=usb:/dev/usb/lp0
fi
#lpadmin -p ${printer_name} -E -v $port -m brother_${printer_model}_printer_en.ppd
lpadmin -p ${printer_name} -E -v $port -P $ppd_file_name

exit 0

utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

C'est bien ce script que nous cherchons à exécuter. Remplace donc 'cat' par 'sudo sh' pour l'exécuter. J'espère qu'auparavant tu avais tout simplement commis une faute de frappe qui expliquerait l'erreur qui t'était renvoyée.

Sisco
Offline
Iscritto: 11/04/2015

Merci Magic Banana pour ton aide mais j'ai beau faire quand je tape:"sudo sh cupswrapper/cupswrapperdcp195c" le terminal m'affiche toujours une erreur dont voici la copie:

utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$ sudo sh cupswrapper/cupswrapperdcp195c
[sudo] password for utilisateur:
ERROR : Brother LPD filter is not installed.
ERROR : copy failed.
/opt/brother/Printers/dcp195c/cupswrapper/brother_dcp195c_printer_en.ppd.
/opt/brother/Printers/dcp195c/cupswrapper/brother_dcp195c_printer_en.ppd
chmod: impossible d'accéder à «/usr/share/cups/model/Brother/brother_dcp195c_printer_en.ppd»: Aucun fichier ou dossier de ce type
cp: impossible d'évaluer «/usr/share/cups/model/Brother/brother_dcp195c_printer_en.ppd»: Aucun fichier ou dossier de ce type
chmod: impossible d'accéder à «/usr/share/ppd/Brother/brother_dcp195c_printer_en.ppd»: Aucun fichier ou dossier de ce type
chmod: impossible d'accéder à «/opt/brother/Printers/dcp195c/inf/brdcp195crc»: Aucun fichier ou dossier de ce type
chmod: impossible d'accéder à «/opt/brother/Printers/dcp195c/inf»: Aucun fichier ou dossier de ce type
* Restarting Common Unix Printing System cupsd [ OK ]
lpadmin: Unable to open PPD file "/usr/share/cups/model/Brother/brother_dcp195c_printer_en.ppd" - Aucun fichier ou dossier de ce type
utilisateur@utilisateur-CR70-2M-CX70-2OC-CX70-2OD:~/Téléchargements/dcp195c_cup
swrapper_GPL_source_1.1.3-1$

Magic Banana

I am a member!

I am a translator!

Offline
Iscritto: 07/24/2010

OK. Donc l'autre fois tu as vraiment du faire une erreur de frappe. Cette fois, tu as une erreur qui vient du script. Et cette erreur ne me plaît guère puisqu'elle indique que "le filtre LPD de Brother n'est pas installé" et que je suppose qu'il est fourni par le pilote LPR dont nous ne trouvons pas les sources.

Voyons si il est réellement nécessaire. Essaie de nouveau d'ajouter l'imprimante mais, cette fois, plutôt que de choisir le pilote recommandé, essaie de spécifier à la main un fichier PPD : celui qui se trouve dans le répertoire "PPD" de http://download.brother.com/welcome/dlf006680/dcp195c_cupswrapper_GPL_source_1.1.3-1.tar.gz (que tu as déjà téléchargé et décompacté).

Sasaki
Offline
Iscritto: 08/11/2014

Salut,

j'ai déjà posté cette question il y a quelques temps, pour le même modèle d'imprimante.

https://trisquel.info/en/forum/brother-dcp-195c-driver-libre

Je confirme qu'en suivant à la lettre les instructions du site de brother il est possible de faire fonctionner sous trisquel l'impression et le scan (je le trouve lent ceci dit).

Je n'ai cependant pas pu vérifier avec certitude la liberté du pilote d'impression, le pilote brscan3, lui, semble libre.

Sisco
Offline
Iscritto: 11/04/2015

Bonjour,

De retour sur le forum, pour que vous m'excusiez de vous avoir laissé sans réponses au conseils que vous m'avez apporté, cela est dû d'abord à un manque de temps et ensuite à une aide plus personnelle par courriel et qui m'a permis de réussir l'installation de mon imprimante Brother DCP-195-C.
J'espère de tout cœur que vous ne m'en tiendrez pas rigueur.

Bien sûr, l'installation de cette imprimante n'a pas été réalisée du premier coup, il fallait trouver les bons pilotes. Je vous envoie ci-dessous la fiche qui a permis son installation.

Merci encore pour votre aide.

Imprimante Brocher DCP-195C sous Trisquel

pilotes imprimantes

.deb à télécharger
http://www.brother.com/cgi-bin/agreement/agreement.cgi?dlfile=http://www.brother.com/pub/bsc/linux/dlf/dcp195clpr-1.1.3-1.i386.deb&lang=English_lpr

http://www.brother.com/cgi-bin/agreement/agreement.cgi?dlfile=http://www.brother.com/pub/bsc/linux/dlf/dcp195ccupswrapper-1.1.3-1.i386.deb&lang=English_gpl

Pilote scanner à télécharger
.deb à télécharger
http://www.brother.com/cgi-bin/agreement/agreement.cgi?dlfile=http://www.brother.com/pub/bsc/linux/dlf/brscan3-0.2.11-4.i386.deb&lang=English_gpl

Clé pilote scanner à télécharger
http://www.brother.com/cgi-bin/agreement/agreement.cgi?dlfile=http://www.brother.com/pub/bsc/linux/dlf/brscan-skey-0.2.4-1.i386.deb&lang=English_lpr

Comme les pilotes sont en 32 bits et ton ordinateur en 64 bits sinon tu l’installes
sudo dpkg --add-architecture i386
puis installer le paquet dont auront besoin les pilotes :
sudo apt-get install libc6:i386

Ton imprimante ne doit pas être branchée en USB
on va créer le Dossier LPD puisque ce pilote drive également certaines imprimantes de ce type
En Terminal
sudo mkdir /var/spool/lpd
sudo mkdir /usr/share/cups/model

tu te places dans le Dossier Téléchargements si les pilotes s’y trouvent
utilisateur@utilisateur
Force l'installation des paquets des pilotes imprimante
$ cd Téléchargements $ sudo dpkg -i --force-all dcp195clpr-1.1.3-1.i386.deb

$ cd Téléchargements $ sudo dpkg -i --force-all dcp195ccupswrapper-1.1.3-1.i386.deb

Contrôle l'installation des paquets : sudo dpkg -l | grep Brother

Le résultat doit être
ii dcp195ccupswrapper 1.0.1-1 Brother CUPS Inkjet Printer Definitions
ii dcp195clpr 1.0.1-1 Brother lpr Inkjet Printer Definitions
Pour le scanner
utilisateur@utilisateur
$ cd Téléchargements $ sudo dpkg -i --force-all brscan3-0.2.11-4.i386.deb
$ cd Téléchargements sudo dpkg -i --force-all brscan-skey-0.2.4-1.i386.deb
Pour voir si tout installé
$ sudo dpkg -l | grep Brother

Branche ton imprimante en usb et ajoute la
LauRent de Ledatux