Added multiport module & did code cleanup.