wifi sd cards
Graham Stabler
Posts: 2,510
I recently heard about these things:
http://uk.eye.fi/
An SD card with built in wifi, normally used as an easy way to get files off a camera. I'm wondering it if might have some applications with the propeller for data capture and the like.
Graham
http://uk.eye.fi/
An SD card with built in wifi, normally used as an easy way to get files off a camera. I'm wondering it if might have some applications with the propeller for data capture and the like.
Graham
Comments
The eyefi is 50 pounds. I might wait for the price to come down a little.
That's really cool, I'd not seen that before. What I like about the eyeFi however is that it will sort of act like another parallel system, I can stick it in my SD based systems and suck off the generated files without any trouble and move it from one system to another, all with no expense of cogs etc. I suppose I could make my own version using a further propeller, not a bad idea but I much prefer wifi to bluetooth for my purposes.
Graham
Bill
http://www.amazon.com/gp/aw/d.html/ref=redir_mdp_mobile/180-9801891-9193100?a=B0002XJ9IY
Seems like this would be an easy way to get data to a computer...
There are a couple rules I've found for the files though.
They must have a image extension, like "jpg".
They must have a number in the file name (like cameras do).
They must be at least 20kB in size.
They must be in a folder such as "DCIM".
Real problem I'm having is that both FSRW and Kye's SD card codes won't open files on this card.
But, I did google up something from Adafruit where they did something similar, so maybe it's possible to make this work...
http://hackaday.com/2013/08/12/hacking-transcend-wifi-sd-cards/
http://haxit.blogspot.ch/2013/08/hacking-transcend-wifi-sd-cards.html
Rayman,
I thought I let you know that the "Eye-Fi 4GB SD Card + Wi-Fi" is on clearance sale at RadioShack for $10.48
http://www.radioshack.com/product/index.jsp?productId=10934904.
I found and purchased one a couple of weeks ago in a local RadioShack.
Thanks for the info on the rules, I had not figured out the "at least 20kB in size" and "have a number in the file name".
Now I know why some files would transfer and others would not.
zappman
Maybe I'll try a different version and see if I can get the Propeller to talk to it....
Being able to hack the Trancend card seems like a real advantage. If you had a lot of free time to play around with it anyway...
Looking at the Toshiba FlashAir now. Claims to be fully SD compliant...
I think I like this one a lot better... Although, it only has the direct link option. This means that I have to connect to it as if it were a wireless access point...
After connecting, I browse to http:\\192.168.0.1 and can see all the files.
One nice thing is that I can see files in the root folder. Also, the files can have any extension.
Was able to use the regular FSRW (from OBEX) to save a ".dat" file and then download it to a computer.
Was able to download a file with a Mac AirBook this way too...
I found this interesting discussion on some "undocumented" features of the card. Maybe you can try some of these and report back?
https://groups.google.com/forum/#!topic/makerbot/Rst5ZIfs5L0
The timeout is a bit of a pain though... Maybe can fix that in the config file too though.
The timeout is a battery saving feature that turns off the wifi after a few minutes. Cycling power brings it back on, but I'd rather have it just stay on...
BTW: Having it join an existing wifi network would be maybe nice too, have to try that as well...
I'm using a PSB board: http://www.rayslogic.com/Propeller/Products/PSB/PSB.htm
You can see in the picture that the SD socket has a metal cover that is grounded and there is also a ground plane under it.
Still, I got reception on a computer in my living room with this setup down in the basement, at least 30 ft away...
I imagine the antenna is right at the outer edge of the card...
I'm even happier with the Toshiba FlashAir now.
After changing the config file, the timeout is now very, very long and I can upload files to the card.
Actually, I tried 4 different file types and only 2 worked (.dat files). A .side and a .png gave "NG" instead of "Success", which I suppose tells you that it didn't work.
It could be that the files were too small. Or, maybe it didn't like the file extension, not sure.
Files went to the root folder, which is good for me, but it looks like you can change that.
I was looking around on the sd card for the config.cgi file, but it's not there... I guess some files are just on the wifi side...
Also, looking around the web I see there's a FlashAir developer forum. Probably more info there.
But, I think I have all I need for now...
One of the limiting things with large C programs is the time taken to download. When you first start writing propeller programs in Spin they work fine, but if the program grows too big the next option is to move to C. But even large C programs (eg more than 500k) get tedious waiting for downloads.
These flash wifi cards could be the answer. If the IDE was coded so it could be told about the flash card, you could do one download of a bootloader program to eeprom using a wired connnection, and from then on, unplug the propeller board. Instead of the IDE searching for a working prop board on com port X, it now is searching for a wifi device. If it finds this, it could do some simple handshaking and all downloads of large programs could happen almost instantly.
Spin programs could be downloaded a lot faster too, and no need for wires. You could even design Propeller boards with no download socket, saving space. Use any prop board with a download socket to program an eeprom just once with a bootloader program that knows about SD cards and put that eeprom in a socket on your new board. Then everything could be done via the wifi connection. Prop tool would need changing though...
It seems that it could be simple to create a helper app that monitors the build folder and copies any new propeller executable files it finds over to the SD card...
Could be nice for robots... Actually, Toshiba gives a list of where this kind of thing could be useful here:
https://flashair-developers.com/en/business/application/
BTW: There are a few other brands of wifi cards out there that might work too...
Does this mean indefinitely?
Edit: Ah, just found it:
Set the automatic time-out period for Wireless LAN functionality.
When the Wireless LAN mode is 4 or 5, the Wireless LAN functionality will stop if other devices are not connecting to the FlashAir for the time specified by this parameter.
The available values are from 60000 to 4294967294, with a default value of 300000. Time is measured in milliseconds.
"FlashAir card versions
There are currently two types of FlashAir cards: FlashAir Class6 and FlashAir W-02 Class10. The main differences between these types are speed and Class10's accelerated wireless LAN communication. Class6 supports firmware version 1.00s and Class10 supports 2.00s which has massively enhanced APIs. Application developers will need to make sure their code supports both versions of the API."
I picked this sdio wifi card in a bargin bin ages ago but it is way beyond my ability to get it to do anything. I cracked it open to see if any of the chips had datasheets on the web, but had no luck. I assume the antenna on this one is the big thick trace along the top edge of the card?
I'm going to order myself one of the flashair cards.
BTW: Mine is 8 GB and class 6.
To start with a simple concept, I wonder if you could have a little batch program that is one line to copy a file? Instead of hitting F10, you would compile and save as a .bin file and then click on the icon for the batch program to transfer. If the windows were kept open, that still might be quicker than an F10 on a large program. At the propeller end just hit the reset button.
Or, slightly fancier, you could keep the download cable connected and the batch program can run a tiny bit of code to toggle the reset line.
re helper programs, say you split a file into two parts - the data file (eg a .bin file) and then a message file. The message file might be just one line of text and it can contain instructions like 'copy download.bin to myprogram_ver4.3.bin'. The message file might be called 'message.txt'. Programs at either end (PC or in Spin) could be looking regularly to see if 'message.txt' exists. If it does, read it, do what it says, then delete it. That could solve the problem of downloading 'myfile.bin' and then a minute later, downloading another 'myfile.bin' with the same filename but newer code because it is harder for a control program to distinguish between the two (unless you use time date stamps, but then you need a clock on the propeller board).
I hope this is simple enough to do with batch programs. Or at worst, very simple command line programs.
Where this would be very handy though is when writing programs that use a lot of graphics - eg touchscreens. With those programs the code might be only 10kb, but it would be associated with icons and pictures that can be megabytes. It is tedious to keep unplugging the SD card all the time, and would be much easier to send that data wirelessly.
I see on ebay they are about $35 with free shipping.
I have to think that a direct cable connection is best for software development, if that is possible.
But, if you have a deployed system, then maybe this gives you an easy way to do firmware upgrades... On startup, your code could check for a specific file on the SD card and program eeprom with it when found...
IIRC it is Mike's code.
I have some modifies copies around, but it works well. In case the original is not available I'll post them.
You need a 64k eeprom at least. Boot loader in the bottom half. Main program is on the upper part.
You can put a file in the sd card and on reboot you can
Update boot loader
Update main program
Run the file without writing eeprom.
Sorry I cannt find the original link at the moment.
Massimo