Shop OBEX P1 Docs P2 Docs Learn Events
Hot-swappable USB connection via PROPPLUG - is it possible? — Parallax Forums

Hot-swappable USB connection via PROPPLUG - is it possible?

DavidMDavidM Posts: 630
edited 2008-09-23 21:34 in Propeller 1
HI,

I have noticed that if you disconnect and reconnect a USB cable into the PROPPLUG (I actually use the USB2SER still!) that the propeller will reset!

Is it possible to have the propplug behave so that if you disconnect a cable and/or reconnect that the propeller does NOT reset?

The reason I want this is to allow HOT SWAPPABLE feature for my users if I were to use a PROPPLUG circuit/device to allow firmware uploading of standard SERIAL Communications.

I am planning on making my own USB to serial type of "propplug" (that will be part of my main circuit) and would like to know how I could achieve this feature

I only want the prop to reset if I were to upload firmware to it.

Thanks

Dave M

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2008-09-23 04:40
    The reset on connect or disconnect is a side effect of the way that the Propeller Tool uses DTR to reset the Propeller for downloading or identification. The way to inhibit this is to put a switch in the reset line from the PropPlug to disconnect the reset line from the Propeller unless you want to use the Propeller Tool.
  • DavidMDavidM Posts: 630
    edited 2008-09-23 04:54
    Hi Mike,

    So I would use some kind "SWITCH" so on my products outside panel that would say "allow firmware update"? if its on then firmware can be installed, if its off ( which disable the DTR ) then the user can "HOTSWAP a usb cable while the prop device is ON?

    Thanks


    Dave M
  • Mike GreenMike Green Posts: 23,101
    edited 2008-09-23 05:02
    Yes
  • DavidMDavidM Posts: 630
    edited 2008-09-23 05:54
    Thanks
    mike


    Dave m
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2008-09-23 15:37
    Dave,

    If customers are using the Prop Plug then they should be able to hot-plug it into the board without causing a reset. The FTDI chip on the Prop Plug causes a reset due to the way devices are detected and enumerated on the bus. Basically the chip is being cycled several times by the USB port, but when you plug it into the board that doesn’t happen. I hope this helps. Take care.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Engineering
  • RaymanRayman Posts: 14,590
    edited 2008-09-23 15:48
    Quite true. Just don't disconnect the USB from the PropPlug and you'll be fine...

    Actually, you should really unplug the PropPlug when not in use because there are several things that can cause the USB connection to make&break causing a reset. EMI can also cause a reset when the PropPlug is connected.
  • DavidMDavidM Posts: 630
    edited 2008-09-23 21:34
    Hi and thanks

    to Chris & Rayman,

    my customers willl not be using a PROPPLUG.

    The "PROPLUG" that I will be devising will be part of the "internals" of my prop powered devices, My users will only see a USB port
    The only option I will enable my users to have is to connect or reconnect a USB cable, they wont know that a prop plug even exists.

    Mike suggested a SWITCH to prevent resetting the prop by disabling the RESET line to the prop, this is probably the easiest/safest option.


    thanks


    Dave M
Sign In or Register to comment.