before not using same delay loop for ped cycle