did some debugging...not all is done yet