Skip to content

Latest commit

 

History

History
84 lines (70 loc) · 2.73 KB

GETTING_STARTED.md

File metadata and controls

84 lines (70 loc) · 2.73 KB

Getting Started

Prerequisites

You will be needing a set of tools in order to develop for the ESP32.

Windows

We rely on Winget to make our life a bit easier. Therefor our first step on windows would be to Install Winget.

Once that's done, we can install the tools we need:

winget install --id Git.Git -e --source winget
winget install -e --id Python.Python.3.10
winget install -e --id AivarAnnamaa.Thonny
winget install -e --id GoLang.Go

curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python get-pip.py
pip install esptool

go install github.com/nats-io/natscli/nats@latest

Clone the repository

git clone git@github.com:area3001/ira_mpy.git

Prepare your ESP32

Download the Micropython firmware

Download the latest Micropython firmware for your controller. For the IRA, we use the ESP32_GENERIC-SPIRAM firmware

Determine the port your controller is connected to

Windows

Under Windows, this is called a COM port. You can find this in the device manager under Ports (COM & LPT). To make things easier, we will export this to an environment variable:

set COM_PORT=COM4

Mac & Linux

Under Mac & Linux, this is called a tty port. You can find this by running the following command:

ls /dev/tty*

You should be looking for something like /dev/ttyUSB0 or /dev/ttyS0. We will export this to an environment variable:

export COM_PORT=/dev/ttyUSB0

Erase the flash and flash micropython

Windows

esptool.exe --chip esp32 --port %COM_PORT% erase_flash
esptool.exe --chip esp32 --port %COM_PORT% --baud 460800 write_flash -z 0x1000 "file_location\___.bin"

Mac & Linux

esptool.py --chip esp32 --port $COM_PORT erase_flash
esptool.py --chip esp32 --port $COM_PORT --baud 460800 write_flash -z 0x1000 "file_location\___.bin"

Copy the files to the ESP32

Use Thonny or Pycharm to copy the following files to the ESP32:

  • main.py
  • fx
  • ira

Configure your device

In order to use your device, you will have to configure it first. This means configuring the wifi and the outputs. Take a look at the Configuration Guidelines for more information.

IDE support

Thonny

Windows

winget install -e --id AivarAnnamaa.Thonny

Pycharm

This was based on https://mischianti.org/micropython-with-esp8266-and-esp32-flashing-firmware-and-using-pycharm-ide-3/