If your pokemon gets confused, press B twice slowly after choosing your attack, but before the birdies appear.