Fixed issue and added debug features to TESTCNTRL.VHD