Shop OBEX P1 Docs P2 Docs Learn Events
Reboot when USB plugged IN — Parallax Forums

Reboot when USB plugged IN

Alex.StanfieldAlex.Stanfield Posts: 198
edited 2012-08-31 13:10 in Propeller 1
I'm needing some help on a "Propeller Proto Board USB" (#32812) card.

My system has a serial console which logs information just fine when I have it plugged into the PC with or without a serial terminal running. It also works ok when no PC is attached to the protoboard USB. (I have P30 pulled-up with a 10K resistor)

BUT it gets rebooted whenever I plug a PC into the USB port of the card :frown:.

Any clue for a fix on this?

Thanks in advance
Alex

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2012-08-31 10:12
    That's normal behavior. The fix is to cut the reset line from the USB interface to the Propeller and wire in a jumper instead that you can disconnect when you're not using the PC to download programs.

    The reason it behaves this way is that the PC has to initialize the USB to serial interface on the Proto Board when you plug it in. The initialization process toggles the DTR line which generates a reset. Opening a serial connection to the Protoboard for downloading involves a similar DTR toggle. As far as the Protoboard hardware is concerned, there's no way to distinguish between the two situations.
  • Alex.StanfieldAlex.Stanfield Posts: 198
    edited 2012-08-31 10:21
    Ok Mike, I thought there was a trick to disable this DTR toggling on the PC.

    BTW, Which is the best place to cut the reset line?

    Thanks
    Alex
  • Mike GreenMike Green Posts: 23,101
    edited 2012-08-31 10:32
    You can disable the use of DTR when opening a serial connection to the Protoboard, but you can't disable it when the USB interface is being enumerated (initialized) by the PC.

    I don't have a USB interface Protoboard handy. I'd just trace the connection from the collector of Q1 (labelled RESET on the schematic) to the reset switch (SW2) and the RESn pin of the Propeller on the board and cut it at a convenient point where there's room for a 2-pin header for a jumper. See the schematic for the USB Protoboard.
  • Duane DegnDuane Degn Posts: 10,588
    edited 2012-08-31 13:10
    Alex,

    Here's a picture of the back side of a USB Protoboard.

    attachment.php?attachmentid=95264&d=1346443093

    The switch (solder side) is just out of view, below the bottom of the photo. This picture shows the solder connections of the four pin header I added to the board after cutting out the USB section (to use as a Prop Plug). The top solder connection is the ground pin which I soldered to the ground plane of the board. The next solder spot down is the reset pin which is soldered to the top of the three traces (the reset trace).

    I figure you'd want to cut somewhere on this trace to add your jumper.

    These next two phots show the top of the board. You can see how the USB section fits back into the area it was cut from.
    UsbCutOutFilled110706a.png
    UsbCutOut110706a.png


    Keep in mind the ground pin the the pin farthest from the power connector/switch side of the board. The reset pin is the pin next to the ground pin. The reset trace is the trace the farthest (of the three coming from the USB section) from the switch side of the board.

    This last photo shows my DIY Prop Plug being used on a non-USB Protoboard.

    PseudoPlug110706a.png
    364 x 290 - 254K
    335 x 272 - 244K
    303 x 206 - 165K
    619 x 535 - 774K
Sign In or Register to comment.