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

Thread: Custom 3.2 Board - Partially working - Bootloading process?

  1. #1
    Senior Member Davidelvig's Avatar
    Join Date
    Aug 2015
    Location
    Wisconsin
    Posts
    280

    Custom 3.2 Board - Partially working - Bootloading process?

    New board based on Teensy 3.2 and MKL02 boot loader from PJRC

    When running Teensyduino (and no Teensy Loader) , connecting the new board, and pressing reset, I see this in the Tools/Port menu
    Click image for larger version. 

Name:	Teensy32-Reset-NoLoader1.jpg 
Views:	6 
Size:	98.0 KB 
ID:	20356
    This is identical to the behavior on an off-the-shelf Teensy 3.2 purchased form PJRC

    After running Teensy Loader, I see this with my custom board
    Click image for larger version. 

Name:	Teensy32-Reset-AfterLoader1.jpg 
Views:	6 
Size:	122.0 KB 
ID:	20355
    - no useful Serial ports

    In comparison, the off-the-shelf Teensy 3.2 board after Teensy Loader runs shows the usual
    Click image for larger version. 

Name:	Teensy32-Reset-AfterLoader1.jpg 
Views:	6 
Size:	15.0 KB 
ID:	20357

    My sense is that I have a lot working here.
    What's next to test?

    Thanks
    Dave

  2. #2
    Senior Member Davidelvig's Avatar
    Join Date
    Aug 2015
    Location
    Wisconsin
    Posts
    280
    One of my consulting EE's has done some testing, comparing my custom board (DB Board) to an off-the-shelf Teensy.

    There's a fundamental difference in behavior between a Teensy board and the DB board. On Teensy, after a reset (but prior to loading a sketch), the 16MHz crystal is oscillating. After loading a sketch, it is still oscillating (or maybe more accurately, it's oscillating again).

    On DB, The 16MHz crystal is oscillating after a reset, but prior to loading a sketch (same as on Teensy). However, during the sketch load process, the 16MHz crystal stops oscillating and doesn't start again, at which point the board is unresponsive. Pressing the reset button will start the crystal again.

    I believe the crystal will only oscillate if software configures the chip correctly to enable it. I don't know what this means, but it seems like it could be significant in understanding where things are getting stuck.
    Any ideas as to why this board is failing from this crystal behavior, or the previous post?

    Thanks in advance!
    Last edited by Davidelvig; 06-01-2020 at 07:21 PM.

  3. #3
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    22,273
    Did you connect 3.3V power to the processor's VBAT pin?

    Check the troubleshooting info at the bottom of the MKL02 page.

    https://www.pjrc.com/store/ic_mkl02.html

    When the processor runs the bootloader but not compiled programs, it's usually VBAT missing. When the compiled program tries to initialize the RTC, it crashes if there is no VBAT.

  4. #4
    Senior Member Davidelvig's Avatar
    Join Date
    Aug 2015
    Location
    Wisconsin
    Posts
    280
    Wow, I think that's it.
    From the Bootloader page, this Troubleshooting link appears to be the one you refer to.

    When I short VBAT to 3V3, the reboot completes, and the sketch runs... and the Serial port appears.

    I know I read that post too as I was designing. I'll review where I went wrong, and continue testing.


    Thanks, Paul!!!

  5. #5
    Senior Member Davidelvig's Avatar
    Join Date
    Aug 2015
    Location
    Wisconsin
    Posts
    280
    Just to follow-up... the problem was indeed that VBAT was not connected to 3v3 on startup.
    Successful board after that jumper.

Posting Permissions

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