From cc2e801ec68504c3fba0fa9fdd05de48cff4a354 Mon Sep 17 00:00:00 2001 From: Emanuele Date: Tue, 12 Nov 2019 09:23:01 +0100 Subject: [PATCH] Carica l'immagine di stampa se nello stato viene segnalata memoria vuota --- MkpWIFI/mainDime.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/MkpWIFI/mainDime.py b/MkpWIFI/mainDime.py index 46c6ffb..d8eff60 100644 --- a/MkpWIFI/mainDime.py +++ b/MkpWIFI/mainDime.py @@ -39,7 +39,10 @@ def main(): LOGGER.debug("Timeout stampa") lastAck = False try: - connessa = printer.keepalive() + connessa, statusUpdated = printer.keepalive() + if statusUpdated and printer.headStatus['txt'] == ">> No Label <<": + LOGGER.warning("Immagine di stampa non caricata, invio..") + lastAck = True except RuntimeError as r: LOGGER.error("Stampante Disconnessa") connessa = False