Shop OBEX P1 Docs P2 Docs Learn Events
Help with Flash Drive Interface — Parallax Forums

Help with Flash Drive Interface

On my circuit board, I'm currently using an SD card socket with the FSRW driver to update the Propeller Firmware. This works fine.

I'd like to switch to a standard Flash Drive interface to do the same thing.

Can someone suggest and easy way to do this? Wish a simple circuit and driver?

Thank you for your help.

Jim

Comments

  • JonnyMacJonnyMac Posts: 9,104
    edited 2017-03-17 14:03
    When you say "flash drive" do you mean a USB thumb drive? If yes, I think you'll need an intermediary because the P1 is unable to be a USB host (I think that changes in the P2).

    Parallax used to carry a board that was a serial-to-flash-drive interface. I looked online, but couldn't find it -- it may still be in their catalog; I just didn't see it.
  • I used to use USB thumb drives in a couple projects but the adapters I used were really picky about which thumb drives it could use.

    I only found a couple 2GB drives which worked with the adapter. I think I had adapters with out of date firmware because others on the forum have had good results using a variety of thumb drives.

    I never worried about trying to upgrade the firmware on my adapter boards since SD cards worked so well.

    Do you have a particular reason you don't want to use SD cards? IMO, SD cards work better with the Propeller than USB thumb drives.
  • MikeDYurMikeDYur Posts: 2,176
    edited 2017-03-17 14:55
    The Memory Stick Datalogger (#27937) is what your looking for. Not sure if it's EOL.

    Takes two less pins than an SD interface.
  • Yup, it's discontinued.
  • I toyed with a Vinculum V2DIP1-32, which as I recall worked okay when using serial UART, but I had no success using it with SPI or parallel, and even ending up bricking a thumb drive with my attempts. I abandoned it in favor of SD cards.
  • You can still buy that interface by looking for the FTDI VDRIVE2 from Digikey etc. I used it extensively with the Bs2 for data loggers. The command set indeed finicky, but manageable and I never had issues with particular USB sticks. I do prefer the SD card with the Prop.
  • Thank you for all your good feedback.

    I also prefer the SD card interface. Very reliable and fairly easy to use.

    I need to switch to the Thumb Drive because I want to email a file to a customer and have them copy it to their thumb drive. Then plug it in and update the Prop firmware. Many customers aren't familiar with or don't have an SD card.

    I'm using the Vinculum VDIP1-32 to read a Kensington Trackball, and it works great. I had to figure out the output myself, so I don't trust it for anything more complex.

    Do you know if the VDRIVE2 uses the same chip as the Datalogger? I can probably get the schematic. I don't mind laying out the components on my board, so I can go with anything that works reliably.

    If one of you can recommend a setup with support code, that will really help.

    Tracy, you said you used the VDRIVE2. Can you dig up the code you used?

    Thanks again for your help.

    Jim
  • The VDRIVE2 uses the vinculum2 chip, but it works with the same command set as the VDRIVE1 or the original Parallax #27937 memory stick data logger. I don't recall having to make any firmware changes when upgrading. I should mention that I always included a means for the µP to turn the power on and off to the VDRIVE. That is the most reliable way to get it into a known state and in my apps it was necessary for conserving battery life.

    I haven't used the VDRIVE2 for upgrading Prop or Stamp firmware, only for data logging. Although, it shouldn't be too hard to implement a nice upgrade feature.

  • I still have the #27937 stick data logger. It used a FTDI VNC1L. See the data sheet 7.1 example
  • There is a spin file for it on the Obex exchange under Data logger SPI mode
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2017-03-19 02:57
    Get them to buy a USB card read stick, the ones that look like a normal USB Flash drive. The SD card goes in from the side so they plug it into their computer (which I assume doesn't have an SD card reader) just the same as if they plugged in a Flash drive. Load on the file and pull the card out and plug it in. Isn't that about as next to basic as you can get? It seems most people could just as well be Neanderthals, they just can't seem to get beyond basic stick and fire.
  • Thanks again for all the good suggestions.

    Peter. I suggested the SD dongle to my customer. I like it, he prefers just the flash drive. :(

    Bob. I need to read the firmware file from the drive. Can the data logger handle that?

    Tracy. Do you have your code for the Vinculum (and which code you used ON the Vinculum)? I'm already using the V2DIP1-32 on my board, to interface with a Kensington Trackball. That uses the HID interface. I don't mind adding another one to handle the flash drive. I looked at the documentation, and they claim to handle all three of the FAT formats, so I'm encouraged to give it a try.

    Please let me know what you recommend. I'm about to jump into it.

    Thanks!

    Jim
  • Take a look at the FTDI website application modules you might want to go with a Vdrive3 or Vdrive programmer there are several ways to configure the firmware.
  • CH376S is controller for USB read/write module.
    It also seem to use SD-card.

  • I couldn't get my old parallax 27937 to work worth a darn. But my new FTDI Vdrive3 works like a champ. Here is the BS2 code and result.
  • The 27937 drive did actually work with the prop and bs2 as far as running through the program it just didn't write anything to the 4gb USB drive. When I checked it for files on the Windows notepad there where no files. I think the firmware version was too old and didn't work with larger gig USB drives
  • Hi Bob,

    That video is great! It looks like it shouldn't be too hard to make it work on the Prop.

    I looked at your BS2 code. I understand it, but it's not what I'm familiar with. You mentioned that you had it working with the Prop. Do you have the code for that?

    Final question. My only goal at this time is to read a binary file to update the Prop firmware. Does someone have a suggestion for reading and processing the binary data from the drive? When I read from and SD card, I check the file name format. If it's OK then I read 512 byte chunks and store them on the EEPROM as 4 128 byte records. Do you know if reading the binary data instead of text is OK here? Since I'm not writing anything, it shouldn't confuse the data with commands. Right?

    Thank you for all your help. Really appreciated!

    Jim
  • I ran the Vdrive3 with the prop and it worked. Here is the spin file that I got off the Obex along with the result.
  • Thanks Bob. I'll take a look at it. Jim
Sign In or Register to comment.