Arduino (C) Bugsmashing help!

Off topicProgramming → Arduino (C) Bugsmashing help!

Right so, im working on an arduino “os”, atm im stuck with annoying SD access shit, basicly an explorer.

Link for the code! : https://github.com/PanFritz/Sheep/ Sorry for the indentation and messy code, copy paste from sublime to arduino IDE and other way around doesnt work very great lol…

Now for the bug shown in a video : https://www.youtube.com/watch?v=as6QBPlXgRg&list=UUgkTFJ4Bk1oFrfOTFvI_VJA Note i realized just now the link was fucked

relevant libraries : SdFat(https://github.com/greiman/SdFat), UTFT(http://www.henningkarlsen.com/electronics/library.php?id=51), and http://forum.arduino.cc/index.php?topic=211131.0 a modificartion for UTFT_tinyFat to use SdFat instead of tinyFat, to allow reading pictures from folders!.

If anyone can spot any problems, mark them down here

Note, if you find any useless pieces of code, point them out, might be things i forgot to delete.

A bit more of an explanation : So chdir() sets the volumes working directory, as you click on a folder it sets the folder as the vwd. Now, the idea i had is to make a char array and store the complete current path there, and before accessing the sd card, make sure thats the vwd and use the chdir function. The problem lies that chdir takes in a char array, wich have set sizes and are annoying as hell to use well. example char path[40] array with the size of 40 bytes, path string “/pics/lol.raw” would then read all the empty bytes! idk… any suggestions?

@redstone_sheep

“nice Video” Is there a markdown for sarcasm? you should use it :D
@ramon156 @dico200 @HiddenSentinels @bela333 pulled from nalaeks list of programmers
@PanFritz i’m not really a Programmer. Well… i’m more like a website coder… but just a little bit xD
Lol sheep, i just realized the yt link was fucked
Ask @Mothership_Q for help on arduino!
Well its more or less C on a bit of a limited computer, but mommy if you can help that would be great <3
So sheep, can you help me again?
Hey? Panda why not squish the bugs? Or find the butterfly in your program.
Yep, he explained something and i fixed it C:, now there is a totaly new bug :(
Nevermind this anymore, i was being stupid and wanted to save RAM. I just opted for 2d arrays to save the day c: Kbai