The TM30 is the form you (or the property owner) submits to immigration no later then 24 business hours after you stay in a property. If you don't file the TM30, you'll be fined 1,600 THB with a max of 2K THB.
Here's a video (in Thai, subtitled in English) from the Thai government about the importance of the TM 30
************************************************************
Here's an article in the Bangkok Post about the TM30
***********************************************************************************************
*****
75/thailands-tm30-revisited-clarifying-the-confusion-
Some immigration offices no longer require it; but Pattaya does.