I searched for a while, but I cannot find the formatting of the IRC protocol message. For example, if I wanted to enter a channel, the client could send "enter the channel nickname" or something in this direction. Somebody knows?
Take a look at the RFC: http://www.irchelp.org/irchelp/rfc/rfc.html
Or open your favorite IRC client and use the sniffer to see what the incoming / outgoing packets look like.
I assume you are asking how to join the channel:
http://www.irchelp.org/irchelp/rfc/chapter4.html#c4_2_1
You just send: JOIN #channel\r\n
JOIN #channel\r\n