logo elektroda
logo elektroda
X
logo elektroda

Tasmota replacement for BL602, programming, pairing with Home Assistant, now with OTA working!

p.kaczmarek2 118665 485
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
  • #451 21251487
    condivisionedmz
    Level 4  
    I was so excited that I managed to flash it that I just changed the wifi settings. I thought I'd do the rest later...
  • ADVERTISEMENT
  • #452 21251493
    p.kaczmarek2
    Moderator Smart Home
    So maybe you've entered wrong WiFi settings? Do 5 quick power off/on cycles to enter safe mode (revert to access point).
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #453 21251502
    condivisionedmz
    Level 4  
    the problem is that the relay doesn't turn off when pressed, it stays on
  • ADVERTISEMENT
  • #454 21251692
    p.kaczmarek2
    Moderator Smart Home
    I don't understand... you don't need on-board relay to work in order to enter safe mode.

    If you want to enter safe mode in OBK, you need to do 5 quick power off/on cycles of the whole device and NOT of the relay on your device. Unplug your whole device, plug it back, unplug, etc....
    Helpful post? Buy me a coffee.
  • #455 21251734
    condivisionedmz
    Level 4  
    done. Then to enter safe mode I should see the wifi access open? But unfortunately I don't see it...

    PS I tried to flash another sonoff and the same thing happened: I enter the parameters of my wifi (correct!) and BAT the sonoff becomes invisible
  • #456 21257639
    condivisionedmz
    Level 4  
    update: I managed, I don't know how, to make my sonoff 1CH Ewelink Wifi RF Switch Module Inching recognize my home wifi. I'll start from the beginning. After several attempts to flash the device, fearing that I had already lost it, I set bouffalo lav dev cube on bl602, enter the program and set the parameters:

    partition table: ............./BouffaloLabDevCube-v1.9.0/chips/bl602/partition/partition_cfg_2M.toml
    firmware: .........../OpenBL602_1.17.741.bin
    boot2: ............./BouffaloLabDevCube-v1.9.0/chips/bl602/builtin_imgs/boot2_isp_bl602_v6.6.2/boot2_isp_release.bin

    I connect the device with the adapter to the PC, click on refresh, set chip erase to true (delete the old firmware), click on open uart and then click on create&download.

    I unplug everything, connect the sonoff directly with a USB cable, then from my smartphone (the PC did not connect) I enter the BL602 wifi (to connect you have to wait for the bl602 wifi to give the message internet not available!!!) and open the 192.168.169.1 page. I enter the menu and set the various parameters, except the wifi!!!!

    on module configuration I set p14 on rel to control the relay remotely. (I was unable to set the physical button on the device)

    I configure the MQTT parameters, configure Short Name and Full Name, go to Home and click on Restart.

    After a couple of minutes I connect to the new wifi (it takes the name of the device), I take courage, re-enter the SSID and password of my WIFI, click on SUBMIT, cancel and recheck the data 5 times and then click on OK. With little confidence I enter the menu of my router to search for the sonoff among the devices connected to the WIFI and finally I see it on 192.168.0.101. Now I just have to figure out how to make it recognize the various GPIO for any sensors.

    THANK YOU ALL!

    Added after 2 [hours] 13 [minutes]:

    unfortunately it was a flash in the pan. The device is unreachable again, the wifi is too unstable. I'm going back to the old ESP8266 modules
  • #457 21257879
    divadiow
    Level 34  
    Out of interest is your AP/ router set to WPA2/WPA3? If yes, is the BL602 stable with it changed to WPA/WPA2 only?
  • #458 21257924
    p.kaczmarek2
    Moderator Smart Home
    This sounds like power supply issue. How do you power your BL602 module? Maybe you have a faulty capacitor?

    Or maybe a bad solder joint?
    Helpful post? Buy me a coffee.
  • #459 21257942
    condivisionedmz
    Level 4  
    I tried with a couple of chargers and USB cables. I didn't do any soldering, and the same thing happens on two twin devices. Now the router's wifi practically doesn't see them anymore...
    the two sonoffs have a small antenna for RF reception. I think I'll try to eliminate it, maybe the wifi power will gain something....
  • #460 21258742
    condivisionedmz
    Level 4  
    I became aware of their delays on the wifi connection to the router (after 5 minutes they connect ...) and I took back in hand the 2 sonoff with bl602 module. The new little problem: I can not assign a fixed IP to the two devices because the router always sees them with the same client name and same MAC address. I tried to change long name, short name and the MAC from the menu but nothing, my router does not recognize the new values.
    ____________________
    update for Sonoff 1CH Ewelink Wifi RF Switch Module Inching:
    PIN14 / REL / 1
    PIN21 / Btn / 1

    PIN7 (RX) dinput
    PIN16 (TX) dinput
    PIN12 ( GPIO14? ) dinput
  • #461 21261016
    condivisionedmz
    Level 4  
    all solved! the problem was that I had not entered the fourth parameter in the dts entry.
    Software interface for device configuration with firmware, partition table, and other settings options.

    Pratically the router was unable to assign the correct Mac Address to the device and the wifi went into confusion. Now it takes it immediately, even powered by a normal usb charger. Now I just have to configure the contact sensor.
    Thanks again for the help!!
  • #462 21286241
    XJ_
    Level 11  
    For me, the BL602 only works on WPA/WPA2, if I set WPA2/WPA3 on the router /Grandstream GWN7615 + GWN7624/, the BL602 does not connect at all (I use a hidden SSID). I tried to reflash boot (6.6.2), dts (40M), but only the Mac address changed, WPA2/WPA3 connection does not work.
    I would need to solve the following:
    - Has anyone working WPA2/WPA3 with hidden SSID on BL602?
    - How to change the Mac address back - the change in OBK does not affect it.
  • #463 21286249
    divadiow
    Level 34  
    XJ_ wrote:
    Has anyone working WPA2/WPA3 with hidden SSID on BL602?


    this seems to be a known issue with the SDK version used to build OBK I believe. WPA2/3 has not worked before.

    XJ_ wrote:
    How to change the Mac address back - the change in OBK does not affect it.


    try this: https://www.elektroda.com/rtvforum/topic3930622-30.html#21263084

    specifically, my addition to the post after 23 minutes
  • #464 21286387
    XJ_
    Level 11  
    divadiow wrote:
    try this: https://www.elektroda.com/rtvforum/topic3930622-30.html#21263084

    specifically, my addition to the post after 23 minutes


    @divadiow Thanks a lot.

    I can confirm that uploading DTS using only the "M" value then the BL602 uses the MaC from "ap_mac_addr".

     mac {
     mode = "F";
     sta_mac_addr = [C0 50 43 C9 00 44];
     ap_mac_addr = [C0 50 43 C9 00 33];
     };


    When "M", "B" or "MFB" is used, the MaC address of the device is used.

    mac {
     mode = "M";
     sta_mac_addr = [C0 50 43 C9 00 44];
     ap_mac_addr = [C0 50 43 C9 00 33];
     };


    Unfortunately, in all settings I've tried, the MaC setting in OBK has no effect on this.

    Added after 6 [minutes]:

    divadiow wrote:
    this seems to be a known issue with the SDK version used to build OBK I believe. WPA2/3 has not worked before.

    That's not good news :(
    So I'll have to use Beken again and the BL602 goes in the drawer behind the RTL8710 for now ;-)
  • #465 21286410
    divadiow
    Level 34  
    Indeed. The SDK version being to blame is an assumption though, I don't know what would be involved to incorporate the latest code. A lot of work I guess. I do recall seeing a lot more mention of "wpa3" in the latest code vs OBK BL SDK.

    Added after 1 [minutes]:

    https://www.elektroda.com/rtvforum/topic4024917-30.html#21030549

    Added after 3 [minutes]:

    I might see if using the latest WiFi driver is possible without much effort. My coding skills are woeful though
  • #466 21286538
    XJ_
    Level 11  
    divadiow wrote:
    this seems to be a known issue with the SDK version used to build OBK I believe. WPA2/3 has not worked before.

    That's not good news :(
    So I'll have to use Beken again and the BL602 goes in the drawer behind the RTL8710 for now ;-)
  • #467 21290296
    lukasz06
    Level 10  
    >>19992780 .
    I recently got my hands on a water/gas valve from Sonoff with this chip. I looked for a replacement for the ESP, but couldn't find one
    Wireless automatic ball valve Works with eWeLink
    https://a.aliexpress.com/_EvmtmM9
    Wireless ball valve Sonoff compatible with eWeLink app. .
  • #468 21291304
    p.kaczmarek2
    Moderator Smart Home
    >>21290296 What does this device look like inside? Do you have any pictures? What module from BL602 is in there?
    Helpful post? Buy me a coffee.
  • #469 21291323
    lukasz06
    Level 10  
    >>21291304 Close-up of an open electronic device mechanism showing a circuit board and wires. A printed circuit board with electronic components on a denim fabric background. Close-up of an electronic circuit on a blue PCB labeled CZC20S. .
    Unfortunately the valve died after 3 days, I sent it back for a claim. Unfortunately I have no more pictures
  • #470 21291349
    p.kaczmarek2
    Moderator Smart Home
    Interesting, I initially thought it was the CBU footprint, but it doesn't fit.
    Helpful post? Buy me a coffee.
  • #471 21294737
    maystero
    Level 24  
    I accidentally bought a MagicHome module from BL602 on Ali. In my search for information on the device I purchased, I came across this very thread. I managed to reprogram the chip and something started working there. I even managed to connect to the HA using MQTT. However, I noticed that the reprogrammed chip works somehow strangely. After powering up, after a short time after startup, the chip stops responding to ping.Interestingly, however, the WEB interface works.
    Code: C / C++
    Log in, to see the code
    .

    Is it only with me that it works like this? Or is there something wrong with my copy? Maybe I programmed something wrong.... Here is a screen shot of the settings:
    Screenshot of Bouffalo Lab Dev Cube software used for programming the BL602 module. .

    Additionally, I noticed that the MQTT communication is also limping along....
    The Drimmer was detected as a switch, and no sensor data refreshes.
    Screenshot displaying the control and diagnostics panel for the MagicHome module with BL602. .

    Is my BL602 defective?

    edit, after I published the post, I noticed that there was a soft update: Built on Nov 8 2024 20:04:01 version 1.17.767
    After the update, no improvement.
  • #472 21303797
    zack3
    Level 2  
    >>21291349 I currently have one of these exact devices that I'm trying to convert to openbeken.
    If you'd like any additional photos or info, let me know.
    Can I assume the pinouts are all the same from a programming perspective?
    Is there anything I should be most weary of when flashing?
  • #473 21305032
    zack3
    Level 2  
    Hey All,
    I recently purchased this "Smart" Valve from Aliexpress
    Smart WiFi valve with remote control function
    I opened it up to flash new firmware to de-cloud it. Found it was a BL602, my first time coming across one. This thread has been absolutely fantastic.

    Ultimately I want to control using openhab, I will likely use MQTT to do so.

    I have managed to flash the software, overcome the wi-fi, and mapped what I think are the correct pins. (See Below)

    Image of a circuit board with pin labels next to a BL602C/E QFN32 layout diagram.

    I however Can't seem to get the motor to turn (to close/open the valve).

    From what I've been able to tell, the RZ7888 (motor driver) is connected via GPIO 14, and should close/open. According to this table I got from the datasheet.

    Pin function table and truth table for a valve from Aliexpress.

    I've tried using the pin finder to turn all of them from low to high, but it didn't seem to have any effect. Any assistance in trying to figure out what might be the best next course of action in trying to decipher this would be much appreciated. As I'm only a hobbyest.

    regards,
    Zack
  • #474 21305127
    p.kaczmarek2
    Moderator Smart Home
    Are you powering BL602 externally from the programmer? Motor control will only work if powered via device power supply.

    Can you show some photos from inside? Have you tried checking pins with multimeter?

    Added after 1 [minutes]:

    Also, this motor control requires two pins, not just one. So it could by GPIO with some other pin.
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #475 21307656
    lukasz06
    Level 10  
    >>21305127 .
    There may be a replacement for this chip, I would like to upload Suple
  • #476 21341967
    wojtekrz
    Level 11  
    Hi,
    I recently bought two simple switches (like Sonoff Basic) with BL602. I managed to flash them and configure WiFi and MQTT to connect to HomeAssistant. But the problem is that I can't connect both to AP simultaneously. When I turn them on separately (either first or second) everything is ok, I can see IP assigned in the router and I can see it configured in Tasmota. But it's impossible to connect them both to AP. Every time one of them is not recognizable.
    I tried to set up static IP, and change the MAC, and unfortunately, nothing helped.
    Did anybody have a similar problem? Any idea how to solve it?
  • #478 21346844
    wojtekrz
    Level 11  
    >>21342476 Thanks for your help. Unfortunately while soldering, the BT pad fell off from the PCB... I assume ther's no chance to upload DTS files via OTA?
  • #479 21347327
    p.kaczmarek2
    Moderator Smart Home
    Please show a detailed photo of the PCB, do you mean that the pad fell of directly from BL602 module, or from the mother board?

    Can you solder a wire directly to QFN pad?

    I could try...
    Helpful post? Buy me a coffee.
  • #480 21347388
    wojtekrz
    Level 11  
    From the motherboard. I don't have the appropriate soldering skills to solder the wire directly to the uC. I'm attaching the photos of both sides of the mb.
    Circuit board with an integrated circuit labeled SM-028_V1.3, with connected wires in various colors. Photo of the back of a printed circuit board with soldered wires.

Topic summary

The discussion revolves around the development and integration of firmware for devices based on the BL602 chip, particularly focusing on flashing procedures, MQTT connectivity, and Home Assistant integration. Users share their experiences with various models, including Magic Home LED controllers and Sonoff devices, detailing successful flashing processes, issues with WiFi connectivity, and the need for stable power supplies. The conversation also touches on the implementation of features like OTA updates, Alexa integration, and the challenges faced with different firmware versions. Users report on the behavior of their devices post-flashing, including boot loops and MAC address duplication issues, while seeking solutions and sharing troubleshooting tips.
Summary generated by the language model.
ADVERTISEMENT