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

Thread: update firmware using USB stick

  1. #1
    Junior Member
    Join Date
    Nov 2021
    Posts
    14

    update firmware using USB stick

    I am using the teensy 4.1
    it has an USB host option. I found some samples but nothing to access files from a plugged USB stick.
    did anyone made such a tool already?
    or is there a good sample on how to access files in a plugged USB drive?
    thanks.

  2. #2
    There is a lot of work going on to add this capability for Teensy. I don't think it exists yet.

    https://forum.pjrc.com/threads/68139...and-MSC/page20

  3. #3
    Junior Member
    Join Date
    Nov 2021
    Posts
    14
    ok, thanks. i have read a number of posts but at the end i was confused. I assume that when it exist some day it will be added to the samples.
    i need to look for an alternative to update. so i do some more searching. can not be the first that want to update without using a pc with arduino :-)

  4. #4
    Others may step with in corrections to this reply, but I'll tell you how I think it all works. Updates are an area where Teensy differs from Arduino. They are not written directly from the Arduino IDE, but rather go through TeensyLoader, a small GUI program which gets called by the IDE, whether that IDE is Arduino or PlatformIo or any other. There is also a command-line version of TeensyLoader that you can use if you want to avoid using an IDE. Both versions send updates via the bootloader chip on the Teensy. I think it's correct to say that the only way to access the Teensy bootloader is via TeensyLoader, or an equivalent. There are a few people who have modified their Teensy boards to use JTAG debuggers, so that's an update method, but it's not "production". The other way that I know of to update a Teensy is to use the approach in the thread linked below. This method is not easier/better than TeensyLoader. It is intended to provide an update method in situations where there is no access to the Teensy's USB connector. This could be because the Teensy is remote or is inside a product that does not allow connection to the Teensy's USB serial port. The idea is to send hex files over a non-USB connection, nominally UART, but could be Ethernet or SPI, etc, or via SD card, and to have software included in the Teensy application that can (a) buffer the new code to flash, (b) erase the existing firmware, (c) copy the new firmware from the buffer to flash, (d) reboot and run the new firmware.

    https://forum.pjrc.com/threads/43165...light=FlasherX

  5. #5
    Junior Member
    Join Date
    Nov 2021
    Posts
    14
    thank you for taking the time to help. this looks interesting. i will be a good alternative. i also found the command line version. this is good for integration in custom software.
    ok, enough to test :-)

Posting Permissions

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