Gcode files are getting corrupted
-
Recently I have had some very large gcode files (218mb) that do not fully print. In troubleshooting the issue, I have downloaded a copy of the file from my maestro only to discover that half the file is not there. The first 2/3rds of the first layer shows up, but then it jumps to the ~300th layer and the rest is fine. This file was not broken when I copied it onto the sd card (I did it manually by putting the SD card into my computer, just in case there was an issue with the web interface uploader), and I have had this happen multiple times with this particular stl. Any thoughts on how I can prevent this from happening in the future? Also, the web interface takes about 25-45min to upload these files. Does that sound normal given that I have it plugged into 100mbps ethernet?
-
If you copy a file to the SD card on a PC, you need to tell the PC to "Eject" or "Safely remove" it, and have confirmation from the PC that it is safe to remove before you pull it out of the socket. Otherwise the PC may still be copying data from its cache to the SD card, even though the file copy is shown as having completed. Also, removing the SD card before the write has completed may result in a corrupted FAT.
I suggest you put the card in a PC and run disk checking tools on it, to check whether the SD card has been corrupted.
Uploading files over the network to a Duet Maestro usually runs at 600 to 800kbytes/sec, although for very large files it may slow down a little. So a 218Mb file should upload in less than 10 minutes. If it is taking longer than that:
- Check that the SD card is formatted with 32kb or 64kb clusters (64kb is best). You can use the M39 command to check.
- Consider buying a better SD card. We suggest choosing a well-known brand with at least a Class 4 speed rating. Format it using 64kb cluster size.
When you upload a file to the SD card over the web interface, the firmware checks the stored file size against the file size reported by DWC, to guard against lost data.