Looking for some help with this long life battery powered smoke detector. I have flashed the latest OpenBeken and have added an autoexec.bat. Two presses of the test button should power up the CB3S module and transmit the battery level (Low Mid, High), whether the test is successful and whether there is a fault or not. This works successfully once I keep power on the CB3S module but without doing this the MCU (BA45F5250) seems to only power the module for about 7 seconds which doesn't seem to be long enough for the CB3S to connect to the WIFI. This does work with the original Tuya firmware. Smoke detection works successfully with OpenBeken but would like get the testing part to work as well.
startDriver TuyaMCU
tuyaMcu_setBaudRate 9600
startDriver tmSensor
// smoke detect, 0 or 1, dpID 1 type enum (4)
setChannelLabel 1 Smoke
setChannelType 1 ReadOnly
linkTuyaMCUOutputToChannel 1 4 1
// Test Result, "checking","check_success","check_failure","others, dpID 9 type enum (4)
setChannelLabel 9 Test
setChannelType 9 ReadOnly
linkTuyaMCUOutputToChannel 9 4 9
// Fault, dpID 11, fault, serious_fault, sensor_fault, probe_fault, power_fault
setChannelLabel 11 Fault
setChannelType 11 ReadOnly
linkTuyaMCUOutputToChannel 11 5 11
// Battery state enumeration, dpID 14 type enum (4)
setChannelLabel 14 Battery
setChannelType 14 ReadOnlyLowMidHigh
linkTuyaMCUOutputToChannel 14 4 14
// Mute, dpID 101
setChannelLabel 15 Mute
setChannelType 15 Toggle
//link dpid 101 to channel 15
//linkTuyaMCUOutputToChannel dpId verType tgChannel
linkTuyaMCUOutputToChannel 101 1 15
The module only ever seems to be able to send the product query information before the power is turned off by the MCU
Sent by WiFi module
55 AA 00 01 00 00 00
HEADER VER=00 Product LEN CHK
Received by WiFi module:
55 AA 00 01 00 24 7B2270223A2266707276656A61616262326834636730222C2276223A22312E302E30227D 7A
HEADER VER=00 Product LEN {"p":"fprvejaabb2h4cg0","v":"1.0.0"} CHK
The MCU replies with the product information but nothing further seems to happen.