Some simple Data Logging/Retrieval Questions
crgwbr
Posts: 614
I'm looking at using the memory stick data logger for an industrial application; I just have a few questions:
1. What's the maximum usable size of the USB flash drive?
2. I want to use a Computer app to write a text (.txt) file (composed of 6 decimal numbers and 6 letters) to the drive. When the user removes the drive, and places it in the data logger, can the propeller read the text file and extract the numbers ad letters?
3. When logging data to the flash drive, what format is the file in? (example .txt, .rtf, etc)
4. How much data per second can I put on the drive; if there is a bottleneck, is it at the Vinculum or the flask drive?
Thanks,
Craig
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"... one of the main causes of the fall of the Roman Empire was that, lacking zero, they had no way to indicate successful termination of their C programs." -
"If Python is executable pseudocode, then perl is executable line noise."
"The best accelerator available for a Mac is one that causes it to go at 9.81 m/s2."
"My software never has bugs. It just develops random features."
"Windows isn't a virus, viruses do something."
"Programmers are tools for converting caffeine into code."
"Enter any 11-digit prime number to continue."
1. What's the maximum usable size of the USB flash drive?
2. I want to use a Computer app to write a text (.txt) file (composed of 6 decimal numbers and 6 letters) to the drive. When the user removes the drive, and places it in the data logger, can the propeller read the text file and extract the numbers ad letters?
3. When logging data to the flash drive, what format is the file in? (example .txt, .rtf, etc)
4. How much data per second can I put on the drive; if there is a bottleneck, is it at the Vinculum or the flask drive?
Thanks,
Craig
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"... one of the main causes of the fall of the Roman Empire was that, lacking zero, they had no way to indicate successful termination of their C programs." -
"If Python is executable pseudocode, then perl is executable line noise."
"The best accelerator available for a Mac is one that causes it to go at 9.81 m/s2."
"My software never has bugs. It just develops random features."
"Windows isn't a virus, viruses do something."
"Programmers are tools for converting caffeine into code."
"Enter any 11-digit prime number to continue."
Comments
2 and 3) The Vinculum does not know about the format of the file. As far as it's concerned, it's just a sequence of bytes. It's up to the Propeller or Stamp program to handle that. The Propeller can certainly read the text information and interpret it. The Vinculum doesn't know about text lines. You ask it to supply a certain number of bytes and it provides them so it's easiest if the data in the text file is fixed format (a certain specific number of characters per line including the end of line delimiter(s)).
4) It's variable. If you're using serial I/O to communicate with the Vinculum, the Baud of the serial I/O sets an upper limit to the transfer rate. If you're using SPI, it depends on the Propeller's SPI routines. The Vinculum has a certain amount of buffer space. Once that's full, the bottleneck is the flash drive which has its own buffer space which varies from one flash drive model to another. The Vinculum also has to handle space allocation on the flash drive's file system. If the file is preallocated and contiguous, the Vinculum doesn't have to do extra reads and writes to access it. Remember that the flash drive is still flash memory and sector writes take at least 5ms once the buffers fill up.
Default Baud is 9600. This can be changed to 230KB and above. The FullDuplexSerial driver only goes up to about 230KB.
Internal Vinculum buffer space is less than 4K. There's 4K of SRAM and it's used for multiple purposes.
Post Edited (Mike Green) : 9/18/2007 3:10:59 PM GMT
If your flash drive looks and works like an SD card, that's where I would expect a bottleneck.
The handling of the file system (FAT) is a function of the operating system (or data logger in this case). It's not handled by the flash drive or flash card. The Vinculum chip handles the FAT in this case and we don't know how optimally it does this. Preallocating the file eliminates this concern since the FAT doesn't need to be updated at all.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"... one of the main causes of the fall of the Roman Empire was that, lacking zero, they had no way to indicate successful termination of their C programs." -
"If Python is executable pseudocode, then perl is executable line noise."
"The best accelerator available for a Mac is one that causes it to go at 9.81 m/s2."
"My software never has bugs. It just develops random features."
"Windows isn't a virus, viruses do something."
"Programmers are tools for converting caffeine into code."
"Enter any 11-digit prime number to continue."
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"... one of the main causes of the fall of the Roman Empire was that, lacking zero, they had no way to indicate successful termination of their C programs." -
"If Python is executable pseudocode, then perl is executable line noise."
"The best accelerator available for a Mac is one that causes it to go at 9.81 m/s2."
"My software never has bugs. It just develops random features."
"Windows isn't a virus, viruses do something."
"Programmers are tools for converting caffeine into code."
"Enter any 11-digit prime number to continue."