From deb33df52a9118f0ef45b5ad7d9bdc37737be806 Mon Sep 17 00:00:00 2001 From: Ircama Date: Tue, 29 Aug 2023 21:44:22 +0200 Subject: [PATCH] Refinements --- README.md | 5 +++-- epson_print_conf.py | 8 ++++---- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 6d2cefc..9419dd4 100644 --- a/README.md +++ b/README.md @@ -247,19 +247,20 @@ Example of advanced printer status with an XP-205 printer: 'Emulation 5': 'other', 'Epson Model': 'XP-205 207 Series', 'IP Address': '192.168.1.87', + 'IPP_URL': 'http://192.168.1.87:631/Epson_IPP_Printer', + 'IPP_URL_path': 'Epson_IPP_Printer', 'Lang 1': 'unknown', 'Lang 2': 'ESCPL2', 'Lang 3': 'BDC', 'Lang 4': 'D4', 'Lang 5': 'ESCPR1', + 'MAC Addr': '...', 'MAC Address': '...', 'Model': 'EPSON XP-205 207 Series', 'Model short': 'XP-205 207 Series', 'Name': '....', 'Print input': 'Auto sheet feeder', 'Total printed pages': '0', - 'URL': 'http://192.168.1.87:631/Epson_IPP_Printer', - 'URL_path': 'Epson_IPP_Printer', 'UpTime': '00:57:48', 'WiFi': '....', 'device_id': 'MFG:EPSON;CMD:ESCPL2,BDC,D4,D4PX,ESCPR1;MDL:XP-205 ' diff --git a/epson_print_conf.py b/epson_print_conf.py index c6cb576..4e6e9da 100644 --- a/epson_print_conf.py +++ b/epson_print_conf.py @@ -310,10 +310,10 @@ class EpsonPrinter: #"Total copies": "1.3.6.1.2.1.43.11.1.1.9.1.1", #"Serial number": "1.3.6.1.2.1.43.5.1.1.17.1", "IP Address": "1.3.6.1.4.1.1248.1.1.3.1.4.19.1.3.1", - "URL_path": "1.3.6.1.4.1.1248.1.1.3.1.4.19.1.4.1", - "URL": "1.3.6.1.4.1.1248.1.1.3.1.4.46.1.2.1", + "IPP_URL_path": "1.3.6.1.4.1.1248.1.1.3.1.4.19.1.4.1", + "IPP_URL": "1.3.6.1.4.1.1248.1.1.3.1.4.46.1.2.1", "WiFi": "1.3.6.1.4.1.1248.1.1.3.1.29.2.1.9.0", - "hex_data": "1.3.6.1.4.1.1248.1.1.3.1.1.5.0", + "MAC Addr": "1.3.6.1.4.1.1248.1.1.3.1.1.5.0", "device_id": "1.3.6.1.4.1.11.2.3.9.1.1.7.0", } @@ -998,7 +998,7 @@ class EpsonPrinter: elif name == "UpTime" and result is not False: sys_info[name] = time.strftime( '%H:%M:%S', time.gmtime(int(result)/100)) - elif name == "MAC Address" and result is not False: + elif name.startswith("MAC ") and result is not False: sys_info[name] = result.hex("-").upper() elif isinstance(result, bytes): sys_info[name] = result.decode()