Announcement

Collapse
No announcement yet.

Hardware mods to Sonoff Wifi Basic

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • #31
    Thank you Pete.

    Using text to speech reoccurring event when garage door is open (via OmniPro 2 and Homeseer) with a flag to shut it off if I am in the garage. Using two voices today comparing speed of Omnipro 2 garage door switches and using the Sonoff. First speech to trigger is the alarm wired sensors with the Omni panel plugin.

    Today no automation is used to shut the garage door automagically.

    Have an outdoor style PIR in the garage which I do not utilize for anything these days.

    Way back tested RFID tags to work with the automobiles which would identify which car was present and what functions would happen when the car was present. Tags using 12VDC automobile power with little draw on car battery. (originally configured automobiles with supplimental tank battery and charging circuits). Got it to about 100% but still hesitate on using it. Mixed it too here with the under the driveway sensors wired to the panel CarTel system.

    Ideally the car has an unique identity with the RF ID and the automation would acknowledge the automobile then open the door sans the use of a mobile phone.

    These are pictures of SonOff add. It is separate from what is there (spaghetti). Using a small PVC junction box adjacent to the garage door for the NC/NO switches using 22/2 and 22/4 cables. The Sentrol sensors have 3 wires (NC, NO). Wanting to keep this stuff / wires separate from the Sonoff stuff. Note that the Sentrol sensors are way overkill for a home garage. (used these in logistics warehouse doors).

    If I could utilize 3-4 more GPIO ports then these could be connected to relays connected to a 4 channel RFID reciever for a self contained multiple function Sonoff box. (door sensors, door button, temperature sensor and 4 channel RFID box).

    Concurrently redoing lighting in garage to pure LED.

    Thinking of using a small DIN rail mounted on the support structure of the GDO.


    Click image for larger version  Name:	sonoffgdo.jpg Views:	1 Size:	33.3 KB ID:	1238231

    Dedicated to Sonoff WiFi testing using a custom POE OpenWRT small footprint hardware modded micro router (hardware modifications are just RTC, using test GPIO pins and Mosquitto (not node red though). OS is small and very tight. Bit of a tangent here.

    Click image for larger version  Name:	image_70455.jpg Views:	1 Size:	55.8 KB ID:	1238232
    OpenWRT OS

    Firmware Version: LEDE Reboot 17.01.4 r3560-79f57e422d / LuCI lede-17.01 branch (git-17.290.79498-d3f0685)
    Mosquitto stuff:

    mosquitto version 1.4.14 (build date 2018-01-17 16:26:59+0000)
    mosquitto is an MQTT v3.1.1/v3.1 broker.

    You can utilize Python or LUA to tap in to the GPIO ports / Mosquitto stuff.



    Made a little heatsink for the DS18B20 chip and bent it a bit away from the board where as none of the bottom of the chip is touching the board using the idea in this picture. I like the little Arduinio DS 18B20 board Led lamp which lets me know that the Sonoff is on.

    Click image for larger version  Name:	heatsink.png Views:	1 Size:	281.3 KB ID:	1238298

    Testing it next to a thermostat.

    Sonoff #1 with no heatsink

    Temperature: 104.4 F

    Sonoff #2 with heatsink pictured above.

    Temperature: 99.4 F

    Thermostat: 92 F

    Got it to about 4 degrees F difference using a large ring terminal and gluing it to the DS18B20 chip.

    Click image for larger version  Name:	heatsink.jpg Views:	1 Size:	80.7 KB ID:	1238380
    Last edited by Pete; August 5th, 2018, 12:32 PM.
    - Pete

    Auto mator
    Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
    Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

    X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

    Comment


    • #32
      A few post back there was indication that console command to set temperature to Fahrenheit no longer works. I did not have a temp sensor connected, but I used “SetOption8 1” and the result acknowledge acceptance of the command. I toggle it back to Celsius with 0 parameter rather than 1.

      Comment


      • #33
        Thank you Michael.

        Did you utilize the

        hxxp://192.168.244.221/cm?cmnd=SetOption8 0

        command?

        This is what I get when I type it.

        RESULT = {"POWER":"Off"} POWER = Off Door2 = CLOSED

        Wondering if it because of I am using Firefox?

        Using the console the power 1 command works fine.

        Power1

        Here is the picture of the console command that I tried. Am I typing in the command correctly?

        Click image for larger version

Name:	consolecommand.jpg
Views:	26
Size:	96.4 KB
ID:	1238378
        Last edited by Pete; August 5th, 2018, 12:18 PM.
        - Pete

        Auto mator
        Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
        Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

        X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

        Comment


        • #34
          I determined that when door sensor is selected the setoption8 is treated as a command to power the door. I will play some more to try to isolate exactly what is happening. I know if the only input I select is DSx20 then the setoption8 0/1 will toggle Celsius/Fahrenheit in the sensor reporting.

          Comment


          • #35
            Thank you Michael.
            - Pete

            Auto mator
            Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
            Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

            X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

            Comment


            • #36
              Unrelated here have the Sonoff WiFi basic AP1 and AP2 configured for the same WAP.

              Noticed that SonOff always connects via AP2.

              If I change AP2 configuration to another WAP it connects right away.

              If I configure AP1 with another WAP (closer) it keeps connecting to AP2.
              - Pete

              Auto mator
              Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
              Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

              X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

              Comment


              • #37
                For the AP, it seems to remember where it last connected and will continue to use it initially. When this fails it will toggle to the other.

                I updated http://mcsSprinklers.com/mcsTasmota.zip with 5.9.13g. This addressed the SetOption8 issue when using a door sensor. It also contains the multiple DS temp sensor library.

                What I was previously doing with the door was to convert all other commands to a POWER command. This was in the early development when I was trying to get door control via Alexa and wanted to use other words in the recognition text. Since my use was dedicated to the door it did not matter that other commands were not available.

                Comment


                • #38
                  Thank you Michael.

                  I do not see the little upload base file (mcsTasmotaMinimal.bin) to update OTA to first in the ZIP file. Looking for an older zip update.

                  Updated

                  Information shows: Program Version 5.9.13g

                  hxxp://192.168.244.221/cm?cmnd=SetOption8%200
                  RESULT = {"SetOption8":"Off"} Works: "Address":"280D7E5B04000049", "Temperature":26.4}}, "TempUnit":"C"}
                  Last edited by Pete; August 7th, 2018, 02:47 PM.
                  - Pete

                  Auto mator
                  Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
                  Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

                  X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

                  Comment


                  • #39
                    Thank you for fixing this Michael.

                    Been changing all of the defaults via the web commands. Noticed a save to dynamic flash versus static flash....don't understand that piece.

                    Wanting that the defaults stick with a cold boot...think that this works anyhow....changed the following so far:

                    1 - time zone
                    2 - NTP server
                    3 - AP1 and AP2 default names - have not figured this out yet...right now it defaults to: Anthem and U
                    4 - default to F (done a while ago)
                    5 - Mosquitto client name default is: (MCS_44BDAC) * Want to change this
                    6 - Topic = %topic% (Irrigation) * Want to change this to say GarageDoor
                    7 - Host (192.168.0.30) * Want to change this to my MQTT broker default IP

                    Going baby steps here changing one at a time then doing a cold boot to make sure it sticks.

                    Not sure though that I can change the default stuff from user_config.h.

                    Noticed a bit of a delay here when garage door is open. IE: Omni Connected GDO zone triggers almost immediate TTS that garage door is open while the SonOff triggers GDO open TTS after the door is shut.
                    Last edited by Pete; August 8th, 2018, 07:19 AM.
                    - Pete

                    Auto mator
                    Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
                    Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

                    X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

                    Comment


                    • #40
                      I am not a power user for Tasmota, but my understanding is that "static" flash is a one-time write where the user_config.h settings are set. You need to compile from source to get these. Once flashed they do not change, but I think the Reset browser option may do it or a setting in user_config.h to overwrite prior "static" flash during initialization.

                      Topic and Host have browser setup options and likely Console commands as well. In my case I overwrite %topic% with the actual name I want during browser setup. I never change it in source compiles.

                      AP1 and AP2 are problematic for fresh flashing because this is the access mechanism without a UART attached. The button pushes to have Tasmota setup a server at 192.168.4.1 is needed.

                      Once settings are changed via Console, or whatever, they become part of "dynamic" flash. They will persist over power cycles.

                      I suggest looking into the Console Backlog command. This lets you copy/paste from a text file into the Console window a series of commands. Create the text file offline and then reuse it each time a new device is flashed.

                      Comment


                      • #41
                        Thank you Michael. Will give it a try using the console backlog command.
                        - Pete

                        Auto mator
                        Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
                        Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

                        X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

                        Comment


                        • #42
                          Purchasing a couple more of the SonOff devices. With these will just be installing labled terminals on the cover so I do not have to open them up. Purchased a box o terminals earlier. It is easy to drill tiny terminal holes (and glue terminal). on the cover and just solder the inside leads to the motherboard.

                          Next endeavor here is a small footprint outdoor LED power supply / Sonoff switch - all DIN mounted using the SonOff basic relay and single DIN Meanwell PS.

                          This is an upgrade to using multiple Meanwell DIN mounted 12 PS / 1 UPB relay switch for all of the Meanwell PS's.

                          Click image for larger version

Name:	sonofflandscaping.jpg
Views:	19
Size:	94.4 KB
ID:	1239215
                          - Pete

                          Auto mator
                          Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
                          Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

                          X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

                          Comment


                          • #43
                            I have a quick question. Using the Sonoff basic with tasmota 5.14. I look at the sensors and it lists: AM2301 Temperature and Humidity
                            and AM2302 Temperature and Humidity as supported on the Wiki. But when I use the web interface on the sonoff to configure the gpio 14, it
                            only lists the AM2301. Can I still use the AM2302 (which is what I have)? Do I need to upgrade to tasmota 6.0?
                            Thought I'd ask to see if anyone has tried this or knows, before i experiment with my sonoff and am2302.

                            Thanks
                            Bruce

                            Comment


                            • #44
                              After further searching, I found that the AM2302 in bundled under the AM2301. Not clear on the tasmota wiki.
                              Tried it and it works fine. It is set to centigrade, but setting SetOption8 to 1 will give fahrenheit.
                              Thought I would just put this here in case anyone else has the same question

                              Comment


                              • #45
                                Thank you Bruce.

                                I was going to give one of the AM series of combo sensors next. Here have only tinkered with the DS18B20 Maxim sensors.

                                Used the tiny arduino boards with an LED and resistor built in for my first two Sonoff Wifi models and very old AAG,

                                Midon and Hobby board sensors that were mounted on a little pc board.

                                Thinking that this is just an upgrade to the AM2301 sensors.


                                - Pete

                                Auto mator
                                Homeseer 3 Pro - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e 64 bit Intel CPU - Mono 5.20
                                Homeseer Zee2 (Lite) - 3.0.0.534 (Linux) - Ubuntu 18.04/W7e BeeLink 4Gb BT3 Pro - Mono 5.20

                                X10, UPB, Zigbee, ZWave and Wifi MQTT automation.

                                Comment

                                Working...
                                X