Custom Teensy LC Bootloader not programming MCU

Status
Not open for further replies.

PublicStatic

New member
I have the preprogrammed PJRC MKL02Z32 bootloader connected to the blank MKL26Z64VFT4 by way of a USB-C connection and I am having some trouble getting things working. The USB-C connection was meant to allow the bootloader and MCU to exist on two separate boards so that the MCU board could be made smaller, and the bootloader would only be attached when programming was required. I have another design that has the bootloader on the same board as the MCU and that works just fine. When I move things to the new two-board configuration I get strange behaviors from the bootloader.

I'm seeing the expected pulse train at 30 kHz on the RESET pin of the MCU and the 3.3V line, along with everything else, looks good on the MCU board. When I press the PROGRAM button on the bootloader board the RESET pin on the MCU is indeed pulled LOW, so that is working. This is when the curious behavior starts however. The SWD-IO pin shows a constant 2V signal and SWD-CLK line is constant LOW. I believe I have verified that the pins are indeed making good contact with no shorts, bridges, or opens. When I set a trigger for the single shot, I can see something trying to happen at the very start, but that seems to fail and it goes to the steady 2V/GND state.

I have seen other behaviors from the bootloader where the IO line will continuously send a pulse packet and the clock line will do the same. The IO and CLK signals appeared to be aligned correctly, but MCU seems to be resetting out of sync. It's like the bootloader is trying to program the MCU but the MCU is not listening.

Any suggestions on how to trouble shoot this issue or what could be wrong with the circuit would be greatly appreciated. I'm at my wits end on this one...

RESET Pin:
RESETPin.png

Constant CLK and IO pins:
BadBootloader.png

Single-shot start of programming:
SingleShotCaptureBAD.png

USB configuration:
USBConfig.png

MCU pins:
MCUPins.png

Bootloader pins:
BootloaderPins.png

Bootloader trying to program the MCU:
BootloaderRunningButNotProgramming0.png

CLK and RESET out of sync:
RESETNotSyncedWithCLOCK.png
 
I want to be clear, that the bootloader is a PJRC bootloader. I feel like the word 'custom' in the title might have made it sound like I made my own bootloader. I made a custom Teensy LC board with the goal of making the MCU board as small as possible by moving the bootloader to another board. From my tests it looks like the signals are getting through but the MCU is not being programmed. I'm running out of ideas for things to try and test. If anyone has any suggestions about what I could to to get more data or info on what's going wrong I'm super interested to try something new. The USB-C connection was chosen because it has a ton of free pins that I could reporpose to allow the bootloader to connect to the MCU from the other board. If anyone has any questions, please let me know, I would love some help solving this issue. I'm just outside my comfort zone and as far as I know the bootloader is a magic chip and I can only speculate as to what it needs to do it's job. I'd love to hear from someone who knows more about how I can debug the behavior and what tests I can do to pin down the error. Thanks everyone!
 
Hi Paul, thank you so much for your reply. I have done some more probing around and I have found that there is a curious 1.8 V steady DC signal on any of the pins that I have left unconnected on the USB-C connector. This is odd since there are no 1.8 V sources on the board, but it could be created by the 3.3 V supply regulator on the bootloader board. It would mean that there is some voltage drop of a little less than half somewhere caused by a short or something I guess. I'll certainly post a reply when I have more information. If anyone has worked with USB-C and has any tips as to what could be causing this, that would be great!
 
Status
Not open for further replies.
Back
Top