Coder Social home page Coder Social logo

blink-ulp's Introduction

ULP blink

Me trying to make an esp32 blink via ULP.

Since there is no PlatformIO integration for ULP, I'll use plain ESP-IDF. But I reuse the PlatformIO framework for espidf. No need for two copies.

Installation (using Linux with Python 2.x)

  • Install PlatformIO IDE with shell commands or just the core
pip install platformio

see https://platformio.org/install for details

  • Install PlatformIO framework espidf for platform espressif32
pio platforms install espressif32 --with-package framework-espidf
  • Install ULP toolchain
mkdir -p ~/esp32
cd ~/esp32
wget https://github.com/espressif/binutils-esp32ulp/releases/download/v2.28.51-esp32ulp-20180809/binutils-esp32ulp-linux64-2.28.51-esp32ulp-20180809.tar.gz
tar xzf binutils-esp32ulp-linux64-2.28.51-esp32ulp-20180809.tar.gz

Check for updates at https://github.com/espressif/binutils-esp32ulp/releases/latest)

  • Configure environment for the ESP-IDF
echo 'export IDF_PATH=$HOME/.platformio/packages/framework-espidf' >~/esp32/env.sh
echo 'export PATH=$IDF_PATH/bin:$IDF_PATH/../toolchain-xtensa32/bin:$PATH' >>~/esp32/env.sh
echo 'export PATH=~/esp32/esp32ulp-elf-binutils/bin:$PATH' >>~/esp32/env.sh

Best to add this to your ~/.profile

. ~/esp32/env.sh

Build - Flash - Monitor

  • Prepare shell to use ESP-IDF (if not done by your .profile already)
. ~/esp32/env.sh
  • Fetch and build this example, flash it and open serial console (adapt ESPPORT and ESPBAUD to your setup. Can be configured in sdkconfig file)
mkdir /tmp/blink-$$ && \
cd /tmp/blink-$$ && \
git clone https://github.com/joba-1/Blink-ULP.git && \
cd Blink-ULP && \
make -j8 flash monitor ESPPORT=/dev/ttyUSB0 ESPBAUD=115200

A led connected to gnd (kathode) and gpio2 (anode) should blink now.

Exit the monitor with [Ctrl]-] (which is [Strg]-[Alt-Gr]-] on german keyboard)

Other make targets

Just build the app

I use this for auto build in eclipse

make app

Build the app and flash it, but not config or bootloader

A bit faster and usually enough after the first flash

make app-flash

List all the other possibilities

make help

JoBa1

blink-ulp's People

Contributors

joba-1 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

ivancho523

blink-ulp's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.