diff options
author | Starfall <us@starfall.systems> | 2024-01-08 09:40:24 -0600 |
---|---|---|
committer | Starfall <us@starfall.systems> | 2024-01-08 09:40:24 -0600 |
commit | a91d41375fc87c958f0b4b2ec09d5bfa2bab9414 (patch) | |
tree | 5ecf2d3f5b5962bb2d317ad4ce1fddd88e8b0ed7 /noarch/etc |
Diffstat (limited to 'noarch/etc')
-rwxr-xr-x | noarch/etc/smfp.conf | 222 | ||||
-rwxr-xr-x | noarch/etc/smfp.fdi.in | 30 | ||||
-rwxr-xr-x | noarch/etc/smfp.rules.in | 29 |
3 files changed, 281 insertions, 0 deletions
diff --git a/noarch/etc/smfp.conf b/noarch/etc/smfp.conf new file mode 100755 index 0000000..8a5f12e --- /dev/null +++ b/noarch/etc/smfp.conf @@ -0,0 +1,222 @@ +<?xml version="1.0" ?> +<smfpconfig> + <option name="network" type="enum">yes</option> + <model vendor="samsung" id="clx216x" modelstring="CLX-216x Series"/> + <model vendor="samsung" id="scx4500" modelstring="SCX-4500 Series"/> + <model vendor="samsung" id="clx6200" modelstring="CLX-6200 Series"/> + <model vendor="samsung" id="clx6220" modelstring="CLX-6220 Series"/> + <model vendor="samsung" id="clx6240" modelstring="CLX-6240 Series"/> + <model vendor="samsung" id="scx6x55" modelstring="SCX-6x55 Series"/> + <model vendor="samsung" id="clx3170" modelstring="CLX-3170 Series"/> + <model vendor="samsung" id="scx4500w" modelstring="SCX-4500W Series"/> + <model vendor="samsung" id="scx4x24" modelstring="SCX-4x24 Series"/> + <model vendor="samsung" id="scx4x28" modelstring="SCX-4x28 Series"/> + <model vendor="samsung" id="scx4300" modelstring="SCX-4300 Series"/> + <model vendor="samsung" id="scx5835_5935" modelstring="SCX-5835_5935 Series"/> + <model vendor="samsung" id="scx5635" modelstring="SCX-5635 Series"/> + <model vendor="samsung" id="scx4x26" modelstring="SCX-4x26 Series"/> + <model vendor="samsung" id="scx4600" modelstring="SCX-4600 Series"/> + <model vendor="samsung" id="scx4623" modelstring="SCX-4623 Series"/> + <model vendor="samsung" id="mfp65x" modelstring="MFP 65x Series"/> + <model vendor="samsung" id="clx8380" modelstring="CLX-8380 Series"/> + <model vendor="samsung" id="clx3180" modelstring="CLX-3180 Series"/> + <model vendor="samsung" id="scx6545" modelstring="SCX-6545 Series"/> + <model vendor="samsung" id="mfp560" modelstring="MFP 560 Series" type="usb"> + <hwoption name="twainspec" type="enum">2</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">no</hwoption> + <hwoption name="resolution" type="list" default="150">75 150 200</hwoption> + <hwoption name="colorcompose" type="list" default="gray256">gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="mfp750" modelstring="MFP 750 Series" type="usb"> + <hwoption name="twainspec" type="enum">2</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">no</hwoption> + <hwoption name="resolution" type="list" default="150">75 150 200 300</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx4100" modelstring="SCX-4100 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">no</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter statement + a5 a5_extra b5 b5_extra b5_jis + executive quatro + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx4200" modelstring="SCX-4200 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">no</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter statement + a5 a5_extra b5 b5_extra b5_jis + executive quatro + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx4x16" modelstring="SCX-4x16 Series" type="usb"> + <hwoption name="twainspec" type="enum">1</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 150 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx4x20" modelstring="SCX-4x20 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx5x30" modelstring="SCX-5x30 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">2000</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="clx3160" modelstring="CLX-3160 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">2000</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx4x21" modelstring="SCX-4x21 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx4725" modelstring="SCX-4725 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">simplex</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> + <model vendor="samsung" id="scx6x20" modelstring="SCX-6x20 Series" type="usb"> + <hwoption name="twainspec" type="enum">3</hwoption> + <hwoption name="sleep_after_scan_ms" type="int">0</hwoption> + <hwoption name="adf" type="enum">duplex</hwoption> + <hwoption name="flatbed" type="enum">yes</hwoption> + <hwoption name="resolution" type="list" default="300">75 100 150 200 300 600</hwoption> + <hwoption name="colorcompose" type="list" default="color24bit">color24bit gray256 bw_halftone bw_lineart</hwoption> + <hwoption name="pageformat" type="list" default="a4"> + a4 letter legal statement folio + a5 a5_extra b5 b5_extra b5_jis + executive quatro letter_plus a4_plus + envelope_9 envelope_10 envelope_11 envelope_12 + envelope_14 envelope_b5 envelope_b6 envelope_c5 + envelope_c6 envelope_c6c5 envelope_dl + envelope_110x230 envelope_monarch + custom + </hwoption> + </model> +</smfpconfig> diff --git a/noarch/etc/smfp.fdi.in b/noarch/etc/smfp.fdi.in new file mode 100755 index 0000000..eb34295 --- /dev/null +++ b/noarch/etc/smfp.fdi.in @@ -0,0 +1,30 @@ +<?xml version='1.0' encoding='UTF-8'?> +<deviceinfo version='0.2'> +$(tab 1)<device> +$(tab 1)<!-- /dev/bus/usb/00?/? --> +$(tab 2) <match key='info.bus' string='usb_device'> +$(tab 3) <match key='usb_device.vendor_id' int='0x$VID'> + $(for pid in $PIDS ; do \ + echo "$(tab2 4)<match key='usb_device.product_id' int='0x$pid'>";\ + echo "$(tab2 5)<append key='info.capabilities' type='strlist'>access_control</append>";\ + echo "$(tab2 5)<merge key='access_control.file' type='copy_property'>linux.device_file</merge>" ;\ + echo "$(tab2 5)<merge key='access_control.type' type='string'>scanner</merge>" ;\ + echo "$(tab2 4)</match>";\ + done) +$(tab 3) </match> +$(tab 2) </match> +$(tab 2) <!-- /dev/usb/lp0 --> +$(tab 2) <match key='info.bus' string='usb'> +$(tab 3) <match key='@info.parent:usb.vendor_id' int='0x$VID'> + $(for pid in $PIDS ; do \ + echo "$(tab2 4)<match key='@info.parent:usb.product_id' int='0x$pid'>";\ + echo "$(tab2 5)<append key='info.capabilities' type='strlist'>access_control</append>";\ + echo "$(tab2 5)<merge key='access_control.file' type='copy_property'>linux.device_file</merge>";\ + echo "$(tab2 5)<merge key='access_control.type' type='string'>scanner</merge>";\ + echo "$(tab2 4)</match>";\ + done) +$(tab 3) </match> +$(tab 2) </match> +$(tab 1)</device> +</deviceinfo> + diff --git a/noarch/etc/smfp.rules.in b/noarch/etc/smfp.rules.in new file mode 100755 index 0000000..0d1c1d9 --- /dev/null +++ b/noarch/etc/smfp.rules.in @@ -0,0 +1,29 @@ +# This file is a part of Unified Linux Driver +# Rules to allow low level USB device access for smfpautoconf +# +# For new distributions, +# Permissions and group are set according to common libsane rules +# + +ACTION!=\\"add\\", GOTO=\\"smfp_label_end\\" + +# Check device type +ENV{DEVTYPE}==\\"usb_device\\", GOTO=\\"smfp_create_usb_dev\\" + +# Check SUBSYSTEM (should be either \\"usb\\" or \\"usb_device\\") +SUBSYSTEM==\\"usb\\", GOTO=\\"smfp_create_usb_dev\\" +SUBSYSTEM==\\"usb_device\\", GOTO=\\"smfp_create_usb_dev\\" + +GOTO=\\"smfp_label_end\\" + +LABEL=\\"smfp_create_usb_dev\\" + +# Check Vendor ID +ATTR{idVendor}!=\\"$VID\\", GOTO=\\"smfp_label_end\\" + +$(for pid in $PIDS ; do echo "ATTRS{idProduct}==\\"$pid\\", ENV{libsane_matched}=\\"yes\\"" ; done) + +ENV{libsane_matched}==\\"yes\\", OWNER=\\"root\\", MODE=\\"664\\", GROUP=\\"lp\\" + +LABEL=\\"smfp_label_end\\" + |