logo elektroda
logo elektroda
X
logo elektroda
ADVERTISEMENT
  • Because of the, from Sonoff advertised, API, I ordered from Appla.cy the B05-BL-A60 bulbs.
    B05-BL-A60 Sonoff Teardown B05-BL-A60 Sonoff Teardown

    Each one has a price of around 11€. Take care, I am talking here about the B05-BL-A60 NOT the B05-B-A60 which has a different chip, different led driver and no API!

    Surprised of the energy class F, I tested the API which is more or less useless if you have a need of some more devices and if you don’t want to struggle with different ID's for each single device.

    After opening the bulb, B05-BL-A60 Sonoff Teardown you will find the LED plate with an BP5758 LED Driver. THE BP5758 seams to be an I2C Tuya Driver. Removing the LED Plate, you will find the power supply and the WIFI components:

    B05-BL-A60 Sonoff Teardown

    After disassembling, all the necessary pins are easily accessible.

    3.3V
    Ground
    TX
    RX
    Boot.

    There is an easy description on how to flash it, on:
    https://www.elektroda.com/rtvforum/topic3889041.html
    More difficulty’s I had to find the proper software to flash the chip. Finally found the tools inside the SDK.
    https://github.com/openshwprojects/OpenBK7231T_App
    Find the SDK folder for BL602 and have a look into tools...

    The firmware do not support the BP5758 yet, but the work is in progress. When I flash the next chip, I will be prepared and will enrich this teardown with more links, better pictures and a step by step description.

    Cool? Ranking DIY
    About Author
    Thom4Fun
    Level 2  
    Offline 
    Thom4Fun wrote 4 posts with rating 7. Been with us since 2022 year.
  • ADVERTISEMENT
  • #2 20264983
    p.kaczmarek2
    Moderator Smart Home
    Thank you for teardown.
    The BP5758D driver is supported, but was not enabled for BL602. I have enabled it so you can test now again.
    I have also improved some things and did several bugfixes for that platform.
    Remember to try using BP5758D_RGBCW command to test the driver after enabling (BP5758D_RGBCW FF00FF0000).

    EDIT: You might need to wait 1 day more for that. We are resolving something on other platform and release is not yet public.
    Helpful post? Buy me a coffee.
  • #3 20265701
    ACCel
    Level 22  
    And what is this API for? Is it local or normally via cloud?
  • ADVERTISEMENT
  • #4 20273925
    protectivedad
    Level 7  
    p.kaczmarek2 wrote:
    Thank you for teardown.
    The BP5758D driver is supported, but was not enabled for BL602. I have enabled it so you can test now again.
    I have also improved some things and did several bugfixes for that platform.
    Remember to try using BP5758D_RGBCW command to test the driver after enabling (BP5758D_RGBCW FF00FF0000).

    EDIT: You might need to wait 1 day more for that. We are resolving something on other platform and release is not yet public.


    The documentation at:
    https://sonoff.tech/sonoff-diy-developer-documentation-b02-bl-b05-bl-http-api/

    Tells me there is an ota_flash command but it says the largest bin is only 508KB. I'm not familiar with the build tools or I'd try to create a "lite" version. Since you have the experience do you think that it is possible to build a smaller then 508KB firmware that can be used to then write the normal firmware? Or is that just too small?

    That is the way I have done it with my Sonoff MINIR2s.

    Thanks,
  • #5 20274285
    Thom4Fun
    Level 2  
    Hi.

    The API can be used only local. First, you have to bring the device into the DIY mode. Then, you can use a RESTfull API.
    But the API is not very useful. You have to know the ID of the device, which will create a lot of reconfiguration if it needs to be replaced or the IP will change.
    There is a full description at:
    https://sonoff.tech/diy-developer/
    I was in hope to be able to use the API for integrating the devices without open and flashing etc etc, but I gave up. Too much trouble. Including that I was not able to update the Firmware. Therefore, you have to register the device. But I do not like to connect anything to the Chinese cloud at all, because you never know what else will be included in their firmware…

    I am not so well at this time. When I will be back from Hospital, I will spend some more time and reporting here…

    Regards
    Thomas
  • #6 20276360
    Thom4Fun
    Level 2  
    Hello.

    Sorry for the delay, I have some healty problems and have to be back to the hospital on Friday.
    But I give the new version a try on a brand new device, and with luck. The gui shows the LED stuff, but the webapplication not.
    As well, the the gui shows 1 driver loded (BP5758D) total 11. The command BP5758D_RGBCW returns "command not found".

    I put
    BP5758D_CLK on Pin 2 and channel to 1, and
    BP5758D_DTA on Pin 21 and channel to 2.

    Not sure if the channel stuff is needed, but in general it works well. The colors are mistaken, but I am sure that this will easy to correct with BP5758D_RGBCW if implemented. As soon as possible, I will update the teardown with more infos.

    Regards
    Thomas
  • #7 20277075
    protectivedad
    Level 7  
    Thom4Fun wrote:
    Hi.

    The API can be used only local. First, you have to bring the device into the DIY mode. Then, you can use a RESTfull API.
    But the API is not very useful. You have to know the ID of the device, which will create a lot of reconfiguration if it needs to be replaced or the IP will change.
    There is a full description at:
    https://sonoff.tech/diy-developer/
    I was in hope to be able to use the API for integrating the devices without open and flashing etc etc, but I gave up. Too much trouble. Including that I was not able to update the Firmware. Therefore, you have to register the device. But I do not like to connect anything to the Chinese cloud at all, because you never know what else will be included in their firmware…

    I am not so well at this time. When I will be back from Hospital, I will spend some more time and reporting here…

    Regards
    Thomas


    Actually the deviceid is not required. Use curl and point to the url away you go. I'm using openhab with http and exec binding. Works well for turn on, off and setting any of the preprogrammed modes. When it comes to adjusting brightness and color temperature it gets a little complicated (haven't solved it yet).

    If you interested the script I use is:
    Code: Bash
    Log in, to see the code
  • #8 20277330
    Thom4Fun
    Level 2  
    Thank you for the code.
    But in any way you use a Chinese firmware where you never know what’s happen without sniffing the network traffic at any time, you have to register to the cloud to get the new firmware and some other points I don’t really like. Maybe I will give it later on a try.
  • #9 20376848
    Zain00
    Level 10  
    My bulb won't light up.
    I put BP5758D_CLK on Pin 2 and channel to 1
    And BP5758D_DTA on Pin 21 and channel to 2

    I need help please .
  • ADVERTISEMENT
  • #10 20376994
    p.kaczmarek2
    Moderator Smart Home
    @Zain00 , to make sure, is your bulb using BL602?
    Helpful post? Buy me a coffee.
  • #11 20377022
    Zain00
    Level 10  
    p.kaczmarek2 wrote:
    @Zain00 , to make sure, is your bulb using BL602?


    This is my bulb

    B05-BL-A60 Sonoff Teardown B05-BL-A60 Sonoff Teardown B05-BL-A60 Sonoff Teardown

    It seems the chip is the same as what @Thom4Fun has, but mine has only 4 pins to the leds while Thom4Fun has 6 pins

    Edit: I just noticed that I have the B05-BL-A19 model
  • #12 20378329
    Zain00
    Level 10  
    New Update: I reflashed the chip and somehow it works now.
    But I noticed that the brightness has decreased, also the I can dim it further down now with openbeken than what I could with the original firmware.
  • #13 20378355
    p.kaczmarek2
    Moderator Smart Home
    @Zain00 can you show a screenshot from main HTTP page showing version and build date?
    Our contributor @rogere66 recently submitted a patch that greatly increased lighting quality and introduced gamma correction setting (you can even calibrate your device!)
    https://github.com/openshwprojects/OpenBK7231T_App/issues/599

    https://github.com/openshwprojects/OpenBK7231T_App/blob/main/docs/led_gamma_control.md
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #15 20378399
    p.kaczmarek2
    Moderator Smart Home
    Can you try doing this process?
    https://github.com/openshwprojects/OpenBK7231T_App/blob/main/docs/led_gamma_control.md
    Or does it yields "unknown command"? You have yesterdays build, but at the moment I am not sure if it's a build made hours before Gamma Control merge, or after...

    Dodano po 1 [minuty]:

    Oh wait! There is another thing to try!
    BP5758D_Current command!
    This can increase brightness of the LED, but do not set too much values, because you'll shorten their life significantly.

    See:
    B05-BL-A60 Sonoff Teardown
    This command can be executed at runtime, but if you want a permanent setting, then you should put it in "short startup command", so it's executed with every reboot.

    NOTE: when testing, refer to datasheet and start with lowest current values. We don't know which current value used original firmware. So you have to experiment. But don't overdo it! It's better to set lower and lengthen LED lifespan than to set higher and burn them.
    Helpful post? Buy me a coffee.
  • #16 20378565
    Zain00
    Level 10  
    It does give me "NOT found", and I used OpenBL602_1.15.301.bin.
    I did try "BP5758D_Current 0001111" command and I think it's working now.

    Also, as @Thom4Fun said the RGP colors are not accurate
  • #17 20378794
    p.kaczmarek2
    Moderator Smart Home
    Zain00 wrote:
    It does give me "NOT found", and I used OpenBL602_1.15.301.bin.

    It seems your build didn't include that, but don't worry, it's not necessary:
    https://github.com/openshwprojects/OpenBK7231T_App/issues/599

    Zain00 wrote:
    I did try "BP5758D_Current 0001111"

    I think it doesn't support binary notation, only hexadecimal and decimal. You should convert desired value from datasheet to decimal. Right now, you entered a random value (code interpreted it as a decimal 1111, one thousand, one hundred eleven) and lucked out that it works.

    Zain00 wrote:

    Also, as @Thom4Fun said the RGP colors are not accurate

    Did you mean RGB?
    Well, this patch is said to improve it at a lot:
    https://github.com/openshwprojects/OpenBK7231T_App/issues/599
    Helpful post? Buy me a coffee.
  • #18 20379108
    Zain00
    Level 10  
    Thank you, yes I mean RGB. Can I update over the air with BL602 chips ? I read before that it's not available

    One other issue I'm facing, I enabled Flag 12 so the state of the bulb is saved when powred off then on. But once I restart or power the bulb on it gives always blue RGB color.
    Is this a bug or should I enable other Flag ?

    Sory for the many questions, I'm still new to this.
  • #19 20381744
    p.kaczmarek2
    Moderator Smart Home
    Fully working OTA was not present in BL602 SDK we used so it's not yet done. It's on TODO list but BL602 is not as frequent as other platforms.

    Regarding blue bug - it's not expected, I will try to check what's happening.

    Maybe you can mitigate it by setting a preferred predefined color in short startup command?
    Helpful post? Buy me a coffee.
  • #20 20381762
    Zain00
    Level 10  
    That what I did for now using the command "backlog led_dimmer 100; led_temperature 500; led_enableAll 1" and disabling Flag 12
  • #21 20443024
    p.kaczmarek2
    Moderator Smart Home
    Okay so far I can only say that we've programmed the bulb and made a video about it:



    Here is the packaging + manual:
    B05-BL-A60 Sonoff Teardown
    B05-BL-A60 Sonoff Teardown B05-BL-A60 Sonoff Teardown B05-BL-A60 Sonoff Teardown B05-BL-A60 Sonoff Teardown
    B05-BL-A60 Sonoff Teardown B05-BL-A60 Sonoff Teardown
    I will do some more tests soon to figure out the errors.
    Helpful post? Buy me a coffee.
  • #22 20921371
    denisrobel
    Level 3  
    is it possible toflash this device OTA via cloudcutter?
  • #23 20921510
    p.kaczmarek2
    Moderator Smart Home
    I don't think so, as far as I know this device isn't even Tuya?
    Helpful post? Buy me a coffee.

Topic summary

The discussion revolves around the Sonoff B05-BL-A60 smart bulbs, focusing on their teardown and API functionality. Users express concerns about the bulb's energy class F rating and the limitations of the API, which requires device IDs for operation, complicating integration with multiple devices. The BP5758 LED driver is identified as an I2C Tuya driver, and users share experiences with firmware updates, including issues with RGB color accuracy and brightness control. Some users report successful flashing of the device and improvements in functionality, while others seek assistance with specific commands and configurations. The conversation highlights the challenges of using the Sonoff API and the desire for better local control without reliance on cloud services.
Summary generated by the language model.
ADVERTISEMENT