Add a debug function that handles debug levels.
Give the listen port an argument.

This also makes the default port 8668.