FAQ
TL;DR: Adding a DHT22 or DS18B20 sensor to the T34/BK7231N gives ±0.5 °C room-temperature readings and relay control; “such modifications are very easy” [Elektroda, p.kaczmarek2, post #21095677] Use GPIO14 (S2) or GPIO9/11, disable PowerSave, and keep a 4.7 kΩ pull-up [ASAIR AM2302 Datasheet].
Why it matters: One low-cost board can now sense, decide and switch your heating without cloud dependency.
Quick Facts
• BK7231N logic level: 3.3 V [Beken Datasheet].
• DHT22 range −40 – 80 °C, ±0.5 °C accuracy [ASAIR AM2302 Datasheet].
• DS18B20 supply 3.0 – 5.5 V, needs 4.7 kΩ pull-up, 12-bit resolution [Maxim DS18B20 Datasheet].
• OBK HTTP: /cm?cmnd=channels returns JSON with sensor values [Elektroda, 21095708]
• T34 relay rating: typical SRD-05 10 A @ 250 VAC [SONGLE Datasheet].
Which T34/BK7231N pins do I use for a DHT22 sensor?
S1 provides GND and S2 goes to GPIO14 (CPU pin 11); add 3.3 V from VCC to the sensor and remove the on-board pull-up/cap at BC8 [Elektroda, Tilator, post #21095664]
Can the external switch header be reused without cutting traces?
Yes. The 3-pin S1/S2 header spacing matches DHT22/DS18B20 leads. Slide the sensor pins in and jumper VCC from the nearest 3.3 V pad [Elektroda, Tilator, post #21095664]
How do I wire a DS18B20 correctly?
- Connect VDD to 3.3 V, GND to GND. 2. Join the data pin to GPIO9 or GPIO11. 3. Place a 4.7 kΩ resistor between data and VDD. The sensor needs external power; parasitic two-wire mode fails on this board [Elektroda, divadiow, post #21238822]
Why does DS18B20 show –1.26 °C or stay offline?
OBK reports –1.26 °C when no response is received. Causes: missing 4.7 kΩ pull-up, PowerSave enabled, or supply below 3 V. Tilator restored readings after raising VDD to 4.75 V and disabling PowerSave [Elektroda, 21238824]
How can I fetch the temperature over HTTP?
Send http:///cm?cmnd=channels. OBK returns JSON with each channel, e.g., "Temperature":23.6 [Elektroda, p.kaczmarek2, post #21095708]
How do I auto-switch the relay when the room gets cold?
Create /autoexec.bat:
- startDriver DHT22 14
- if $CH1<20 then backlog power 1; delay 600; power 0
Upload and reboot; the script re-runs every minute [OBK autoexecExamples].
Does PowerSave affect 1-Wire sensors?
Yes. PowerSave 1 lengthens bus timing and can block DS18B20 discovery. Keep PowerSave 0 for reliable readings [Elektroda, p.kaczmarek2, post #21237883]
Is the T34 safe to touch after the mod?
No. The board lacks mains isolation; GND may sit at live potential. Insulate the sensor and wiring with heat-shrink or epoxy and work only when unplugged [Elektroda, p.kaczmarek2, post #21095677]
Can I flash OBK without removing the MCU?
Yes. Solder RX to BR4, press a sharp probe on TX, and use 3.3 V UART at 115 200 bps. Tilator flashed this way successfully [Elektroda, 21095664]
What other peripherals can the board accept?
An IR receiver on any free GPIO enables remote control, but it may need PowerSave off and a clean 3.3 V rail [Elektroda, p.kaczmarek2, post #21095677]
What accuracy should I expect?
DHT22: ±0.5 °C, 2 %RH. DS18B20: ±0.5 °C from –10 °C to +85 °C [ASAIR AM2302 Datasheet; Maxim DS18B20 Datasheet].
Edge case: Log shows “DHT checksum failure!” every second—what now?
Checksum errors point to long leads or noise. Shorten wires, add a 100 nF cap across VCC-GND and keep leads under 20 cm. Replace if humidity has corroded pads [Elektroda, Tilator, post #21348605]
Comments
Yes, this is a good idea. With OBK , such modifications are very easy. We've did similiar thing with DHT11 on our YT channel: https://www.youtube.com/watch?v=KEjOPuYd3CE The second modification that... [Read more]
You are right and I'm aware of it. The cap you can see is only there to demonstrate the connection. Final installation needs some glue between the parts. Can you tell me is it possible to read the temperature... [Read more]
I think our OBK channels command should work: http://192.168.0.163/cm?cmnd=channels Please try it out and let me know if it works for you. [Read more]
Thanks. [Read more]
Hello again, There seems to be DS18B20/DS1820 support available now. Thank you again. This was good add on it. I have not tested it yet, but will do it as soon as I have a bit spare time. [Read more]
I'm eager to hear some feedback! Please try and let know. PS: Don't use PowerSave 1 with it. [Read more]
@tilator does your DHT22 give readings still with the latest builds? I don't suppose you ever took a pic of the PCB inside the casing? I'm just curious about my one which doesn't seem to work with OBK... [Read more]
At least version version 1.17.661 works fine. Pictures are available if they anyhow help you. [Read more]
Now I had time to try it, but DS18B20 sensor does not come available. There are at least two different physical configurations to install this sensor. Which one should I use? I installed it by connecting... [Read more]
I've always done it like this: https://obrazki.elektroda.pl/7110850100_1727165493_thumb.jpg seen in my pic here https://www.elektroda.com/rtvforum/viewtopic.php?p=21158431#21158431 [Read more]
I did try that too without good outcome. I have this T34 SOC and I try to use GPIO 11 which is UART TX. Might there be some setting wrong related to that? Added after 5 [hours] 11 [minutes]: Seems... [Read more]
So, to sum up, you are using GPIO 11 which is UART TX and: - DHT22 works there - LED (to blink it, as Rel role or LED role) works as well - but DS18B20 doesn't work? Added after 34 : Maybe you... [Read more]
Yes, and on top of thet GPIO 9 works with DHT22 too but not with DS18B20. How can I find out if it's on? [Read more]
I thought powersave 1 was OK now with DS1820? https://www.elektroda.com/rtvforum/viewtopic.php?p=21190145#21190145 @max4elektroda [Read more]
Can you tell does the driver give sensor enough power by pulling GPIO line up or does it still need other external power and pull up resistor? [Read more]
I took one of those mini relays having BK7231N and connected DS18B20 to it using GBIO 9. Still no temperature reading. If I add sensor usin WEB UI there happens nothing. No loaded driver listed on front... [Read more]
still requires external power afaik so, 3.3v, gpio and ground. 4.7kohm between data and vcc. [Read more]
Thanks. A bit new info: I got some readings from BK7231N device and the tric was to give it a bit higher voltage. 4,75V. Even thogh the values it gove were a bit high somewhere above 33 C while actual... [Read more]
What's this in log: Info:SENSOR:DHT start, pin is 6 Info:SENSOR:DHT checksum failure! it keeps repeting about once every second. [Read more]