Skip to content
Mayank Kumar edited this page Nov 14, 2020 · 14 revisions

Header Script Version macOS Support Github All Releases paypal

tbt-flash.sh enables flashing external GFX enclosures for the first time on macOS via EFI. To flash firmware, your system will restart. The script will provide directions as you execute it.

⚠️ Nov. 13, 2020: It was reported and confirmed that tbt-flash currently does not work for macOS 11.0.1 or later. Please use an older version of macOS until the script is updated for compatibility.

Disclaimer

Flashing firmware inherently comes with risks and can render your eGFX enclosure inoperable. Proceed with caution and at your risk. I will not be responsible for any damage(s) to your system(s). By using this script, you acknowledge this disclaimer and license.

Installation & Flashing

  1. Ensure you are running macOS Catalina or newer. macOS 10.15.5 or later requires TBTFlash v1.0.2 or newer.
  2. Disable System Integrity Protection.
  3. If on a T2 Mac, use Startup Security Utility to set system to ‘No Security’.
  4. Ensure you have access to a firmware (.bin) file for your eGFX enclosure.
  5. Remove GPU from the enclosure and disconnect any other Thunderbolt devices.
  6. Run the following command in Terminal to install:
    curl -qLs $(curl -qLs https://bit.ly/39lD8mJ | grep '"browser_download_url":' | cut -d'"' -f4) > tbt-flash.sh; sh tbt-flash.sh; rm tbt-flash.sh
    If Github is busy, the above command may not work. In that case, please download and execute the script from Releases. This will install the tool on your system. For future use, you only need to type:
    tbt-flash
  7. Choose Flash eGFX option. Follow instructions exactly as stated in the script.
  8. Script will require rebooting to flash firmware. You will see an Apple logo and progress bar while flashing occurs.

This script does not modify macOS in any way, and only executes a modified EFI application to enable firmware flashing. It is expected that most users will use this tool infrequently, hence uninstalling the tool will completely remove all of its components. You can re-enable System Integrity Protection and boot security once flashing is complete.

Debugging via Manual Flash

I have not had the chance to test exhaustively with a variety of Thunderbolt boards, so there might be cases where flashing just does not work. In this case, I require EFI logs for further debugging. To generate these logs, you need access to an EFI shell and a pen drive. To set up your environment:

  1. Install rEFInd.
  2. Add Tianocore's EDKII EFI shell to rEFInd tools.
  3. Generate a patched EFI flasher with tbt-flash.sh using the Debug Flash option.
  4. Format your pen drive to FAT32 using Disk Utility.
  5. Connect your eGPU, go to System Information > Thunderbolt, and note down it's UID. Ensure that it is the UID of the enclosure and not of the Thunderbolt controller on your Mac.
  6. Disconnect all other devices except pen drive and eGPU.
  7. Copy the generated EFI flasher as well as the firmware (.bin) file to this drive. Rename your firmware file to Firmware.bin.
  8. Reboot into rEFInd with pen drive plugged in and choose EFI shell.
  9. To access your disk, type in:
fs2:
ls .

Usually the pen drive will be on fs2:. However, in case it is not, try different numbers instead of 2 and use ls to see what files are on there. If none match, reboot by exiting the shell.

  1. Once you have access to your pen drive in EFI, ensure eGPU is connected. To flash the eGPU:
ThorUtil.efi -u <UID> -fs \Firmware.bin -nb -noreset >a debug.log

Use the UID you noted in Step 5 and the firmware you placed on the pen drive. Logs will be generated in debug.log.

  1. Share this log while filing an issue on this repository.

Credits

EFI flashing and utility patching was a combined effort, with due credit to @asotoshpalai. This project would not have been possible without him.

Support

Consider starring the repository or donating via:

paypal

Thank you for using tbt-flash.sh.