First time poster so be gentle 🙂
I've got a pair of wonderwall smart heaters that use tuya. The they have a CBU board in them and I have flashed a few of these before using other people's methods.
How would I go about creating a config for them once there flashed? How would I work out the pinout?
Plan B is to just gut the device and use a ZigBee switch and an external temperature sensor to control them.
Any help would be really appreciated, this forum has saved me so many times already!
Added after 45 [seconds]:
Sorry for the terrible photos, can get better ones tomorrow.
Hello, it should be easy to support that device, I can write a custom driver for you if that's needed, but I need your assistance to know the hardware details.
First of all, do you a have a multimeter? Just a simple one featuring continuity test (beep mode).
I need to know which CBU pins are connected where.
Can you do some kind of sketch, or do annotations on the photo?
Maybe start with relay... or buttons...
Doing a better quality PCB photos (not blurry!) will also work.
Here's the CBU pinout:
Common GPIO, which can be reused as SPI_SCK (Correspond to Pin 11 of the IC)
Common GPIO, which can be reused as SPI_MOSI (Correspond to Pin 12 of the IC)
Common GPIO (Correspond to Pin 20 of the IC)
Common GPIO (Correspond to Pin 18 of the IC)
ADC, which corresponds to P23 on the internal IC (Correspond to Pin 17 of the IC)
UART_RX2, which corresponds to P1 on the internal IC. (Correspond to Pin 28 of the IC)
UART_TX2, which is used for outputting logs and corresponds to P0 of the internal IC (Correspond to Pin 29 of the IC)
Support hardware PWM (Correspond to Pin 24 of the IC)
Support hardware PWM (Correspond to Pin 23 of the IC)
Support hardware PWM (Correspond to Pin 22 of the IC)
Support hardware PWM (Correspond to Pin 15 of the IC)
Support hardware PWM (Correspond to Pin 16 of the IC)
Power supply reference ground
Power supply 3V3
UART_TX1, which is used for transmitting user data and corresponds to Pin 27 of the IC. For the MCU solution, please refer to CBx Module.
UART_RX1, which is used for receiving user data and corresponds to Pin 26 of the IC. For the MCU solution, please refer to CBx Module.
Common GPIO (Correspond to Pin 10 of the IC)
Reset pin, low active (internally pulled high), compatible with other modules (Correspond to Pin 21 of the IC)
Common GPIO (Correspond to Pin 25 of the IC)
Common GPIO, which can be reused as SPI_MISO (Correspond to Pin 14 of the IC)
Common GPIO, which can be reused as SPI_CS (Correspond to Pin 13 of the IC)
Mode selection pin. If it is connected to the ground before being powered on, enter the firmware test mode. If it is not connected or connected to VCC before being powered on, enter the firmware application mode. Correspond to Pin 19 on the internal IC.
@gangle well you can always desolder the CBU... but I assume you want easier route?
Well, okay, then do this: open OpenBK page, and in Configure Device, set few pins to relays, each on different channel, like that:
then try toggling relay on channel 0 (in this case P0 pin) - check if something happens and write down result.
Then try toggling relay on channel 1 (in this case P1 pin) - check if something happens, again, write down result..
Then... do the same for remaining channels.
Write down result.
Then, finally, remove Relay roles from P0 to P4, and add those roles to P5, P6, etc... again, set channels, 0, 1, 2, 3.... and try toggling.
By doing this for each pin, you may determine some of the IO roles. For example, you may be able to determine which pin is buzzer, which is relay (?), which is heater.... it's a brute-force approach, but it works.
BTW, just to be sure - there is nothing under 7-segment display, right? No hidden MCU?
Please report your results here. Futhermore, you could use the same approach for buttons - for example, set each pin role to dInput (or just to Btn) and press and observe for changes in channel (linked channel, channels are used to pair relays and buttons or dInputs ,etc)
I do have the firm wear and that is probably the way to go i think, it seems that the device turns on and off for short bursts to make sure the heater panel doesn't over heat!
I've attached the backup.