If you have to stick with 15*13 px grid, I'm fine with it. Even if some icons are not so recognizable, since there is the name in the header, it's great.
Btw the blinking square is fine enough.
class tinyFAT
{
public:
_master_boot_record MBR;
_boot_sector BS;
_directory_entry DE;
_current_file currFile;
unsigned long firstDirSector;
byte buffer[512];
class tinyFAT
{
public:
_master_boot_record MBR;
_boot_sector BS;
_directory_entry DE;
unsigned long firstDirSector;
byte *buffer;
Sorunome wrote:@Jonnection: literately every single time i tried file.writeLn no matter what it contained.
#include <tinyFAT.h> //requires the tinyFAT library. You can download it here : http://www.henningkarlsen.com/electronics/library.php?id=37
#include <avr/pgmspace.h>
#include <SPI.h>
#include <Gamebuino.h>
Gamebuino gb;
byte res;
void setup() {
gb.begin();
file.initFAT();
gb.display.clear();
gb.display.print(F("Deleting old file...\n"));
gb.display.update();
if(file.exists("test.txt")){
file.delFile("test.txt");
}
file.create("test.txt");
res=file.openFile("test.txt", FILEMODE_TEXT_WRITE);
if(res==NO_ERROR){
gb.display.print(F("Writing to file...\n"));
gb.display.update();
file.writeLn("Hello World!");
file.closeFile();
gb.display.print(F("Done writing to file!\n"));
gb.display.update();
}else{
gb.display.print(F("Error opening file!\n"));
gb.display.update();
}
while(true); // infinite pause
}
void loop() {
// put your main code here, to run repeatedly:
}
Return to Software Development
Users browsing this forum: No registered users and 50 guests