Recover a Shelly Dimmer v1

A friend of mine tried out tasmota on a Shelly Dimmer, but he decided in the end to go back to the Shelly firmware because of the calibration and more precise configuration of the dimmer. The dimmer connected to a LED and you want to match the lowest possible energy to start at an offset because the LED won't turn on until you reach 50% duty cycle.

After trying flashing back from tasmota to Shelly, the dimmer broke down and couldn't be controlled by wlan anymore.

To recovery the Shelly Dimmer you need to have:

  • Debug connector 1x6 RM 1.27
  • USB UART for 3.3V
  • Shelly Recovery Firmware
Disconnect the 230 Volt connectors before connecting anything else to it!!!

The Shelly Dimmer comes with a debug connector which is accessable from outside and it consist of 1x6 RM 1.27. You may find different pinouts for the Dimmer. The correct pinout for the Shelly Dimmer v1 is:

     [x][x][x][x][x] 230V connector

[] U0TXD
[] U0RXD
[] GPIO2
[] GPIO0
[] 3V3
[] GND

* Button

Most USB UARTs will provide a good enough power supply for the shelly to boot up.

You need to connect a 3.3V UART to U0TXD, U0RXD, 3V3 and GND. Further you need to connect GPIO0 to GND to get the ESP8266 into boot mode.

Power cycle the ESP either by remove the 3.3V pin or by cycling the USB port.

There are multiple "recovery" firmwares around. I've used the following:

I'm strongly recommend you're doing a full backup before flashing the recovery firmware. There might be calibration data in the firmware.

# check if the connection works -p /dev/ttyUSB0 chip_id

# create a backup -p /dev/ttyUSB0 read_flash 0x0 0x200000 shelly_dimmer_v1_backup.bin

# flash the recovery firmware -p /dev/ttyUSB0 write_flash 0x0 dimmer.bin

Please disconnect now GPIO0 and U0TXD and U0RXD. U0RXD and U0TXD is used to communicate with an auxillary micro controller which controls the 230V. If you don't disconnect the U0RXD/U0TXD, a firmware update will be stuck because it can't talk with the micro controller.

Now connect to the Accesspoint of the Shelly, connect it into your wireless network and do a firmware update.

The Shelly Dimmer should be ready to build it into your home again.