Skip to content

tngwoerleij/go-light

 
 

Repository files navigation

Go-Light

Lua code to convert a toy traffic light into a extreme feedback device

Setup for ubuntu

  1. Install python

  2. Install virtualenvwrapper

    apt install virtualenvwrapper
    . /usr/local/bin/virtualenvwrapper_lazy.sh # add to .bashrc as well
  1. Create a virtualenv
    mkvirtualenv nodemcu
  1. Install esptool
    workon nodemcu
    pip install esptool
    pip install nodemcu-uploader

Firmware for nodemcu

  1. Change to this repo

  2. Make sure the microcontroller is connected to ttyUSB0 (needs: timer, gpio and string module)

    esptool.py  --port /dev/ttyUSB0 erase_flash
    esptool.py  --port /dev/ttyUSB0 write_flash --flash_mode dio 0x00000 nodemcu-master-*-integer.bin
  1. Check if flashing worked (press the reset button while doing this and wait about 10 sec for the repl to appear)
    cu --nostop -s 115200 -l /dev/ttyUSB0
  1. Customize config.lua

  2. Upload the source the lua source to the nodemcu

    ./upload.sh

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Lua 91.7%
  • Shell 8.3%