USB to USB flash Drive File Copier


Closed Thread
Page 1 of 6 12345 ... LastLast
Results 1 to 40 of 223
  1. #1
    Join Date
    Dec 2008
    Location
    philippines
    Posts
    5

    Smile USB to USB flash Drive File Copier

    Please help me my thesis is USB to USB file copier with out using Computer
    i had read for compatible IC the VINCULUM
    can you help me i need to use microcontroller the my problem is the source code
    like for the display and commands for how to communicate that both IC can i ask for the codes or sample codes for file transfer and viewing the file tru LCD? thank you hope any one can help me

  2. #2
    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 emildownloads View Post
    Please help me my thesis
    What is your degree going to be in?
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Dec 2008
    Location
    philippines
    Posts
    5


    Did you find this post helpful? Yes | No

    Default reply

    Electronics and commucation engineering
    i am student can you help me for my thesis?

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


    Did you find this post helpful? Yes | No

    Default

    Yes, I and others here will help if you have a direct question, but do not look for someone doing your project for you.

    That being said, I have played with a VDIP1 some and two of them connected to a PIC might do the job.

    BrianT gave a nice starter example here, it is what I used to get started with the VDIP1.
    http://www.picbasic.co.uk/forum/showthread.php?t=7700
    Dave
    Always wear safety glasses while programming.

  5. #5
    Join Date
    Dec 2008
    Location
    philippines
    Posts
    5


    Did you find this post helpful? Yes | No

    Default Thanks

    im sorry
    i mean just a little things to help me
    thank you very much
    can I ask for VNC1L firmware then it is needed to burned it to the IC like PIC microcontroller?
    and it can be burned only for 1 firmware?

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


    Did you find this post helpful? Yes | No

    Default

    I can only talk about the VDIP1 as that is the only one I have used so far.

    The VDIP1 comes with firmware burned in from the factory. The firmware can be modified / customized somewhat.

    Here is a good page to start
    http://www.vinculum.com/

    This page has the different firmwares available
    http://www.vinculum.com/downloads.html#vfirmware

    Near the bottom of that page in applications and utilities. there is a program called
    Vinculum Firmware Customiser (V1.1b)

    This allows to modify some of the main settings of the firmware. Once the firmware has been modified, if using the VDIP1, copy the firmware to the root of a USB "thumb drive". Placs the drive into the VDIP1, at power up the VDIP1 will load the new firmware from the "thumb drive". This all can also be accomplished via serial port connected to the VDIP1 but the flash/thumb drive is so easy.
    Dave
    Always wear safety glasses while programming.

  7. #7
    Join Date
    Dec 2008
    Location
    philippines
    Posts
    5


    Did you find this post helpful? Yes | No

    Default thanks

    thank you mackrackit
    soh it means only 1 firmware can be loaded for every VNCL IC
    for my project that IC to transfer a files and i will put an LCD how can i acmmunicate that it is not easy to put a program on PIC rigth? any way
    how can i use the PIC microcontroller and VNCL IC?
    how they can communicate?
    for VNCL firmware i know it has a free defined commands like in VDFC firmware
    how can i control that commands if I use PIC microcontroller?
    for example i use PIC18F458 how can i configure the output pins of the pic?
    since the VNCL can accept the FIFO, UART or SPI. what is the examples codes for the pic like if i use picbasic commands? can i write the codes to manipulate the commands of VNCL but how can i control it to the pins of PIC microcontoller?
    thanks, , ,

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


    Did you find this post helpful? Yes | No

    Default

    Up in post #4 I gave you a link showing how to WRITE to the VDIP1.

    Here is the code from a project where I am READING from the VDIP1.
    The VDIP1 part looks a lot like the writing example from BrianT. I used his same methods.

    You should be able to connect two VDIP1s to the same PIC and with a little imagination do the copy.

    Have you progrmed a PIC to do anything yet???

    Code:
    '#####################
    '16F877A
    DEFINE OSC 20
    '####################
    @ __config _HS_OSC & _WDT_OFF & _LVP_OFF & _CP_OFF &_BODEN_OFF
    INCLUDE "modedefs.bas"
    
    'LCD SET UP
    DEFINE LCD_DREG     PORTC
    DEFINE LCD_DBIT     0
    DEFINE LCD_RSREG    PORTD
    DEFINE LCD_RSBIT    1
    DEFINE LCD_EREG     PORTD
    DEFINE LCD_EBIT     0
    DEFINE LCD_BITS     4
    DEFINE LCD_LINES    2
    DEFINE LCD_COMMANDUS    2000
    DEFINE LCD_DATAUS   50
    '#####################
    NUMS	VAR	BYTE[16]
    VDAT    VAR BYTE[96]
    X1	VAR	BYTE
    X2	VAR	BYTE
    X3	VAR	BYTE
    X4	VAR	BYTE
    X5	VAR	BYTE
    X6	VAR	BYTE
    X7	VAR	BYTE
    X8	VAR	BYTE
    V1	VAR	BYTE
    V2	VAR	BYTE
    V3	VAR	BYTE
    V4	VAR	BYTE
    V5	VAR	BYTE
    V6	VAR	BYTE
    V7	VAR	BYTE
    V8	VAR	BYTE
    VinRXD  VAR PORTD.7 'DATA TO VDIP
    FLOWIN  VAR PORTD.6 'FLOW CONTROL FROM VDIP
    
    '#####################
    PAUSE 1000
    LCDOUT $FE,1,"MACKRACK"
    LCDOUT $FE,$C0,"IT BV2"
    PAUSE 1000
    
    
    RUN:
    'LCDOUT $FE,1,X1,X2,X3,X4,X5,X6,X7,X8
    SERIN2 PORTB.5,24972,[WAIT("GRAM:"),STR NUMS\8]	'7, Even, INVERTED
    X1 = NUMS[0]
    X2 = NUMS[1]
    X3 = NUMS[2]
    X4 = NUMS[3]
    X5 = NUMS[4]
    X6 = NUMS[5]
    X7 = NUMS[6]
    X8 = NUMS[7]
    HIGH PORTD.2
    PAUSE 100
    LOW PORTD.2
    PAUSE 100
    LCDOUT $FE,1,X1,X2,X3,X4,X5,X6,X7,X8
    PAUSE 100
    
    '#########################
    'START STICK
    HIGH VinRXD
    PAUSE 5
    SEROUT2 PORTB.3, 24972,["MACKRACKIT",13,10]
    SEROUT2 VinRXD,8588,["ECS",13] '7,E = 8588 , TRUE
    HIGH VinRXD
    PAUSEUS 10
    SEROUT2 VinRXD,8588,["IPA",13]
    HIGH VinRXD
    PAUSEUS 10
    WAIT11:
    IF FLOWIN = 1 THEN WAIT11
    SEROUT2 VinRXD,8588,["OPR ",X1,X2,X3,X4,X5,X6,X7,X8,".DAT",13]
    
    WAIT12:
    IF FLOWIN = 1 THEN WAIT12
    SEROUT2 VinRXD,8588,["RDF 1000",13]
    SERIN2 PORTB.4,8588,[STR VDAT\96]
    V1 = VDAT[0]
    V2 = VDAT[1]
    V3 = VDAT[2]
    V4 = VDAT[3]
    V5 = VDAT[4]
    V6 = VDAT[5]
    V7 = VDAT[6]
    V8 = VDAT[7]
    PAUSEUS 10
    
    WAIT13:
    IF FLOWIN = 1 THEN WAIT13
    SEROUT2 VinRXD,8588,["CLF ",X1,X2,X3,X4,X5,X6,X7,X8,".DAT",13]
    WAIT14:
    LCDOUT $FE,1,"FINISH"
    IF FLOWIN = 1 THEN WAIT14
    LCDOUT $FE,1,X1,X2,X3,X4,X5,X6,X7,X8
    LCDOUT $FE,$C0," SENT"
    'SEROUT2 PORTB.3, 24972,[V1,V1,V2,V3,V4,V5,V6,V7,V8,10,13]
    SEROUT2 PORTB.3, 24972,[STR VDAT,10,13]
    SEROUT2 PORTB.3, 24972,["DONE",10,13]
    PAUSE 2000
    GOTO RUN
    Dave
    Always wear safety glasses while programming.

  9. #9
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    guys...what compiler do you use for this code posted above by mackrackit?

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


    Did you find this post helpful? Yes | No

    Default

    I use Pic Basic Pro for the compiler and MPASM for the assembler.
    Dave
    Always wear safety glasses while programming.

  11. #11
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    thanks for the quick reply...

    are these compilers and assemblers downloadable for free? i can only find a demo version and it is just capable of compiling 30 lines.

    could you please give me the procedure on how to program the vinculum(vdip2) using pic microcontroller? i'm kind of confused. will the command set of the vinculum be included in the program that will be burned to the pic just like in the code above? i'm new at this so please help me...thank you very much.

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


    Did you find this post helpful? Yes | No

    Default

    Everything is free except PicBasicPro.

    This sounds like a first project for you. Start with someting like blinking a LED at the push of a switch... Then come back to this, but up in post #4 there is a link showing how to write to the module.
    Dave
    Always wear safety glasses while programming.

  13. #13
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    you are right, this is the first project for me, so i'm really starting from scratch. ive seen post #4 but i have one question, what will i do with that code after compiling it, whats next? will i burn it to the pic? i really need your answer on this to start. thank you.

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


    Did you find this post helpful? Yes | No

    Default

    Most that use Pic Basic are probably writing the code using Micro Code Studio, you can use any text editor though MCS is pretty good.

    When the code is written and the compile button is clicked MCS starts PBP which is a comand line program. PBP will turn the BASIC code into Assembly code. Then either PM or MPASM starts, this is selectable. PM or MPASM will turn the Assembly file into a HEX file.

    The HEX file is what gets written to the PIC.

    To get the HEX into the PIC a piece of hardware called a programmer is used. There are many to pick from. The programmer will have software to control the flow of data into the PIC and read back what was written to verify the code on the PIC.

    Now the PIC is ready to power up and run.

    What all do you have so we can help you get started with some learning code?
    Dave
    Always wear safety glasses while programming.

  15. #15
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    i have downloaded the pbp compiler but its just in a demo, it can only compile 30 lines. do you know any alternative compiler?

    as for the materials that i have, i have here a pic16f877a and a programmer module for that pic. the vdip2 that i have ordered will be arriving soon.

  16. #16
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    please correct me if i'm wrong,

    i will burn the program to the pic, then, i will connect the pic to the vinculum using uart mode. then the pic will be the one to issue commands to the vinculum and there is no need for the 232 connections. is that right?

    also, how i'm i going to apply the vinculum command sets such as WRF and CLF ? will the compiler be able to understand them?

  17. #17
    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 newbie View Post
    please correct me if i'm wrong,

    i will burn the program to the pic, then, i will connect the pic to the vinculum using uart mode. then the pic will be the one to issue commands to the vinculum and there is no need for the 232 connections. is that right?

    also, how i'm i going to apply the vinculum command sets such as WRF and CLF ? will the compiler be able to understand them?
    Have you read the code examples posted here? How to read and write are both here.

    As for a compiler, PBP is the only one I will recommend.
    Practice blinking LEDs with the demo version and other small things first. Then try something bigger later.

    You will not be able to make this work as a first project even if you had the full version of PBP.
    Dave
    Always wear safety glasses while programming.

  18. #18
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    about the shorts programs like the blinking leds, i have done that already. i already know how to program and burn in pic micro controller. my only problem is to connect it to the vdip, since this is my only first time to use the vinculum so.. was i right with this statement? :

    "i will burn the program to the pic, then, i will connect the pic to the vinculum using uart mode. then the pic will be the one to issue commands to the vinculum and there is no need for the 232 connections"

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


    Did you find this post helpful? Yes | No

    Default

    I thought you said this was your first project...

    If you know all the basics and read the examples you would have seen that the RS232 chip is not needed if you are bit banging the serial.
    Dave
    Always wear safety glasses while programming.

  20. #20
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    sorry for the misunderstanding...what I meant was this is my first project using the vinculum not the pic.

    can you please tell me what you know about controlling the vinculum using a pic microcontroller. i need to know more info about this topic.

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


    Did you find this post helpful? Yes | No

    Default

    Pretty much what I have done with these are posted above. The above example is a data logger for a GPS. The link to the post from Brian T has the writing example. You can see on the GPS example how to collect data and save it to the module.

    To be honest, the VDIP thing works well but is a pain in the _ _ _ .
    I purchased two and ended up with one in the logger and the other is collecting dust. The data sheet is hard to follow and if it was not for Brian's post I do not think I could have made it work or would have given up.


    If you are having a specific problem I am sure we can work though it.
    Let us know.
    Dave
    Always wear safety glasses while programming.

  22. #22
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    alright thank you.. i will be working on my project and i will be posting the questions if there will be any problem while doing it (which i know there will )

  23. #23
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    Sir do you think it is possible to connect an external dvd drive to the vdip2? Since it is in usb interface can i write data to the external dvd using the vdip2?

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


    Did you find this post helpful? Yes | No

    Default

    Interesting idea.
    My first thought was no, I do not think it would be possible.
    But if you could find the commands from the drivers that normally run these things then why not??

    I bet it will not be easy....
    Dave
    Always wear safety glasses while programming.

  25. #25
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    so im still gonna be needing driver commands to do it?
    i wasn't as easy as i thought, i was thinking that since it has been converted to a usb interface, it would be able to interact with the vdip just like a flash drive with the writing as the burning to the dvd.

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


    Did you find this post helpful? Yes | No

    Default

    A couple of things off the top of my head that I am sure you will have to send to the burner somehow is
    multi-write ?
    finalize disk ?

    I have never written a burning program for any platform so I am just guessing.
    Dave
    Always wear safety glasses while programming.

  27. #27
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    sir i tried to compile the program that you posted in post no.8, it didn't show any errors but in the middle of assembling the file, the MPASM prompted that there was an error (but didn't say what it is) and the progress bar for the asm file turned red. Did this program work for you? you used 16f877a right?

    about the external dvd drive i will work on that as soon as i get my vdip2 working ... thanks!

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


    Did you find this post helpful? Yes | No

    Default

    Yes, that was a working program, with a 16F877A. Check your project directory and see what the *.ER and *.ERR files have in them.

    A friend brought up the buffering problem with CD burners. Just does not seem like a good project for a PIC.

    And another could be problem... You have to tell the VDIP exactly how many characters you will be sending though it.
    Dave
    Always wear safety glasses while programming.

  29. #29
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    sir this is what was inside the vinculum.err file

    Error[118] C:\PBP\SAMPLES\LABXUSB\VINCULUM.ASM 198 : Overwriting previous address contents (2007)

    what does this mean?

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


    Did you find this post helpful? Yes | No

    Default

    That is from the configuration line in the code.
    Code:
    @ __config _HS_OSC & _WDT_OFF & _LVP_OFF & _CP_OFF &_BODEN_OFF
    Remove or comment out the above line and give it a try.

    This tells about setting the "configs" in your code.
    http://www.picbasic.co.uk/forum/showthread.php?t=543

    You will be better of just writing you own code from scratch and use my code for an example. Then you know how everything is set up.
    Dave
    Always wear safety glasses while programming.

  31. #31
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    the program has been successfully assembled now. Thank you very much.
    I will follow your advice and write my own program from scratch.

    i was just wondering...did you use any simulator software for this program before burning it to the pic or you just burned it to the pic right after successfully assembling it?

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


    Did you find this post helpful? Yes | No

    Default

    I do not use any simulating programs, never ran across one that I trusted except the one built into MPLAB.
    A bread board or two and parts are my simulator
    Dave
    Always wear safety glasses while programming.

  33. #33
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    sir do you use the software hyperterminal with the vdip? Are all the commands applicable for the hyperterminal for issuing commands to the vdip also applicable for vdip uart pic programming?

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


    Did you find this post helpful? Yes | No

    Default

    I do not use hyperterminal much. The serial communicator built into MCS is what I have been using.
    Yes the commands are the same as you would send with a PIC.
    Dave
    Always wear safety glasses while programming.

  35. #35
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    sir can you please explain me this part of your code:

    SEROUT2 PORTB.3, 24972,["MACKRACKIT",13,10]
    SEROUT2 VinRXD,8588,["ECS",13] '7,E = 8588 , TRUE

    what do you mean by the numbers such as 24972 and 8588 in this statement? also 13 and 10...

    Ive been reading the comments in the code but still im confused..

  36. #36
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by newbie View Post
    sir can you please explain me this part of your code:

    SEROUT2 PORTB.3, 24972,["MACKRACKIT",13,10]
    SEROUT2 VinRXD,8588,["ECS",13] '7,E = 8588 , TRUE

    what do you mean by the numbers such as 24972 and 8588 in this statement? also 13 and 10...

    Ive been reading the comments in the code but still im confused..
    13 , 10 are linefeed and return, look at an ascii table for which is which, good thing to study anyway. The number 24972 tells the compiler what baud rate to use, it's in the book, near the back under tables, very near the ascii table . . .hint, hint. . .
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

  37. #37
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    thank you very much for that info...

    have you used the command DIR and then printed the list of files to the the LCD?

  38. #38
    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 newbie View Post
    thank you very much for that info...

    have you used the command DIR and then printed the list of files to the the LCD?
    I was "printing" to a terminal window, but a LCD would work also.
    Dave
    Always wear safety glasses while programming.

  39. #39
    Join Date
    Nov 2009
    Posts
    72


    Did you find this post helpful? Yes | No

    Default

    sir can you please tell me about the whole pin connections of the program back in post #8...

    i could not see in there that you used the tx and rx pins of the pic16f877a..

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


    Did you find this post helpful? Yes | No

    Default

    Well, I did not use the TX/RX pins. I did not use the hardware ports.

    VinRXD VAR PORTD.7 'DATA TO VDIP
    FLOWIN VAR PORTD.6 'FLOW CONTROL FROM VDIP
    and
    PORTB.4 is data from the VDIP.

    The other serial connections are to and from a PC. I was to lazy to rig a keypad so I was using a terminal to send data to the PIC to send commands to the VDIP.

    You do not need to use the hardware serial ports from the PIC for this. SERIN2/SEROUT2 are fine for reading and writing to the VDIP. Have one other pin from the VDIP for FLOW control, this lets the PIC know if the VDIP is ready for another command.

    I never did a schematic for this or I would post it.
    Dave
    Always wear safety glasses while programming.

Closed Thread
Page 1 of 6 12345 ... LastLast

Similar Threads

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