-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
did the whole thing from scratch - seems to work now
- Loading branch information
T-vK
committed
Oct 22, 2016
1 parent
b9b3767
commit 741b180
Showing
3 changed files
with
41 additions
and
60 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,72 +1,51 @@ | ||
## Easily compile and flash binaries for the ESP32 and ESP31b | ||
You might also be interested in the branch for the ESP8266 and ESP8266EX: https://github.com/T-vK/docker-esp-sdk/ | ||
|
||
## !!! This branch is completely untested for now! | ||
|
||
## How to install | ||
|
||
If you don't have docker, install docker first: https://docs.docker.com/engine/installation/linux/ | ||
|
||
``` bash | ||
git clone -b esp32 https://github.com/T-vK/docker-esp-sdk.git | ||
cd docker-esp-sdk | ||
sudo docker build -t tavk/esp-sdk:0.1 . | ||
sudo docker build -t tavk/esp32-sdk:0.1 . | ||
``` | ||
|
||
## How to use | ||
## How to use examples | ||
|
||
### Compiling binaries | ||
|
||
``` bash | ||
sudo docker run -t -i -u esp \ | ||
-v /home/ubuntu/esp8266/esp-open-sdk/examples/blinky:/home/esp/shared_project \ | ||
tavk/esp-sdk:0.1 \ | ||
make | ||
-v /home/debian/esp-idf/examples/01_hello_world:/home/esp/shared_project \ | ||
tavk/esp32-sdk:0.1 \ | ||
make all | ||
``` | ||
|
||
- Replace `/home/ubuntu/esp8266/esp-open-sdk/examples/blinky` with the absolute path to the directory of the project oyu want to compile. | ||
- Replace `make` with whatever command is necessary to compile your binary/binaries. | ||
- Replace `/home/debian/esp-idf/examples/01_hello_world` with the absolute path to the directory of the project oyu want to compile. | ||
- Replace `make all` with whatever command is necessary to compile your binary/binaries. | ||
|
||
|
||
### Flashing binaries | ||
### Flashing | ||
|
||
``` bash | ||
sudo docker run -t -i -u esp \ | ||
--device=/dev/ttyUSB0 \ | ||
-v /home/ubuntu/esp8266/esp-open-sdk/examples/blinky:/home/esp/shared_project \ | ||
tavk/esp-sdk:0.1 \ | ||
esptool.py --port /dev/ttyUSB0 write_flash 0x00000 blinky-0x00000.bin 0x40000 blinky-0x40000.bin | ||
tavk/esp32-sdk:0.1 \ | ||
make flash | ||
``` | ||
|
||
- Replace `/home/ubuntu/esp8266/esp-open-sdk/examples/blinky` with the absolute path to the directory that contains the files you want to flash. | ||
- Replace `/home/debian/esp-idf/examples/01_hello_world` with the absolute path to the directory that contains the files you want to flash. | ||
- Replace `/dev/ttyUSB0` with the COM port that your ESP is connected to. | ||
- Replace `esptool.py --port /dev/ttyUSB0 write_flash 0x00000 blinky-0x00000.bin 0x40000 blinky-0x40000.bin` with whatever command is necessary to flash your binaries. | ||
|
||
|
||
### Flashing bootloaders | ||
- Replace `make flash` with whatever command is necessary to flash your binaries. | ||
|
||
``` bash | ||
sudo docker run -t -i -u esp \ | ||
--device=/dev/ttyUSB0 \ | ||
-v /home/ubuntu/projects/esp-bootloader:/home/esp/shared_project \ | ||
tavk/esp-sdk:0.1 \ | ||
esptool.py --port /dev/ttyUSB0 write_flash --flash_mode dio --flash_size 32m 0x0 bootloader.bin | ||
``` | ||
### Please refer to https://github.com/espressif/esp-idf for more indepth information on how to compile/flash for your ESP32 | ||
|
||
- Replace `/home/ubuntu/projects/esp-bootloader` with the absolute path to the directory that contains the files you want to flash. | ||
- Replace `/dev/ttyUSB0` with the COM port that your ESP is connected to. | ||
-Replace `esptool.py --port /dev/ttyUSB0 write_flash --flash_mode dio --flash_size 32m 0x0 bootloader.bin` with whatever command is necessary to flash your binaries. | ||
|
||
### If the make file takes care of compiling AND flashing | ||
|
||
``` bash | ||
sudo docker run -t -i -u esp \ | ||
--device=/dev/ttyUSB0 \ | ||
-v /home/debian/espusb:/home/esp/shared_project \ | ||
tavk/esp-sdk:0.1 \ | ||
make ESP_ROOT=/home/esp/esp-open-sdk burn | ||
``` | ||
## Testing | ||
I have compiled one example project successfully. | ||
Since I don't have my ESP32 yet, I can't test if the flashing actually works. | ||
But I'm sure you will tell me in the issues if something doesn't work. :) | ||
|
||
- Replace `/dev/ttyUSB0` with the COM port your esp is connected to. | ||
- Replace `/home/debian/espusb` with the absolute path to directory of the project you want to compile/flash. | ||
- Replace `make ESP_ROOT=/home/esp/esp-open-sdk burn` with the command necessary to compile and flash your project. | ||
I don't really know how to change the config wihtout going through menuconfig manually, | ||
so that might be a problem.. I haven't really looked into it too much though. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters