m2tklib
m2tklib copied to clipboard
Need to replace init function by begin function in sample files when using SDFat
What steps will reproduce the problem?
1.using original sample file to access SD content(as per May 26 2014)
2.
3.
What is the expected output? What do you see instead?
- not compiling, "init " function not recognized
What version of the product are you using? On what operating system?
pro micro board, windows 8, Arduino IDE 1.05r2
Please provide any additional information below.
Just need to replace Sdfat.init by sdfat.begin to account for new version of
SDfat library
#if defined(FS_SdFat)
pinMode(SS, OUTPUT); // force the hardware chip select to output
//if (sdfat.init(SPI_HALF_SPEED, 10) ) {
if (sdfat.begin(10, SPI_HALF_SPEED) ) {
Could not actually check if sample worked as sketch is oversized (>34K) anyway.
Thanks for the great job for your U8glib and menu libraries
Original issue reported on code.google.com by [email protected]
on 26 May 2014 at 9:12
What is your version of the SDfat library?
Original comment by [email protected]
on 26 May 2014 at 5:59
Dear Oliver,
My version is sdfatlib20131225 .
In the changes.txt file of SD library, the author mentioned "A key change was
to remove sd.init(spiRateID, chipSelect) in favor of sd.begin(chipSelect,
spiRateID). The difference between these two is the order of the arguments
which has caused serious confusion at times."
BTW, I am the same guy who posted about having issues with M2klib /SD examples
being above 30K on the Arduino forum.
This kind of surprised me as most of the Arduino boards like UNO and so forth
have only 30K available for sketch. I did not see in the forums, any people
commenting about having such issues running your sample sketches.
In my limited understanding of compiler and Arduino, this makes me wonder if my
issues might not have come from an improper Arduino IDE/compiler install
resulting in the compiler loading useless piece of code thus bloating the
memory. What would be your opinion about this ?
Thanks in any case for your great U8Glib and M2Klib libraries.
Cordially,
Francois
Original comment by [email protected]
on 27 May 2014 at 2:30
Thank you for mentioning the change in the sd library. I guess i need to update
the related code in this project.
Task is: Update SDFAT lib and apply changes
Sketch size: To my knowledge only view people use m2tklib. And not too many
people use a SD card. So there are not too many complains.
In fact i developed sd support mainly for a project which as using a atmega644,
with 64K flash. But the main problem is, that each lib requires some amount of
memory and the combination of all three libs (u8glib, m2tklib and sdlib) fills
up all flash ROM in a 32K controller. A Arduino mega board will be a better
choice.
Original comment by [email protected]
on 27 May 2014 at 5:05
- Added labels: Milestone-1.12, Type-Enhancement
- Removed labels: Type-Defect