Main Site Documentation

Copying txt file to SD card


#1

What is the fastest way to copy txt file to SD card on Panda II? I cannot use RS232 shield nor can I connect resistance to Mode pin. I am using my application to generate txt file with config data and then I need to send it to Panda. Every time Panda restarts deployed application will read data from the text file. I’m really out of time, competition is in less than three weeks and there is a lot of work to be done…


#2

Did you check out this post? http://www.tinyclr.com/forum/2/6226/


#3

Déjà vu?


#4

Stack Overflow, Netduino Forums, Elite Security, I totally forgot that I have asked about SD here already…
Ok, Brett lets sum up, just to be sure. Your suggestion is to deploy program number one which will write some data to SD card. Next, program two should be deployed and it will be using previously written txt. I like it. Sorry for posting twice, mod can delete one topic. Thanks.


#5

Yep that was my suggestion - works fine when you’re just in deploy/test/debug mode !


#6

There is one problem. This could work only if I had predefined programs that will be deployed. The idea is that user configures couple of parameters. I will still need to use some programing environment to build that programs.

Back to usb client, could this simple adapter replace rs232 shield
http://www.limundo.com/kupovina/Racunari-i-Oprema/Kablovi/USB-2-0-to-9-Pin-Serial-RS-232-RS232-Adapter/4956531
?


#7

that module will not do what an RS232 shield gives you - the RS232 shield takes a TTL signal (from the Panda) and ends up with a RS232 connection you can connect to the next device. What that thing is is a USB connection that ends up with an RS232.

Sorry, I haven’t played with CDC mode, so I can’t really say I know what the correct end state for you is. If what you need is a TTL UART connection that ends up at a PC, you can use something like this to do the conversion http://www.ebay.com.au/itm/USB-2-0-UART-TTL-6PIN-Module-Serial-Converter-CP2102-/160768254330?pt=AU_Computers_Networking_Accessories&hash=item256e88e17a
But I really only think you need to change away from USB debugging to allow you to set up the device as a mass storage device, if that’s what you want, and that doesn’t require much more than the jumper on the mode pin (which you said you couldn’t use ?) and then at least a pull-up resistor on RX of your selected COM port.

One other possible way to deal with this, if you have a need to permanently allow people to update settings from the PC, is to have this set up with a serial input connection over the CDC port, have your Fez app know about a command set and have an app on the PC that then writes the config to the serial port and the Fez grabs that and writes it to the SD card. That might be less impactful than hijacking MODE and serial debugging?