Epson L4150 L4160 L4170 Resetter Adjustment Program – Working
# File menu file_menu = tk.Menu(menubar, tearoff=0) menubar.add_cascade(label="File", menu=file_menu) file_menu.add_command(label="Refresh Ports", command=lambda: app.port_combo.configure(values=app.get_serial_ports())) file_menu.add_separator() file_menu.add_command(label="Exit", command=root.quit)
def reset_pad_counter(self): """Reset waste ink pad counter""" if not self.connected: messagebox.showwarning("Warning", "Printer not connected") return if not messagebox.askyesno("Confirm Reset", "WARNING: Resetting the waste ink counter without replacing the\n" "waste ink pads may cause ink leakage and printer damage.\n\n" "Have you replaced the waste ink pads?\n\n" "Proceed with reset?"): return def reset(): self.progress.start() try: # Send reset command response = self.send_command(self.CMD_RESET_COUNTER, 16) if response: self.log_message("Pad counter reset command sent successfully") time.sleep(1) self.get_counters() # Refresh counters messagebox.showinfo("Success", "Waste ink pad counter has been reset!") else: raise Exception("No response from printer") except Exception as e: self.log_message(f"Reset failed: {str(e)}") messagebox.showerror("Error", f"Reset failed: {str(e)}") finally: self.progress.stop() threading.Thread(target=reset, daemon=True).start() Epson L4150 L4160 L4170 Resetter Adjustment Program
# Supported models SUPPORTED_MODELS = { 'L4150': {'family': 'L4150', 'ink_count': 4, 'pad_count': 2}, 'L4160': {'family': 'L4160', 'ink_count': 4, 'pad_count': 2}, 'L4170': {'family': 'L4170', 'ink_count': 4, 'pad_count': 2} } # File menu file_menu = tk