Look for Gnokii if using Linux any flavor, or for Gammu if your using Win32 platform. Both includes full C source-code, and protocol descriptions.