Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

IoT Playground for ESP32, Arduino, M5Stack, and other firmware platforms

License

NotificationsYou must be signed in to change notification settings

vs4vijay/iot-playground

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A firmware playground for IoT Devices like ESP32, Arduino, M5Stack, etc.

  • Update subomdules usingscripts/update-submodules.sh script

Platform IO

Install Platform IO

pip install platformio

Compile firmware

pio run

Arduino CLI

Install Arduino CLI

curl -fsSL https://raw.githubusercontent.com/arduino/arduino-cli/master/install.sh| BINDIR=~/.local/bin sh

Install Core, Boards, Libraries

arduino-cli core install m5stack:esp32 --additional-urls"https://m5stack.oss-cn-shenzhen.aliyuncs.com/resource/arduino/package_m5stack_index.json"arduino-cli core search m5stackarduino-cli board listallarduino-cli lib install M5Cardputer M5Unified IRremoteESP8266 ArduinoJson TinyGpsPlus"Adafruit NeoPixel" --log-level warn --verbose

Compile firmware with Arduino CLI

arduino-cli compile --fqbn m5stack:esp32:m5stack_cardputer -e \                    --libraries M5Cardputer,IRRemoteESP8266 \                    --build-property build.partitions=huge_app \                    --build-property upload.maximum_size=3145728 \                    ./M5CardRemote.ino

Merge bootloader, partiotion table with app

esptool.py --chip esp32 merge_bin -o flash_image.bin @flash_argsesptool.py --chip esp32s3 merge_bin --output M5CardRemote.M5Cardputer.bin \    0x0000 build/m5stack.esp32.m5stack_cardputer/M5CardRemote.ino.bootloader.bin \    0x8000 build/m5stack.esp32.m5stack_cardputer/M5CardRemote.ino.partitions.bin \    0x10000 build/m5stack.esp32.m5stack_cardputer/M5CardRemote.ino.bin

ESP IDF

Install ESP IDF

sudo apt install git wget flex bison gperf python3 python3-pip python3-venv cmake ninja-build ccache libffi-dev libssl-dev dfu-util libusb-1.0-0mkdir~/espgit clone -b release/v5.3 --recursive https://github.com/espressif/esp-idf.git --depth 1~/esp/esp-idfcd~/esp/esp-idf./install.shsource~/esp/esp-idf/export.sh# OR.~/esp/esp-idf/export.sh

Compile firmware with ESP IDF

  • cd into the project
idf.py menuconfigidf.py build

Merge bootloader, partiotion table with app

cd build/esptool.py --chip esp32 merge_bin -o ../firmware.bin --fill-flash-size 4MB @flash_args

Other commands

idf.py build flash monitoridf.py menuconfigidf.py set-target esp32idf.py add-dependency

Rust

Install Rust

curl --proto'=https' --tlsv1.2 -sSf https://sh.rustup.rs| sh

Install espup

cargo install espupespup install

Compile firmware with Rust

cd demo_rustcargo build --release

Flash firmware

  • Install esptool.py -pip install -U esptool
esptool write_flash -z 0 name.bin

QEMU Emulation

# Install pre-requisitessudo apt install -y libgcrypt20 libglib2.0-0 libpixman-1-0 libsdl2-2.0-0 libslirp0# Installidf_tools.py install qemu-xtensa qemu-riscv32# Reload env..~/esp/esp-idf/export.sh# Boot firmware imageqemu-system-xtensa -machine esp32 -nographic -drive file=firmware1.bin,if=mtd,format=raw
  • Press Ctrl+A then C to exit qemu

Development Notes

esptool.py --chip esp32 read_flash 0x310000 0xF0000 spiffs.binmkspiffs.exe -u spiffs_unpack -b 4096 -p 256 -s 0xF0000 .\spiffs.binesptool.py --chip esp32 merge_bin --fill-flash-size 4MB -o flash_image.bin @flash_args)https://github.com/mluis/qemu-esp32qemu-system-xtensa -machine esp32 -drive file=build/flash_image.bin,if=mtd,format=raw -serial tcp::5555,server,nowait -display none -daemonizehttps://github.com/esp-rs/esp-idf-template

Credits and Thanks


[8]ページ先頭

©2009-2025 Movatter.jp