Hi,
If my sketch start reading a file from SD, the board simple reset =(
Can any body help me in it?
I´m using the Sdfat lib and IDE 1.5.2 on arduino uno.
The code have 28,302 bytes and several pages
Hi,
If my sketch start reading a file from SD, the board simple reset =(
Can any body help me in it?
I´m using the Sdfat lib and IDE 1.5.2 on arduino uno.
The code have 28,302 bytes and several pages
Can any body help me in it?
Without seeing your code? No.
Hi,
my first 'suspect' usually is memory overflow, another one could be wrong wiring. In the latter case I would expect this already with sd.init.
Maybe u want to check my blog posts on troubleshooting and memory consumption.
http://robertgetzner.com/PersonalWordpress/arduino-sd-storage-troubleshooting-guidline-public-worldwide-collaboration/
http://robertgetzner.com/PersonalWordpress/experiences-with-arduinosd-card-and-memory-consumption-now-it-works/
Best, Robert
PaulS:
Can any body help me in it?
Without seeing your code? No.
The code is very big
If I post only the parts whit SD use, can be?
I think is memory overflow, because if I short the code (remove some functions) while the program is parsing the SD they work right, but if I implement all functions while is parsing, the Arduino restart or freeze. Can I fix this memory problem?
PS: Thanks for documentation, I´m reading right now
If I post only the parts whit SD use, can be?
No. You can use the Additional Options... link to attach the file.
However, if the program IS very large, and you are running it on a UNO, with 2K of SRAM, then the SD class is using 1/4 of that just for the buffer to write to the SD card. And it is very likely that you don't have enough memory.
Can I fix this memory problem?
You could upgrade to a Mega, or you could post your code. Posting your code is cheaper and quicker, but may not be the final solution. Upgrading may be required.
PaulS:
If I post only the parts whit SD use, can be?
No. You can use the Additional Options... link to attach the file.
Paul, Do not take it personally, but I'm developing this commercial device for a client and I'm afraid to provide the code on the internet, I hope you understand me.
PaulS:
However, if the program IS very large, and you are running it on a UNO, with 2K of SRAM, then the SD class is using 1/4 of that just for the buffer to write to the SD card. And it is very likely that you don't have enough memory.
Not only SdFat.h, but LiquidCrystal_I2C.h + wire.h + EEPROMEx.h
PaulS:
You could upgrade to a Mega, or you could post your code. Posting your code is cheaper and quicker, but may not be the final solution. Upgrading may be required.
I´m tested on Mega right now, and works fine, but whit uno I can make it stand alone, using mega will be more expensive.
I will keep brushing bits, if not work I will try it Tutorial: i2c SRAM for the Arduino - Arduino and everything related — LiveJournal
Paul, Do not take it personally, but I'm developing this commercial device for a client and I'm afraid to provide the code on the internet, I hope you understand me.
Sure. If you'd said that up front, I wouldn't have even harped on the code issue.