mirror of
https://github.com/maziggy/bambuddy.git
synced 2026-10-03 04:31:28 +02:00
The A1 printer's FTP server hangs when Python's storbinary() calls voidresp() to wait for the server's completion response. This caused upload timeouts on A1 and A1 Mini printers. Fix contributed by an A1 user - replaces storbinary() with manual chunked transfer using transfercmd() + sendall(): - Uses 1MB chunks (CHUNK_SIZE constant) for better throughput - Sets explicit 120s socket timeout on data connection - Manually closes connection after transfer, avoiding voidresp() hang Applied to all printer models since the manual approach is compatible with X1C/P1S/P1P as well (transfercmd is what storbinary uses internally).