USB to USB flash Drive File Copier


Closed Thread
Results 1 to 40 of 223

Hybrid View

  1. #1
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    hi mackrackit, it been a while..

    about the 2D arrays, i agree. you should get rid of those..its just making things complicated..all you need to do is simply save the file names in arrays of 12 characters like this:
    SERIN2 VinTXD,84,[SKIP 20, WAIT(CRET),STR FILE1\12 \CRET,WAIT(CRET), STR FILE2\12 \CRET,WAIT(CRET),STR FILE3\12 \CRET,WAIT(CRET),STR FILE4\12 \CRET]

    skip 20 is to avoid saving unnecessary prompts such as "device detected" or something like that.

    cret is where i saved $0D (carriage return). files are separated by carriage returns in between them so what i did was wait for its occurrence for me to be able to know when it is the end of a file and the start of another so that i can save it to another array.

    if you want to view a new batch of files, do something like this:
    SERIN2 VinTXD,84,[WAITSTR FILE4\12, WAIT(CRET), STR FILE1\12 \CRET,WAIT(CRET), STR FILE2\12 \CRET,WAIT(CRET),STR FILE3\12 \CRET,WAIT(CRET),STR FILE4\12 \CRET,WAIT(CRET)]

    you will then receive a new set of file names saved in FILE1 to FILE4.

  2. #2
    Join Date
    Mar 2010
    Posts
    40


    Did you find this post helpful? Yes | No

    Default

    hi,
    may i ask..if i wan to use battery to replace the power supply, what battery to recommend?

  3. #3
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by fokus_1116 View Post
    hi,
    may i ask..if i wan to use battery to replace the power supply, what battery to recommend?
    That is a difficult one to answer.
    The VDIP requires 5 volts. Four re-chargeable "AA" batteries will give ~4.8 volts, close enough but for how long. Then if someone were to use regular batteries now there is ~6 volts present, not good, the MCU will "smoke".

    Could use a 7805 regulator with a ~9 volt or higher battery pack but then you need to carry around a "brick" of batteries. And the 7805 requires a heat sink and is not the most efficient thing out there, reliable yes... LM317 could also be used but has some of the same problems.

    You may want to use a switching regulator. Could have one that works with a battery input from 3 to 6 volts, then four "AA" batteries of any type will work. Depending on the circuit the efficiency can be very good.

    Not knowing the load of the finished project, you may not know yet either, the best I caqn do is point you here
    http://www.national.com/analog
    Look at the "WEBENCH DESIGNER". Input your parameters and see what come up.

    I have also hear some talk about off the shelf DC to DC converters.
    Dave
    Always wear safety glasses while programming.

  4. #4
    Join Date
    Jan 2009
    Location
    California, USA
    Posts
    323


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mackrackit View Post
    That is a difficult one to answer.
    The VDIP requires 5 volts. Four re-chargeable "AA" batteries will give ~4.8 volts, close enough but for how long.
    Be cautious with your battery types here... 4 NiCad AA's will give about 4.8v, but 4 rechargeable ALKALINE AA's can give over 5.6V +

    For linear regulators, these aren't too bad...
    http://ww1.microchip.com/downloads/e...Doc/21991c.pdf
    Only a couple hundred mV dropout voltage, so they work OK on 5 v circuits from a 6v battery.

    You may want to use a switching regulator. Could have one that works with a battery input from 3 to 6 volts, then four "AA" batteries of any type will work. Depending on the circuit the efficiency can be very good.
    If you need to run off a wide supply range, including sucking batteries down "to the last drop" then a good switching supply is THE way to go....


    steve

  5. #5
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default

    Byte_Butcher, Where do you find rechargable ALKALINE AA's ? I have never heard of such a thing.... I'm curious...

    Dave Purola,
    N8NTA

  6. #6
    Join Date
    Jan 2009
    Location
    California, USA
    Posts
    323


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Dave View Post
    Byte_Butcher, Where do you find rechargable ALKALINE AA's ? I have never heard of such a thing.... I'm curious...
    /Cough/ err... well, they do exist, and a quick google search should find you some. But I was MISTAKEN about the ones that I have. I was sure it said Alkaline on the package when I got them, but on closer inspection, these say NiMH on the side of the battery.

    So I guess I meant to say that" 4 rechargeable NiMH AA's can give over 5.6V +" Sorry...

    steve

  7. #7
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    What is the brand of the NiMH and AH of the batteries you use?
    The NiMH I use are 1.2 volts at 2500 AH.
    Dave
    Always wear safety glasses while programming.

Similar Threads

  1. USB CDC Communications for Dummies!
    By Squibcakes in forum USB
    Replies: 104
    Last Post: - 15th January 2014, 13:43
  2. How to drive the Vinculum VDIP1 in UART mode
    By BrianT in forum Code Examples
    Replies: 41
    Last Post: - 23rd May 2013, 12:34
  3. Simple USB Comms Problem
    By awmt102 in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 6th January 2010, 20:17
  4. USB-FTDI[UM232R] with PIC16f877a
    By bjox in forum USB
    Replies: 1
    Last Post: - 23rd February 2008, 22:40
  5. PICs and USB Flash Drives
    By The Master in forum USB
    Replies: 2
    Last Post: - 23rd October 2007, 10:23

Members who have read this thread : 0

You do not have permission to view the list of names.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts