From Network Security Wiki


        This section is under construction.


Download the firmware:
  • Non-SPIRAM firmware will work on any board, whereas SPIRAM enabled firmware will only work on boards with 4MiB of external pSRAM.
  • Firmware built with ESP-IDF v3.x has support for BLE, LAN and PPP.
  • Firmware built with ESP-IDF v4.x, has support for BLE, but no LAN or PPP.
  • If in doubt use v3.x.

Flashing the Firmware: --chip esp32 --port /dev/ttyUSB0 erase_flash --chip esp32 --port /dev/ttyUSB0 --baud 460800 write_flash -z 0x1000 esp32-idf4-20191220-v1.12.bin

Flashing the Bootloader

If you get this error in console, Likely bootloader is corrupt or erased:

invalid header: 0xffffffff

Download new bootloader file from this Zip file:

Install the bootloader at 0x0 location: --port /dev/ttyACM0 --baud 9600 --before default_reset --after hard_reset write_flash -z --flash_mode dio --flash_size detect 0x0 bootloader.bin

  • If you get this error while installing both bootloader & the Application files:
Detected overlap at address: 0x8000 for file:

You need to give proper space between the files:

0x1000 bootloader.bin  0x8000 esp32-idf4-20191220-v1.12.bin
  • If you see these error in Console:
E (540) esp_image: Image length 1339808 doesn't fit in partition length 1114112
;31mE (541) boot: Factory app partition is not bootable
E (543) boot: No bootable app partitions in the partition table


E (54) flash_parts: partition 0 invalid magic number 0x6e9
E (60) boot: Failed to verify partition table
E (65) boot: load partition table error!

Most likely the Bootloader is installed but there is no application installed or is not bootable.




  • Download the below library file from below link & upload it to ESP32:
  • Connect the ESP32 to I2C LCD-1602 as below:
P5 ---------------- SCL
P4 ---------------- SDA
GND --------------- GND
5V ---------------- VCC
  • Testing the LCD:
i2c = I2C(1, sda=Pin(4), scl=Pin(5))
lcd = LCD1602(i2c)

  • Print the output on the LCD:
from machine import I2C, Pin
from mp_i2c_lcd1602 import LCD1602
from time import sleep_ms

i2c = I2C(1, sda=Pin(9), scl=Pin(10))

LCD = LCD1602(i2c)

LCD.puts("I2C LCD1602")
n = 0
while 1:
    LCD.puts(n, 0, 1)
    n += 1


{{#widget:DISQUS |id=networkm |uniqid=ESP32 |url= }}