Changed from Switch/case to if/elseif to save some runtime ram
New comments and minor fixes
Merge pull request #22 from Damme/patch-1

Changed from Switch/case to if/elseif to save some runtime ram