Function rename
Reorder functions in a sensible manner
Fix premature macro change

This will probably be changed into a function soon.
Abbreviate variable binding