Well, for starters, quit beating yourself up over it.
You went to poomse picnic and got butterflies in your stomach...happens.
But you also noticed, nothing bad happened afterward. You did not get hurt or anything.
There are many ways to relax. One thing for me is when I remind myself that in the grand 9or not so grand) scheme of things tournaments mean absolutely nothing. Win or lose, it's of no consequence.
Second, find what works for you.
Personally I don't watch the people before me do their form. It focuses me on the wrong thing, they mes up I am likely to lose my train of thought.
Of all my hangups, strangely enough I have no problems standing in front of a bunch of people doing mys stuff. Then again I did enough school demos at the local elementary schools....at 6 a day, you can't stay nervous all morning...
Anyhow, number one thing for martial Arts:
BREATHE
grab yourself a beginner tape of yoga and study the breathing technique. I swear belly breathing helps a lot to sooth the butterflies!
meditate if you must, find a good point to focus on, NOT the butterflies.
I know at one grading - for o particular reason - I was so nervous before we started, I felt like throwing up. A bit fresh air and a hug from a friend solved that problem.