Skip to content
Provide ESP8266 based itead Sonoff with Web, MQTT and OTA firmware using Arduino IDE or PlatformIO
C++ C Python Processing Makefile Objective-C Other
Branch: development
Clone or download
Pull request Compare This branch is 83 commits ahead, 3079 commits behind arendst:development.
Latest commit 8c0c774 Jan 18, 2020
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github Update issue templates Sep 24, 2019
api Update/rebase to 7.0.0.5 for digiDIMv8 Nov 23, 2019
arduino Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
bins bin folder cleanup Jan 19, 2020
generic Update/rebase to 7.0.0.5 for digiDIMv8 Nov 23, 2019
include Update/rebase to 7.0.0.5 for digiDIMv8 Nov 23, 2019
jpgs Add files via upload Oct 5, 2019
lib Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
pio Update/rebase to 7.0.0.5 for digiDIMv8 Nov 23, 2019
tasmota Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
tools Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
.gitattributes Fix xsns_26_lm75ad.ino line endings Jun 25, 2018
.gitignore Rebase to 6.6.0.6 Aug 25, 2019
.gitpod.yml Prep again Nov 23, 2019
.travis.yml Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
API.md Prep again Nov 23, 2019
BUILDS.md
CODE_OF_CONDUCT.md Updated to 6.5.0 Apr 3, 2019
CONTRIBUTING.md Prep again Nov 23, 2019
Doxyfile Prep again Nov 23, 2019
I2CDEVICES.md Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
LICENSE.txt v5.1.0 May 13, 2017
MODULES.md Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
README.md Update README.md Jan 16, 2020
RELEASENOTES.md Prep again Nov 23, 2019
SUPPORT.md Prep again Nov 23, 2019
TEMPLATE.md Rebase to 6.6.0.6 Aug 25, 2019
TEMPLATES.md Prep again Nov 23, 2019
esp8266.flash.1m0.ld Prep again Nov 23, 2019
platformio.ini Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
platformio_override_sample.ini Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
platformio_tasmota_env.ini Upgrade to 8.1.0.1(digiDIMv9) Dec 31, 2019
updateDocs.sh Prep again Nov 23, 2019

README.md

Tasmota - digiDIM Kinda Sorta Not Really Temporary Fork @ 8.1.0.1 - Core 2.6.1

Precompiled bins supplied in the bins folder of this repo.

NOTE: Once you upgrade to 8.x you will only be able to downgrade to an older version via serial flash.

Changes

  • Dimming status sent at all power state changes
  • Power topic updated if a dimming change causes the power state to change
  • Martin Jerry SD-01 (02,03) Dimmer support
  • digiDIMv(X) indicated in the information tab for support purposes

I personally use this build on Tuya based dimmers and the Martin Jerry SD-01 Dimmer in our home with Home Assistant. Shown here

Martin Jerry SD-01 Dimmer

Tessan SD-02 Dimmer

Acenx SD-03 Dimmer

Lesim Dimmer with Number Display

Upgraded TreatLife Dimmer with Touch Panel

Moes Dimmer similar to the Oittm but possibly ships to additional countries

Martin Jerry SD-01 & Tessan SD-02 & Acenx SD-03 Dimmer Setup

Manual Flashing(Soldering Method)

Unplug the faceplate from the rear dimming module until you are ready to connect it to mains power! Do not connect the USB flasher to the faceplate while mains power is applied to the unit! The magic smoke will come out or worse!

Solder the wires for flashing like you normally would for a Tuya module flash as shown here . You do not need to solder GPIO 0 as the UP button is also GPIO 0, simply hold this button up during boot. Use the latest bin file provided in this folder.

Tuya-Convert (OTA Method)

The device should be in pairing mode (fast blink) upon applying power to the switch. Follow the standard Tuya-Convert process. After the dimmer is on the network, download the latest latest bin file provided in this folder to a folder on your computer. Use the Firmware Upgrade button on the Tasmota GUI and browse to the bin file that was just downloaded. If you receive a upload buffer miscompare error while uploading, this means you do not have enough flash space available on the dimmer. To correct the issue, flash the tasmota-minimal bin through the Tasmota GUI. Then flash the digiDIM bin file.

Setup

Once you have the device connected to your WiFi and MQTT broker, change the module type to the MJ-SD01 Dimmer. Let the device reboot and issue the following backlog on the console. Make sure every command takes effect:

backlog rule1 on switch3#state=2 do dimmer + endon on switch2#state=2 do dimmer - endon on switch2#state=3 do dimmer 20 endon on switch3#state=3 do dimmer 100 endon; rule1 1; setoption32 8; switchmode1 6; switchmode2 5; switchmode3 5

Once the switch reboots. Issue a switchmode3 command and make sure it comes back as a setting of "5". This will verify all of the above backlog commands went through correctly. If you do not see switchmode3 set to 5, you can issue each of the backlog commands separately one at a time and watch them go through.

In the rule1 you can change the "do dimmer 20" section to any value you like, a long press of down will set dimmer to 20%, a long press up will set the dimmer to 100%. Modify these to your needs.

Optional Rule for ON/OFF long press to send an MQTT toggle message to another switch/topic (example):

rule2 on switch1#state=3 do publish Table-Dimmer/Main TOGGLE endon 
rule2 1

NOTE: In the future, when you are preparing to flash a stock build of Tasmota to the MJ-SD01 Dimmer, select the Generic template first before flashing to prevent a possible conflict with another device template.

BONUS: Want the Red LED on while the light is off? Run this rule:

Rule3 on power1#state=1 do ledpower 0 endon on power1#state=0 do ledpower 1 endon  
Rule3 1

Sample Configuration YAML Code

- platform: mqtt
  name: "TuyaTest"
  state_topic: "stat/TuyaTest/POWER"
  command_topic: "cmnd/TuyaTest/POWER"
  availability_topic: "tele/TuyaTest/LWT"
  brightness_state_topic: "stat/TuyaTest/RESULT"
  brightness_command_topic: "cmnd/TuyaTest/Dimmer"
  brightness_scale: 100
  brightness_value_template: "{{ value_json.Dimmer }}"
  qos: 1
  payload_on: "ON"
  payload_off: "OFF"
  payload_available: "Online"
  payload_not_available: "Offline"
  retain: false
You can’t perform that action at this time.