• Light box

    01/06/2018 at 21:43 0 comments

    Created a foldable light box out of

    • cardboard
    • painter's tape
    • some white cloth
    • double sided tape
    • white paper
    • four round 10x2 magnets
    • four M5 nuts


    • Scissors
    • knife
    • hot glue gun
    • pen

    The first two picture show the general layout. The flaps you see in the first picture to the left are just painter's tape with magnets to hold the thing together when it's put together for use. You can also see - in the third rectangle from the left - the two nuts that the magnets hold on to.

    Plugged together:

    First light:

  • Sonoff basic flash mode

    12/15/2017 at 21:51 0 comments

    Today I was trying to download custom firmware to a sonoff basic. For those who don't know what that is: It's an ESP8266 with a flash chip, power supply, and a relay that you can use to switch a 230 V load. Really simple, and since it's based on an ESP, also very hackable. There's even some holes for a header with 3V3, RX, TX and GND that yells at you to plug in your own code. So I wanted to do just that.

    Basically, flashing is as simple as for any other generic ESP board, especially with arduino which uses esptool under the hood. Many tutorials describe the basic workflow:

    • unplug the device from mains, if it was connected before
    • really do that previous step!
    • wait until everything has discharged and is safe to touch
    • wait some more
    • solder in a 4- or 5-pin header (the fifth pin is not necessary)
    • connect a USB to serial converter
    • supply the chip with an external 3V3 power supply (capable of supplying 300 mA or so)
    • use esptool to flash your own firmware.

    I won't repeat the numerous pictures here, just google for "sonoff basic flash" or something similar.

    However, I ran into a problem: After esptool reported that it had flashed the new firmware successfully, my ESP just wouldn't run. I finally found this issue on github:


    It boils down to this: when flashing, you have to do so in DOUT mode. You can select this in the arduino tools menu or on the command line for esptool.