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

Thread: Uploading sketches fail to Teensy 4.1

  1. #1

    Uploading sketches fail to Teensy 4.1

    I just bought 4 Teensy 4.1's and am getting errors uploading to all of them. I am running MacOS 1.13.6 and a clean installation of Arduino 1.8.12 and have installed TeensyDuino 1.52. When attempting to upload a simple blink code, it compiles, but then returns the error about not uploading. I have picked the Teensy 4.1, and have made sure it it uploading to the correct port. I have confirmed everything works on Teensy 3.0 and 3.2, but ALL of my Teensy 4.1's behave this same way.

    When I press the Program button, a little red LED lights, but I still can't upload sketches. Thoughts?

    Code:
    Sketch uses 14688 bytes (0%) of program storage space. Maximum is 8126464 bytes.
    Global variables use 41660 bytes (7%) of dynamic memory, leaving 482628 bytes for local variables. Maximum is 524288 bytes.
    Teensy did not respond to a USB-based request to enter program mode.
    Please press the PROGRAM MODE BUTTON on your Teensy to upload your sketch.
    An error occurred while uploading the sketch

  2. #2
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    11,780
    Check the cable - try another one perhaps. The T_4.1 runs USB at 480 Mbps versus prior T_3.x's at 12 Mbps. So a cable that has worked before may fail at the higher speeds it has been seen.

    Pressing the Button and seeing the red light shows the T_4.1 is ready to be programmed - and at that point if TeensyLoader is running - the IDE port selection does not matter - the named sketch HEX shown on the lower portion of the loader app will be uploaded when it comes online with the computer. A bad cable can prevent that. Seeing this with 4 new T_4.1's all having the issue suggests computer connectivity is the problem. The TeensyLoader has " Help / Verbose " option that opens a second window logging Teensy arrival and programming process. Openeing that should update when the button is pressed.

  3. #3
    Good suggestion. Well, I tried two USB other cables and I get the same problem. I have also tried to upload the blink sketch to a Teensy 4.0 and this works. I think the 4.0 uses the same 480 Mbps USB as 4.1 So it really does seem to be a Teensy 4.1 issue. The TeensyLoader doesn't even pop up when I try to upload to the 4.1.

    When I compile, then press the Program button, I get the following on the Teensy Loader:

    Code:
    16:16:18.163 (ports 2): HID remove callback
    16:16:18.163 (ports 2): HID add callback, vid=16c0, pid=0478, ver=0105, loc=fa400000
    16:16:18.163 (loader): HID/macos: detach callback: is currently open device
    16:16:18.163 (ports 2): USB device remove callback
    16:16:18.163 (ports 2): remove, loc=fa400000
    16:16:18.163 (ports 2): usb_remove: usb:fa400000
    16:16:18.163 (ports 2): del device: location=fa400000
    16:16:18.257 (loader): Device went offline
    16:16:18.508 (loader): HID/macos: number of devices found = 0
    16:16:18.512 (loader): HID/macos: no devices found (empty set)
    16:16:18.717 (ports 2): USB device add callback
    16:16:18.717 (ports 2):   loc=fa400000, vid=16C0, pid=0478, ver=0105, ser=000BAFAB
    16:16:18.717 (ports 2):   actual serailnum=765867
    16:16:18.717 (ports 2):   found prior teensy at this loc, age=0.554
    16:16:18.717 (ports 2):     name: [no_device] (Teensy 4.1) Bootloader
    16:16:18.759 (loader): HID/macos: attach callback
    16:16:18.783 (loader): Device came online, code_size = 8126464
    16:16:18.788 (loader): Board is: Teensy 4.1 (IMXRT1062), version 1.05
    16:16:18.805 (loader): File "Blink.ino.hex". 14308 bytes, 0% used
    16:16:18.811 (loader): set background IMG_ONLINE
    16:16:19.007 (loader): HID/macos: status: ok
    And it seems to keep trying to connect every 40 seconds or so. But never uploads.
    Last edited by spectasaurus; 06-24-2020 at 08:18 PM. Reason: added more info

  4. #4
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    22,094
    In Teensy Loader, click Teensy > About. Is it really version 1.52?

    If you had an older version already running before upgrading to 1.52, it's possible the old one is still active. All you need to do is click File > Quit, so the old Teensy Loader isn't running anymore. Then click Verify or Upload in Arduino and it will run a copy of 1.52 (assuming you're using Arduino with Teensyduino 1.52 installed).

  5. #5
    Quote Originally Posted by PaulStoffregen View Post
    In Teensy Loader, click Teensy > About. Is it really version 1.52?

    If you had an older version already running before upgrading to 1.52, it's possible the old one is still active. All you need to do is click File > Quit, so the old Teensy Loader isn't running anymore. Then click Verify or Upload in Arduino and it will run a copy of 1.52 (assuming you're using Arduino with Teensyduino 1.52 installed).
    It seems this was the problem. Obviously I never saw that TeensyLoader was still open. Thanks a lot Paul!

Posting Permissions

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