def btn1_action(): if state == 0: indicator1() TTTruck.loop_record() elif state == 1: TTTruck.loop_reverse() elif state == 2: TTTruck.set_sync_source() elif state == 3: TTTruck.publish_loop()
def _(event): TTTruck.set_sync_source()