sms stack implementation