Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 4 of 4

Thread: Custom board "Download Error" and then chip dies

  1. #1
    Junior Member
    Join Date
    Jul 2013

    Custom board "Download Error" and then chip dies


    I am developing a custom board using the Mini54 bootloader and been having problems downloading programs and eventually the total death of the chip. The symptoms are as follows;

    When power is applied via the USB it is regulated to 3.3V by the MK20DX128.
    When the program button is pushed, the usb port is enumerated and the Teensyduino loader will attempt to download the program (blink) but times out after about 4 seconds and gives the "download error" message. Repeating the process many times, it varies but approximately 20 attempts, the program will sometimes successfully download and then sometimes reboot and run.

    After a undetermined period, some hours, the Mini54 will stop responding to the button push and the reset and program pins no longer have 3.3V on them so I assume the chip has died..

    What I have checked;

    I have run Arduino and the Teensy loader on Mac OSX and Windows with the same affect. Using the same USB cable I have no problem at all programming the Teensy3.

    All connections to the MK20DX128 are as per the Teensy3, except pin numbers due to the package change of the Mini54 (see schematic). I have double/triple checked that all unused pins on the Mini54 are unconnected and that only the pins that should be connected to GND are connected to GND, all of the pins that should be connected to 3V3 are connected to 3V3 and that there are no shorts between pins.

    Initially I thought there were issues with the layout of the USB data lines causing the download error but I have also hard wired the USB connector with nice short, straight wires directly to the 33R resistors which are adjacent to the MCU with no change and this also does not explain the total failure of the chip. Now, I am thinking that I may have damaged the chips, I have destroyed 3 now!, by ESD and they are gradually degrading to death but would love to have some feedback from the knowledgeable people on the forum with any other ideas.

    Click image for larger version. 

Name:	schematic.jpg 
Views:	270 
Size:	68.5 KB 
ID:	1047



  2. #2
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Teensy 3.0 has three 2.2 uF capacitors. I see only 1 on your schematic. The VUSB line really must have at least 1uF.

    Here's the USB 2.0 spec.

    Read section on pages 177-178.

  3. #3
    Senior Member
    Join Date
    Jun 2013
    Torrance CA
    I don't see anything wrong with the schematic with regard to the connection between the Mini54 and the MK20, and since the download process starts when you press the program button my guess is that part's working.

    I do note that you're not using the same crystal layout as Paul's schematic. Do you have the ground connections on it because you're using a resonator? If so, what do the extra capacitors do?

    I also see that you're leaving off all the connections to the analog circuitry. Have you looked at the datasheet to make sure that's ok, e.g. leaving VSSA and VREFH etc. disconnected doesn't do anything weird to the chip's internals?

    I can tell you that I've built two designs now using a MK20 and a Mini54 from PJRC and both worked. I did leave the USB ID pin disconnected (because I'm using a mini B connector that doesn't have one), and I didn't use the ferrite chips because neither design needed high-accuracy analog measurements, but otherwise I copied the Teensy 3 schematic exactly.

    Do you have anything else in your circuit that might be overloading the MK20's internal voltage regulator? You could try using an external 5V -> 3.3V regulator and leaving VREGIN disconnected....

  4. #4
    Junior Member
    Join Date
    Jul 2013
    Thanks for your replies and assistance.

    I have replaced the Mk20DX and Mini54 and added an additional 2.2uF cap on VBUS but unfortunately no change, still getting the "download error" message. I have managed to download a program which runs happily and repeatedly after powering down/up.

    I will check the datasheet again with respect to VSSA and VREFH. I have left the analogue circuits off to simplify the number of components that may be causing the problem.

    At the moment there is nothing on the board except as shown in the schematic, but I will try with an external 3.3V.

    I will let you know if I have any success.

Posting Permissions

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