Public
Authored by natalie 💜

Step-by-step Windows flashing guide

This guide is long, but following it step-by-step gets you a working MegaGRRL Desktop board and dev environment.

You can follow along with this video: https://www.youtube.com/watch?v=wvfQTjJ12Ss

  1. Install a text editor that works well with code, such as Notepad++
  2. Make sure RN2 and the sound chips are not populated on your MegaGRRL Desktop board, then plug it in to USB and power, and turn it on.
  3. (Windows 7 only) Download and install the CH340 USB driver from this link
  4. Download Espressif's MSYS2 environment from this link
  5. Open the zip file and extract the msys32 directory to a convenient place. The path must not include any spaces. Putting it directly in the C: drive will work.
  6. Enter the msys32 directory and run mingw32.exe.
  7. Paste in the following. Pasting can be done with Shift+Insert or the right-click menu. curl https://git.agiri.ninja/snippets/3/raw | bash
  8. ESP-IDF will be downloaded and setup. This will take several minutes. Close and re-open mingw32.exe when it is complete.
  9. Open Device Manager and find the USB-Serial device under "Ports (COM & LPT)". Remember its COM port number.
  10. In the mingw32 window, enter the following, making sure the COM port number matches what you saw in Device Manager. This will burn the flash voltage selection efuse. $IDF_PATH/components/esptool_py/esptool/espefuse.py --port COM1 set_flash_voltage 3.3V
  11. Enter cd megagrrl/firmware to enter the firmware directory.
  12. Enter git tag to see the list of tagged firmware versions.
  13. Find the tag with the highest version and use git checkout to obtain the files. For example, if the highest version available is v0.93dev, you would type git checkout v0.93dev
  14. Go back to the msys32 directory, and navigate to home\<name>\megagrrl\firmware\main. Find hal.h and open it in Notepad++. Remove the // on the //#define FWUPDATE line, and save the file.
  15. Go back to the mingw32 window. Enter ESPPORT=COM1 make flash, again correcting the COM port number to match your system. This flashes the firmware updater. This process will take several minutes.
  16. Unplug the MegaGRRL Desktop board, and populate the missing resistor network RN2. When done, plug it back in to power and USB and turn it on again.
  17. Undo your changes to hal.h and save the file again.
  18. In mingw32, enter make all to build the main firmware. It will only take a few seconds this time.
  19. Enter mv build/megagrrl.bin factory.mgf
  20. In Windows Explorer go back to the home\<name>\megagrrl\firmware directory. Copy the factory.mgf file to an SD card.
  21. Insert the SD card into the MegaGRRL Desktop board. It will now update itself.
Edited
setup.sh 696 Bytes
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment