init ok and begin loop