Ports

I've updated the code.

If you want a more thorough implementation of the configuration logic, I could probably provide one within the next few days. Do you have any requirements for PR's that span more than 1 line of code?