logo elektroda
logo elektroda
X
logo elektroda

On-PCB BK7231N TH01 Battery Temp/Humidity Sensor with SHT30 Sensor - Another Variant

divadiow 2373 13
ADVERTISEMENT
  • #1 21110006
    divadiow
    Level 36  
    Hi

    I won't go mad with detail because it's just another TH01 type battery temperature/humidity sensor that other threads can be consulted on for more intimate detail on this kind of device. Posting so this can be another +1 for the device list.

    This one appears to vary in that it has no module. The BK7231N is soldered directly to the PCB and is accompanied by an SHT30 temperature and humidity sensor.

    TH01 temperature and humidity sensor with attached test wires on a wooden table next to the casing. TH01 temperature and humidity sensor with connected wires on a wooden floor background. User manual brochure for a temperature and humidity sensor. Sensor box with a label containing barcodes and compatibility icons. Wi-Fi temperature and humidity sensor kit, user manual, and reset tool. Close-up of a printed circuit board with a BK7231N chip and other electronic components. Close-up of a PCB with a BK7231N chip. Close-up of a circuit board with a soldered integrated circuit and components. Circuit board with mounted integrated circuit and electronic components.

    The test pads are

    Printed circuit board of a temperature and humidity sensor with BK7231N chip.

    The two unlabelled in the middle are two of these 4 I believe

    Diagram of connections with labeled pins on a circuit board.

    which means there is no readily available UART2_TXD for the output log. The underside of the PCB is plain but for a ground pad.

    Dump attached. Firmware version 1.1.17, which looks to be cloudcuttable. Extracted pin assignments:

    Code: Text
    Log in, to see the code


    and the user params

    Code: JSON
    Log in, to see the code


    The presence of "net_led_pin":"26" in the json but not in the plain text assignment list means Easy Flasher forgot to include P26 for the WifiLED.

    It's good to see the new additions showing

    Code: Text
    Log in, to see the code


    which means we assign the SHT:
    Screenshot of the pin configuration interface for P7 and P8 with SHT3X assignments.

    The alert pin is not yet usable.

    basic autoexec to config battery:

    Code: Text
    Log in, to see the code


    P20 button swapped for DoorSnsrWSleep so the button can wake the device from deep sleep.

    Data table for DoorSensorWithDeepSleep driver.

    Code: JSON
    Log in, to see the code
  • ADVERTISEMENT
  • #3 21110323
    p.kaczmarek2
    Moderator Smart Home
    That's a nice discovery, I haven't seen any such sensor (door/humidity/water) with BK7231 directly on PCB. Is that yet another method used to reduce costs by Tuya?
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #4 21111898
    divadiow
    Level 36  
    A reasonable assumption
  • ADVERTISEMENT
  • #5 21516997
    fernandorpeixeiro
    Level 4  
    Hi and congratulations for your excellent work.

    I've a problem with a sensor, it's like the one posted in the first message.
    It doesn't show temperature nor humidity.
    I've flashed it with openbeken, last version. It shows battery percentage, although I'm feeding it with a lm1117.

    In the log is showing a clear message that states: "Info:MAIN:Driver SHT3X is not known in this build."

    Is there a way to test if sht30 isn't damaged? I'm not using this sensor for a few months, without batteries.

    This is the startup command:
    addEventHandler OnClick 20 startScript this runmeas 456

    init:
    echo "Init driver and powersave "
    startDriver TuyaMCU
    setChannelType 3 toggle
    setChannelType 1 temperature_div10
    setChannelType 2 humidity

    again:
    echo "activate SHT3X Sensor"
    startDriver SHT3X
    setChannel 3 1
    echo "Send some measure"
    delay_s 2
    echo "stop SHT3X driver"
    stopDriver SHT3X
    setChannel 3 0
    echo "wait 10min"
    delay_s 10
    goto again

    runmeas:
    // stopScript ID bExcludeSelf
    // this will stop all other instances
    stopScript 456 1
    echo "Force measurement"
    startDriver SHT3X
    setChannel 3 1
    delay_s 2
    stopDriver SHT3X
    setChannel 3 0
    echo "go back to loop"
    goto again;

    For now I'm only interested in having temp and humidity values, because probably the sensor will be permanently energized, so don't mind about power save modes.

    Thanks for any help.
    Fernando

    Screenshot of system logs, showing channel changes, MQTT connections, and errors related to unknown SHT3X driver.

    Screenshot of the OpenBekenX user interface showing device status information.

    GPIO interface configuration showing a list of pins and their functions.
  • #6 21517270
    max4elektroda
    Level 21  
    SHT3X driver is not enabled in the firmware by default.
    If you have a git account, you can download a version with this driver in the artifacts of
    PR #1601.
  • #7 21517587
    fernandorpeixeiro
    Level 4  
    >>21517270
    Good morning
    Thanks max4elektroda, you nailed it.
  • #8 21614248
    fernandorpeixeiro
    Level 4  
    Hi,
    Today I was trying to connect other Tuya sensor to my Home Assistant setup, and I saw that there was an upgrade. As soon as the upgrade started to roll, the sensor, I have the one above, stopped publishing temperature and humidity.
    On the log was the same that I posted on 5#, I tried to roll back to version "OpenBK7231N_1.18.118.rbl", no luck.
    Can someone get me the ota file with sht3x driver, or explain what am I doing wrong?

    Thanks.
  • ADVERTISEMENT
  • #9 21614257
    p.kaczmarek2
    Moderator Smart Home
    I think that Releases section has _sensors build version of OpenBeken available for download. https://github.com/openshwprojects/OpenBK7231T_App
    Helpful post? Buy me a coffee.
  • #10 21615280
    fernandorpeixeiro
    Level 4  
    >>21614257
    Thanks p.kaczmarek2, by the way, why so many versions? Couldn't they all fit in one single release?
  • #11 21743694
    jacgerri
    Level 2  
    Hi,

    I've the same TH01 as posted in the first message but it doesn't show temperature or humidity.
    Running on Built on Oct 26 2025 04:10:36, version 1.18.206.
    In the log nothing is mentioned about missing driver. I've added in autoexec.bat: startDriver SHT3X

    BK7231T microcontroller pin configuration with functions and values mapped

    But only one driver is loaded

    Screenshot of OpenBK7231N interface showing system status and control buttons

    I took a good look at the sensor and it's an 8-pin GTH30 (https://www.lcsc.com/datasheet/C3010791.pdf) instead of a SHT30, but don't know if I need another driver. All the pins are connected as earlier mentioned (GHT30 pin1 SDA to PWM2/P8 pin 24, and GHT30 pin4 SCL to PWM1/P7 pin 23)


    Close-up of a GTH30 sensor on a green PCB with visible traces and electronic components.


    I've tried it on two others with the same result. I'm curious if one of you faced the same issue and if you have a solution.
    Thanks
  • Helpful post
    #12 21743731
    divadiow
    Level 36  
    SHT30 driver is available in the Sensors release of OpenBeken

    https://github.com/divadiow/OpenBK7231T_App/blob/main/src/obk_config.h#L340

    List of OpenBK7231N binary firmware files with configuration variants

    Not heard of GHT30 before.

    You could swap SHT3X assignment now for SoftSDA and SoftSCL, run startdriver i2c then try scani2c soft command

    do you get an i2c address back like

    Code: Text
    Log in, to see the code


    it looks like SHT3X driver expects 0x44
    https://github.com/openshwprojects/OpenBK7231T_App/blob/main/src/driver/drv_sht3x.c#L16
  • #13 21743974
    jacgerri
    Level 2  
    Yes, brilliant. It cost me days, but this is the solution! Thanks.

    startdriver i2c gave me the feedback that it was loaded; startDriver SHT3X gave me this:

    Driver list in the OpenBK7231N command tool console interface

    So I've flashed the release which you mentioned and I've finally the sensor output.

    IoT device status panel with temperature, humidity, and battery level data

    Thanks again.
  • #14 21743978
    divadiow
    Level 36  
    interesting. Good to know this GHT30 is compatible.

Topic summary

A new variant of the TH01 battery temperature/humidity sensor was presented, featuring the BK7231N chip soldered directly onto the PCB alongside an SHT30 temperature and humidity sensor, differing from previous versions that used a CBU module. The pin assignment matches earlier devices, with some discussion on the alert pin configuration. This design may represent a cost-reduction approach by Tuya. A user reported issues with temperature and humidity readings after flashing the sensor with OpenBeken firmware, noting the log message "Driver SHT3X is not known in this build," indicating the SHT3X driver is not enabled by default. The solution involves using a firmware build that includes the SHT3X driver, available in the artifacts of pull request #1601 on the OpenBeken GitHub repository.
Summary generated by the language model.
ADVERTISEMENT