I have seen this behavior in some species of frogs. I can come up with four reasons: 1) it is an anti-predator response (the "unken reflex") and the predator can be real or perceived; 2) habitat conditions are not to the frog's liking; 3) an injury or disease affecting the frogs sense of balance or 4) he's trying out for the Olympic gymnastics team
I would change the frog's diet to crickets or night crawlers, it is possible that the meal worms are not of high quality or they disagree with the frog's digestive system.