# Epson Stylus Photo R300 mit Originaltreiber über CUPS (RAW)

# Epson Stylus Photo R300 mit Originaltreiber über CUPS (RAW)

<p class="callout success">Ziel: Den originalen Epson-Treiber unter Windows verwenden und die Druckdaten unverändert über eine CUPS-RAW-Warteschlange an den Drucker weiterleiten.</p>

#### Voraussetzungen

- Windows 11 (64 Bit)
- Raspberry Pi mit installiertem CUPS
- Epson Stylus Photo R300
- 64-Bit-Treiber für den R300

#### 1. Treiber herunterladen

Den Treiber kann man über den Microsoft Update Catalog herunterladen oder im Anhang [5098\_a1b99bb764e2c49ac8170f9e96164a608254a9e5.cab](https://bookstack.familie-boexler.de/attachments/36) : <span class="" data-state="closed">[Microsoft Update Catalog – Epson Stylus Photo R300](https://catalog.update.microsoft.com/Search.aspx?q=Epson+Stylus+Photo+R300&utm_source=chatgpt.com)</span>

#### 2. Treiber in Windows (Driver Store) importieren

PowerShell **als Administrator** öffnen.

In den Treiberordner wechseln:

```powershell
cd "C:\Drivers\EpsonR300"
```

Treiber importieren:

```powershell
pnputil /add-driver ".\prnep00d.inf"
```

Ausgabe prüfen.

```powershell
Treiberpaket wurde erfolgreich hinzugefügt.
Veröffentlichter Name: oem24.inf
```

#### 3. Druckertreiber registrieren

Treiberverwaltung über "**Win + R**" öffnen:

```powershell
printui.exe /s /t2
```

Anschließend:

- Treiber -&gt; Hinzufügen -&gt; Weiter -&gt; x64 -&gt; Weiter -&gt; Datenträger... -&gt; `prnep00d.inf` auswählen

Den Treiber **Epson Stylus Photo R300 (M)** installieren.

Kontrolle:

```
Get-PrinterDriver |
    Where-Object {
        $_.Name -like "*R300*" -or
        $_.Manufacturer -like "*EPSON*"
    } |
    Select-Object Name, Manufacturer, MajorVersion
```

<div class="relative w-full mt-4 mb-1" id="bkmrk--4"><div class=""><div class="contents"><div class="border border-token-border-light border-radius-3xl corner-superellipse/1.1 rounded-3xl"><div class="relative h-full w-full border-radius-3xl bg-(--code-block-surface) corner-superellipse/1.1 overflow-clip rounded-3xl [--code-block-surface:var(--bg-elevated-secondary)] dark:[--code-block-surface:var(--composer-surface-primary)] lxnfua_clipPathFallback"><div class="relative"><div class="h-full min-h-0 min-w-0"><div class="h-full min-h-0 min-w-0"><div class=""><div class="relative"><div class=""><div class="relative z-0 flex max-w-full"></div></div></div></div></div></div></div></div></div></div></div></div><p class="callout info">`pnputil` hat zunächst nur das Paket in den Driver Store gelegt. Über `printui.exe /s /t2` hast du den eigentlichen Druckertreiber anschließend bei der Windows-Druckverwaltung registriert. Genau deshalb erscheint er jetzt bei `Get-PrinterDriver`. Microsoft trennt diese beiden Schritte ebenfalls: Treiberpaket bereitstellen und Druckertreiber installieren/registrieren.</p>

#### 4. Drucker unter Windows hinzufügen

```powershell
$portName = "LPR_Epson_R300_RAW"
$printerServer = "10.10.5.32"
$queueName = "Epson_R300_RAW"

Add-PrinterPort `
    -Name $portName `
    -LprHostAddress $printerServer `
    -LprQueueName $queueName `
    -LprByteCounting
```

#### 5. RAW-Warteschlange in CUPS erstellen

Auf dem Raspberry:

```shell
sudo lpadmin \
    -p Epson_R300_RAW \
    -E \
    -v 'usb://EPSON/Stylus%20Photo%20R300?serial=L13P20502121634580&interface=1' \
    -m raw
```

<div class="relative w-full mt-4 mb-1" id="bkmrk--9"><div class=""></div></div>Freigeben:

```shell
sudo lpadmin \
    -p Epson_R300_RAW \
    -o printer-is-shared=true

sudo cupsctl --share-printers
sudo systemctl restart cups
```

<div class="relative w-full mt-4 mb-1" id="bkmrk--11"><div class=""><div class="contents"><div class="border border-token-border-light border-radius-3xl corner-superellipse/1.1 rounded-3xl"><div class="relative h-full w-full border-radius-3xl bg-(--code-block-surface) corner-superellipse/1.1 overflow-clip rounded-3xl [--code-block-surface:var(--bg-elevated-secondary)] dark:[--code-block-surface:var(--composer-surface-primary)] lxnfua_clipPathFallback"><div class="relative"><div class="h-full min-h-0 min-w-0"><div class="h-full min-h-0 min-w-0"><div class=""><div class="relative"></div></div></div></div></div></div></div></div></div></div>

#### 6. RAW-Warteschlange prüfen

```shell
lpstat -v Epson_R300_RAW
```

<div class="relative w-full mt-4 mb-1" id="bkmrk--14"><div class=""><div class="contents"><div class="border border-token-border-light border-radius-3xl corner-superellipse/1.1 rounded-3xl"><div class="relative h-full w-full border-radius-3xl bg-(--code-block-surface) corner-superellipse/1.1 overflow-clip rounded-3xl [--code-block-surface:var(--bg-elevated-secondary)] dark:[--code-block-surface:var(--composer-surface-primary)] lxnfua_clipPathFallback"><div class="relative"><div class="h-full min-h-0 min-w-0"><div class="h-full min-h-0 min-w-0"><div class=""><div class="relative"></div></div></div></div></div></div></div></div></div></div>Beispiel:

```
device for Epson_R300_RAW:
usb://EPSON/Stylus%20Photo%20R300...
```

<div class="relative w-full mt-4 mb-1" id="bkmrk--16"><div class=""><div class="contents"><div class="relative"><div class="h-full min-h-0 min-w-0"><div class="h-full min-h-0 min-w-0"><div class="border border-token-border-light border-radius-3xl corner-superellipse/1.1 rounded-3xl"><div class="h-full w-full border-radius-3xl bg-(--code-block-surface) corner-superellipse/1.1 overflow-clip rounded-3xl [--code-block-surface:var(--bg-elevated-secondary)] dark:[--code-block-surface:var(--composer-surface-primary)] lxnfua_clipPathFallback"><div class="relative"><div class="pe-11 pt-3"></div></div></div></div></div></div></div></div></div></div>Weitere Informationen:

```
lpstat -l -p Epson_R300_RAW
```

<div class="relative w-full mt-4 mb-1" id="bkmrk--18"><div class=""><div class="contents"><div class="border border-token-border-light border-radius-3xl corner-superellipse/1.1 rounded-3xl"><div class="relative h-full w-full border-radius-3xl bg-(--code-block-surface) corner-superellipse/1.1 overflow-clip rounded-3xl [--code-block-surface:var(--bg-elevated-secondary)] dark:[--code-block-surface:var(--composer-surface-primary)] lxnfua_clipPathFallback"><div class="relative"><div class="h-full min-h-0 min-w-0"><div class="h-full min-h-0 min-w-0"><div class=""><div class="relative"><div class=""></div></div></div></div></div></div></div></div></div></div></div>

#### 7. LPD-Unterstützung aktivieren

Die RAW-Warteschlange wird von Windows per LPR angesprochen. Dafür muss auf dem Raspberry Pi Port **515/TCP** erreichbar sein.

```shell
find /usr/lib/cups -name cups-lpd
```

Vorhandene Units prüfen:

```shell
systemctl list-unit-files | grep -Ei 'cups.*lpd|lpd.*cups'
```

Falls keine Unit vorhanden ist:

```shell
sudo nano /etc/systemd/system/cups-lpd@.service
```

```ini
[Unit]
Description=CUPS LPD Server
Documentation=man:cups-lpd(8)
After=cups.service
Requires=cups.service

[Service]
User=lp
ExecStart=/usr/lib/cups/daemon/cups-lpd -n -o document-format=application/octet-stream
StandardInput=socket
StandardOutput=socket
```

```shell
sudo nano /etc/systemd/system/cups-lpd.socket
```

```ini
[Unit]
Description=CUPS LPD Server Socket

[Socket]
ListenStream=515
Accept=yes

[Install]
WantedBy=sockets.target
```

```shell
sudo systemctl daemon-reload
sudo systemctl enable --now cups-lpd.socket
sudo ss -ltnp | grep ':515'
```

Windows:

```powershell
Test-NetConnection <IP-des-Raspberry> -Port 515
```