I did that firmware for my klipper project
Simple firmware for Biqu relay with delays for startup and shutdown
startup delay is 60sec
shutdown delay is 30sec
after turn off can return to on state
only on/off function, without short circuit detection
For uVision compiler setup use that video https://youtu.be/nHCjFw2TS4M?feature=shared
microcontroller STC15W204S
Keil C51 uVision https://www.keil.com/demo/eval/c51.htm
STC ISP programming software (v6.91) https://www.stcmicro.com/rar/stc-isp6.91.rar