IRC48M on Teensy 3.5

Status
Not open for further replies.

fauxpark

New member
Hello!

I've been experimenting with getting USB working on the Teensy 3.5 with ChibiOS + QMK, in particular using the IRC48M oscillator. However no matter what I tried, it didn't seem to work. Both data pins were stuck high according to my logic analyser and so Windows simply gave a "device descriptor request failed". I'd been referencing the existing code written for the K66 (Teensy 3.6) and the supported Kinetis chips all more or less share the same USB driver code. It was only after I removed all the IRC48M-related stuff I'd copied that I got actual USB enumeration.

Eventually I came across AN4905, which states:

The K64, K63, and K24 family devices with 1 MByte of flash were the first Kinetis MCUs to implement the crystal-less USB feature.

This seems to indicate that the MK64FX512 used in the 3.5 does not have the ability to use the IRC48M oscillator for this purpose, but the MK64FX1M0, and MK66FX1M0 do. Is this correct?

My code changes can be found here: https://github.com/ChibiOS/ChibiOS-Contrib/pull/306
And here: https://github.com/qmk/qmk_firmware/pull/14420

One more thing: after I'd finally gotten it running I did some further tinkering and seem to have bricked it completely by setting MCG_C7 to 2 (OSCCLK1). I misread the clock diagram on this page: https://www.utasker.com/kinetis/MCG.html and I can now see why that was a dumb thing to do. Now nothing at all happens when I plug it in to my machine, not even when pressing the reset button. Holding it down for the 15 seconds also appears to achieve nothing. Would there be a way to resuscitate this board?

Thanks!
 
Last edited:
Status
Not open for further replies.
Back
Top