more refactoring from hand-to-function-parsing and reworked SMS to parse out actual SMS length