@crami25
Thank you crami25
I thought that I have to use the RELAY-Unit-Component and the PbHub.Unit-Component simultaneously in UIFlow.
But as you told me, I just have to set the Outputs on the PbHub to 0 oder 1 :-)
No need of the RELAY-Unit-Component in software.
from m5stack import *
from m5ui import *
from uiflow import *
import unit
setScreenColor(0x222222)
pbhub0 = unit.get(unit.PBHUB, unit.PORTA)
while True:
pbhub0.digitalWrite(0, 0, 1)
wait_ms(100)
pbhub0.digitalWrite(1, 0, 1)
wait_ms(100)
pbhub0.digitalWrite(2, 0, 1)
wait_ms(100)
pbhub0.digitalWrite(3, 0, 1)
wait_ms(100)
pbhub0.digitalWrite(4, 0, 1)
wait(1)
pbhub0.digitalWrite(0, 0, 0)
wait_ms(100)
pbhub0.digitalWrite(1, 0, 0)
wait_ms(100)
pbhub0.digitalWrite(2, 0, 0)
wait_ms(100)
pbhub0.digitalWrite(3, 0, 0)
wait_ms(100)
pbhub0.digitalWrite(4, 0, 0)
wait(1)
Great it works!
Best regards Thomas