SD card reader
Klap
Posts: 65
I need some help involving the SD Card Adapter.
I just got an SD card adapter and have been playing with it for over a few days. I got a lot of help from the fsrw-and-friend file which I downloaded off of the parallax forum. I do not have a TV connection so I rewrote some of the code to work on the Serial Terminal. I got the code to work last night so it could Identify the SD card I was using and read/write files. Then this morning I made some more adjustments and I could not get the program to work again. I spend 5 hours straight trying to undo what I did and rewrote everything again from scratch but could not find the problem. I know it has got to be something simple because I got it working just yesterday in less than an hour. This is driving me crazy. If anyone could look over my code I would really appreciate it. I am including all of the code I have writing and also a readme file containing all of the work I have been doing and all of my notes about how to use my files.
Thank you ahead of time,
Aaron Klapheck
www.AaronKlapheck.com
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I just got an SD card adapter and have been playing with it for over a few days. I got a lot of help from the fsrw-and-friend file which I downloaded off of the parallax forum. I do not have a TV connection so I rewrote some of the code to work on the Serial Terminal. I got the code to work last night so it could Identify the SD card I was using and read/write files. Then this morning I made some more adjustments and I could not get the program to work again. I spend 5 hours straight trying to undo what I did and rewrote everything again from scratch but could not find the problem. I know it has got to be something simple because I got it working just yesterday in less than an hour. This is driving me crazy. If anyone could look over my code I would really appreciate it. I am including all of the code I have writing and also a readme file containing all of the work I have been doing and all of my notes about how to use my files.
Thank you ahead of time,
Aaron Klapheck
www.AaronKlapheck.com
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
zip
314K
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
·······
······· "What do you mean, it doesn't have any tubes?"
······· "No such thing as a dumb question" unless it's on the internet
········
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
have a look at thread http://forums.parallax.com/forums/default.aspx?f=25&m=338494 . Search for PASMStore.zip which currently is in the last post.
There I also used the fsrw object without TV but with Serial interface. I don't see why you had to change the fsrw.
Just a thought here - did the SD card get corrupted - Do you need to reformat it ?
Regards,
John
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
'Necessity is the mother of invention'
Those who can, do.Those who can’t, teach.
Quattro has a good point. Sometimes if a file isn't formally closed out, the whole SD card will become unusable until it is reformatted. When I first started using SD cards, I had to reformat the card almost every time after running a program to debug it, otherwise the Propeller would get hung up because (I guess) it was waiting for the corrupted SD card to respond. In one case the card got so messed up, reformatting was impossible and I had to start with a fresh card. Make sure you are closing out each file properly before shutting off power or trying to start new files, etc.
good luck,
Mark
You might try starting with a copy of FemtoBASIC (DongleBASIC) for use with serial.
This will allow you to confirm that your card/interface is working correctly, then move
back to dong your own code.
OBC
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
New to the Propeller?
Visit the: The Propeller Pages @ Warranty Void.
Have yet to find out why this happens.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
For me, the past is not over yet.
Dos does a max of 2 gig right?? I have a 4 gig SD Card, would it still work?
k.
http://forums.parallax.com/showthread.php?p=746666
Jonathan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
lonesock
Piranha are people too.
I can't believe I wasted all of my time on this one stupid error. My code was perfect, my SD card was perfect, all of my electrical connections were also correct. All of this time the problem was that uController.com sold me a defective product! I took a quick look at the schematics for the uController SD Card Adapter and took a closer look at the hardware they used. As I was doing this I noticed that there was a small spherical metallic ball near one of the pins. After using uControllers products ONE TIME one of their wields came loose. After re-welding the pin back to the board the all of my programs worked perfectly. There is always at least a one in a thousand chance of getting a defective product. It seems as though everyone else has a good working product from uController so I suppose that in this case I was that one thousandth person. If a large amount of others have had the same problem though then perhaps uController is loosing their touch.
Thanks for your ideas on reformatting though. I will keep those in mind when I use the SD card.
uController stuff is generally solid and of good quality.
You might have gotten the "unlucky" board.
OBC
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
New to the Propeller?
Visit the: The Propeller Pages @ Warranty Void.
(1) The basepin terminology is confusing: You have to figure out which pin is the base pin then you have to figure out which way the pin numbers are increasing: for example you may have the right base pin but if you flip the SD Card Adapter around then the pins will not line up to the code. In addition to that if a person was to make their own connect to the SD card then they may not have the pins line up the exact same way. Lining up the clk pin to the clk pin, the do pin to the do pin, etc. I think would be much easier to understand.
(2) I am using the Serial Terminal so I had to at least edit the top file.
(3) The naming system for the files I thought was very confusing. I am an ME so it took me a while to understand everything that was going on and how to use the programs. I always try to dumb my code down so that I will remember what I am doing when I come back to this several years from now.
I will be working on finishing up writing my code today or tomorrow and will post is shortly after. I hope others will find it as useful as I do.
Please contact me privately if there's anything I can do to make up for the defective part.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Brian
uController.com - home of SpinStudio - the modular Development system for the Propeller
PropNIC - Add ethernet ability to your Propeller! PropJoy - Plug in a joystick and play some games!
SD card Adapter - mass storage for the masses Audio/Video adapter add composite video and sound to your Proto Board
The SD Card Adapter I am using is a surface mount (not a through hole). A through hole would definitely be more stable, but I am not sure if the cost of building it would be prohibitive. The amount of solder used, although small, I believe is adequate. All of the other connects are in solid condition. If I am the only person who has had a problem with it then as I mentioned I am probably the one in a thousandth person who got the bad product.
http://forums.parallax.com/forums/default.aspx?f=25&m=339479
I am glad you got to the bottom of it. I know Brian (uController) would like to know the details as he has a great product and would like to ensure that this does not happen again..
Regards,
John Twomey
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
'Necessity is the mother of invention'
Those who can, do.Those who can’t, teach.