Hallo Leute, ich möchte auf einer SD Karte eine .txt anlegen. Ich verwende das FAT32 Dateisystem von elm chan. Das Formatieren der SD Karte auf FAT32 sowie das Anlegen eines Ordners funktionieren ohne Problem, jedoch nicht das Erstellen einer .txt Datei. Kann mir einer weiterhelfen? FATFS Fatfs[_DRIVES]; /* File system object for each logical drive */ FIL File1; /* File objects */ /* Initialize logical drive */ f_mount(0, &Fatfs[0]); /* Create file system */ f_mkfs(0, 0, 512); f_mkdir("100602_wast_log\0"); // Ordner anlegen f_open(&File1, "log.txt", FA_CREATE_ALWAYS | FA_WRITE | FA_READ); f_printf(&File1, "%6d", -200); f_close(&File1); /* Unregister work area prior to discard it */ f_mount(0, NULL); Vielen Dank schonmal. Grüße Stefan Wackwitz
Hallo, ich war wohl zu ungeduldig, es funktioniert doch! Ich hatte ein Problem mit dem Stack... Grüße Stefan
Bitte melde dich an um einen Beitrag zu schreiben. Anmeldung ist kostenlos und dauert nur eine Minute.
Bestehender Account
Schon ein Account bei Google/GoogleMail? Keine Anmeldung erforderlich!
Mit Google-Account einloggen
Mit Google-Account einloggen
Noch kein Account? Hier anmelden.